From c77d12b9ef72aaf88599121df0fa83b20841aeba Mon Sep 17 00:00:00 2001 From: andy <1042025947@qq.com> Date: Tue, 29 Sep 2026 08:58:41 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BC=80=E6=94=BE=E5=B9=B3=E5=8F=B0=E7=AE=A1?= =?UTF-8?q?=E7=90=86=20=E5=BC=82=E5=B8=B8=E9=80=9A=E7=9F=A5=E7=AE=A1?= =?UTF-8?q?=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/system/exceptionNotification.js | 40 +++ src/api/system/platform.js | 64 ++++ src/views/attendance/statistical/index.vue | 44 ++- src/views/finance/financeStatistics/index.vue | 2 +- src/views/restaurant/images/index.vue | 1 + src/views/system/dept/index.vue | 30 +- .../system/exceptionNotification/index.vue | 302 ++++++++++++++++++ src/views/system/platform/index.vue | 293 +++++++++++++++++ src/views/system/staff/index.vue | 86 ++++- 9 files changed, 831 insertions(+), 31 deletions(-) create mode 100644 src/api/system/exceptionNotification.js create mode 100644 src/api/system/platform.js create mode 100644 src/views/system/exceptionNotification/index.vue create mode 100644 src/views/system/platform/index.vue diff --git a/src/api/system/exceptionNotification.js b/src/api/system/exceptionNotification.js new file mode 100644 index 0000000..490ab3a --- /dev/null +++ b/src/api/system/exceptionNotification.js @@ -0,0 +1,40 @@ +import request from '@/utils/request' + +export function listExceptionNotification(query) { + return request({ + url: '/system/exceptionNotification/list', + method: 'get', + params: query + }) +} + +export function addExceptionNotification(data) { + return request({ + url: '/system/exceptionNotification', + method: 'post', + data: data + }) +} + +export function getExceptionNotification(id) { + return request({ + url: '/system/exceptionNotification/' + id, + method: 'get' + }) +} + +export function updateExceptionNotification(data) { + return request({ + url: '/system/exceptionNotification', + method: 'put', + data: data + }) +} + +export function deleteExceptionNotification(id) { + return request({ + url: '/system/exceptionNotification/' + id, + method: 'delete' + }) +} + diff --git a/src/api/system/platform.js b/src/api/system/platform.js new file mode 100644 index 0000000..a2ac656 --- /dev/null +++ b/src/api/system/platform.js @@ -0,0 +1,64 @@ +import request from '@/utils/request' + +// 查询员工管理列表 +export function list(query) { + return request({ + url: '/system/platform/list', + method: 'get', + params: query + }) +} + +// 查询员工管理详细 +export function getDetail(id) { + return request({ + url: '/system/platform/' + id, + method: 'get' + }) +} + +// 新增员工管理 +export function add(data) { + return request({ + url: '/system/platform', + method: 'post', + data: data + }) +} + +// 修改员工管理 +export function update(data) { + return request({ + url: '/system/platform', + method: 'put', + data: data + }) +} + +export function resetKey(data) { + return request({ + url: '/system/platform/resetKey', + method: 'put', + data: data + }) +} + + + +// 删除员工管理 +export function del(id) { + return request({ + url: '/system/platform/' + id, + method: 'delete' + }) +} + +// 查询员工管理列表 +export function serviceList() { + return request({ + url: '/system/platform/service/list', + method: 'get', + }) +} + + diff --git a/src/views/attendance/statistical/index.vue b/src/views/attendance/statistical/index.vue index 9a076d0..193b61b 100644 --- a/src/views/attendance/statistical/index.vue +++ b/src/views/attendance/statistical/index.vue @@ -19,6 +19,7 @@ 搜索 重置 + 导入统计 @@ -348,7 +349,7 @@ - + + + + +
将文件拖到此处,或点击上传
+
+ 下载模板 +

仅允许导入xls、xlsx格式文件。

