Commit d9cc80fc by caoyanzhi

fix: 修复新建分组bug

parent 3349442c
......@@ -1254,7 +1254,7 @@ export default {
/**
* 检查模板code
*/
checkTemplageCode(template) {
async checkTemplageCode(template) {
this.templateData = [];
let middleTemplate = JSON.parse(template);
if (middleTemplate) {
......@@ -1264,7 +1264,7 @@ export default {
this.currentComputeType = templateVal.compute.computeType >> 0;
if (this.currentComputeType === 0 && !!templateVal.compute.computeWidgetId) {
this.getTemplateCodeById(templateVal.compute.computeWidgetId);
await this.getTemplateCodeById(templateVal.compute.computeWidgetId);
}
// 固定计算属性(最后保存用到)
if (this.currentComputeType === 1) {
......@@ -1273,28 +1273,16 @@ export default {
// 门店
if (!!templateVal.valWidgetId) {
setTimeout(_ => {
this.getTemplateCodeById(templateVal.valWidgetId);
}, 50);
await this.getTemplateCodeById(templateVal.valWidgetId);
}
if (!!newTime.length) {
if (this.currentComputeType === 1) {
setTimeout(_ => {
newTime.forEach((ele, index) => {
if (!!ele.timeWidgetId) {
this.getTemplateCodeById(ele.timeWidgetId);
}
});
}, 200);
} else {
setTimeout(_ => {
newTime.forEach((ele, index) => {
if (!!ele.timeWidgetId) {
this.getTemplateCodeById(ele.timeWidgetId);
}
});
}, 200);
}
setTimeout(_ => {
newTime.forEach((ele, index) => {
if (!!ele.timeWidgetId) {
this.getTemplateCodeById(ele.timeWidgetId);
}
});
}, 200);
}
}
},
......@@ -1306,7 +1294,7 @@ export default {
widgetId: id,
requestProject: 'gic-member-tag-web'
};
findWidget(param)
return findWidget(param)
.then(res => {
if (res.errorCode == 1) {
let data = res.result;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment