diff --git a/src/components/feedBackTable/fun.js b/src/components/feedBackTable/fun.js index d3083b5a..7e970a9f 100644 --- a/src/components/feedBackTable/fun.js +++ b/src/components/feedBackTable/fun.js @@ -3,7 +3,7 @@ import FEEDBACKCOMP from "./index.vue"; const FBConstructor = Vue.extend(FEEDBACKCOMP); const FBT = (options = {}) => { - const { data = {} } = options; + const { data = {}, callBack } = options; // if (!UserId) throw `UserId is requred.but ${UserId}` const id = `FB${new Date().getTime()}`; const instance = new FBConstructor(); @@ -13,6 +13,7 @@ const FBT = (options = {}) => { document.body.appendChild(instance.vm.$el); instance.vm.open({ ...data }); instance.vm.$on("success", (Id) => { + if (callBack) callBack(); }); instance.vm.$on("closed", () => { document.body.removeChild(instance.vm.$el); diff --git a/src/components/feedBackTable/index.vue b/src/components/feedBackTable/index.vue index d4bb1d11..bc957de7 100644 --- a/src/components/feedBackTable/index.vue +++ b/src/components/feedBackTable/index.vue @@ -10,7 +10,7 @@
{{ title }}
- + @@ -46,6 +46,9 @@ export default { return `${this.$t("feedBack:table:title")}`; } }, + success() { + this.$emit("success"); + }, }, }; diff --git a/src/views/feedBack/index.vue b/src/views/feedBack/index.vue index d5a6e827..63f6bd21 100644 --- a/src/views/feedBack/index.vue +++ b/src/views/feedBack/index.vue @@ -116,14 +116,14 @@ > {{ $t("common:button:reset") }} - {{ $t("common:button:export") }} - + --> { this.getList(); + this.$emit("success"); }, }); }, diff --git a/src/views/trials/trials-panel/trial-summary/trial-information/index.vue b/src/views/trials/trials-panel/trial-summary/trial-information/index.vue index 17553d56..11664b4c 100644 --- a/src/views/trials/trials-panel/trial-summary/trial-information/index.vue +++ b/src/views/trials/trials-panel/trial-summary/trial-information/index.vue @@ -179,6 +179,9 @@ export default { name: this.$route.query.researchProgramNo, trialId: this.trialId, }, + callBack: () => { + this.initForm(); + }, }); }, },