diff --git a/src/views/customerOrg/customerOrgGroup.vue b/src/views/customerOrg/customerOrgGroup.vue index efe62c9..6e92a3c 100644 --- a/src/views/customerOrg/customerOrgGroup.vue +++ b/src/views/customerOrg/customerOrgGroup.vue @@ -608,23 +608,27 @@ export default { let customerOrgGroupAsbitems = [] //分组包含的套餐 //编辑 - putapi(`/api/app/customer-org-group/${this.form.id}`, body).then(res => { - if (res.code != -1) { + putapi(`/api/app/customer-org-group/${this.form.id}`, body) + .then(res => { + // console.log(res) + if (res.code != -1) { + console.log("保存分组成功!"); let lfind = arrayExistObj( this.customerOrgGroups, "id", this.form.id ); if (lfind > -1) objCopy(this.form, this.customerOrgGroups[lfind]); - if(this.formOri.price != this.form.price){ + console.log('this.formOri.price != this.form.price',this.formOri.price,this.form.price) + if(this.formOri.price != this.form.price){ return getapi(`/api/app/customerorggroupdetail/getcustomerorggroupdetailinasbitem?CustomerOrgGroupId=${customerOrgGroupId}`) } } }).then(res =>{ - if(res.code != -1){ + if(res && res.code != -1){ customerOrgGroupAsbitems = res.data; if(customerOrgGroupAsbitems.length < 1){ - console.log("操作成功!"); + console.log("该分组暂没有组合项目!"); this.dialogVisible = false; }else{ let detailsBody = { @@ -635,7 +639,7 @@ export default { } } }).then(res =>{ - if(res.code != -1){ + if(res && res.code != -1){ console.log("操作成功!并自动按总价同比折算组合项目价格!"); this.dialogVisible = false; // 刷新明细