From 145aca4ce40cbdb14f940975da44db63eb5c497f Mon Sep 17 00:00:00 2001 From: fujunling <2984387807@qq.com> Date: 星期三, 26 七月 2023 17:38:38 +0800 Subject: [PATCH] fjl --- Source/UBCS-WEB/src/components/template/SetPersonnel.vue | 16 +++++++++------- 1 files changed, 9 insertions(+), 7 deletions(-) diff --git a/Source/UBCS-WEB/src/components/template/SetPersonnel.vue b/Source/UBCS-WEB/src/components/template/SetPersonnel.vue index cf03538..2a71099 100644 --- a/Source/UBCS-WEB/src/components/template/SetPersonnel.vue +++ b/Source/UBCS-WEB/src/components/template/SetPersonnel.vue @@ -76,7 +76,6 @@ visible(n) { this.dialogVisible = n; if (n) { - this.saveParam=this.setSaveParam(); this.apiInit() this.apiDict() } @@ -86,7 +85,6 @@ }, users:{ handler(val){ - console.log('鐩戝惉users',val) this.collectParam.flowTaskUsers = val }, deep:true, @@ -94,8 +92,9 @@ }, parameter:{ handler(newval,oldval){ - console.log('瀛�',newval) - } + this.saveParam=newval + },deep:true, + immediate:true } }, data() { @@ -106,7 +105,7 @@ tags: [], typeName: [], collectParam: {}, - saveParam: this.setSaveParam(), + saveParam: {}, users: [], rules: { processName: [ @@ -119,7 +118,7 @@ mounted() { }, - created() { + created() { }, methods: { setSaveParam() { @@ -136,7 +135,6 @@ async apiInit() { const response = await personnelInit({ type: this.parameter[this.parameterKeys.type], templateId: this.parameter[this.parameterKeys.code]}) if (response.status === 200) { - console.log(response) this.initFrom = response.data.data.user this.tags = response.data.data.collect const { modelKey, templateId, modelName } = response.data.data.flow @@ -144,7 +142,9 @@ this.collectParam = { modelKey, templateId, flowTaskUsers: flowTaskUsers } this.users = response.data.data.user console.log(this.collectParam) + console.log('this.saveParam.before',this.saveParam) this.saveParam = { ...this.saveParam, modelKey, templateId, modelName } + console.log('this.saveParam',this.saveParam) if (this.tags.length !== 0) this.handleClickTag(this.tags[0]) } }, @@ -200,6 +200,7 @@ console.log(this.collectParam.flowTaskUsers) console.log(len == 0) console.log(len != this.initFrom.length) + console.log('saveParam',this.saveParam) if (len == 0 && len != this.initFrom.length) { this.$message({ type: "error", @@ -208,6 +209,7 @@ } else { const {modelKey,modelName,processDesc,processName,templateId,topName,vars,ids} = this.saveParam const vals= {modelKey,modelName,processDesc,processName,templateId,topName,ids,...vars} + console.log('vals',vals); const response = await personnelSave({ variables:vals, flowTaskUsers: this.collectParam.flowTaskUsers, }) if (response.status === 200) { console.log(response) -- Gitblit v1.9.3