stash
This commit is contained in:
parent
caf5d2d11f
commit
7b958cbff0
1 changed files with 14 additions and 0 deletions
|
@ -83,6 +83,20 @@ export default {
|
|||
});
|
||||
this.fetchMessageTemplateVariables();
|
||||
},
|
||||
watch: {
|
||||
messageTemplates() {
|
||||
for (const template of this.messageTemplates) {
|
||||
if (!this.messageTemplatesIntermediate.find(t => t.id === template.id)) {
|
||||
this.messageTemplatesIntermediate.push(JSON.parse(JSON.stringify(template)));
|
||||
}
|
||||
}
|
||||
for (const template of this.messageTemplatesIntermediate) {
|
||||
if (!this.messageTemplates.find(t => t.id === template.id)) {
|
||||
this.messageTemplatesIntermediate = this.messageTemplatesIntermediate.filter(t => t.id !== template.id);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
|
|
Loading…
Reference in a new issue