add modul inventory

This commit is contained in:
2025-11-08 20:50:29 +02:00
parent 4aa36bb5b2
commit 5f6d41a871
11 changed files with 561 additions and 3 deletions

View File

@@ -6,6 +6,7 @@ from admin.orders import OrdersPage
from admin.clients import Clients
from admin.fidelity_cards import FidelityCards
from admin.settings import Settings
from admin.inventory.inventory import Inventory
class Dashboard:
def __init__(self, page: ft.Page):
@@ -59,6 +60,11 @@ class Dashboard:
selected_icon=ft.Icon(ft.Icons.CARD_GIFTCARD),
label_content=ft.Text("Card de\nfidelitate"),
),
ft.NavigationRailDestination(
icon=ft.Icons.INVENTORY_2_OUTLINED,
selected_icon=ft.Icon(ft.Icons.INVENTORY_2),
label_content=ft.Text("Inventar"),
),
ft.NavigationRailDestination(
icon=ft.Icons.SETTINGS_APPLICATIONS_OUTLINED,
selected_icon=ft.Icon(ft.Icons.SETTINGS_APPLICATIONS),
@@ -103,10 +109,14 @@ class Dashboard:
self.placeholder.content = self.fidelity_cards.build()
self.placeholder.update()
case 7:
self.inventory = Inventory(self.page, self)
self.placeholder.content = self.inventory.build()
self.placeholder.update()
case 8:
self.settings = Settings(self.page, self)
self.placeholder.content = self.settings.build()
self.placeholder.update()
case 8:
case 9:
self.page.client_storage.clear()
self.page.session.clear()
self.page.go('/')