diff --git a/jero-web/src/components/SelectedBy/index.vue b/jero-web/src/components/SelectedBy/index.vue index 35711e606..13c9683ae 100644 --- a/jero-web/src/components/SelectedBy/index.vue +++ b/jero-web/src/components/SelectedBy/index.vue @@ -67,7 +67,8 @@ departId: '', defaultExpandedKeys: [], submitLoading: false, - visibleTree: false + visibleTree: false, + userName: [] } }, mounted() { @@ -110,7 +111,7 @@ } if (this.userIds && this.userIds.length > 0) { this.submitLoading = true - this.$emit('SelectedByForm', this.userIds.join(',')) + this.$emit('SelectedByForm', this.userIds.join(','),this.userName.join(',')) } else { this.$message.warning(this.$t('selectLeastOne')) } @@ -142,7 +143,7 @@ postAction('sys/user/queryDepartUserTreeList', { departId: this.departId, json: gData, - flag:'1' + flag: '1' }).then((res) => { this.confirmLoading = false if (res.success) { @@ -155,8 +156,14 @@ } }) }, - checkChange(e) { + checkChange(e, name) { + this.userName = [] this.userIds = e + if (name.checkedNodes && name.checkedNodes.length > 0) { + name.checkedNodes.forEach(res => { + this.userName.push(res.data.props.dataRef.title) + }) + } } } } diff --git a/jero-web/src/views/projectManagement/components/certificationDirectoryAdd.vue b/jero-web/src/views/projectManagement/components/certificationDirectoryAdd.vue index 59c7a4b5c..1179cf11d 100644 --- a/jero-web/src/views/projectManagement/components/certificationDirectoryAdd.vue +++ b/jero-web/src/views/projectManagement/components/certificationDirectoryAdd.vue @@ -10,14 +10,14 @@ :visible="visible" style="height: 100%;overflow: auto;padding-bottom: 53px;"> - +
{{$t('directoryName')}}
- + {{$t('batch')}}
- + {{$t('testReportLocation')}} - + {{$t('explain')}} - + { + this.$refs.ruleForm.clearValidate() + }) }, edit(val) { this.visible = true this.$nextTick(() => { this.formInline = val + this.$refs.ruleForm.clearValidate() }) }, handleCancel() { this.visible = false }, handleSubmit() { - if (!this.formInline.directoryName && !this.formInline.lot && !this.formInline.directoryFile && - !this.formInline.experimentFile && !this.formInline.detectionReportLocation && !this.formInline.explainInfo) { - this.$message.warning(this.$t('dataCannotEmpty')) - } else { - let Action - let url = '' - if (this.formInline.id) { - url = this.url.edit - Action = putAction - } else { - url = this.url.add - Action = postAction - } - let query = { - projectLibraryId: this.$route.query.id, - ...this.formInline - } - this.confirmLoading = true - Action(url, query).then((res) => { - if (res.success) { - this.$message.success(this.$t('OperationSuccessful')) - this.visible = false - this.confirmLoading = false - this.$emit('certificationDirectoryList') - } else { - this.confirmLoading = false - this.$message.warning(res.message) - } - }) - } + this.$refs.ruleForm.validate(valid => { + if (valid){ + if (!this.formInline.directoryName && !this.formInline.lot && !this.formInline.directoryFile && + !this.formInline.experimentFile && !this.formInline.detectionReportLocation && !this.formInline.explainInfo) { + this.$message.warning(this.$t('dataCannotEmpty')) + } else { + let Action + let url = '' + if (this.formInline.id) { + url = this.url.edit + Action = putAction + } else { + url = this.url.add + Action = postAction + } + let query = { + projectLibraryId: this.$route.query.id, + ...this.formInline + } + this.confirmLoading = true + Action(url, query).then((res) => { + if (res.success) { + this.$message.success(this.$t('OperationSuccessful')) + this.visible = false + this.confirmLoading = false + this.$emit('certificationDirectoryList') + } else { + this.confirmLoading = false + this.$message.warning(res.message) + } + }) + } + } + }) }, clickButtonToUpload(item) { this.$refs.uploadFile.perentHandleFunc() diff --git a/jero-web/src/views/toDoCenter/projectRegulationTasks/components/reviewedByThePersonInCharge.vue b/jero-web/src/views/toDoCenter/projectRegulationTasks/components/reviewedByThePersonInCharge.vue index 82e7dcb05..8b31bb419 100644 --- a/jero-web/src/views/toDoCenter/projectRegulationTasks/components/reviewedByThePersonInCharge.vue +++ b/jero-web/src/views/toDoCenter/projectRegulationTasks/components/reviewedByThePersonInCharge.vue @@ -49,6 +49,9 @@ {{$t('turnToDo')}} + + {{this.formInline.dezrrSubmitUserName}} +
@@ -184,16 +187,21 @@ } else { this.$refs.SelectedByRef.visible = false this.formInline.secondChargePersonUserId = '' + this.formInline.dezrrSubmitUserName = '' + this.formInline.dezrrSubmitUserId = '' } }, //转办接口 - SelectedByForm(userIds) { + SelectedByForm(userIds, name) { if (this.query.TaskKey == 'zrrtjjfw') { this.formInline.dezrrSubmitUserId = userIds } else { this.formInline.secondChargePersonUserId = userIds } + this.formInline.dezrrSubmitUserName = name + this.formInline = { ...this.formInline } this.$refs.SelectedByRef.visible = false + this.$refs.SelectedByRef.submitLoading = false }, submitNoRule(callBack) { callBack(this.formInline)