新增消息管理

This commit is contained in:
du 2024-02-06 10:46:11 +08:00
parent 968a86277f
commit 987b1e2016
33 changed files with 1394 additions and 1332 deletions

View File

@ -306,3 +306,14 @@ export function saveUser(data) {
});
}
/**
*-
*/
export function noticePage(params) {
return request({
url: `/admin/notice/noticePage`,
method: "GET",
params:params
});
}

View File

@ -82,7 +82,7 @@
</div>
</div>
<div v-if="tip" class="el-upload__tip">
<div style="display: inline-block">
<div style="display: inline-block;">
<el-alert :title="tip" type="error" show-icon :closable="false" />
</div>
</div>
@ -186,6 +186,8 @@ const beforeUpload = (file) => {
return isTypeOk;
};
const baseUrl = ref(import.meta.env.VITE_UPLOAD_URL);
/**
* 上传文件
*/
@ -204,7 +206,7 @@ const handleUpload = (res) => {
clearInterval(timmer.value);
timmer.value = null;
if (res.data) {
res.data.url = res.data.filepath;
res.data.url = baseUrl.value + res.data.filepath;
res.data.fileType = getFileType(res.data.url);
fileList.value.push(res.data);
emits("onUpdate", fileList.value);
@ -296,12 +298,12 @@ const setFiles = () => {
});
};
watch(
() => props.listPic,
() => {
setFiles();
}
);
// watch(
// () => props.listPic,
// () => {
// setFiles();
// }
// );
onMounted(() => {
setFiles();
@ -310,88 +312,88 @@ onMounted(() => {
<style lang="scss" scoped>
.pic-contaner {
display: flex;
flex-direction: column;
.picture {
flex-wrap: wrap;
display: inline-flex;
.uploader {
width: fit-content !important;
}
.img {
margin-left: 10px;
border-radius: 10px;
margin-bottom: 10px;
border: 1px #999 dashed;
}
.file-content {
display: inline-flex;
flex-direction: column;
align-items: center;
justify-content: center;
position: relative;
.file-name {
font-size: 10px;
padding: 5px;
overflow: hidden;
text-overflow: ellipsis;
display: box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
}
}
.item {
position: relative;
.progress {
position: absolute;
top: 0;
bottom: 0;
right: 0;
left: 0;
transform: translateX(12%) translateY(6%);
}
.mask {
opacity: 0;
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
margin-bottom: 20px;
margin-left: 10px;
border-radius: 10px;
background-color: var(--el-overlay-color-lighter);
transition: opacity 0.3s;
.actions {
width: 100px;
height: 100px;
display: flex;
flex-wrap: wrap;
align-items: center;
justify-content: center;
@include position-center(xy);
span {
width: 50%;
text-align: center;
cursor: pointer;
color: var(--el-color-white);
transition: color 0.1s, transform 0.1s;
&:hover {
transform: scale(1.5);
}
.el-icon {
font-size: 24px;
}
}
display: flex;
flex-direction: column;
.picture {
flex-wrap: wrap;
display: inline-flex;
.uploader {
width: fit-content !important;
}
.img {
margin-left: 10px;
border-radius: 10px;
margin-bottom: 10px;
border: 1px #999 dashed;
}
.file-content {
display: inline-flex;
flex-direction: column;
align-items: center;
justify-content: center;
position: relative;
.file-name {
font-size: 10px;
padding: 5px;
overflow: hidden;
text-overflow: ellipsis;
display: box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
}
}
.item {
position: relative;
.progress {
position: absolute;
top: 0;
bottom: 0;
right: 0;
left: 0;
transform: translateX(12%) translateY(6%);
}
.mask {
opacity: 0;
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
margin-bottom: 20px;
margin-left: 10px;
border-radius: 10px;
background-color: var(--el-overlay-color-lighter);
transition: opacity 0.3s;
.actions {
width: 100px;
height: 100px;
display: flex;
flex-wrap: wrap;
align-items: center;
justify-content: center;
@include position-center(xy);
span {
width: 50%;
text-align: center;
cursor: pointer;
color: var(--el-color-white);
transition: color 0.1s, transform 0.1s;
&:hover {
transform: scale(1.5);
}
.el-icon {
font-size: 24px;
}
}
}
}
&:hover .mask {
opacity: 1;
}
}
}
&:hover .mask {
opacity: 1;
}
}
}
}
:deep(.el-upload--picture-card) {
--el-upload-picture-card-size: v-bind(props.height + "px") !important;
--el-upload-picture-card-size: v-bind(props.height + "px") !important;
}
</style>

View File

@ -17,14 +17,16 @@ import { QuillEditor } from '@vueup/vue-quill'
import '@vueup/vue-quill/dist/vue-quill.snow.css'
import { reactive, onMounted, ref, toRaw, watch } from 'vue'
// import { backsite } from '@/api'
import { uploadFile } from '@/api/file'
const props = defineProps(['value'])
const props = defineProps(['value','id','userId','FileType'])
const emit = defineEmits(['updateValue'])
const content = ref('')
const myQuillEditor = ref()
watch(() => props.value, (val) => {
console.log(toRaw(myQuillEditor.value))
toRaw(myQuillEditor.value).setHTML(val)
// console.log(toRaw(myQuillEditor.value))
// toRaw(myQuillEditor.value).setHTML(val)
content.value = val
}, { deep: true })
const fileBtn = ref()
const data = reactive({
@ -55,8 +57,10 @@ const imgHandler = (state) => {
}
const setValue = () => {
const text = toRaw(myQuillEditor.value).getHTML()
// console.log(text,'text===>');
emit('updateValue', text)
}
const baseImgUrl = ref(import.meta.env.VITE_UPLOAD_URL);
const handleUpload = (e) => {
const files = Array.prototype.slice.call(e.target.files)
if (!files) {
@ -64,8 +68,20 @@ const handleUpload = (e) => {
}
const formdata = new FormData()
formdata.append('file', files[0])
// backsite.uploadFile(formdata)
uploadFile(props.userId,props.id,props.FileType,formdata)
.then(res => {
if (res.data.filepath) {
const quill = toRaw(myQuillEditor.value).getQuill()
const length = quill.getSelection().index
// res
quill.insertEmbed(length, 'image', baseImgUrl.value + res.data.filepath)
//
quill.setSelection(length + 1)
}
})
// uploadFile(formdata)
// .then(res => {
// console.log(res,'formdatares====>');
// if (res.data.url) {
// const quill = toRaw(myQuillEditor.value).getQuill()
// const length = quill.getSelection().index
@ -86,11 +102,11 @@ onMounted(() => {
</script>
<style scoped lang="scss">
:deep(.ql-editor) {
min-height: 170px;
min-height: 170px;
}
:deep(.ql-formats) {
height: 21px;
line-height: 21px;
height: 21px;
line-height: 21px;
}
</style>

View File

@ -3,6 +3,7 @@ import TitleC from "./TitleC/index.vue";
import BaseDialog from './BaseDialog/index.vue'
import CustomUpload from "./CustomUpload/index.vue";
import QuillEditor from "./QuillEditor/index.vue";
import ImageUpload from "./ImageUpload/index.vue";
// import TEditor from "./Editor/index.vue"
export default [TitleC,BaseDialog,CustomUpload,QuillEditor]
export default [TitleC,BaseDialog,CustomUpload,QuillEditor,ImageUpload]

View File

@ -0,0 +1,10 @@
const Layout = () => import('@/layout/index.vue')
export default {
path: 'http://42.193.40.239:8050/',
component: Layout,
meta: {
title: '大数据分析',
icon: 'point',
},
}

View File

@ -38,18 +38,6 @@ export default {
title: '职务管理',
breadcrumb: true,
},
children: [
{
path: 'postdetail',
name: 'post-detail',
component: () => import('@/views/system/post-management/detail-post.vue'),
meta: {
title: '职务详情',
sidebar: false,
breadcrumb: true,
}
},
]
},
{
path: 'role',
@ -155,6 +143,16 @@ export default {
}
},
]
}
},
{
path: 'messageindex',
name: 'messageindex',
meta: {
icon: 'point',
title: '消息管理',
breadcrumb: true,
},
component: () => import('@/views/system/message/index.vue'),
},
]
}

View File

@ -108,6 +108,7 @@ import base from './modules/basemanage';
import trends from './modules/work-trends';
import manage from './modules/work-manage';
import statistic from './modules/statistic';
import bigData from './modules/big-data';
// 动态路由(异步路由、导航栏路由)
let asyncRoutes = [
@ -125,6 +126,7 @@ let asyncRoutes = [
manage,
statistic,
system,
bigData,
]
}
]

View File

@ -28,6 +28,8 @@ export enum FileType {
//道孚
workManagement = 'workManagement',//工作管理
workDynamics = 'workDynamics',//工作管理
message = 'message',//消息管理富文本
messageCover = 'messageCover',//消息管理封面
}
// 文件接口类型
export enum ApiFile {

View File

@ -1,7 +1,7 @@
<template>
<div class="percentage-content">
<div class="content">
<div style="margin-bottom: 16px" class="h-layout space-between h-center">
<div style="margin-bottom: 16px;" class="h-layout space-between h-center">
<div>
<div class="h-layout">
<div class="tool-item" @click="(dialogVisible = true), (form = {}),(readonly=false)">
@ -22,7 +22,7 @@
</div>
</div>
</div>
<div style="width: 30%">
<div style="width: 30%;">
<div>
<el-input
v-model="search"
@ -201,19 +201,19 @@ onMounted(() => {
</script>
<style lang="scss" scoped>
.content {
width: 100%;
// flex: auto;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgba(8, 33, 85, 0.1);
height: 100%;
padding: 0.83333vw;
overflow-y: auto;
overflow-x: hidden !important;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
-o-box-sizing: border-box;
-ms-box-sizing: border-box;
box-sizing: border-box;
width: 100%;
// flex: auto;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgb(8 33 85 / 10%);
height: 100%;
padding: 0.83333vw;
overflow-y: auto;
overflow-x: hidden !important;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
}
</style>

View File

@ -89,7 +89,7 @@
></el-option>
</el-select>
</el-form-item>
<el-form-item label="主要功能:" prop="equfunction" style="width: 100%">
<el-form-item label="主要功能:" prop="equfunction" style="width: 100%;">
<el-input
:readonly="props.readonly"
placeholder="请输入主要功能"
@ -97,7 +97,7 @@
>
</el-input>
</el-form-item>
<el-form-item label="装备照片">
<el-form-item label="工作附件">
<el-upload
class="avatar-uploader"
ref="upload"
@ -113,7 +113,7 @@
<img
v-if="addPostFactorForm.equipPhoto"
:src="addPostFactorForm.equipPhoto"
style="width: 100%; height: 100%"
style="width: 100%; height: 100%;"
/>
<el-icon v-else class="avatar-uploader-icon">
<Plus />
@ -308,15 +308,15 @@ watch(
<style lang="scss" scoped>
.detailForm-content {
margin-right: 30px;
margin-right: 30px;
}
:deep(.el-form) {
display: flex;
flex-wrap: wrap;
// justify-content: space-around;
justify-content: space-between;
display: flex;
flex-wrap: wrap;
// justify-content: space-around;
justify-content: space-between;
}
:deep(.el-form-item) {
width: 47%;
width: 47%;
}
</style>

View File

@ -1,268 +1,22 @@
<template>
<div class="content">
<div class="content-top">
<div
class="danger-bg-01"
:style="{ 'background-color': item.color }"
v-for="(item, index) in dangerlist"
:key="index"
>
<div style="position: absolute">
<div class="danger-left-top">
<img src="@/assets/images/yinhuan.png" alt="" />
<span>{{ item.name }}风险</span>
</div>
<div class="danger-left-num">{{ item.num }}</div>
</div>
<div class="danger-right">
<img class="background" src="@/assets/images/zhuangshi.png" alt="" />
</div>
</div>
</div>
<div class="content-middle">
<div class="content-title">风险统计</div>
<div class="content-middle-danger">
<div
class="middle-danger"
:style="{ 'background-color': item.back, color: item.color }"
v-for="(item, index) in list"
:key="index"
>
<div class="layui-card-header">{{ item.name }}</div>
<div class="layui-card-body">{{ item.num }}</div>
</div>
</div>
</div>
<div class="content-middle" style="height: 22vw">
<div class="content-title">统计表</div>
<div ref="listDangerCon" class="list-listDangerCon"></div>
</div>
</div>
</template>
<script lang="ts" setup>
import { onMounted, reactive, ref, shallowRef } from "vue";
import { getcompanyEntNum } from "@/api/onefile";
import * as echarts from "echarts";
// id
import useUserStore from "@/store/modules/user";
const userStore = useUserStore();
const user = ref(JSON.parse(userStore.userInfo));
const userId = ref(user.value.userId);
const dangerlist = ref([
{ name: "红色", num: 0, color: "#FF6A6A" },
{ name: "橙色", num: 0, color: "#FF9069" },
{ name: "黄色", num: 0, color: "#F2D254" },
{ name: "蓝色", num: 0, color: "#78A5F6" },
]);
const list = ref([
{ name: "检查次数", num: 1971, back: "#FFEBEB", color: "#FF5353" },
{ name: "隐患总数", num: 134, back: "#EEF4FF", color: "#4D82E1" },
{ name: "已整改", num: 121, back: "#E4F4F2", color: "#009688" },
]);
const listDangerCon = ref();
const chart = shallowRef();
const optionWater = reactive({
tooltip: {
trigger: "axis",
},
toolbox: {
feature: {
// dataView: { show: true, readOnly: false },
// magicType: { show: true, type: ['line', 'bar'] },
// restore: { show: true },
saveAsImage: { show: true },
},
},
legend: {
data: ["检查次数", "隐患总数", "已整改"],
},
xAxis: [
{
type: "category",
data: [
"1月",
"2月",
"3月",
"4月",
"5月",
"6月",
"7月",
"8月",
"9月",
"10月",
"11月",
"12月",
],
axisPointer: {
type: "shadow",
},
},
],
yAxis: [
{
type: "value",
axisLabel: {
formatter: "{value} 次",
},
},
],
series: [
{
name: "检查次数",
type: "bar",
tooltip: {
valueFormatter: function (value) {
return value;
},
},
data: [
2.0, 4.9, 7.0, 23.2, 25.6, 76.7, 135.6, 162.2, 32.6, 20.0, 6.4, 3.3,
],
},
{
name: "隐患总数",
type: "bar",
tooltip: {
valueFormatter: function (value) {
return value;
},
},
data: [
2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3,
],
},
{
name: "已整改",
type: "bar",
tooltip: {
valueFormatter: function (value) {
return value;
},
},
data: [
2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3,
],
},
],
});
//echarts
const initCharts = () => {
chart.value = echarts.init(listDangerCon.value);
chart.value.setOption(optionWater);
};
const chartResize = () => {
chart.value.resize();
};
//
const getCompanyEntNum = () => {
let params = {
userId: userId.value,
dataType: 2,
};
getcompanyEntNum(params).then((res: any) => {
dangerlist.value[0].num = res.data.redNum;
dangerlist.value[1].num = res.data.orangeNum;
dangerlist.value[2].num = res.data.yellowNum;
dangerlist.value[3].num = res.data.blueNum;
});
};
// import useUserStore from "@/store/modules/user";
// const userStore = useUserStore();
// const user = ref(JSON.parse(userStore.userInfo));
// const userId = ref(user.value.userId);
onMounted(() => {
initCharts();
chartResize();
getCompanyEntNum();
});
</script>
<style lang="scss" scoped>
.content {
width: 100%;
padding: 20px;
}
.content-top {
width: 100%;
display: flex;
justify-content: space-between;
.danger-bg-01 {
height: 160px;
width: 24%;
border-radius: 5px;
}
}
.danger-left-top {
color: white;
padding: 10px 15px;
img {
vertical-align: -2px;
margin-right: 5px;
width: 20px;
}
span {
font-size: 20px;
}
}
.danger-left-num {
font-size: 52px;
padding: 15px;
color: rgb(255 255 255);
margin-left: 10px;
}
.background {
float: right;
height: 100%;
}
.risk-unit {
font-size: 16px;
color: white;
position: absolute;
right: 8px;
padding-top: 115px;
}
.danger-right {
}
.content-middle {
background: #fff;
border-radius: 6px;
padding: 10px;
margin-top: 20px;
.content-title {
width: 100%;
height: 42px;
line-height: 42px;
color: #333;
border-bottom: 1px solid #f6f6f6;
font-size: 18px;
}
.content-middle-danger {
padding-top: 10px;
width: 100%;
display: flex;
justify-content: space-between;
.middle-danger {
width: 33%;
padding: 10px;
border-radius: 5px;
.layui-card-header {
height: 42px;
line-height: 42px;
font-size: 16px;
}
.layui-card-body {
font-size: 36px;
line-height: 36px;
overflow: hidden;
text-overflow: ellipsis;
word-break: break-all;
white-space: nowrap;
margin: 10px 0;
font-weight: bold;
}
}
}
}
.list-listDangerCon {
width: 100%;
height: 100%;
padding: 20px;
}
</style>

View File

@ -19,8 +19,8 @@ const formType = ref("login");
//
const loginFormRef = ref();
const loginForm = ref({
sysusername: localStorage.login_account || "admin",
syspassword: "guixi2023",
sysusername: localStorage.login_account || "",
syspassword: "",
verCode: "",
verKey: "",
remember: !!localStorage.login_account,
@ -242,7 +242,7 @@ const handleClose = () => {
:src="img"
alt=""
@click="getCode"
style="width: 100%; height: 100%"
style="width: 100%; height: 100%;"
/>
</template>
</el-input>
@ -258,7 +258,7 @@ const handleClose = () => {
:loading="loading"
type="primary"
size="large"
style="width: 100%"
style="width: 100%;"
@click.prevent="handleLogin"
>登录</el-button
>
@ -308,7 +308,7 @@ const handleClose = () => {
:src="img"
alt=""
@click="getCode"
style="width: 100%; height: 100%"
style="width: 100%; height: 100%;"
/>
</template>
</el-input>
@ -342,7 +342,7 @@ const handleClose = () => {
:loading="loading"
type="primary"
size="large"
style="width: 100%; margin-top: 20px"
style="width: 100%; margin-top: 20px;"
@click.prevent="handleReset"
>确认</el-button
>
@ -364,224 +364,224 @@ const handleClose = () => {
<style lang="scss" scoped>
[data-mode="mobile"] {
#login-box {
position: relative;
width: 100%;
top: inherit;
left: inherit;
transform: translateX(0) translateY(0);
flex-direction: column;
justify-content: start;
border-radius: 0;
box-shadow: none;
.login-banner {
width: 100%;
height: 100%;
padding: 20px 0;
.banner {
#login-box {
position: relative;
right: inherit;
width: 100%;
height: 100%;
max-width: 375px;
margin: 0 auto;
display: inherit;
top: inherit;
object-fit: cover;
}
left: inherit;
transform: translateX(0) translateY(0);
flex-direction: column;
justify-content: start;
border-radius: 0;
box-shadow: none;
.login-banner {
width: 100%;
height: 100%;
padding: 20px 0;
.banner {
position: relative;
right: inherit;
width: 100%;
height: 100%;
max-width: 375px;
margin: 0 auto;
display: inherit;
top: inherit;
object-fit: cover;
}
}
.login-form {
width: 100%;
min-height: auto;
padding: 30px;
}
}
.login-form {
width: 100%;
min-height: auto;
padding: 30px;
.copyright {
position: relative;
bottom: 0;
padding-bottom: 10px;
}
}
.copyright {
position: relative;
bottom: 0;
padding-bottom: 10px;
}
}
:deep(input[type="password"]::-ms-reveal) {
display: none;
display: none;
}
.bg-banner {
position: fixed;
z-index: 0;
width: 100%;
height: 100%;
background-image: url(@/assets/images/login-bg.jpg);
background-repeat: no-repeat;
background-size: 100% 100%;
background-position: center;
position: fixed;
z-index: 0;
width: 100%;
height: 100%;
background-image: url(@/assets/images/login-bg.jpg);
background-repeat: no-repeat;
background-size: 100% 100%;
background-position: center;
}
#login-box {
display: flex;
justify-content: space-between;
position: absolute;
top: 50%;
left: 50%;
transform: translateX(-50%) translateY(-50%);
background-color: var(--el-bg-color);
border-radius: 10px;
overflow: hidden;
box-shadow: var(--el-box-shadow);
.login-banner {
position: relative;
width: 450px;
background-color: var(--el-fill-color-light);
overflow: hidden;
.banner {
width: 100%;
@include position-center(y);
height: 100%;
object-fit: contain;
}
.logo {
position: absolute;
top: 20px;
left: 20px;
width: 30px;
height: 30px;
border-radius: 4px;
background: url("../assets/images/logo.png") no-repeat;
background-size: contain;
box-shadow: var(--el-box-shadow-light);
}
}
:deep(.el-input-group__append) {
padding: 0 !important;
}
.login-form {
display: flex;
flex-direction: column;
justify-content: center;
min-height: 500px;
width: 500px;
padding: 50px;
justify-content: space-between;
position: absolute;
top: 50%;
left: 50%;
transform: translateX(-50%) translateY(-50%);
background-color: var(--el-bg-color);
border-radius: 10px;
overflow: hidden;
.title-container {
position: relative;
.title {
font-size: 1.3em;
color: var(--el-text-color-primary);
margin: 0 auto 30px;
font-weight: bold;
}
box-shadow: var(--el-box-shadow);
.login-banner {
position: relative;
width: 450px;
background-color: var(--el-fill-color-light);
overflow: hidden;
.banner {
width: 100%;
@include position-center(y);
height: 100%;
object-fit: contain;
}
.logo {
position: absolute;
top: 20px;
left: 20px;
width: 30px;
height: 30px;
border-radius: 4px;
background: url("../assets/images/logo.png") no-repeat;
background-size: contain;
box-shadow: var(--el-box-shadow-light);
}
}
}
.el-form-item {
margin-bottom: 24px;
:deep(.el-input) {
height: 48px;
line-height: inherit;
width: 100%;
input {
height: 48px;
}
.el-input__prefix,
.el-input__suffix {
:deep(.el-input-group__append) {
padding: 0 !important;
}
.login-form {
display: flex;
flex-direction: column;
justify-content: center;
min-height: 500px;
width: 500px;
padding: 50px;
overflow: hidden;
.title-container {
position: relative;
.title {
font-size: 1.3em;
color: var(--el-text-color-primary);
margin: 0 auto 30px;
font-weight: bold;
}
}
}
.el-form-item {
margin-bottom: 24px;
:deep(.el-input) {
height: 48px;
line-height: inherit;
width: 100%;
input {
height: 48px;
}
.el-input__prefix,
.el-input__suffix {
display: flex;
align-items: center;
}
.el-input__prefix {
left: 10px;
}
.el-input__suffix {
right: 10px;
}
}
}
.flex-bar {
display: flex;
align-items: center;
}
.el-input__prefix {
left: 10px;
}
.el-input__suffix {
right: 10px;
}
justify-content: space-between;
margin-bottom: 20px;
}
}
.flex-bar {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 20px;
}
.sub-link {
display: flex;
align-items: center;
justify-content: center;
margin-top: 20px;
font-size: 14px;
color: var(--el-text-color-secondary);
.text {
margin-right: 10px;
.sub-link {
display: flex;
align-items: center;
justify-content: center;
margin-top: 20px;
font-size: 14px;
color: var(--el-text-color-secondary);
.text {
margin-right: 10px;
}
}
}
}
.copyright {
position: absolute;
bottom: 30px;
width: 100%;
margin: 0;
position: absolute;
bottom: 30px;
width: 100%;
margin: 0;
}
.code {
width: 120px;
width: 120px;
}
.qr-code {
position: absolute;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
bottom: 5%;
padding: 10px 25px;
border-radius: 10px;
right: 5%;
background: #fff;
box-shadow: 0 10px 30px 0 rgb(0 0 0 / 20%);
img {
width: 100px;
margin-bottom: 5px;
}
span {
font-size: 14px;
font-weight: 700;
cursor: pointer;
}
position: absolute;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
bottom: 5%;
padding: 10px 25px;
border-radius: 10px;
right: 5%;
background: #fff;
box-shadow: 0 10px 30px 0 rgb(0 0 0 / 20%);
img {
width: 100px;
margin-bottom: 5px;
}
span {
font-size: 14px;
font-weight: 700;
cursor: pointer;
}
}
:deep(.qr-dialog) {
.el-dialog__body {
display: flex;
flex-direction: column;
align-items: center;
padding-top: 0;
}
img {
width: 300px;
}
span {
font-size: 18px;
font-weight: 700;
margin-top: 10px;
}
.el-dialog__body {
display: flex;
flex-direction: column;
align-items: center;
padding-top: 0;
}
img {
width: 300px;
}
span {
font-size: 18px;
font-weight: 700;
margin-top: 10px;
}
}
.logo-name {
position: absolute;
top: 30px;
left: 44px;
display: flex;
flex-direction: row;
align-items: center;
.img-logo {
width: 587px;
height: 78px;
}
.logo-v {
position: absolute;
top: 30px;
left: 44px;
display: flex;
flex-direction: column;
}
.zw {
margin: 0 0 0 20px;
font-size: 23px;
}
.sysname {
font-size: 30px;
font-weight: bold;
margin: 0 20px;
color: #231916;
}
flex-direction: row;
align-items: center;
.img-logo {
width: 587px;
height: 78px;
}
.logo-v {
display: flex;
flex-direction: column;
}
.zw {
margin: 0 0 0 20px;
font-size: 23px;
}
.sysname {
font-size: 30px;
font-weight: bold;
margin: 0 20px;
color: #231916;
}
}
</style>

View File

@ -76,11 +76,11 @@ import useUserStore from "@/store/modules/user";
import { ElMessage, FormInstance, FormRules } from "element-plus";
import { getYears } from "@/utils/common";
import {
getFactorCheckstandard,
addSafeduty,
updateSafeduty,
} from "@/api/performDuties";
// import {
// getFactorCheckstandard,
// addSafeduty,
// updateSafeduty,
// } from "@/api/performDuties";
const formRef = ref<FormInstance>();
const userStore = useUserStore();

View File

@ -133,11 +133,11 @@ import useUserStore from "@/store/modules/user";
import { ElMessage, FormInstance, FormRules } from "element-plus";
import { getYears } from "@/utils/common";
import {
getFactorCheckstandard,
addFactor,
updateFactor,
} from "@/api/performDuties";
// import {
// getFactorCheckstandard,
// addFactor,
// updateFactor,
// } from "@/api/performDuties";
const formRef = ref<FormInstance>();
const userStore = useUserStore();

View File

@ -32,9 +32,9 @@
/>
<div>
<TitleC titleName="履职清单" />
<div class="detail-content" style="flex-direction: column">
<div class="detail-content" style="flex-direction: column;">
<!-- 条件筛选 -->
<div class="h-layout h-center" style="margin-bottom: 16px">
<div class="h-layout h-center" style="margin-bottom: 16px;">
<div class="h-layout">
<div
class="tool-item"
@ -130,7 +130,7 @@
<template #default="scope">
<span
v-if="scope.row.isfinish == '已完成'"
style="color: green"
style="color: green;"
>
{{ scope.row.isfinish }}
</span>
@ -191,7 +191,7 @@
</el-pagination>
</div>
<TitleC titleName="安全生产职责清单" />
<div class="h-layout h-center" style="margin-bottom: 16px">
<div class="h-layout h-center" style="margin-bottom: 16px;">
<div class="h-layout">
<div
class="tool-item"
@ -256,14 +256,14 @@
<script lang='ts' setup>
import { onMounted, reactive, ref } from "vue";
import { ElMessage, ElMessageBox } from "element-plus";
import {
listPerformDetail,
getFactorType,
factorPage,
delFactor,
getSafedutyList,
delSafeduty,
} from "@/api/performDuties";
// import {
// listPerformDetail,
// getFactorType,
// factorPage,
// delFactor,
// getSafedutyList,
// delSafeduty,
// } from "@/api/performDuties";
import Adddetails from "./details.vue";
import AddSafedutydetails from "./Safedutydetails.vue";
import { getYears } from "@/utils/common";
@ -442,24 +442,24 @@ onMounted(() => {
</script>
<style lang="scss" scoped>
.content {
width: 100%;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgba(8, 33, 85, 0.1);
height: 100%;
padding: 0.83333vw;
overflow-y: scroll;
overflow-x: hidden !important;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
-o-box-sizing: border-box;
-ms-box-sizing: border-box;
box-sizing: border-box;
width: 100%;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgb(8 33 85 / 10%);
height: 100%;
padding: 0.83333vw;
overflow-y: scroll;
overflow-x: hidden !important;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
}
.option-tv {
cursor: pointer;
font-size: --fontSize13;
color: --fontColor;
// margin-right: 20px;
cursor: pointer;
font-size: --fontsize13;
color: --fontcolor;
// margin-right: 20px;
}
</style>

View File

@ -22,13 +22,13 @@
value-format="YYYY-MM-DD" :size="size" />
</div>
</el-form-item>
<el-form-item style="width: 100%" label="接受岗位" prop="performId">
<el-form-item style="width: 100%;" label="接受岗位" prop="performId">
<el-select v-model="ruleForm.performId" multiple class="m-2" placeholder="请选择接收岗位">
<el-option v-for="item in performOptions" :key="item.listperformid" :label="item.performclassname"
:value="item.listperformid" />
</el-select>
</el-form-item>
<el-form-item style="width: 100%" label="任务内容" prop="content">
<el-form-item style="width: 100%;" label="任务内容" prop="content">
<el-input :rows="5" v-model="ruleForm.content" type="textarea" placeholder="请输入任务内容" />
</el-form-item>
@ -41,7 +41,7 @@ import { reactive, ref, onMounted, watch } from "vue";
import useUserStore from "@/store/modules/user";
import type { FormInstance, FormRules } from 'element-plus'
import { ElMessage } from 'element-plus'
import { getSpecialTasksTypeList, getSpecialTasksPerformList, addSpecialTasks } from "@/api/performDuties";
// import { getSpecialTasksTypeList, getSpecialTasksPerformList, addSpecialTasks } from "@/api/performDuties";
import { getUUID, FileType } from "@/utils/common";
const baseUrl = ref(import.meta.env.VITE_UPLOAD_IMG_URL);
const userStore = useUserStore();
@ -140,14 +140,12 @@ watch(
.detailForm-content {
margin-right: 30px;
}
:deep(.el-form) {
display: flex;
flex-wrap: wrap;
// justify-content: space-around;
justify-content: space-between;
}
:deep(.el-form-item) {
width: 47%;
}

File diff suppressed because it is too large Load Diff

View File

@ -15,7 +15,7 @@
</div>
</template>
</TitleC>
<div style="display:flex;margin-bottom: 10px;">
<div style="display: flex;margin-bottom: 10px;">
<div class="label-select filter-tab">
<el-select v-model="msgIndex" @change="changeMsgIndex" placeholder="请选择">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value">
@ -74,7 +74,7 @@
</template>
<script lang='ts' setup>
import { onMounted, reactive, ref } from "vue";
import { getGovNoticeUserPage, getGovNoticePage, delGovNotice } from "@/api/performDuties"
// import { getGovNoticeUserPage, getGovNoticePage, delGovNotice } from "@/api/performDuties"
import useUserStore from "@/store/modules/user";
import { useRouter } from "vue-router";
import MsgDetails from "../msgDetails.vue";
@ -214,11 +214,9 @@ onMounted(() => {
-ms-box-sizing: border-box;
box-sizing: border-box;
}
.dialog-footer button:first-child {
margin-right: 10px;
}
.avatar-uploader .avatar {
width: 178px;
height: 178px;
@ -234,11 +232,9 @@ onMounted(() => {
overflow: hidden;
transition: var(--el-transition-duration-fast);
}
.avatar-uploader .el-upload:hover {
border-color: var(--el-color-primary);
}
.el-icon.avatar-uploader-icon {
font-size: 28px;
color: #8c939d;

View File

@ -15,7 +15,7 @@
</div>
</template>
</TitleC>
<div style="display:flex;margin-bottom: 10px;">
<div style="display: flex;margin-bottom: 10px;">
<div class="label-select filter-tab">
<el-select v-model="taskIndex" @change="changeTaskIndex" placeholder="请选择">
<el-option v-for="item in taskFilter" :key="item.value" :label="item.label" :value="item.value">
@ -81,7 +81,7 @@
</template>
<script lang='ts' setup>
import { onMounted, reactive, ref } from "vue";
import { getSpecialTasksUserList, getSpecialTasksPage, delSpecialTasks } from "@/api/performDuties"
// import { getSpecialTasksUserList, getSpecialTasksPage, delSpecialTasks } from "@/api/performDuties"
import { ElMessage } from 'element-plus'
import useUserStore from "@/store/modules/user";
import { useRouter } from "vue-router";
@ -205,22 +205,18 @@ onMounted(() => {
-ms-box-sizing: border-box;
box-sizing: border-box;
}
.dialog-footer button:first-child {
margin-right: 10px;
}
.avatar-uploader .avatar {
width: 178px;
height: 178px;
display: block;
}
.radio {
font-size: 14px;
font-weight: 500;
color: #3587fb;
.icon-radio {
width: 15px;
height: 15px;
@ -228,26 +224,20 @@ onMounted(() => {
margin-right: 5px;
}
}
.have-radio {
color: #3587fb;
.icon-radio {
fill: #3587fb;
}
}
.complete-radio {
color: #2ECB89;
color: #2ecb89;
.icon-radio {
fill: #2ECB89;
fill: #2ecb89;
}
}
.timeout-radio {
color: #fb4e33;
.icon-radio {
fill: #fb4e33;
}

View File

@ -15,7 +15,7 @@
</div>
</template>
</TitleC>
<div class="h-layout h-center s" style="margin-bottom: 16px">
<div class="h-layout h-center s" style="margin-bottom: 16px;">
<!-- <div style="flex: 1"></div> -->
<div class="label-select">
<el-input v-model="search" @keydown.enter.native="getUserStudyPages" placeholder="请输入搜索内容" class="search-input">
@ -35,7 +35,7 @@
<el-table-column prop="coverimg" :resizable="true" align="center" label="封面" width="150">
<template #default="scope1">
<div style="width: 102px;height: 33px;margin: auto;">
<el-image style="width: 100%; height: 100%" :src="scope1.row.coverimg" :zoom-rate="1.2"
<el-image style="width: 100%; height: 100%;" :src="scope1.row.coverimg" :zoom-rate="1.2"
:preview-src-list="[scope1.row.coverimg]" fit="cover" :z-index='999' preview-teleported
:hide-on-click-modal='true' />
</div>
@ -45,7 +45,7 @@
<el-table-column :resizable="true" align="left" label="学习标题">
<template #default="scope">
<span :title=scope.row.studyName
style="white-space:nowrap;overflow:hidden;text-overflow:ellipsis;width:100%;padding-left:20px">{{
style="white-space: nowrap;overflow: hidden;text-overflow: ellipsis;width: 100%;padding-left: 20px;">{{
scope.row.studyName }}</span>
</template>
</el-table-column>
@ -71,7 +71,7 @@
</template>
<script lang='ts' setup>
import { onMounted, reactive, ref } from "vue";
import { getUserStudyPage } from "@/api/performDuties"
// import { getUserStudyPage } from "@/api/performDuties"
import useUserStore from "@/store/modules/user";
import { useRouter } from "vue-router";
import StuDetails from "../stuDetails.vue";
@ -127,60 +127,56 @@ onMounted(() => {
</script>
<style lang="scss" scoped>
.content {
width: 100%;
// flex: auto;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgb(8 33 85 / 10%);
height: 100%;
padding: 0.83333vw;
overflow-y: auto;
overflow-x: hidden !important;
/* stylelint-disable-next-line property-no-vendor-prefix */
-moz-box-sizing: border-box;
/* stylelint-disable-next-line property-no-vendor-prefix */
-webkit-box-sizing: border-box;
/* stylelint-disable-next-line property-no-vendor-prefix */
-o-box-sizing: border-box;
/* stylelint-disable-next-line property-no-vendor-prefix */
-ms-box-sizing: border-box;
box-sizing: border-box;
width: 100%;
// flex: auto;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgb(8 33 85 / 10%);
height: 100%;
padding: 0.83333vw;
overflow-y: auto;
overflow-x: hidden !important;
/* stylelint-disable-next-line property-no-vendor-prefix */
-moz-box-sizing: border-box;
/* stylelint-disable-next-line property-no-vendor-prefix */
-webkit-box-sizing: border-box;
/* stylelint-disable-next-line property-no-vendor-prefix */
-o-box-sizing: border-box;
/* stylelint-disable-next-line property-no-vendor-prefix */
-ms-box-sizing: border-box;
box-sizing: border-box;
}
.dialog-footer button:first-child {
margin-right: 10px;
margin-right: 10px;
}
.avatar-uploader .avatar {
width: 178px;
height: 178px;
display: block;
width: 178px;
height: 178px;
display: block;
}
</style>
<style>
.avatar-uploader .el-upload {
border: 1px dashed var(--el-border-color);
border-radius: 6px;
cursor: pointer;
position: relative;
overflow: hidden;
transition: var(--el-transition-duration-fast);
border: 1px dashed var(--el-border-color);
border-radius: 6px;
cursor: pointer;
position: relative;
overflow: hidden;
transition: var(--el-transition-duration-fast);
}
.avatar-uploader .el-upload:hover {
border-color: var(--el-color-primary);
border-color: var(--el-color-primary);
}
.el-icon.avatar-uploader-icon {
font-size: 28px;
color: #8c939d;
width: 178px;
height: 178px;
text-align: center;
font-size: 28px;
color: #8c939d;
width: 178px;
height: 178px;
text-align: center;
}
.label-select {
width: 20%;
/* margin-bottom: 20px; */
width: 20%;
/* margin-bottom: 20px; */
}
</style>

View File

@ -23,7 +23,7 @@
</template>
<script setup lang="ts" >
import { onMounted, watch } from "vue";
import { readGovNotice } from "@/api/performDuties"
// import { readGovNotice } from "@/api/performDuties"
import useUserStore from "@/store/modules/user";
const userStore = useUserStore();
const user = ref(JSON.parse(userStore.userInfo));
@ -72,25 +72,20 @@ watch(
padding-bottom: 50px;
margin: auto;
width: 90%;
>h1 {
text-align: center;
}
>div:nth-of-type(1) {
display: flex;
justify-content: space-between;
>div {
display: flex;
>h2:nth-of-type(1) {
margin-right: 50px;
}
}
}
}
.info-p {
white-space: pre-wrap;
font-size: 20px;

View File

@ -63,7 +63,7 @@
</template>
<script lang='ts' setup>
import { onMounted, reactive, ref } from "vue";
import { getSpecialTasks, getSpecialTasksUser } from "@/api/performDuties";
// import { getSpecialTasks, getSpecialTasksUser } from "@/api/performDuties";
import { getFile } from "@/api/file";
import { FileType } from "@/utils/common";
import useUserStore from "@/store/modules/user";
@ -156,50 +156,49 @@ onMounted(() => {
</script>
<style lang="scss" scoped>
.content {
width: 100%;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgba(8, 33, 85, 0.1);
height: 100%;
padding: 0.83333vw;
overflow-y: scroll;
overflow-x: hidden !important;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
-o-box-sizing: border-box;
-ms-box-sizing: border-box;
box-sizing: border-box;
width: 100%;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgb(8 33 85 / 10%);
height: 100%;
padding: 0.83333vw;
overflow-y: scroll;
overflow-x: hidden !important;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
}
.detail-content {
// padding: 0px 16px 16px 16px;
display: flex;
flex-direction: column;
// padding: 0px 16px 16px 16px;
display: flex;
flex-direction: column;
// .el-form {
// width: 100%;
// display: flow-root;
// .el-form {
// width: 100%;
// display: flow-root;
// .inline-item {
// width: 48%;
// float: left;
// .inline-item {
// width: 48%;
// float: left;
// :deep(.el-form-item__label) {
// line-height: 40px !important;
// }
// }
// :deep(.el-form-item__label) {
// line-height: 40px !important;
// }
// }
// .inline-block {
// width: 100%;
// .inline-block {
// width: 100%;
// :deep(.el-form-item__label) {
// line-height: 40px !important;
// }
// }
// :deep(.el-form-item__label) {
// line-height: 40px !important;
// }
// }
// .right {
// float: right;
// }
// }
// .right {
// float: right;
// }
// }
}
</style>

View File

@ -8,10 +8,6 @@
<svg-icon name="refurbish" class="icon" />
<span>刷新</span>
</div>
<div class="tool-item">
<svg-icon name="export" class="icon" />
<span>导出</span>
</div>
</div>
</div>
</div>
@ -126,6 +122,6 @@ const tableData = ref([{ cName: "xxx村名" }, { cName: "xxx村名" }]);
<style lang="scss" scoped>
.table {
margin-top: 16px;
margin-top: 16px;
}
</style>

View File

@ -112,7 +112,7 @@ const userId = ref(user.value.userId);
const uuid = ref("");
const ruleForm = reactive<FormRules>({
sysusername: [{ required: true, message: "请输入账号", trigger: "blur" }],
syspassword: [{ required: true,pattern: "^(?=.*[a-zA-Z])(?=.*\\d).{10,}$", message: "请输入10位密码包括英文与数字", trigger: "blur" }],
syspassword: [{ required: true,pattern: "^(?=.*[a-zA-Z])(?=.*\\d).{10,}$", message: "请输入10位密码包括大小写英文字母与数字", trigger: "blur" }],
chinaname: [{ required: true, message: "请输入中文名", trigger: "blur" }],
userroles: [{ required: true, message: "请选择角色", trigger: "change" }],
sysunitorentid: [

View File

@ -94,11 +94,11 @@ import useUserStore from "@/store/modules/user";
import { ElMessage, FormInstance, FormRules } from "element-plus";
import { getYears } from "@/utils/common";
import {
getFactorCheckstandard,
addFactor,
updateFactor,
} from "@/api/performDuties";
// import {
// getFactorCheckstandard,
// addFactor,
// updateFactor,
// } from "@/api/performDuties";
const formRef = ref<FormInstance>();
const userStore = useUserStore();

View File

@ -48,11 +48,11 @@ import useUserStore from "@/store/modules/user";
import { ElMessage, FormInstance, FormRules } from "element-plus";
import { getYears } from "@/utils/common";
import {
getFactorCheckstandard,
addSafeduty,
updateSafeduty,
} from "@/api/performDuties";
// import {
// getFactorCheckstandard,
// addSafeduty,
// updateSafeduty,
// } from "@/api/performDuties";
const formRef = ref<FormInstance>();
const userStore = useUserStore();

View File

@ -0,0 +1,167 @@
<template>
<BaseDialog
:dialogVisible="props.visible"
@close="onclone"
:titleName="
readonly ? '消息详情' : props.form.govNoticeId ? '编辑消息' : '新增消息'
"
width="50%"
@onSubmit="handleSubmit"
:footerclosed="true"
:diafooter="true"
:footerkeepnaem="props.readonly ? false : true"
>
<div class="detailForm-content">
<el-form
ref="formRef"
label-position="right"
label-width="100"
:disabled="readonly"
:rules="ruleForm"
:model="addMessageForm"
>
<el-form-item label="标题名称:" prop="title" style="width: 100%;">
<el-input
placeholder="请输入"
v-model="addMessageForm.title"
></el-input>
</el-form-item>
<el-form-item label="内容:" prop="content" style="width: 100%;">
<div class="qedit">
<QuillEditor
class="qedit"
:value="addMessageForm.content"
@updateValue="getMsg"
:id="uuid"
:userId="userId"
:FileType="FileType.message"
/>
</div>
</el-form-item>
<el-form-item label="封面:" prop="content" style="width: 100%;">
<CustomUpload
:listPic="fileList"
:OTCType="FileType.messageCover"
:uuid="uuid"
:userId="userId"
:baseUrl="baseUrl"
:max="9"
@onUpdate="updateFile"
></CustomUpload>
<!-- :readonly="readonly" -->
</el-form-item>
</el-form>
</div>
</BaseDialog>
</template>
<script setup lang="ts" >
import { reactive, ref, onMounted, watch } from "vue";
import useUserStore from "@/store/modules/user";
import { getYears, getUUID, FileType } from "@/utils/common";
import { ElMessage, FormInstance, FormRules } from "element-plus";
import { uploadFile, getFile, delFile } from "@/api/file";
const formRef = ref<FormInstance>();
const userStore = useUserStore();
const user = ref(JSON.parse(userStore.userInfo));
const userId = ref(user.value.userId);
const uuid = ref("");
const ruleForm = reactive<FormRules>({
title: [{ required: true, message: "请输入标题", trigger: "blur" }],
});
const props = defineProps({
visible: {
type: Boolean,
default: false,
},
form: Object,
readonly: {
type: Boolean,
default: false,
},
id: String,
});
const addMessageForm = ref<any>({ content: "",title:"" });
const emits = defineEmits(["close", "onSubmit"]);
//
const getMsg = (val) => {
addMessageForm.value.content = val;
};
//退
const handleSubmit = () => {
formRef.value?.validate((valid) => {
if (valid) {
console.log(addMessageForm.value);
// const params = JSON.parse(JSON.stringify(addMessageForm.value));
// performAdd(params).then((res: any) => {
// if (res.code == 1) {
// ElMessage.success({
// message: "",
// type: "success",
// });
// onclone();
// }
// });
}
return false;
});
};
//
const fileList = ref([]);
//
const baseUrl = ref(import.meta.env.VITE_UPLOAD_URL);
const getFiles = () => {
let otcid = props.govNoticeId;
let otctype = FileType.messageCover;
getFile(otcid, otctype).then((res: any) => {
fileList.value = res.data;
console.log( fileList.value,'res==>');
});
};
/**
* 文件列表更新
*/
const updateFile = (files: any) => {
fileList.value = files;
};
//
const onclone = () => {
emits("close");
};
watch(
() => props.visible,
() => {
uuid.value = getUUID();
getFiles();
}
);
onMounted(() => {});
</script>
<style lang="scss" scoped>
.detailForm-content {
margin-right: 30px;
}
:deep(.el-form) {
display: flex;
flex-wrap: wrap;
justify-content: space-between;
}
:deep(.el-form-item) {
width: 47%;
}
</style>

View File

@ -0,0 +1,219 @@
<template>
<div class="percentage-content">
<div class="content">
<div class="h-layout space-between h-center">
<div>
<div class="h-layout">
<div class="tool-item" @click="getList">
<svg-icon name="refurbish" class="icon" />
<span>刷新</span>
</div>
<div
class="tool-item"
@click="(dialogVisible = true), (form = {}), (readonly = false)"
>
<svg-icon name="add" class="icon" />
<span>新增</span>
</div>
</div>
</div>
<div style="width: 30%;">
<div>
<el-input
v-model="search"
@keydown.enter.native="getList"
placeholder="请输入关键字"
class="search-input"
>
<template #append>
<span @click="getList" class="search-bottom">
<svg-icon name="search" class="icon_class" />
<span>搜索</span>
</span>
</template>
</el-input>
</div>
</div>
</div>
<el-table
ref="loading"
class="table"
v-loading="tableDataloading"
:data="tableData"
header-row-class-name="el-one-header"
@selection-change="handleSelectionChange"
border
>
<el-table-column
align="center"
:resizable="true"
width="100"
label="序列"
type="index"
>
<template #default="scope">
{{ scope.$index + 1 + (currentPage - 1) * pageSize }}
</template>
</el-table-column>
<el-table-column
prop="title"
:resizable="true"
label="标题"
width="250"
>
</el-table-column>
<el-table-column
prop="content"
:resizable="true"
align="center"
label="内容"
>
</el-table-column>
<el-table-column
:resizable="true"
align="center"
width="300"
label="操作"
>
<template #default="scope">
<span
class="operate"
@click="
(dialogVisible = true), (form = scope.row), (readonly = false)
"
>
<svg-icon name="edit" class="icon"></svg-icon>
<span class="edit">编辑</span>
</span>
<span
class="operate"
@click="
(dialogVisible = true), (form = scope.row), (readonly = true)
"
>
<svg-icon name="detail" class="icon"></svg-icon>
<span class="detail">详情</span>
</span>
<span class="operate" @click="clickDelete(scope.row.govNoticeId)">
<svg-icon name="delete" class="icon"></svg-icon>
<span class="delete">删除</span>
</span>
</template>
</el-table-column>
</el-table>
<!-- 分页 -->
<el-pagination
class="pagination"
@size-change="getList"
@current-change="getList"
v-model:current-page.sync="currentPage"
:page-sizes="[10, 15, 20, 30]"
v-model:page-size.sync="pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="total"
background
>
</el-pagination>
</div>
<!-- 新增/修改 -->
<AddModifyMessage
:visible="dialogVisible"
:form="form"
:readonly="readonly"
@close="onclone"
/>
</div>
</template>
<script lang='ts' setup>
import { onMounted, reactive, ref } from "vue";
import { useRouter } from "vue-router";
const router = useRouter();
import { noticePage } from "@/api/Sys";
import { ElMessage, ElMessageBox } from "element-plus";
import AddModifyMessage from "./add-modify-message.vue";
import useUserStore from "@/store/modules/user";
const userStore = useUserStore();
const user = ref(JSON.parse(userStore.userInfo));
const userId = ref(user.value.userId);
const search = ref([]);
const tableData = ref([]);
const currentPage = ref(1);
const pageSize = ref(10);
const total = ref(0);
const dialogVisible = ref(false);
const form = ref({});
const readonly = ref(false);
//
const tableDataloading = ref(false);
const getList = () => {
tableDataloading.value = true;
let params = {
condition: search.value,
limit: pageSize.value,
page: currentPage.value,
};
noticePage(params).then((res: any) => {
console.log(res,'res==>');
tableData.value = res.data.list;
total.value = res.data.total;
tableDataloading.value = false;
});
};
const clickDelete = (govNoticeId) => {
// ElMessageBox.confirm("?", "", {
// confirmButtonText: "",
// cancelButtonText: "",
// type: "warning",
// }).then(() => {
// delListperform(govNoticeId).then((res: any) => {
// if (res.code == 1) {
// ElMessage.success({
// message: "",
// type: "success",
// });
// } else {
// ElMessage.error({
// message: res.message,
// type: "error",
// });
// }
// getList();
// });
// });
};
//
const onclone = () => {
dialogVisible.value = false;
form.value = {};
getList();
};
onMounted(() => {
getList();
});
</script>
<style lang="scss" scoped>
.content {
width: 100%;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgb(8 33 85 / 10%);
height: 100%;
padding: 0.83333vw;
overflow-y: auto;
overflow-x: hidden !important;
box-sizing: border-box;
.table {
margin-top: 16px;
}
}
</style>

View File

@ -40,55 +40,49 @@ const getMsg = (val) => {
<style lang="scss" scoped>
.percentage-content {
height: auto;
display: flex;
flex-direction: column;
.rg {
padding: 16px;
background: #ffffff;
box-shadow: 0px 0px 6px rgba(0, 120, 255, 0.1);
border-radius: 6px;
display: flex;
flex-direction: row;
margin-bottom: 10px;
:deep(.el-radio-button__inner) {
min-width: 150px;
}
}
.content {
width: 100%;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgba(8, 33, 85, 0.1);
padding: 0.83333vw;
overflow-y: auto;
overflow-x: hidden !important;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
-o-box-sizing: border-box;
-ms-box-sizing: border-box;
box-sizing: border-box;
position: relative;
height: auto;
display: flex;
flex-direction: column;
.qedit {
height: 63vh;
.rg {
padding: 16px;
background: #fff;
box-shadow: 0 0 6px rgb(0 120 255 / 10%);
border-radius: 6px;
display: flex;
flex-direction: row;
margin-bottom: 10px;
:deep(.el-radio-button__inner) {
min-width: 150px;
}
}
.option {
margin: 50px 0 10px 0;
display: flex;
align-items: center;
justify-content: center;
.btn {
width: 10vw;
}
.content {
width: 100%;
background: #fff;
border-radius: 0.26042vw;
box-shadow: 0 0 0.41667vw 0 rgb(8 33 85 / 10%);
padding: 0.83333vw;
overflow-y: auto;
overflow-x: hidden !important;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
box-sizing: border-box;
position: relative;
display: flex;
flex-direction: column;
.qedit {
height: 63vh;
}
.option {
margin: 50px 0 10px;
display: flex;
align-items: center;
justify-content: center;
.btn {
width: 10vw;
}
}
}
}
}
</style>

View File

@ -52,7 +52,7 @@
filterable
/>
</el-form-item>
<el-form-item label="装备照片" style="width: 100%;">
<el-form-item label="工作附件" style="width: 100%;">
<el-upload
class="avatar-uploader"
ref="uploadAfter"

View File

@ -24,10 +24,6 @@
<svg-icon name="refurbish" class="icon" />
<span>刷新</span>
</div>
<div class="tool-item">
<svg-icon name="export" class="icon" />
<span>导出</span>
</div>
</div>
</div>
</div>

View File

@ -49,7 +49,7 @@
value-format="YYYY-MM-DD"
/>
</el-form-item>
<el-form-item label="装备照片" style="width: 100%;">
<el-form-item label="工作附件" style="width: 100%;">
<el-upload
class="avatar-uploader"
ref="uploadAfter"

BIN
道孚县PC管理端.zip Normal file

Binary file not shown.