Commit c8b0095b by Joey

fix: 单据提交时没有刷新

parent d87ac7b3
...@@ -142,6 +142,13 @@ export default { ...@@ -142,6 +142,13 @@ export default {
this.init = true; this.init = true;
}); });
}); });
GMS.vbus.$on("workflow-state-change", (val) => {
console.log('refresh', val)
this.init = false;
this.$nextTick(() => {
this.init = true;
})
})
GMS.vbus.$on("submitSuccess", (res, param) => { GMS.vbus.$on("submitSuccess", (res, param) => {
GMS.vbus.$emit("custom-query-refresh"); GMS.vbus.$emit("custom-query-refresh");
GMS.vbus.$emit("tab-count-refresh"); GMS.vbus.$emit("tab-count-refresh");
...@@ -169,6 +176,7 @@ export default { ...@@ -169,6 +176,7 @@ export default {
GMS.vbus.$off("saveSuccess"); GMS.vbus.$off("saveSuccess");
GMS.vbus.$off("submitSuccess"); GMS.vbus.$off("submitSuccess");
GMS.vbus.$off("change-form-state"); GMS.vbus.$off("change-form-state");
GMS.vbus.$off("workflow-state-change")
}, },
}; };
</script> </script>
......
...@@ -55,15 +55,16 @@ export default { ...@@ -55,15 +55,16 @@ export default {
} }
} }
// 监听工作流状态改变 // 监听工作流状态改变
GMS.vbus.$on("workflow-state-change", (val) => { GMS.vbus.$on("workflow-state-change", this.handleWorkflowStateChange)
this.workflowState = val
this.getBtnGroup()
})
}, },
beforeDestroy() { beforeDestroy() {
GMS.vbus.$off("workflow-state-change"); GMS.vbus.$off("workflow-state-change", this.handleWorkflowStateChange);
}, },
methods: { methods: {
handleWorkflowStateChange(val) {
this.workflowState = val
this.getBtnGroup()
},
checkParent() { checkParent() {
let curNode = this.$refs.btnGroup let curNode = this.$refs.btnGroup
while (curNode) { while (curNode) {
......
...@@ -56,8 +56,16 @@ export default { ...@@ -56,8 +56,16 @@ export default {
// this.type = 'load' // this.type = 'load'
}); });
}); });
GMS.vbus.$on("workflow-state-change", (val) => {
console.log('refresh', val)
this.init = false;
this.$nextTick(() => {
this.init = true;
})
})
}, },
beforeDestroy() { beforeDestroy() {
GMS.vbus.$off("workflow-state-change")
GMS.vbus.$off("change-form-state"); GMS.vbus.$off("change-form-state");
this.$portalAPI.off('on-close-tag', this.checkBillChange) this.$portalAPI.off('on-close-tag', this.checkBillChange)
}, },
......
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