fix(submissions): having one scope only make the back return not work

This commit is contained in:
2026-10-15 23:36:06 +02:00
parent 4fd683ff2c
commit b837abdba0
3 changed files with 19 additions and 5 deletions
+2 -2
View File
@@ -12,7 +12,7 @@ const { t } = useI18n();
const userStore = useUserStore();
const { userInfo } = storeToRefs(userStore);
const pageHeaderStore = usePageHeaderStore();
const { title: dynamicTitle } = storeToRefs(pageHeaderStore);
const { title: dynamicTitle, backRoute: dynamicBackRoute } = storeToRefs(pageHeaderStore);
const title = computed(() => {
if (dynamicTitle.value) return dynamicTitle.value;
@@ -21,7 +21,7 @@ const title = computed(() => {
});
const goBack = () => {
const backRoute = route.meta.getBackRoute?.(route);
const backRoute = dynamicBackRoute.value ?? route.meta.getBackRoute?.(route);
if (backRoute) {
router.push(backRoute);
}