diff --git a/AGENTS.md b/AGENTS.md index 33c824e1..7b4ab82a 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -35,4 +35,5 @@ Standard commands are documented in `README.md` and `package.json` scripts. Quic - **web-client dev server**: Runs on port 3000 by default via `next dev`. - **.NET 10 SDK for Blazor apps**: Install via `~/.dotnet/dotnet-install.sh --channel 10.0 --install-dir $HOME/.dotnet`. The update script handles this automatically. Ensure `DOTNET_ROOT=$HOME/.dotnet` and `PATH` includes `$HOME/.dotnet`. - **Blazor TPOS dev server**: `dotnet run --project src/WebClientTpos.Server` from `apps/web-client-tpos-net/` serves on port 5092 by default. Build with `dotnet build` from the same directory. Smoke tests: `dotnet test tests/WebClientTpos.SmokeTests/`. -- **Blazor POS page patterns**: All POS Razor files use `@layout PosLayout`, `@inherits PosBase`, bilingual `EN: / VI:` comments, `@* ═══ SECTION ═══ *@` separators, CSS variables (`--pos-*`), `FormatPrice(decimal)`, `NavigateTo(string)`, Lucide icons, and hardcoded Vietnamese demo data. Verticals: Cafe, Restaurant, Karaoke, Spa, Retail. Shared screens: Operations (ClockInOut, ShiftManagement, CashDrawer, PendingOrders, QuickSale), Payment, Dialogs. +- **Blazor POS page patterns**: All POS Razor files use `@layout PosLayout`, `@inherits PosBase`, bilingual `EN: / VI:` comments, `@* ═══ SECTION ═══ *@` separators, CSS variables (`--pos-*`), `FormatPrice(decimal)`, `NavigateTo(string)`, Lucide icons. Verticals: Cafe, Restaurant, Karaoke, Spa, Retail. Shared screens: Operations (ClockInOut, ShiftManagement, CashDrawer, PendingOrders, QuickSale), Payment, Dialogs. +- **BFF data layer**: Cafe, Restaurant, and Spa POS pages load data from `/api/bff/` endpoints via `PosDataService` (injected with `@inject`). The BFF controller (`BffDataController`) uses Dapper + Npgsql to read directly from PostgreSQL. Karaoke still uses mock data (pending FnB engine rooms schema). Pages show "Đang tải..." while loading and "Không thể tải dữ liệu" on API failure.