feat(mobile-navigation-improvements): Complete US-213 - Actualizare Hamburger Menu în toate paginile
Implemented by Ralph autonomous loop. Iteration: 10 Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -6,36 +6,16 @@
|
||||
title="Trezorerie"
|
||||
:show-menu="true"
|
||||
:actions="mobileTopBarActions"
|
||||
@menu-click="toggleMobileMenu"
|
||||
@menu-click="showDrawer = true"
|
||||
@action-click="handleTopBarAction"
|
||||
/>
|
||||
|
||||
<!-- US-109: Mobile Hamburger Menu -->
|
||||
<Sidebar v-model:visible="mobileMenuVisible" position="left" class="mobile-sidebar">
|
||||
<template #header>
|
||||
<div class="sidebar-header">
|
||||
<span class="sidebar-title">ROA2WEB</span>
|
||||
</div>
|
||||
</template>
|
||||
<div class="sidebar-menu">
|
||||
<router-link to="/data-entry" class="sidebar-item">
|
||||
<i class="pi pi-receipt"></i>
|
||||
<span>Bonuri</span>
|
||||
</router-link>
|
||||
<router-link to="/reports/bank-cash-register" class="sidebar-item active">
|
||||
<i class="pi pi-wallet"></i>
|
||||
<span>Trezorerie</span>
|
||||
</router-link>
|
||||
<router-link to="/reports/dashboard" class="sidebar-item">
|
||||
<i class="pi pi-chart-bar"></i>
|
||||
<span>Rapoarte</span>
|
||||
</router-link>
|
||||
<router-link to="/settings" class="sidebar-item">
|
||||
<i class="pi pi-cog"></i>
|
||||
<span>Setări</span>
|
||||
</router-link>
|
||||
</div>
|
||||
</Sidebar>
|
||||
<!-- Mobile Drawer Menu (replaces old Sidebar) -->
|
||||
<MobileDrawerMenu
|
||||
v-model="showDrawer"
|
||||
:user="authStore.user"
|
||||
@logout="handleLogout"
|
||||
/>
|
||||
|
||||
<!-- US-109: Filter BottomSheet for mobile -->
|
||||
<BottomSheet v-model="showFilters">
|
||||
@@ -413,7 +393,7 @@
|
||||
import { ref, computed, onMounted, onUnmounted, watch } from "vue";
|
||||
import { useToast } from "primevue/usetoast";
|
||||
import { useTreasuryStore } from "@reports/stores/treasury";
|
||||
import { useCompanyStore } from "@reports/stores/sharedStores";
|
||||
import { useCompanyStore, useAuthStore } from "@reports/stores/sharedStores";
|
||||
import { useAccountingPeriodStore } from "@reports/stores/sharedStores";
|
||||
import { format } from "date-fns";
|
||||
import { exportToExcel, exportBankCashRegisterPDF } from "@reports/utils/exportUtils";
|
||||
@@ -422,12 +402,15 @@ import { exportToExcel, exportBankCashRegisterPDF } from "@reports/utils/exportU
|
||||
import MobileTopBar from "@shared/components/mobile/MobileTopBar.vue";
|
||||
import MobileBottomNav from "@shared/components/mobile/MobileBottomNav.vue";
|
||||
import BottomSheet from "@shared/components/mobile/BottomSheet.vue";
|
||||
import Sidebar from "primevue/sidebar";
|
||||
import MobileDrawerMenu from "@shared/components/mobile/MobileDrawerMenu.vue";
|
||||
import { useRouter } from "vue-router";
|
||||
|
||||
const toast = useToast();
|
||||
const router = useRouter();
|
||||
const treasuryStore = useTreasuryStore();
|
||||
const companyStore = useCompanyStore();
|
||||
const periodStore = useAccountingPeriodStore();
|
||||
const authStore = useAuthStore();
|
||||
|
||||
// State for company selection
|
||||
const selectedCompanyId = ref(companyStore.selectedCompany?.id_firma || null);
|
||||
@@ -436,11 +419,12 @@ const selectedCompanyId = ref(companyStore.selectedCompany?.id_firma || null);
|
||||
const isMobile = ref(window.innerWidth < 768);
|
||||
const showFilters = ref(false);
|
||||
const actionsMenu = ref(null);
|
||||
const mobileMenuVisible = ref(false);
|
||||
const showDrawer = ref(false);
|
||||
|
||||
// US-109: Toggle mobile hamburger menu
|
||||
const toggleMobileMenu = () => {
|
||||
mobileMenuVisible.value = !mobileMenuVisible.value;
|
||||
// Handle logout from drawer menu
|
||||
const handleLogout = async () => {
|
||||
await authStore.logout();
|
||||
router.push('/login');
|
||||
};
|
||||
|
||||
// US-109: Mobile TopBar actions (filter, refresh, export)
|
||||
|
||||
Reference in New Issue
Block a user