diff --git a/src/pages/Claim/Card/ClaimDescriptor.vue b/src/pages/Claim/Card/ClaimDescriptor.vue index af7e84d38..dafdfacdd 100644 --- a/src/pages/Claim/Card/ClaimDescriptor.vue +++ b/src/pages/Claim/Card/ClaimDescriptor.vue @@ -7,6 +7,7 @@ import { useState } from 'src/composables/useState'; import TicketDescriptorProxy from 'pages/Ticket/Card/TicketDescriptorProxy.vue'; import WorkerDescriptorProxy from 'src/pages/Worker/Card/WorkerDescriptorProxy.vue'; +import CustomerDescriptorProxy from 'src/pages/Customer/Card/CustomerDescriptorProxy.vue'; import ClaimDescriptorMenu from 'pages/Claim/Card/ClaimDescriptorMenu.vue'; import CardDescriptor from 'components/ui/CardDescriptor.vue'; import VnLv from 'src/components/ui/VnLv.vue'; @@ -113,7 +114,7 @@ const setData = (entity) => { @@ -121,7 +122,7 @@ const setData = (entity) => { diff --git a/src/pages/Claim/ClaimList.vue b/src/pages/Claim/ClaimList.vue index cbc51174f..096da642e 100644 --- a/src/pages/Claim/ClaimList.vue +++ b/src/pages/Claim/ClaimList.vue @@ -10,8 +10,8 @@ import ClaimFilter from './ClaimFilter.vue'; import VnLv from 'src/components/ui/VnLv.vue'; import CardList from 'src/components/ui/CardList.vue'; import ClaimSummaryDialog from './Card/ClaimSummaryDialog.vue'; -import WorkerSummaryDialog from 'src/pages/Worker/Card/WorkerSummaryDialog.vue'; -import CustomerSummaryDialog from 'src/pages/Customer/Card/CustomerSummaryDialog.vue'; +import CustomerDescriptorProxy from 'src/pages/Customer/Card/CustomerDescriptorProxy.vue'; +import WorkerDescriptorProxy from '../Worker/Card/WorkerDescriptorProxy.vue'; const stateStore = useStateStore(); const router = useRouter(); @@ -28,25 +28,18 @@ function navigate(id) { router.push({ path: `/claim/${id}` }); } -function viewSummary(id, summaryDialog) { - let dialogComponent; - - switch (summaryDialog) { - case 'worker': - dialogComponent = WorkerSummaryDialog; - break; - case 'customer': - dialogComponent = CustomerSummaryDialog; - break; - case 'claim': - dialogComponent = ClaimSummaryDialog; - break; - default: - return; - } - +function viewSummary(id) { quasar.dialog({ - component: dialogComponent, + component: ClaimSummaryDialog, + componentProps: { + id, + }, + }); +} + +function viewDescriptor(id) { + quasar.dialog({ + component: CustomerDescriptorProxy, componentProps: { id, }, @@ -101,23 +94,19 @@ function viewSummary(id, summaryDialog) { >