diff --git a/.claude/skills/agent-orchestrator/SKILL.md b/.claude/skills/agent-orchestrator/SKILL.md
index 02570fa..90839a1 100644
--- a/.claude/skills/agent-orchestrator/SKILL.md
+++ b/.claude/skills/agent-orchestrator/SKILL.md
@@ -1,30 +1,39 @@
---
name: agent-orchestrator
description: >
- Breaks down large, multi-step software tasks into structured sub-agents on the Claude Code CLI using the Task tool.
- Use this skill whenever the user describes a complex project or feature that has multiple components - e.g., "build a login API with JWT and unit tests", "set up a CI/CD pipeline with Docker and GitHub Actions", "create a full-stack todo app with auth, REST API, and frontend".
- Trigger this skill when the task clearly has more than one distinct sub-system, layer, or concern that could be worked on in parallel or in sequence.
- DO NOT trigger for simple, single-step tasks like "write a function to reverse a string" or "fix this bug".
+ Breaks down large, multi-step software tasks into structured sub-agents on the
+ Claude Code CLI using the Task tool. Use this skill whenever the user
+ describes a complex project or feature that has multiple components - e.g.,
+ "build a login API with JWT and unit tests", "set up a CI/CD pipeline with
+ Docker and GitHub Actions", "create a full-stack todo app with auth, REST API,
+ and frontend". Trigger this skill when the task clearly has more than one
+ distinct sub-system, layer, or concern that could be worked on in parallel or
+ in sequence. DO NOT trigger for simple, single-step tasks like "write a
+ function to reverse a string" or "fix this bug".
---
# Agent Orchestrator
-A skill for decomposing large engineering tasks into parallel and sequential sub-agents on Claude Code CLI using the **Task tool**.
+A skill for decomposing large engineering tasks into parallel and sequential
+sub-agents on Claude Code CLI using the **Task tool**.
## When to Use
Trigger when the user's task has **multiple distinct components** - for example:
+
- "Build a REST API with authentication, rate limiting, and unit tests"
- "Set up a monorepo with shared packages, CI pipeline, and deployment configs"
-- "Create a data pipeline: ingest transform store visualize"
+- "Create a data pipeline: ingest transform store visualize"
-Do **not** trigger for single-step tasks (e.g., "rename this variable", "add a README").
+Do **not** trigger for single-step tasks (e.g., "rename this variable", "add a
+README").
---
## Prompt Template
-Copy the block below and paste it into your Agent Code CLI session. Replace the placeholder in the `TASK` variable with your actual task description.
+Copy the block below and paste it into your Agent Code CLI session. Replace the
+placeholder in the `TASK` variable with your actual task description.
---
@@ -143,19 +152,25 @@ Begin now with STEP 1.
## Tips for Customizing the Template
-- **Replace the TASK value** with your actual task string. Keep it on one line, in quotes.
-- **Add context if needed**: Append lines after `TASK:` like `STACK: "Node.js, PostgreSQL, Jest"` or `CONSTRAINTS: "Use ESM modules only"` - the orchestrator will incorporate them.
+- **Replace the TASK value** with your actual task string. Keep it on one line,
+ in quotes.
+- **Add context if needed**: Append lines after `TASK:` like
+ `STACK: "Node.js, PostgreSQL, Jest"` or
+ `CONSTRAINTS: "Use ESM modules only"` - the orchestrator will incorporate
+ them.
- **For monorepos or specific file layouts**: Add a `STRUCTURE:` hint, e.g.:
```
STRUCTURE: "src/api/, src/auth/, src/tests/, docker-compose.yml"
```
-- **To limit parallelism** (e.g., on resource-constrained machines): Add `MAX_PARALLEL_AGENTS: 2` after the TASK line.
+- **To limit parallelism** (e.g., on resource-constrained machines): Add
+ `MAX_PARALLEL_AGENTS: 2` after the TASK line.
---
## Example Usage
**Input task:**
+
> "Build a login API with JWT authentication and unit tests"
**Expected orchestrator output (before execution):**
@@ -180,12 +195,15 @@ Dependency Plan:
Starting execution. Spawning parallel sub-agents now...
```
-T1 and T2 spawn immediately. T3 spawns once T1 completes. T4 and T5 spawn once T3 completes. T6 spawns last.
+T1 and T2 spawn immediately. T3 spawns once T1 completes. T4 and T5 spawn once
+T3 completes. T6 spawns last.
---
## Notes
- This skill requires Agent Code CLI with the **Task tool** enabled.
-- Each spawned sub-agent has no memory of the others - pass all needed context explicitly in the Task prompt.
-- For very large tasks (10+ sub-tasks), consider breaking the orchestration into phases and applying this skill recursively per phase.
+- Each spawned sub-agent has no memory of the others - pass all needed context
+ explicitly in the Task prompt.
+- For very large tasks (10+ sub-tasks), consider breaking the orchestration into
+ phases and applying this skill recursively per phase.
diff --git a/AGENTS.md b/AGENTS.md
index 56e2499..1c8acf7 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -17,8 +17,10 @@ Chứa route/page/layout theo Next.js App Router.
- **`(main)/`** - Main shopping interface (duyệt menu, đăng nhập, đăng ký,
thanh toán)
- **`(feed)/`** - Feed/discovery page (khám phá quán)
- - **`(manager)/`** - Manager dashboard (quản lý sản phẩm, đơn hàng) - **[ĐANG
- PHÁT TRIỂN]**
+ - **`(manager)/`** - Manager dashboard (quản lý sản phẩm, phân tích tài
+ chính) - **[ĐANG PHÁT TRIỂN ~70%]**
+ - **`(staff)/`** - Staff shift schedule (lịch làm việc nhân viên) - **[HOÀN
+ THÀNH]**
- **Tài liệu:** `app/APP.md` - Chi tiết routes, pages, CSS tokens
### `components/` - Reusable UI Components (Atomic Design)
@@ -80,7 +82,14 @@ Sections phức tạp kết hợp molecules + atoms, có logic, data filtering:
- **`cart/`** - CartFab, CartSummary, CartList
- **`product-grid/`** - ProductGrid, ProductFilters
- **`forms/`** - LoginForm, RegisterForm, CheckoutForm, ReviewForm
-- **`modals/`** - ReviewModal, ConfirmModal
+- **`modals/`** - ReviewModal, ConfirmModal, CashPaymentModal, QRPaymentModal,
+ PaymentSuccessModal
+- **`manager/`** - ProductModal (image upload), ComboModal, CategoryModal,
+ DeleteConfirm, StatusBadge, ProductsTab, CombosTab, CategoriesTab
+- **`analytics/`** - BarChart, LineChart, PieChart (SVG), ProductTable,
+ SummaryCard
+- **`shift-schedule/`** - WeeklySchedule, MonthlyCalendar, MobileShiftView,
+ ShiftCreateModal, ShiftDetailModal
- **`shop-grid/`** - ShopGrid, ShopFilters
- **`hero-section/`** - HeroSection
- **`featured-section/`** - FeaturedProducts, FeaturedShops
@@ -103,6 +112,7 @@ Page layouts, không có data cụ thể, children composition:
- **`main-layout/`** - MainLayout (header + sidebar + content + footer)
- **`feed-layout/`** - FeedLayout
- **`manager-layout/`** - ManagerLayout
+- **`staff-layout/`** - StaffLayout (navigation shell for staff pages)
- **`checkout-layout/`** - CheckoutLayout
- **`auth-layout/`** - AuthLayout
@@ -161,8 +171,12 @@ Chứa logic dùng chung, context, constants, types:
- **`auth-context.tsx`** - AuthProvider + useAuth() hook (login, logout,
register)
- **`cart-context.tsx`** - CartProvider + useCart() hook (add, remove, quantity
- operations)
+ operations, clearCart)
- **`menu-context.tsx`** - MenuProvider + useMenu() hook (category state)
+- **`manager-context.tsx`** - ManagerProvider + useManager() hook (CRUD for
+ products, combos, categories)
+- **`shift-context.tsx`** - ShiftProvider + useShift() hook (staff shift
+ management: create, update, delete, date selection)
- **Tài liệu:** `lib/LIB.md` - Chi tiết types, constants, contexts
### `public/` - Static Assets
@@ -233,11 +247,41 @@ components/
│ ├── product-grid/
│ │ ├── ProductGrid.tsx
│ │ └── ProductGrid.types.ts
+│ ├── modals/
+│ │ ├── ReviewModal.tsx
+│ │ ├── CashPaymentModal.tsx
+│ │ ├── QRPaymentModal.tsx
+│ │ └── PaymentSuccessModal.tsx
+│ ├── manager/
+│ │ ├── ProductModal.tsx
+│ │ ├── ComboModal.tsx
+│ │ ├── CategoryModal.tsx
+│ │ ├── DeleteConfirm.tsx
+│ │ ├── StatusBadge.tsx
+│ │ ├── ProductsTab.tsx
+│ │ ├── CombosTab.tsx
+│ │ └── CategoriesTab.tsx
+│ ├── analytics/
+│ │ ├── BarChart.tsx
+│ │ ├── LineChart.tsx
+│ │ ├── PieChart.tsx
+│ │ ├── ProductTable.tsx
+│ │ └── SummaryCard.tsx
+│ ├── shift-schedule/
+│ │ ├── WeeklySchedule.tsx
+│ │ ├── MonthlyCalendar.tsx
+│ │ ├── MobileShiftView.tsx
+│ │ ├── ShiftCreateModal.tsx
+│ │ └── ShiftDetailModal.tsx
│ └── index.ts
├── templates/
│ ├── main-layout/
│ │ ├── MainLayout.tsx
│ │ └── MainLayout.types.ts
+│ ├── manager-layout/
+│ │ └── ManagerLayout.tsx
+│ ├── staff-layout/
+│ │ └── StaffLayout.tsx
│ └── index.ts
└── ATOMIC_DESIGN.md
```
@@ -314,9 +358,15 @@ components/
- **Mock data first** - Use `lib/constants.ts` for development, replace with API
later
- **Contexts for state sharing:**
- - `AuthContext` (lib/auth-context.tsx) - User state + auth operations
- - `CartContext` (lib/cart-context.tsx) - Shopping cart + operations
- - `MenuContext` (lib/menu-context.tsx) - Active category state
+ - `AuthContext` (lib/auth-context.tsx) - User state + auth operations →
+ `useAuth()`
+ - `CartContext` (lib/cart-context.tsx) - Shopping cart + operations →
+ `useCart()` (includes `clearCart`)
+ - `MenuContext` (lib/menu-context.tsx) - Active category state → `useMenu()`
+ - `ManagerContext` (lib/manager-context.tsx) - Manager dashboard state (CRUD
+ for products/combos/categories) → `useManager()`
+ - `ShiftContext` (lib/shift-context.tsx) - Staff shift management (create,
+ update, delete shifts, date selection) → `useShift()`
- **localStorage keys:** `coffee-shop-user`, `coffee-shop-cart` (defined in
contexts)
@@ -625,21 +675,33 @@ className = "w-full sm:w-1/2 md:w-1/3 p-4 md:p-6 hidden md:block";
## 5) Project Status
+> Last Updated: 2026-04-18
+
### ✅ Completed Features
- User authentication (login, register, logout)
- Product grid display with category filtering
- Shopping cart with add/remove/update operations
-- Payment page with review modal
+- Payment page with PaymentSummaryCard + review modal
+- Cash payment modal (CashPaymentModal) with change calculation
+- QR payment modal (QRPaymentModal) with QR code generation (`qrcode.react`) and
+ 5-second auto-confirm countdown
+- Payment success modal (PaymentSuccessModal) with cart clear
- Shop discovery (feed page)
- Responsive design (mobile, tablet, desktop)
- Header + Footer with navigation
- Sidebar category filter
+- Manager dashboard — Products, Combos, Categories tabs with full CRUD
+- Product image upload in ProductModal
+- Financial Analytics dashboard (LineChart, BarChart, PieChart, ProductTable)
+- Staff shift schedule (`/staff/schedule`) — weekly/monthly views, mobile view,
+ CRUD shifts, department filter
### 🚀 In Progress
+- Manager dashboard (~70% complete) - `app/(manager)/` route group
+ - Remaining: order management, inventory tracking, real API integration
- Atomic Design refactoring (components reorganization)
-- Manager dashboard (quản lý sản phẩm) - `app/(manager)/` route group
### 📋 Planned Features
diff --git a/README.md b/README.md
index c355a6e..5c11532 100644
--- a/README.md
+++ b/README.md
@@ -3,6 +3,8 @@
Dự án Frontend cho hệ thống đặt món cà phê, xây dựng bằng Next.js App Router,
React 19, TypeScript và Tailwind CSS v4.
+_Last Updated: 2026-04-18_
+
---
## Mô Tả Dự Án
@@ -11,7 +13,9 @@ Giao diện người dùng (frontend) cho hệ thống đặt và bán đồ u
### Tính Năng Hiện Tại
-#### 1. **Trang Đăng Nhập & Đăng Ký** (`app/(main)/login`, `app/(main)/register`)
+#### Tính Năng Khách Hàng (Customer Features)
+
+##### 1. **Trang Đăng Nhập & Đăng Ký** (`app/(main)/login`, `app/(main)/register`)
- Form đăng nhập với validation (username, password)
- Form đăng ký với xác thực OTP
@@ -19,7 +23,7 @@ Giao diện người dùng (frontend) cho hệ thống đặt và bán đồ u
- Hỗ trợ 3 loại tài khoản: Manager, Staff, Customer
- Hiển thị thông tin shop trong form
-#### 2. **Trang Khám Phá Quán Nước** (`app/(feed)/feed`)
+##### 2. **Trang Khám Phá Quán Nước** (`app/(feed)/feed`)
- Danh sách các quán cà phê
- Tìm kiếm theo tên quán và địa chỉ
@@ -27,9 +31,7 @@ Giao diện người dùng (frontend) cho hệ thống đặt và bán đồ u
- Responsive layout (grid 1/2/3 cột)
- Empty state khi không tìm thấy quán
-#### 3. **Trang Chính - Duyệt Thực Đơn** (`app/(main)`)
-
-Dành cho khách hàng:
+##### 3. **Trang Chính - Duyệt Thực Đơn** (`app/(main)`)
- Sidebar collapsible (64px/240px) - danh mục sản phẩm
- Grid sản phẩm responsive (1-5 cột tuỳ thiết bị)
@@ -38,41 +40,52 @@ Dành cho khách hàng:
- Lọc tự động theo trạng thái available
- Mobile menu: scrollable category tabs (< md)
-#### 4. **Trang Thanh Toán** (`app/(main)/payment`)
+##### 4. **Trang Thanh Toán** (`app/(main)/payment`)
- Bảng danh sách sản phẩm trong giỏ hàng với điều chỉnh số lượng
- Invoice aside sticky với tổng giá và nút thanh toán (Tiền mặt, QR)
- Modal đánh giá 5 sao dành riêng cho khách hàng (ReviewModal)
+- **CashPaymentModal:** nhập tiền mặt, tính tiền thối, báo lỗi nếu tiền không đủ
+- **QRPaymentModal:** tạo mã QR thanh toán (qrcode.react), tự xác nhận sau 5
+ giây đếm ngược
+- **PaymentSuccessModal:** xác nhận thanh toán thành công, tự động xoá giỏ hàng
-#### 5. **Hệ Thống Giỏ Hàng** (`lib/cart-context.tsx`)
+##### 5. **Hệ Thống Giỏ Hàng** (`lib/cart-context.tsx`)
- Lưu trữ trạng thái giỏ trong localStorage
- Thêm/xóa/tăng/giảm số lượng sản phẩm
- Tính tổng giá và số mặt hàng
- Persist dữ liệu giữa các session
+- `clearCart()` để xoá toàn bộ giỏ sau thanh toán
-#### 6. **Hệ Thống Xác Thực** (`lib/auth-context.tsx`)
+##### 6. **Hệ Thống Xác Thực** (`lib/auth-context.tsx`)
- Quản lý trạng thái người dùng (login/logout/register)
- Lưu thông tin user trong localStorage
- Mock auth database với 3 loại tài khoản
- Hỗ trợ hoàn tất đăng ký qua OTP
-#### 7. **Hệ Thống Danh Mục** (`lib/menu-context.tsx`)
+##### 7. **Hệ Thống Danh Mục** (`lib/menu-context.tsx`)
- Chia sẻ trạng thái category giữa Header mobile và Sidebar
- Tự động clear search khi thay đổi category
-#### 8. **Manager Dashboard** (`app/(manager)/manager`)
+#### Tính Năng Quản Lý (Manager Features)
-Dành cho quản lý:
+##### 8. **Manager Dashboard** (`app/(manager)/manager`) — ~70% hoàn thành
- Sidebar desktop: Brand, tab navigation (Thực đơn / Combo / Danh mục), link tới
Analytics
-- CRUD sản phẩm, combo, danh mục qua modals
- Auth guard: tự động redirect non-manager về `/`
+- **Products tab:** CRUD sản phẩm qua ProductModal, bao gồm:
+ - Upload ảnh sản phẩm với xem trước, nút "Đổi ảnh" và xoá ảnh
+ - Giao diện vùng kéo thả với dashed border
+ - Toggle trạng thái available
+ - Dialog xác nhận xoá
+- **Combos tab:** CRUD combo qua ComboModal, toggle trạng thái, xác nhận xoá
+- **Categories tab:** CRUD danh mục qua CategoryModal, xác nhận xoá
-#### 9. **Trang Phân Tích Tài Chính** (`app/(manager)/manager/analytics`)
+##### 9. **Trang Phân Tích Tài Chính** (`app/(manager)/manager/analytics`)
- Summary cards: Doanh thu, đơn hàng, lợi nhuận, giá trị đơn trung bình (so sánh
kỳ trước)
@@ -81,6 +94,24 @@ Dành cho quản lý:
- Bảng top 5 sản phẩm và bảng chi tiết có thể sắp xếp
- Lọc theo danh mục
+#### Tính Năng Nhân Viên (Staff Features)
+
+##### 10. **Lịch Làm Việc Nhân Viên** (`app/(staff)/staff/schedule`)
+
+- Xem lịch theo tuần và theo tháng
+- Mobile shift view (danh sách ca theo ngày)
+- Lọc theo phòng ban / bộ phận
+- Modal tạo ca làm việc mới (ShiftCreateModal)
+- Modal xem chi tiết ca (ShiftDetailModal)
+- Auth guard: chỉ staff/manager mới truy cập được
+
+#### Cải Thiện Tiếp Cận (Accessibility)
+
+- Thuộc tính `title` trên các nút icon (tooltip cho screen reader)
+- ARIA roles trên modals: `role="dialog"`, `aria-modal`, `aria-labelledby`
+- Semantic HTML: nhãn form với `htmlFor` đúng chuẩn
+- `alt` text đầy đủ cho ảnh sản phẩm
+
---
## Cách Chạy Dự Án
@@ -144,9 +175,12 @@ frondend/
| | +-- layout.tsx # Feed layout
| | +-- feed/page.tsx # Trang khám phá quán nước (/feed)
| +-- (manager)/ # Manager route group
-| +-- layout.tsx # Manager layout - auth guard + ManagerProvider
-| +-- manager/page.tsx # Manager Dashboard (/manager)
-| +-- manager/analytics/page.tsx # Financial Analytics (/manager/analytics)
+| | +-- layout.tsx # Manager layout - auth guard + ManagerProvider
+| | +-- manager/page.tsx # Manager Dashboard (/manager)
+| | +-- manager/analytics/page.tsx # Financial Analytics (/manager/analytics)
+| +-- (staff)/ # Staff route group
+| +-- layout.tsx # Staff layout - auth guard
+| +-- staff/schedule/page.tsx # Lịch làm việc nhân viên (/staff/schedule)
+-- components/ # Atomic Design UI components
| +-- atoms/ # Nguyên tử: Button, Input, Badge, Text...
| +-- molecules/ # Phân tử: ProductCard, ShopCard, SearchBar...
@@ -202,8 +236,9 @@ frondend/
| ---------------- | --------- | ------------------------------------- |
| Next.js | 16.1.7 | React Framework (App Router) |
| React | 19.2.3 | Thư viện UI |
-| TypeScript | ^5 | Kiểu dữ liệu tĩnh |
+| TypeScript | ^5.9.3 | Kiểu dữ liệu tĩnh |
| Tailwind CSS | ^4.2.2 | Utility-first CSS framework |
+| qrcode.react | ^4.2.0 | Tạo mã QR thanh toán |
| Geist Font | - | Font chữ (Google Fonts via next/font) |
| FontAwesome | 6.7.2 | Icon library (CDN) |
| pnpm | - | Package manager |
@@ -224,14 +259,15 @@ frondend/
- **Thanh Toán:** `app/(main)/payment/page.tsx`
- **Manager Dashboard:** `app/(manager)/manager/page.tsx`
- **Phân Tích Tài Chính:** `app/(manager)/manager/analytics/page.tsx`
+- **Lịch Làm Việc Nhân Viên:** `app/(staff)/staff/schedule/page.tsx`
### Tài Khoản Demo
-| Loại tài khoản | Tên đăng nhập | Mật khẩu |
-| -------------- | ------------- | ------------- |
-| Manager | admin | admin |
-| Staff | Nguyễn Văn An | Nguyễn Văn An |
-| Customer | 0987654321 | user1 |
+| Loại tài khoản | Tên đăng nhập | Mật khẩu / OTP |
+| -------------- | ------------- | -------------------------- |
+| Manager | admin | admin |
+| Staff | Nguyễn Văn An | Nguyễn Văn An |
+| Customer | 0987654321 | bất kỳ 6 chữ số (mock OTP) |
### Design & Styling
diff --git a/TODO.md b/TODO.md
index cb9d54c..6d6ea4a 100644
--- a/TODO.md
+++ b/TODO.md
@@ -1,5 +1,9 @@
# Coffee Shop Frontend - TODO
+_Last Updated: 2026-04-18_
+
+---
+
## Completed Features & Implementations
### A. Dead Code Removed
@@ -37,17 +41,66 @@
- [x] npm run build - PASSED (Compiled successfully, TypeScript clean, static
pages generated)
+### F. Cart & Payment (Completed)
+
+- [x] Cart checkout flow — cart context with addToCart, removeFromCart,
+ setQuantity, clearCart
+- [x] Payment page implementation (`app/(main)/payment`)
+- [x] CashPaymentModal: cash input, change calculation, insufficient cash error
+- [x] QRPaymentModal: QR code generation via qrcode.react, 5-second countdown
+ auto-confirm
+- [x] PaymentSuccessModal: success confirmation, auto-clears cart
+
+### G. Manager Dashboard — ~70% Complete (In Progress)
+
+- [x] Manager Dashboard page (`app/(manager)/manager/page.tsx`) with auth guard
+- [x] Products tab with CRUD (ProductModal)
+- [x] Image upload in ProductModal: file input, preview, "Đổi ảnh" button,
+ remove button, dashed border drop zone
+- [x] Combos tab with CRUD (ComboModal)
+- [x] Categories tab with CRUD (CategoryModal)
+- [x] Delete confirmation dialogs for all entities
+- [x] Status toggle buttons (available/unavailable)
+- [x] Sidebar navigation with link to Analytics
+
+### H. Financial Analytics Dashboard (Completed)
+
+- [x] Analytics page (`app/(manager)/manager/analytics`)
+- [x] Summary cards: Revenue, Orders, Profit, Average Order Value (with period
+ comparison)
+- [x] Period selector: Day / Week / Month / Year
+- [x] SVG charts: LineChart, BarChart, PieChart with hover tooltips
+- [x] Top 5 products table and sortable detail table
+- [x] Category filter
+
+### I. Staff Shift Schedule (Completed)
+
+- [x] Staff schedule module (`app/(staff)/staff/schedule`)
+- [x] Weekly calendar view
+- [x] Monthly calendar view
+- [x] Mobile shift view (list per day)
+- [x] ShiftCreateModal: create new shifts
+- [x] ShiftDetailModal: view shift details
+- [x] Department/role filtering
+- [x] Auth guard for staff/manager only
+
+### J. Accessibility Improvements (Completed)
+
+- [x] title attributes on icon buttons (tooltips for screen readers)
+- [x] ARIA roles on modals: role="dialog", aria-modal, aria-labelledby
+- [x] Semantic HTML: form labels with correct htmlFor
+- [x] Image alt text for product images
+
---
## Pending Features (Future Work)
### Cart & Ordering
-- [ ] Implement cart checkout flow (app/(main)/cart or modal)
-- [ ] Cart sidebar/modal with item list and total
+- [ ] Cart sidebar/modal with item list and total (quick-access without going to
+ payment page)
- [ ] Order submission API integration
-- [ ] Payment page implementation (app/(main)/payment)
-- [ ] Order history/tracking page
+- [ ] Order history/tracking page for customers
- [ ] Toast notifications for cart actions
### Authentication & User Management
@@ -58,22 +111,22 @@
- [ ] Password reset/recovery flow
- [ ] Session management and token refresh
-### Manager Features
+### Manager Features (Remaining ~30%)
-- [ ] Manager dashboard page (app/(manager)/page.tsx)
-- [ ] Product management (add/edit/delete)
-- [ ] Category management
-- [ ] Order management & tracking
-- [ ] Sales analytics/dashboard
-- [ ] Inventory management
+- [ ] Order management & tracking for manager
+- [ ] Inventory management beyond available toggle (stock counts, low-stock
+ alerts)
+- [ ] Staff management tab in Manager Dashboard
+- [ ] Shift approval workflow (manager approves staff shift requests)
### Backend Integration
- [ ] Replace MOCK_PRODUCTS with API calls (GET /api/products)
- [ ] Replace MOCK_SHOPS with API calls (GET /api/shops)
- [ ] Replace MOCK_USERS with real authentication (POST /api/auth/login)
-- [ ] Real product images (replace placeholder.jpg)
-- [ ] Image upload for products
+- [ ] Real product images hosted on server/CDN (replace public/imgs/products/)
+- [ ] Real analytics data from backend (GET /api/analytics)
+- [ ] Real shift/schedule data from backend
### UX Improvements
@@ -85,11 +138,12 @@
- [ ] Filter by price range
- [ ] Quantity selector in product card
- [ ] Related products suggestions
+- [ ] Push notifications for order status updates
### Performance & SEO
-- [ ] Dynamic route generation for products (app/(main)/product/[id]/page.tsx)
-- [ ] Dynamic route generation for shops (app/(feed)/shop/[id]/page.tsx)
+- [ ] Dynamic route generation for products (`app/(main)/product/[id]/page.tsx`)
+- [ ] Dynamic route generation for shops (`app/(feed)/shop/[id]/page.tsx`)
- [ ] Meta tags and Open Graph for SEO
- [ ] Image optimization and lazy loading
- [ ] Code splitting and dynamic imports
@@ -97,7 +151,7 @@
### Accessibility & Testing
- [ ] Keyboard navigation testing
-- [ ] ARIA labels audit
-- [ ] Unit tests for contexts
-- [ ] E2E tests for user flows
-- [ ] Accessibility audit (WCAG 2.1 AA)
+- [ ] Full ARIA labels audit (WCAG 2.1 AA)
+- [ ] Unit tests for contexts (auth, cart, menu, manager)
+- [ ] E2E tests for user flows (checkout, login, manager CRUD)
+- [ ] Accessibility audit tool (axe, Lighthouse)
diff --git a/app/(main)/payment/page.tsx b/app/(main)/payment/page.tsx
index f3b92b7..01c680f 100644
--- a/app/(main)/payment/page.tsx
+++ b/app/(main)/payment/page.tsx
@@ -131,7 +131,6 @@ export default function PaymentPage() {
/>
-
);
}
diff --git a/app/(manager)/manager/page.tsx b/app/(manager)/manager/page.tsx
index 2d0280c..05d64a0 100644
--- a/app/(manager)/manager/page.tsx
+++ b/app/(manager)/manager/page.tsx
@@ -57,7 +57,7 @@ export default function ManagerPage() {
Tài chính
@@ -92,7 +92,7 @@ export default function ManagerPage() {
Ca làm
@@ -125,7 +125,7 @@ export default function ManagerPage() {
)}
diff --git a/components/organisms/modals/CashPaymentModal.tsx b/components/organisms/modals/CashPaymentModal.tsx
index 6521044..2b01547 100644
--- a/components/organisms/modals/CashPaymentModal.tsx
+++ b/components/organisms/modals/CashPaymentModal.tsx
@@ -2,6 +2,7 @@
import Button from "@/components/atoms/buttons/Button";
import { useEffect, useState } from "react";
+
import type { CashPaymentModalProps } from "./Modal.types";
const formatPrice = (value: number) =>
@@ -41,27 +42,25 @@ export default function CashPaymentModal({