Commit bddde292 by qiaoyanqi

切换页签j加tag

parent 120cd9bd
...@@ -112,11 +112,12 @@ export default { ...@@ -112,11 +112,12 @@ export default {
bill.getMasterData().setValue("billCode", response.data.content.billData.billCode); bill.getMasterData().setValue("billCode", response.data.content.billData.billCode);
const id = response.data.content.billData.id; const id = response.data.content.billData.id;
initIndexZero();//处理上张下张 initIndexZero();//处理上张下张
let curTagId = window.nros.context.getCurrTag();
GMS.vbus.$Message.success("保存成功"); GMS.vbus.$Message.success("保存成功");
if (param.param && param.param.isApprove) { if (param.param && param.param.isApprove) {
GMS.vbus.$emit('change-form-state', { state: ''}) GMS.vbus.$emit('change-form-state', { state: ''},curTagId)
} else { } else {
GMS.vbus.$emit('change-form-state', { state: 'readOnly', billId: id}) GMS.vbus.$emit('change-form-state', { state: 'readOnly', billId: id},curTagId)
} }
// GMS.vbus.$emit("saveSuccess", buidData, param); // GMS.vbus.$emit("saveSuccess", buidData, param);
} else { } else {
......
...@@ -86,7 +86,8 @@ export default { ...@@ -86,7 +86,8 @@ export default {
const id = data.content.billData.id; const id = data.content.billData.id;
minusIndex();//上张下张用 minusIndex();//上张下张用
GMS.$hideContainer.$Message.success('提交成功'); GMS.$hideContainer.$Message.success('提交成功');
GMS.vbus.$emit("workflow-state-change", 90) let curTagId = window.nros.context.getCurrTag();
GMS.vbus.$emit("workflow-state-change", 90,curTagId);
} else if (code === 201) { } else if (code === 201) {
GMS.$hideContainer.$Spin.hide() GMS.$hideContainer.$Spin.hide()
data.message && GMS.$hideContainer.$Message.error({ data.message && GMS.$hideContainer.$Message.error({
......
...@@ -57,7 +57,10 @@ export default { ...@@ -57,7 +57,10 @@ export default {
this.$portalAPI.off('on-close-tag', this.checkBillChange) this.$portalAPI.off('on-close-tag', this.checkBillChange)
}, },
methods: { methods: {
changeFormState(param){ changeFormState(param,curTagId){
if(curTagId!=this.curTagId){
return
}
if(param && Object.prototype.toString.call(param)=='[object Object]'){ if(param && Object.prototype.toString.call(param)=='[object Object]'){
const { state, billId } = param; const { state, billId } = param;
if (billId !== undefined) { if (billId !== undefined) {
...@@ -70,6 +73,18 @@ export default { ...@@ -70,6 +73,18 @@ export default {
this.init = true; this.init = true;
}); });
}, },
changeData(billId,state,curTagId) {
if(curTagId!=this.curTagId){
return
}
this.init = false;
this.$nextTick(() => {
this.type = 'load';
this.state = state;
this.init = true;
this.billId = billId;
});
},
checkBillChange(cb, id) { checkBillChange(cb, id) {
if (id != this.curTagId) { if (id != this.curTagId) {
cb(true) cb(true)
...@@ -110,18 +125,6 @@ export default { ...@@ -110,18 +125,6 @@ export default {
GMS.oldBillDataMap[this.curTagId] = bill.getBuillData() GMS.oldBillDataMap[this.curTagId] = bill.getBuillData()
}, 100); }, 100);
}, },
changeData(billId,state,curTagId) {
if(curTagId!=this.curTagId){
return
}
this.init = false;
this.$nextTick(() => {
this.type = 'load';
this.state = state;
this.init = true;
this.billId = billId;
});
},
}, },
}; };
</script> </script>
......
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