From 2ac20d5f15dc8794a0ddbc945a3bc771ca9a3f28 Mon Sep 17 00:00:00 2001 From: jorgep Date: Thu, 8 Feb 2024 12:11:12 +0100 Subject: [PATCH] feat: refs #6657 create component & composable --- src/components/common/VnSummaryDialog.vue | 23 +++++++++++++++++++ src/composables/useSummaryDialog.js | 15 ++++++++++++ src/pages/Claim/ClaimList.vue | 12 +++++----- src/pages/Customer/CustomerList.vue | 17 ++++---------- .../CustomerExtendedListActions.vue | 19 ++++----------- src/pages/Entry/EntryList.vue | 19 ++++----------- src/pages/InvoiceIn/InvoiceInList.vue | 17 ++++---------- src/pages/InvoiceOut/InvoiceOutList.vue | 17 ++++---------- src/pages/Order/OrderList.vue | 17 ++++---------- src/pages/Shelving/ShelvingList.vue | 17 ++++---------- src/pages/Supplier/SupplierList.vue | 19 ++++----------- src/pages/Ticket/TicketList.vue | 17 ++++---------- src/pages/Travel/TravelList.vue | 19 ++++----------- src/pages/Worker/WorkerList.vue | 17 ++++---------- test/cypress/integration/vnLog.spec.js | 2 +- 15 files changed, 90 insertions(+), 157 deletions(-) create mode 100644 src/components/common/VnSummaryDialog.vue create mode 100644 src/composables/useSummaryDialog.js diff --git a/src/components/common/VnSummaryDialog.vue b/src/components/common/VnSummaryDialog.vue new file mode 100644 index 000000000..08fc8870d --- /dev/null +++ b/src/components/common/VnSummaryDialog.vue @@ -0,0 +1,23 @@ + + diff --git a/src/composables/useSummaryDialog.js b/src/composables/useSummaryDialog.js new file mode 100644 index 000000000..7d431129b --- /dev/null +++ b/src/composables/useSummaryDialog.js @@ -0,0 +1,15 @@ +import VnSummaryDialog from 'src/components/common/VnSummaryDialog.vue'; +import { useQuasar } from 'quasar'; + +export function useSummaryDialog() { + const quasar = useQuasar(); + + function viewSummary(id, summary) { + quasar.dialog({ + component: VnSummaryDialog, + componentProps: { id, summary }, + }); + } + + return { viewSummary }; +} diff --git a/src/pages/Claim/ClaimList.vue b/src/pages/Claim/ClaimList.vue index 1b5979f5a..492963399 100644 --- a/src/pages/Claim/ClaimList.vue +++ b/src/pages/Claim/ClaimList.vue @@ -1,7 +1,6 @@