From 6d1720731a3681d9248d8b3a7b1f60880085e463 Mon Sep 17 00:00:00 2001 From: wulin Date: Tue, 1 Sep 2020 16:56:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=8F=90=E4=BA=A4=E5=AE=A1?= =?UTF-8?q?=E6=89=B9=EF=BC=8C=E5=AE=A1=E6=89=B9=E3=80=82=E3=80=82=E3=80=82?= =?UTF-8?q?=E7=AD=89=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/modules/equipment/main.vue | 159 ++++++++++++++++++ .../record/recorddetail-add-or-update.vue | 35 +++- .../modules/result/record/recorddetail.vue | 11 +- 3 files changed, 193 insertions(+), 12 deletions(-) create mode 100644 src/views/modules/equipment/main.vue diff --git a/src/views/modules/equipment/main.vue b/src/views/modules/equipment/main.vue new file mode 100644 index 0000000..25ec54c --- /dev/null +++ b/src/views/modules/equipment/main.vue @@ -0,0 +1,159 @@ + + + + + diff --git a/src/views/modules/result/record/recorddetail-add-or-update.vue b/src/views/modules/result/record/recorddetail-add-or-update.vue index 1a5aca0..c03429c 100644 --- a/src/views/modules/result/record/recorddetail-add-or-update.vue +++ b/src/views/modules/result/record/recorddetail-add-or-update.vue @@ -210,10 +210,10 @@ export default { } if (this.keyResultEditorElem3_5 !== null) { - this.keyResultEditorElem3_5.txt.html('无') + this.keyResultEditorElem3_5.txt.html('

') } if (this.keyResultEditorElem3_7 !== null) { - this.keyResultEditorElem3_7.txt.html('无') + this.keyResultEditorElem3_7.txt.html('

') } this.visible = true this.$nextTick(async () => { @@ -273,10 +273,12 @@ export default { this.keyResultEditorElem3_7.$textElem.attr('contenteditable', false) } } + if (this.dataForm.id && this.dataForm.id > 0) { const data = await apiDetailInfo(this.dataForm.id) if (data && data.code === 0) { this.dataForm = data.detailInfo + console.log(this.dataForm.keyResult37) if (this.keyResultEditor !== null) { this.keyResultEditor.txt.html(this.dataForm.keyResult || '') } @@ -286,11 +288,19 @@ export default { if (this.scoreCommentEditor !== null) { this.scoreCommentEditor.txt.html(this.dataForm.scoreComment || '') } - if (this.keyResultEditorElem3_5 !== null) { - this.keyResultEditorElem3_5.txt.html(this.dataForm.keyResult35 || '无') + if (this.keyResultEditorElem3_5 !== null){ + if(this.dataForm.keyResult35 !== null) { + this.keyResultEditorElem3_5.txt.html(this.dataForm.keyResult35 || '') + }else{ + this.keyResultEditorElem3_5.txt.html('

') + } } if (this.keyResultEditorElem3_7 !== null) { - this.keyResultEditorElem3_7.txt.html(this.dataForm.keyResult37 || '无') + if(this.dataForm.keyResult37 !== null) { + this.keyResultEditorElem3_7.txt.html(this.dataForm.keyResult35 || '') + }else{ + this.keyResultEditorElem3_7.txt.html('

') + } } } } @@ -309,7 +319,8 @@ export default { }) }, stringIsNull (str) { - if (typeof str === 'undefined' || str === null || str === '') { + console.log('比较' + str) + if (typeof str === 'undefined' || str === null || str === '' || str === '


') { return true } return false @@ -327,6 +338,18 @@ export default { return } } + if (this.auth.keyResult35 === 2 && this.type === 1) { + if (this.stringIsNull(this.keyResultEditorElem3_5.txt.html())) { + this.alertInfo('3.5考核标准不能为空') + return + } + } + if (this.auth.keyResult37 === 2 && this.type === 1) { + if (this.stringIsNull(this.keyResultEditorElem3_7.txt.html())) { + this.alertInfo('3.7考核标准不能为空') + return + } + } if (this.auth.checkWeight === 2) { if (this.stringIsNull(this.dataForm.checkWeight)) { this.alertInfo('权重不能为空') diff --git a/src/views/modules/result/record/recorddetail.vue b/src/views/modules/result/record/recorddetail.vue index cf72e00..c280191 100644 --- a/src/views/modules/result/record/recorddetail.vue +++ b/src/views/modules/result/record/recorddetail.vue @@ -28,23 +28,22 @@
-

提交审批

+ 提交审批

- - - + 审批 +

-

确认得分

+ 确认得分
-

+ 驳回