This commit is contained in:
2024-04-08 11:08:38 +08:00
parent 9e142de3de
commit 327758740b
6 changed files with 94 additions and 5 deletions

View File

@ -82,6 +82,7 @@ import { typelist } from "@/api/manage/template";
import { department, listDisease } from "@/api/manage/script";
export default {
props: ['templateId', 'templateName'],
name: "Template",
data() {
return {
@ -143,8 +144,22 @@ export default {
name(val) {
this.querydepartmen.departmentName = val
this.Departmentlist();
},
templateId(newValue, oldValue) {
if (newValue) {
this.handleselectId = newValue;
}
},
templateName(newValue, oldValue) {
if (newValue) {
this.handleselectName = newValue;
}
}
},
mounted() {
this.handleselectId = this.templateId;
this.handleselectName = this.templateName;
},
created() {
this.getList();
this.Departmentlist();

View File

@ -80,6 +80,7 @@
<script>
import { listTemplate, getTemplate, delTemplate, addTemplate, updateTemplate, listWechatTemplateNum, typelist } from "@/api/manage/template";
export default {
props: ['templateId', 'templateName'],
name: "miniProgram",
data() {
return {
@ -143,8 +144,22 @@ export default {
name(val) {
this.querydepartmen.departmentName = val
this.Departmentlist();
},
templateId(newValue, oldValue) {
if (newValue) {
this.handleselectId = newValue;
}
},
templateName(newValue, oldValue) {
if (newValue) {
this.handleselectName = newValue;
}
}
},
mounted() {
this.handleselectId = this.templateId;
this.handleselectName = this.templateName;
},
created() {
this.getList();
this.Departmentlist();

View File

@ -80,6 +80,7 @@
<script>
import { listTemplate, getTemplate, delTemplate, addTemplate, updateTemplate, listWechatTemplateNum, typelist } from "@/api/manage/template";
export default {
props: ['templateId', 'templateName'],
name: "officialAccount",
data() {
return {
@ -143,8 +144,22 @@ export default {
name(val) {
this.querydepartmen.departmentName = val
this.Departmentlist();
},
templateId(newValue, oldValue) {
if (newValue) {
this.handleselectId = newValue;
}
},
templateName(newValue, oldValue) {
if (newValue) {
this.handleselectName = newValue;
}
}
},
mounted() {
this.handleselectId = this.templateId;
this.handleselectName = this.templateName;
},
created() {
this.getList();
this.Departmentlist();

View File

@ -90,6 +90,7 @@ import { listPropaganda, getPropaganda, delPropaganda, addPropaganda, updateProp
import stationAcatar from "../../system/stationAvatar/index.vue";
export default {
name: "propaganda",
props: ['templateId', 'templateName'],
components: { stationAcatar },
data() {
return {
@ -158,6 +159,22 @@ export default {
},
};
},
mounted() {
this.handleselectId = this.templateId
this.handleselectName = this.templateName
},
watch: {
templateId(newValue, oldValue) {
if (newValue) {
this.handleselectId = newValue;
}
},
templateName(newValue, oldValue) {
if (newValue) {
this.handleselectName = newValue;
}
}
},
computed: {
pickerStartTime() {
return {

View File

@ -76,6 +76,7 @@ import { listQuestion, getQuestion, delQuestion, addQuestion, updateQuestion, ge
export default {
name: "Question",
props: ['templateId', 'templateName'],
data() {
return {
classificationOpen: false,
@ -117,6 +118,22 @@ export default {
this.getTreeselect();
this.getList();
},
mounted() {
this.handleselectId = this.templateId
this.handleselectName = this.templateName
},
watch: {
templateId(newValue, oldValue) {
if (newValue) {
this.handleselectId = newValue;
}
},
templateName(newValue, oldValue) {
if (newValue) {
this.handleselectName = newValue;
}
}
},
methods: {
clickDepartmenitem(item) {
this.loading = true;

View File

@ -88,10 +88,12 @@
</el-form-item>
<el-form-item label="问卷库模板选择" prop=""
v-if="form.taskSubdivisiontemplateType == 'QUESTIONNAIRE'">
<question @on-template="questionontemplate"></question>
<question @on-template="questionontemplate" :templateId="form.templateId"
:templateName="form.templateName"></question>
</el-form-item>
<el-form-item label="宣教库模板选择" prop="" v-if="form.taskSubdivisiontemplateType == 'PROPAGANDA'">
<propaganda @on-template="propagandaontemplate"></propaganda>
<propaganda @on-template="propagandaontemplate" :templateId="form.templateId"
:templateName="form.templateName"></propaganda>
</el-form-item>
</el-form>
</div>
@ -108,7 +110,8 @@
</div>
<div class="pushMethod">
模板
<message @on-template="messageontemplate"></message>
<message @on-template="messageontemplate" :templateId="form.messageTemplateId"
:templateName="form.messageTemplateName"></message>
</div>
<div class="pushMethod">
<el-switch v-model="form.messagePushSign" active-color="#13ce66" active-value="1"
@ -134,7 +137,9 @@
<div class="pushMethod">
模板
<span>
<officialAccount @on-template="officialAccountontemplate"></officialAccount>
<officialAccount @on-template="officialAccountontemplate"
:templateId="form.officialTemplateId" :templateName="form.officialTemplateName">
</officialAccount>
</span>
</div>
<div class="pushMethod">
@ -161,7 +166,9 @@
<div class="pushMethod">
模板
<span>
<miniProgram @on-template="miniProgramtemplate"></miniProgram>
<miniProgram @on-template="miniProgramtemplate"
:templateId="form.appletTemplateId" :templateName="form.appletTemplateName">
</miniProgram>
</span>
</div>
<div class="pushMethod">
@ -323,6 +330,9 @@ export default {
e.taskType = Number(e.taskType)
e.taskSubdivision = Number(e.taskSubdivision)
e.taskStatus = Number(e.taskStatus)
e.messagePushSign = '' + e.messagePushSign
e.officialPushSign = '' + e.officialPushSign
e.appletPushSign = '' + e.appletPushSign
this.changeTaskType(e.taskType, e.taskSubdivision)
let item = {
routeNodeName: e.routeNodeName,