From 5a0ce986264bd2a25b4597b36eaf15dcedf98d56 Mon Sep 17 00:00:00 2001 From: dwithana Date: Wed, 11 Dec 2024 13:47:17 -0500 Subject: [PATCH] Use v-b-modal.modal-lg directive to open search modal --- src/components/dashboard/Dashboard.vue | 2 -- src/components/entity/EntityList.vue | 3 ++- src/components/entity/ItemSearch.vue | 15 +-------------- src/components/shared/Search.vue | 9 +++++++-- src/components/supplement/SupplementList.vue | 2 +- src/components/workflow/WorkflowList.vue | 7 +------ 6 files changed, 12 insertions(+), 26 deletions(-) diff --git a/src/components/dashboard/Dashboard.vue b/src/components/dashboard/Dashboard.vue index 975c595..225fe1b 100644 --- a/src/components/dashboard/Dashboard.vue +++ b/src/components/dashboard/Dashboard.vue @@ -1187,8 +1187,6 @@ export default { ); break; } - - this.$bvModal?.show("modal-lg"); }, getDateString() { const date = new Date(); diff --git a/src/components/entity/EntityList.vue b/src/components/entity/EntityList.vue index cbd72eb..012f15f 100644 --- a/src/components/entity/EntityList.vue +++ b/src/components/entity/EntityList.vue @@ -723,6 +723,7 @@ @@ -68,11 +68,6 @@ export default { searchItems(searchWord) { this.refreshData(searchWord); }, - - // pop up child component (the Search pop-up ialog) - onSearch() { - this.$bvModal?.show("modal-lg"); - }, // call item search API async refreshData(searchWord = "") { @@ -101,14 +96,6 @@ export default { } }, }, - - updated() { - this.onSearch(); - }, - - mounted() { - this.onSearch(); - }, }; diff --git a/src/components/shared/Search.vue b/src/components/shared/Search.vue index 938a76c..4870789 100644 --- a/src/components/shared/Search.vue +++ b/src/components/shared/Search.vue @@ -4,10 +4,11 @@ size="lg" id="modal-lg" centered + ref="searchModal" @show="processModalData()" :no-close-on-backdrop="type === 'item-search'" > - -