From b666d2f68d597ee92b1939583b6ae4dd50b8578f Mon Sep 17 00:00:00 2001 From: Ho Ngoc Hai Date: Sun, 29 Mar 2026 03:43:55 +0700 Subject: [PATCH] feat(pos): fix settings navigation and add receipt template management MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Fix POS settings button redirecting to /auth/login when UserRole is not loaded — now navigates to /admin/shop/{shopId}/overview - Add receipt template management page with full CRUD: - Create/edit/delete receipt templates stored in localStorage - Live preview of thermal receipt (80mm/58mm paper width) - 18 toggleable fields (logo, address, phone, tax ID, items, etc.) - Customizable header, footer, font size, paper width - Set default template for POS printing - Add "Hoá đơn in" section to shop settings with active template info - Add sidebar menu item and route for receipt-templates - Add vi-VN/en-US localization keys Co-Authored-By: Claude Opus 4.6 (1M context) --- .../Layout/PosLayout.razor | 12 +- .../Pages/Admin/Shop/ReceiptTemplates.razor | 697 ++++++++++++++++++ .../Pages/Admin/Shop/ShopPage.razor | 5 + .../Pages/Admin/Shop/ShopSettings.razor | 65 ++ .../Services/ShopSidebarConfig.cs | 2 + .../wwwroot/locales/en-US.json | 1 + .../wwwroot/locales/vi-VN.json | 1 + 7 files changed, 781 insertions(+), 2 deletions(-) create mode 100644 apps/web-client-tpos-net/src/WebClientTpos.Client/Pages/Admin/Shop/ReceiptTemplates.razor diff --git a/apps/web-client-tpos-net/src/WebClientTpos.Client/Layout/PosLayout.razor b/apps/web-client-tpos-net/src/WebClientTpos.Client/Layout/PosLayout.razor index 73cc9562..b0b5c644 100644 --- a/apps/web-client-tpos-net/src/WebClientTpos.Client/Layout/PosLayout.razor +++ b/apps/web-client-tpos-net/src/WebClientTpos.Client/Layout/PosLayout.razor @@ -98,7 +98,7 @@