From 17397e68389293655d6d008ad99ba54a3ebba476 Mon Sep 17 00:00:00 2001 From: limingyu Date: Mon, 11 Mar 2024 08:59:47 +0800 Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E9=9A=90=E6=82=A3=E5=BF=AB=E6=8A=A5?= =?UTF-8?q?=E9=9A=90=E6=82=A3=E5=8F=91=E7=8E=B0=E4=BA=BA=E4=BF=AE=E6=94=B9?= =?UTF-8?q?=E4=B8=BA=E5=8D=95=E9=80=89=EF=BC=8C=E5=B9=B6=E5=8F=AF=E4=BB=A5?= =?UTF-8?q?=E4=BF=AE=E6=94=B9;2=E3=80=81=E4=BF=AE=E5=A4=8D=E9=9A=90?= =?UTF-8?q?=E6=82=A3=E6=8E=92=E6=9F=A5=20=E5=A4=9A=E6=AC=A1=E7=82=B9?= =?UTF-8?q?=E5=87=BB=E6=8F=90=E4=BA=A4=E6=B8=85=E5=8D=95=E4=B9=8B=E5=90=8E?= =?UTF-8?q?=20=E6=9C=89=E6=8A=A5=E9=94=99;3=E3=80=81=E9=87=8D=E7=82=B9?= =?UTF-8?q?=E5=B7=A5=E7=A8=8B=E5=AE=89=E5=85=A8=E7=8E=AF=E4=BF=9D=E6=A3=80?= =?UTF-8?q?=E6=9F=A5=E5=8A=A0=20=E5=BD=92=E6=A1=A3=E7=8A=B6=E6=80=81=20?= =?UTF-8?q?=E5=BD=92=E6=A1=A3=E7=8A=B6=E6=80=81=E5=B0=B1=E6=98=AF=E6=A3=80?= =?UTF-8?q?=E6=9F=A5=E7=A1=AE=E8=AE=A4=E5=B9=B6=E4=B8=94=E9=9A=90=E6=82=A3?= =?UTF-8?q?=E5=85=A8=E9=83=A8=E9=AA=8C=E6=94=B6;4=E3=80=81=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D=E9=87=8D=E5=A4=A7=E9=9A=90=E6=82=A3=E8=A2=AB=E7=A1=AE?= =?UTF-8?q?=E8=AE=A4=E4=B8=BA=E5=BF=BD=E7=95=A5=E9=9A=90=E6=82=A3=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88=B1?= =?UTF-8?q?=E7=9A=84=E8=AE=A1=E7=AE=97=E6=96=B9=E5=BC=8F=E5=90=8E=E5=8A=A0?= =?UTF-8?q?=E6=B0=94=E6=B3=A1=EF=BC=8C=E9=BC=A0=E6=A0=87=E6=94=BE=E4=B8=8A?= =?UTF-8?q?=E5=8E=BB=E5=90=8E=E6=98=BE=E7=A4=BA=E7=9B=B8=E5=BA=94=E7=9A=84?= =?UTF-8?q?=E6=96=87=E5=AD=97=E6=8F=8F=E8=BF=B0=E8=A7=84=E5=88=99;9?= =?UTF-8?q?=E3=80=81=E7=9B=91=E7=AE=A1=E7=AB=AF=E5=88=9B=E5=BB=BA=E7=9A=84?= =?UTF-8?q?=E5=AE=89=E5=85=A8=E6=89=BF=E8=AF=BA=E4=B9=A6=E6=A8=A1=E6=9D=BF?= =?UTF-8?q?=E4=B8=8D=E8=83=BD=E5=88=A0=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../checkrecord/components/checkdstart.vue | 130 +++++--- .../hidden/confirm/components/detail.vue | 2 +- src/views/hidden/ignore/components/detail.vue | 5 +- src/views/hidden/list/components/edit.vue | 96 +++--- src/views/hiddenApi/publicMethod/detail.vue | 35 +- .../inspection/components/record-list.vue | 34 +- .../archive/components/info.vue | 31 +- .../promise/components/list.vue | 2 +- static/bi/index.html | 310 ++++++++++-------- 9 files changed, 412 insertions(+), 233 deletions(-) diff --git a/src/views/check/checkrecord/components/checkdstart.vue b/src/views/check/checkrecord/components/checkdstart.vue index 7aff043..ad2c7a1 100644 --- a/src/views/check/checkrecord/components/checkdstart.vue +++ b/src/views/check/checkrecord/components/checkdstart.vue @@ -406,50 +406,56 @@ - - - - - - - - - - - - - 添加 - - - - - - + + - - - 删除 - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -679,7 +685,8 @@ export default { } }, editVector: '添加隐患', - addLoading: false + addLoading: false, + modelKey: 0 } }, watch: { @@ -1511,7 +1518,8 @@ export default { LISTMANAGER_ID: this.LISTMANAGER_ID, HAVESCHEME: 0, hiddenPartType: this.hiddenPartType, - findCreator: findCreator + findCreator: findCreator, + hiddenFindCreator: this.myUserInfo.USER_ID // DISCOVERYTIME: this.hiddenForm.DISCOVERYTIME, // 隐患发现时间 // CONFIRM_USER: this.hiddenForm.CONFIRM_USER // 隐患确认人 } @@ -1730,11 +1738,17 @@ export default { requestFN( '/user/goEditMyInfo', {} - ).then((data) => { + ).then(async(data) => { // var o = { 'DEPARTMENT_ID': data.pd.DEPARTMENT_ID, 'USER_ID': data.pd.USER_ID } - this.myUserInfo.DEPARTMENT_ID = data.depname + // this.myUserInfo.DEPARTMENT_ID = data.depname + this.myUserInfo.DEPARTMENT_ID = data.pd.DEPARTMENT_ID this.myUserInfo.DEPARTMENTName = data.pd.deptName + if (data.pd.DEPARTMENT_ID) { + await this.getFindUserListByDepId(data.pd.DEPARTMENT_ID) + } + this.modelKey++ // 为了重新渲染级联选择器 this.myUserInfo.USERNAME = data.pd.NAME + this.myUserInfo.USER_ID = data.pd.USER_ID this.$forceUpdate() }).catch((e) => { this.addLoading = false @@ -1747,24 +1761,46 @@ export default { remoFindOther(index) { // 删除隐患发现人员 this.findCreatorList.splice(index, 1) }, - updateFindOtherDep(DEPARTMENT_ID, i) { // 点击发现部门 - this.findCreatorList[i].USER_ID = '' - this.getFindUserList(DEPARTMENT_ID, i) + updateFindDep(DEPARTMENT_ID) { + this.myUserInfo.USER_ID = '' + this.getFindUserListByDepId(DEPARTMENT_ID) }, - getFindUserList(DEPARTMENT_ID, index) { // 获取发现发现部门的人员信息 - this.listLoading = true - requestFN( - '/user/listAll', - { - DEPARTMENT_ID: DEPARTMENT_ID, - tm: new Date().getTime() - } - ).then((data) => { - this.$set(this.findUserList, index, data.userList) - }).catch((e) => { - this.listLoading = false + // updateFindOtherDep(DEPARTMENT_ID, i) { // 点击发现部门 + // this.findCreatorList[i].USER_ID = '' + // this.getFindUserList(DEPARTMENT_ID, i) + // }, + getFindUserListByDepId(DEPARTMENT_ID) { + return new Promise((resolve) => { + this.listLoading = true + requestFN( + '/user/listAll', + { + DEPARTMENT_ID: DEPARTMENT_ID, + tm: new Date().getTime() + } + ).then((data) => { + this.findUserList = data.userList + this.$forceUpdate() + resolve() + }).catch((e) => { + this.listLoading = false + }) }) }, + // getFindUserList(DEPARTMENT_ID, index) { // 获取发现发现部门的人员信息 + // this.listLoading = true + // requestFN( + // '/user/listAll', + // { + // DEPARTMENT_ID: DEPARTMENT_ID, + // tm: new Date().getTime() + // } + // ).then((data) => { + // this.$set(this.findUserList, index, data.userList) + // }).catch((e) => { + // this.listLoading = false + // }) + // }, updateConfirmDept() { // 根据选择的隐患确认部门显示隐患确认人 this.listLoading = true requestFN( diff --git a/src/views/hidden/confirm/components/detail.vue b/src/views/hidden/confirm/components/detail.vue index ada18b1..dc96c83 100644 --- a/src/views/hidden/confirm/components/detail.vue +++ b/src/views/hidden/confirm/components/detail.vue @@ -65,7 +65,7 @@
- 提 交 + 提 交 打 回 返 回
diff --git a/src/views/hidden/ignore/components/detail.vue b/src/views/hidden/ignore/components/detail.vue index 33ad799..f447939 100644 --- a/src/views/hidden/ignore/components/detail.vue +++ b/src/views/hidden/ignore/components/detail.vue @@ -47,8 +47,9 @@ 隐患级别 - {{ pd.editLevelName }} - {{ pd.HIDDENLEVELNAME }} + + + {{ pd.HIDDENLEVELNAME }} 隐患类型 diff --git a/src/views/hidden/list/components/edit.vue b/src/views/hidden/list/components/edit.vue index e253af6..bafe935 100644 --- a/src/views/hidden/list/components/edit.vue +++ b/src/views/hidden/list/components/edit.vue @@ -163,46 +163,28 @@ - - - - - - - - - - - - 添加 - - - - - + + - - 删除 - - @@ -360,7 +342,8 @@ export default { confirmUserList: [], // 隐患确认人 isClearRectificationor: true, // 是否清空整改人 iframeSrc: '', - dialogMap: false + dialogMap: false, + modelKey: 0 } }, watch: { @@ -506,9 +489,13 @@ export default { requestFN( '/user/goEditMyInfo', {} - ).then((data) => { - this.myUserInfo.DEPARTMENT_ID = data.deptname - this.myUserInfo.USERNAME = data.pd.NAME + ).then(async(data) => { + this.myUserInfo.DEPARTMENT_ID = data.pd.DEPARTMENT_ID + this.modelKey++ // 为了触发级联选择器重新渲染 + if (data.pd.DEPARTMENT_ID) { + await this.getFindUserListByDepId(data.pd.DEPARTMENT_ID) + } + this.myUserInfo.USER_ID = data.pd.USER_ID this.$forceUpdate() }).catch((e) => { @@ -555,6 +542,7 @@ export default { } this.pd.findCreator = findCreator this.pd.hiddenPartType = this.hiddenPartType + this.pd.hiddenFindCreator = this.myUserInfo.USER_ID this.$refs.form.validate(valid => { if (this.pd.HIDDEN_ID) { if (valid) { @@ -810,24 +798,46 @@ export default { remoFindOther(index) { // 删除隐患发现人员 this.findCreatorList.splice(index, 1) }, - updateFindOtherDep(DEPARTMENT_ID, i) { // 点击发现部门 - this.findCreatorList[i].USER_ID = '' - this.getFindUserList(DEPARTMENT_ID, i) + // updateFindOtherDep(DEPARTMENT_ID, i) { // 点击发现部门 + // this.findCreatorList[i].USER_ID = '' + // this.getFindUserList(DEPARTMENT_ID, i) + // }, + updateFindDep(DEPARTMENT_ID) { + this.myUserInfo.USER_ID = '' + this.getFindUserListByDepId(DEPARTMENT_ID) }, - getFindUserList(DEPARTMENT_ID, index) { // 获取发现发现部门的人员信息 - this.listLoading = true - requestFN( - '/user/listAll', - { - DEPARTMENT_ID: DEPARTMENT_ID, - tm: new Date().getTime() - } - ).then((data) => { - this.$set(this.findUserList, index, data.userList) - }).catch((e) => { - this.listLoading = false + getFindUserListByDepId(DEPARTMENT_ID) { + return new Promise((resolve) => { + this.listLoading = true + requestFN( + '/user/listAll', + { + DEPARTMENT_ID: DEPARTMENT_ID, + tm: new Date().getTime() + } + ).then((data) => { + this.findUserList = data.userList + this.$forceUpdate() + resolve() + }).catch((e) => { + this.listLoading = false + }) }) }, + // getFindUserList(DEPARTMENT_ID, index) { // 获取发现发现部门的人员信息 + // this.listLoading = true + // requestFN( + // '/user/listAll', + // { + // DEPARTMENT_ID: DEPARTMENT_ID, + // tm: new Date().getTime() + // } + // ).then((data) => { + // this.$set(this.findUserList, index, data.userList) + // }).catch((e) => { + // this.listLoading = false + // }) + // }, updateConfirmDept() { // 根据选择的隐患确认部门显示隐患确认人 this.pd.CONFIRM_USER = '' this.listLoading = true diff --git a/src/views/hiddenApi/publicMethod/detail.vue b/src/views/hiddenApi/publicMethod/detail.vue index b6b5f86..e214305 100644 --- a/src/views/hiddenApi/publicMethod/detail.vue +++ b/src/views/hiddenApi/publicMethod/detail.vue @@ -393,6 +393,27 @@
+ +
@@ -488,7 +509,8 @@ export default { }, dialogVideoVisible: false, dialogViewPdf: false, - hiddenExamineList: [] + hiddenExamineList: [], + returnInformation: '' } }, @@ -510,6 +532,17 @@ export default { var vm = this vm.pd = data.hidden// 隐患信息 this.hiddenExamineList = data.hiddenExa // 特殊处置审核信息 隐患记录 + // 找出hiddenExamineList中验收打回日期最新的一条 + if (this.hiddenExamineList.length > 0) { + for (let i = 0; i < this.hiddenExamineList.length; i++) { + if (this.hiddenExamineList[i].TYPE === 3) { + this.returnInformation = this.hiddenExamineList[i] + if (this.returnInformation != '' && new Date(this.hiddenExamineList[i].CREATTIME).getTime() > new Date(this.returnInformation.CREATTIME).getTime()) { + this.returnInformation = this.hiddenExamineList[i] + } + } + } + } vm.hs = data.hs // 查询整改方案 vm.checkList = data.checkList // 验收信息 this.hImgs = data.hImgs // 图片 diff --git a/src/views/keyprojects/inspection/components/record-list.vue b/src/views/keyprojects/inspection/components/record-list.vue index 4157125..fec821b 100644 --- a/src/views/keyprojects/inspection/components/record-list.vue +++ b/src/views/keyprojects/inspection/components/record-list.vue @@ -54,9 +54,10 @@ - + @@ -78,6 +79,7 @@ export default { directives: { waves }, data() { return { + loginUserId: JSON.parse(sessionStorage.getItem('user')).USER_ID, listLoading: true, listQuery: { page: 1, @@ -132,6 +134,36 @@ export default { this.$parent.KEYPROJECTCHECK_ID = ID this.$parent.activeName = 'Info' }, + goDelete(ID) { + this.$confirm('是否删除该安全环保检查及以下隐患?', '提示', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning' + }).then(() => { + this.listLoading = true + requestFN( + '/keyprojectcheck/goDelete', + { + KEYPROJECTCHECK_ID: ID + } + ).then((data) => { + this.$message({ + type: 'success', + message: '删除成功!' + }) + this.listLoading = false + this.getList() + }).catch((e) => { + this.$message({ + type: 'info', + message: '删除失败!' + }) + this.listLoading = false + }) + }).catch(() => { + console.log('取消删除') + }) + }, back() { this.$parent.activeName = 'List' this.$parent.OUTSOURCED_ID = '' diff --git a/src/views/safetyenvironmental/archive/components/info.vue b/src/views/safetyenvironmental/archive/components/info.vue index 8bed751..172cb8c 100644 --- a/src/views/safetyenvironmental/archive/components/info.vue +++ b/src/views/safetyenvironmental/archive/components/info.vue @@ -75,9 +75,10 @@ {{ item.HIDDENDESCR }} 隐患部位 {{ item.HIDDENPART_NAME?item.HIDDENPART_NAME:item.HIDDENPART }} - + 查看 流程图 + 删除 @@ -308,6 +309,34 @@ export default { checkFlow(item) { this.$refs.flowChart.init(item) }, + goDelete(item) { + this.$confirm('确定要删除此隐患吗?', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning' + }).then(() => { + requestFN( + '/hiddenApi/deleteHiddenForSafetyenvironmental', + { + HIDDEN_ID: item.HIDDEN_ID, + tm: new Date().getTime() + } + ).then((res) => { + if (res.result === 'success') { + this.$message({ + message: '删除成功', + type: 'success' + }) + } else { + this.$message({ + message: res.codeMsg, + type: 'error' + }) + } + this.getData() + }).catch((e) => {}) + }).catch(() => {}) + }, goBack() { this.$parent.INSPECTION_ID = '' this.$parent.activeName = 'List' diff --git a/src/views/security_commitment/promise/components/list.vue b/src/views/security_commitment/promise/components/list.vue index 9e51cb6..626fa8e 100644 --- a/src/views/security_commitment/promise/components/list.vue +++ b/src/views/security_commitment/promise/components/list.vue @@ -45,7 +45,7 @@ 查看 启用 禁用 - 删除 + 删除 编辑 diff --git a/static/bi/index.html b/static/bi/index.html index e718d18..f4f6f37 100644 --- a/static/bi/index.html +++ b/static/bi/index.html @@ -13,6 +13,8 @@ + + @@ -140,32 +142,38 @@ 本年隐患
-
-
- 待处理 + +
+
+ 待处理 +
+
+ {{hdCount.yearUncheck}} +
-
- {{hdCount.yearUncheck}} + + +
+
+ 已处理 +
+
+ {{hdCount.yearChecked}} +
-
-
-
- 已处理 -
-
- {{hdCount.yearChecked}} -
-
-
-
- 隐患整改率 -
-
+ + +
+
+ 隐患整改率 +
+
{{hdCount.yearTotal==0?0:((hdCount.yearChecked/hdCount.yearTotal*100).toFixed(2))}} - % + % +
-
+
@@ -176,32 +184,38 @@ 本季隐患
-
-
- 待处理 + +
+
+ 待处理 +
+
+ {{hdCount.quarterUncheck}} +
-
- {{hdCount.quarterUncheck}} + + +
+
+ 已处理 +
+
+ {{hdCount.quarterChecked}} +
-
-
-
- 已处理 + + +
+
+ 隐患整改率 +
+
+ {{hdCount.quarterTotal==0?0:((hdCount.quarterChecked/hdCount.quarterTotal*100).toFixed(2))}} + % +
-
- {{hdCount.quarterChecked}} -
-
-
-
- 隐患整改率 -
-
- {{hdCount.quarterTotal==0?0:((hdCount.quarterChecked/hdCount.quarterTotal*100).toFixed(2))}} - % -
-
+
@@ -212,32 +226,38 @@ 本月隐患
-
-
- 待处理 + +
+
+ 待处理 +
+
+ {{hdCount.monthUncheck}} +
-
- {{hdCount.monthUncheck}} + + +
+
+ 已处理 +
+
+ {{hdCount.monthChecked}} +
-
-
-
- 已处理 + + +
+
+ 隐患整改率 +
+
+ {{hdCount.monthTotal==0?0:((hdCount.monthChecked/hdCount.monthTotal*100).toFixed(2))}} + % +
-
- {{hdCount.monthChecked}} -
-
-
-
- 隐患整改率 -
-
- {{hdCount.monthTotal==0?0:((hdCount.monthChecked/hdCount.monthTotal*100).toFixed(2))}} - % -
-
+
@@ -250,32 +270,38 @@ 本旬隐患
-
-
- 待处理 + +
+
+ 待处理 +
+
+ {{hdCount.xunUncheck}} +
-
- {{hdCount.xunUncheck}} + + +
+
+ 已处理 +
+
+ {{hdCount.xunChecked}} +
-
-
-
- 已处理 + + +
+
+ 隐患整改率 +
+
+ {{hdCount.xunTotal==0?0:((hdCount.xunChecked/hdCount.xunTotal*100).toFixed(2))}} + % +
-
- {{hdCount.xunChecked}} -
-
-
-
- 隐患整改率 -
-
- {{hdCount.xunTotal==0?0:((hdCount.xunChecked/hdCount.xunTotal*100).toFixed(2))}} - % -
-
+
@@ -286,32 +312,38 @@ 本周隐患
-
-
- 待处理 + +
+
+ 待处理 +
+
+ {{hdCount.weekUncheck}} +
-
- {{hdCount.weekUncheck}} + + +
+
+ 已处理 +
+
+ {{hdCount.weekChecked}} +
-
-
-
- 已处理 + + +
+
+ 隐患整改率 +
+
+ {{hdCount.weekTotal==0?0:((hdCount.weekChecked/hdCount.weekTotal*100).toFixed(2))}} + % +
-
- {{hdCount.weekChecked}} -
-
-
-
- 隐患整改率 -
-
- {{hdCount.weekTotal==0?0:((hdCount.weekChecked/hdCount.weekTotal*100).toFixed(2))}} - % -
-
+
@@ -322,32 +354,38 @@ 本日隐患
-
-
- 待处理 + +
+
+ 待处理 +
+
+ {{hdCount.dayUncheck}} +
-
- {{hdCount.dayUncheck}} + + +
+
+ 已处理 +
+
+ {{hdCount.dayChecked}} +
-
-
-
- 已处理 + + +
+
+ 隐患整改率 +
+
+ {{hdCount.dayTotal==0?0:((hdCount.dayChecked/hdCount.dayTotal*100).toFixed(2))}} + % +
-
- {{hdCount.dayChecked}} -
-
-
-
- 隐患整改率 -
-
- {{hdCount.dayTotal==0?0:((hdCount.dayChecked/hdCount.dayTotal*100).toFixed(2))}} - % -
-
+