fix: remove VnFilterPanel inside Summary

This commit is contained in:
Javier Segarra 2024-04-29 10:12:50 +02:00
parent bdc5d7210f
commit 8c3d32ec86
1 changed files with 8 additions and 39 deletions

View File

@ -20,14 +20,14 @@ const router = useRouter();
const { t } = useI18n(); const { t } = useI18n();
const entityId = computed(() => $props.id || route.params.id); const entityId = computed(() => $props.id || route.params.id);
const isDialog = Boolean($props.id); const isDialog = false;
const hideRightDrawer = () => { // const hideRightDrawer = () => {
if (!isDialog) { // if (!isDialog) {
stateStore.rightDrawer = false; // stateStore.rightDrawer = false;
} // }
}; // };
onMounted(hideRightDrawer); // onMounted(hideRightDrawer);
onUnmounted(hideRightDrawer); // onUnmounted(hideRightDrawer);
const filter = { const filter = {
include: [ include: [
{ {
@ -46,23 +46,6 @@ const filter = {
</script> </script>
<template> <template>
<template v-if="!isDialog && stateStore.isHeaderMounted()">
<Teleport to="#actions-append">
<div class="row q-gutter-x-sm">
<QBtn
flat
@click="stateStore.toggleRightDrawer()"
round
dense
icon="menu"
>
<QTooltip bottom anchor="bottom right">
{{ t('globals.collapseMenu') }}
</QTooltip>
</QBtn>
</div>
</Teleport>
</template>
<div class="q-pa-md"> <div class="q-pa-md">
<CardSummary ref="summary" :url="`Shelvings/${entityId}`" :filter="filter"> <CardSummary ref="summary" :url="`Shelvings/${entityId}`" :filter="filter">
<template #header="{ entity }"> <template #header="{ entity }">
@ -102,18 +85,4 @@ const filter = {
</template> </template>
</CardSummary> </CardSummary>
</div> </div>
<QDrawer
v-if="!isDialog"
v-model="stateStore.rightDrawer"
side="right"
:width="256"
show-if-above
>
<QScrollArea class="fit text-grey-8">
<ShelvingFilter
data-key="ShelvingList"
@search="router.push({ name: 'ShelvingList' })"
/>
</QScrollArea>
</QDrawer>
</template> </template>