From 25f4d1f6548ab92234db28881714411c7c36cd30 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Tue, 11 Jun 2024 11:58:27 +0200 Subject: [PATCH] fix: point 3 --- src/components/ui/CardSummary.vue | 6 +++++- src/pages/Department/Card/DepartmentSummary.vue | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/components/ui/CardSummary.vue b/src/components/ui/CardSummary.vue index ae9a43578..62efc6727 100644 --- a/src/components/ui/CardSummary.vue +++ b/src/components/ui/CardSummary.vue @@ -22,6 +22,10 @@ const props = defineProps({ type: String, default: '', }, + moduleName: { + type: String, + default: null, + }, }); const emit = defineEmits(['onFetch']); const route = useRoute(); @@ -83,7 +87,7 @@ function existSummary(routes) { v-if="showRedirectToSummaryIcon" class="header link" :to="{ - name: `${route.meta.moduleName}Summary`, + name: `${moduleName ?? route.meta.moduleName}Summary`, params: { id: entityId || entity.id }, }" > diff --git a/src/pages/Department/Card/DepartmentSummary.vue b/src/pages/Department/Card/DepartmentSummary.vue index 6377ac779..ecbb39ed0 100644 --- a/src/pages/Department/Card/DepartmentSummary.vue +++ b/src/pages/Department/Card/DepartmentSummary.vue @@ -32,6 +32,7 @@ onMounted(async () => { :url="`Departments/${entityId}`" class="full-width" style="max-width: 900px" + module-name="Department" >