diff --git a/src/components/ui/CardDescriptor.vue b/src/components/ui/CardDescriptor.vue index 202325bbf..2d41c36a2 100644 --- a/src/components/ui/CardDescriptor.vue +++ b/src/components/ui/CardDescriptor.vue @@ -24,14 +24,18 @@ const { t } = useI18n(); onMounted(() => fetch()); +const emit = defineEmits(['onFetch']); + const entity = ref(); async function fetch() { const params = {}; - if (props.filter) params.filter = props.filter; + if (props.filter) params.filter = JSON.stringify(props.filter); const { data } = await axios.get(props.url, { params }); entity.value = data; + + emit('onFetch', data); } watch(props, async () => { @@ -46,9 +50,9 @@ watch(props, async () => {
- {{ - t('components.cardDescriptor.mainList') - }} + + {{ t('components.cardDescriptor.mainList') }} + {
+
- + @@ -98,6 +103,7 @@ watch(props, async () => {
+ diff --git a/src/pages/Customer/CustomerList.vue b/src/pages/Customer/CustomerList.vue index 745731962..e8a75bcb9 100644 --- a/src/pages/Customer/CustomerList.vue +++ b/src/pages/Customer/CustomerList.vue @@ -100,7 +100,7 @@ function viewSummary(id) { diff --git a/src/pages/Worker/Card/WorkerCard.vue b/src/pages/Worker/Card/WorkerCard.vue index b014e9b7f..39c4cbfd9 100644 --- a/src/pages/Worker/Card/WorkerCard.vue +++ b/src/pages/Worker/Card/WorkerCard.vue @@ -1,24 +1,18 @@ - - - - diff --git a/src/pages/Worker/Card/WorkerDescriptor.vue b/src/pages/Worker/Card/WorkerDescriptor.vue index bd08fb1c1..b763469bc 100644 --- a/src/pages/Worker/Card/WorkerDescriptor.vue +++ b/src/pages/Worker/Card/WorkerDescriptor.vue @@ -1,9 +1,8 @@