+
+
+ +
+ @@ -508,7 +535,18 @@ export default { this.getList(); }, methods: { - + + /** 详情导入 */ + handleImport() { + this.upload.title = "员工导入"; + this.upload.open = true; + }, + //下载模版 + importTemplate() { + this.download('attendance/statistical/importTemplate', { + }, `考勤统计模版_${new Date().getTime()}.xlsx`) + }, + viewInfo(row){ this.info.title=row.name+" ["+DateUtils.formatDate(row.month, 'yyyy-MM') +"] 操作记录"; getAttendanceOper(row.id).then(response => { diff --git a/src/views/finance/financeStatistics/index.vue b/src/views/finance/financeStatistics/index.vue index 49a6c5c..9f49a48 100644 --- a/src/views/finance/financeStatistics/index.vue +++ b/src/views/finance/financeStatistics/index.vue @@ -48,7 +48,7 @@ v-if="scope.row.status ==='待审核'" icon="el-icon-check" @click="handleComfirm(scope.row)" - v-hasPermi="['finance:financeStatistics:comfirm']" + v-hasPermi="['finance:financeStatistics:confirm']" >确认发放 diff --git a/src/views/restaurant/images/index.vue b/src/views/restaurant/images/index.vue index ada53d6..a1922fd 100644 --- a/src/views/restaurant/images/index.vue +++ b/src/views/restaurant/images/index.vue @@ -57,6 +57,7 @@ 删除 diff --git a/src/views/system/dept/index.vue b/src/views/system/dept/index.vue index bdc3f51..d754214 100644 --- a/src/views/system/dept/index.vue +++ b/src/views/system/dept/index.vue @@ -56,9 +56,10 @@ :default-expand-all="isExpandAll" :tree-props="{children: 'children', hasChildren: 'hasChildren'}" > - - - + + + + - + @@ -448,8 +449,9 @@ + - + + + + + + + + @@ -944,6 +957,7 @@ import { getToken } from "@/utils/auth"; import Treeselect from "@riophae/vue-treeselect"; import { getAllowAdjustment } from "@/api/system/allowAdjustment"; import "@riophae/vue-treeselect/dist/vue-treeselect.css"; +import { getDicts } from "@/api/system/dict/data"; export default { name: "Staff", @@ -960,13 +974,6 @@ export default { callback() // 校验通过 } }); - - // 假设后台返回 { code: 0, data: true } true=已存在 - // if (res.data.data) { - // callback(new Error('姓名【'+value+'】已存在,所有员工(含离职)不可重名')) - // } else { - // callback() // 校验通过 - // } } return { @@ -982,6 +989,8 @@ export default { //部门列表 deptOptions: [], deptOpt:[], + //岗位信息 + jobInfoOptions: [], //补贴列表 subsidyOptions: [], // 弹出层标题 @@ -1111,9 +1120,9 @@ export default { imageUrl:[ { required: true, message: "请上传员工头像", trigger: "blur" }, ], - // timeClockList: [ - // { required: true, message: "打卡机不能为空", trigger: "blur" } - // ], + timeClockList: [ + { required: true, message: "打卡机不能为空", trigger: "blur" } + ], jobCode: [ { required: true, message: "请选择员工岗位信息", trigger: "blur" } ], @@ -1133,8 +1142,53 @@ export default { this.getDeptList(); this.getSubsidyList(); }, - methods: { +watch: { + 'form.deptId'(newVal, oldVal) { + if(newVal != undefined && newVal != null){ + this.buildJobInfo(newVal[newVal.length-1]); + } + } +}, + + methods: { + buildJobInfo(deptId){ + if(!deptId){ + return; + } + this.jobInfoOptions = []; + const deptCode= this.getDeptCode(this.deptOptions, deptId); + console.log("部门code", deptCode); + if(!deptCode){ + return; + } + for (let job of this.dict.type.job_info) { + const jobCodes = job.value.split("_"); + console.log("部门code", jobCodes[1], jobCodes); + if(jobCodes[1] === deptCode){ + this.jobInfoOptions.push(job); + } + } + }, + + getDeptCode(dataList, deptId){ + for (let item of dataList) { + // 当前节点匹配 + if (item.id === deptId) { + return item.extend.deptCode + } + // 存在子节点则递归查找子树 + if (item.children && item.children.length > 0) { + const res = this.getDeptCode(item.children, deptId) + // 递归有结果就直接返回,不再继续循环 + if (res) { + return res + } + } + } + // 整棵树没找到返回null + return null + }, //上传头像 handleAvatarSuccess(res, file) {