- 🎯 Giới thiệu
- ✨ Tính năng
- 🏗️ Kiến trúc
- 🛠️ Công nghệ
- 📦 Cài đặt
- 🚀 Khởi chạy
- 📖 API Documentation
- 🎨 Giao diện
- 🔧 Cấu hình
- 📱 Tính năng Thanh toán
- 🎉 Hệ thống Khuyến mãi
- 🧪 Testing
- 📚 Tài liệu
- 🤝 Đóng góp
ShoeStore là một hệ thống thương mại điện tử hoàn chỉnh được thiết kế đặc biệt cho cửa hàng giày dép. Dự án sử dụng kiến trúc Full-stack với:
- Backend: ASP.NET Core 9.0 + Blazor Server (Admin Panel)
- Frontend: ReactJS 18 + Shadcn UI (Customer Interface)
- Database: SQL Server với Entity Framework Core
- Authentication: JWT cho API, Cookie cho Admin
- 🔐 Xác thực: Đăng ký, đăng nhập, quên mật khẩu, đổi mật khẩu
- 👤 Quản lý tài khoản: Thông tin cá nhân, lịch sử đơn hàng
- 🔍 Sản phẩm: Tìm kiếm, lọc theo thương hiệu/danh mục/giá/size
- 🛒 Giỏ hàng: Thêm/xóa/cập nhật sản phẩm, tính toán tự động
- 🎫 Voucher: Áp dụng mã giảm giá, lịch sử sử dụng
- 🎉 Khuyến mãi: Hiển thị giá khuyến mãi tự động
- 💳 Thanh toán: MoMo, VnPay, tích hợp gateway
- 📦 Đơn hàng: Theo dõi trạng thái, chi tiết đơn hàng
- 📊 Dashboard: Thống kê doanh thu, phân tích
- 👥 Quản lý người dùng: Danh sách, phân quyền
- 📦 Quản lý sản phẩm: CRUD sản phẩm, hình ảnh, kho hàng
- 🏷️ Thương hiệu & Danh mục: Quản lý phân loại
- 📋 Quản lý đơn hàng: Xử lý, cập nhật trạng thái
- 🎫 Quản lý Voucher: Tạo, cập nhật mã giảm giá
- 🎉 Quản lý Khuyến mãi: Tạo chương trình khuyến mãi
- 🔒 JWT Authentication: Bảo mật API endpoints
- 📱 RESTful APIs: Chuẩn REST cho frontend
- 📄 Swagger Documentation: API documentation tự động
- 🚀 Performance: Caching, optimization
- 🔄 Real-time: SignalR cho notifications
📁 ShoeStore/
├── 🌐 WebApp/ # Backend ASP.NET Core
│ ├── 🎮 Controllers/ # API Controllers
│ ├── 🔧 Services/ # Business Logic
│ ├── 📊 Data/ # Entity Framework
│ ├── 📝 Models/ # Entities & DTOs
│ ├── 🎨 BlazorPages/ # Admin UI
│ └── 🌍 wwwroot/ # Static files
├── ⚛️ shoestore-react/ # Frontend React
│ ├── 🎨 src/components/ # UI Components
│ ├── 📄 src/pages/ # Page Components
│ ├── 🔧 src/services/ # API Services
│ └── 🎯 src/context/ # State Management
├── 🗄️ sqlscripts/ # Database Scripts
├── 📋 Plan/ # Planning Documents
└── 🧪 WebApp.Tests/ # Unit Tests
- Framework: ASP.NET Core 9.0
- UI Admin: Blazor Server + AntDesign 1.4.0
- Database: SQL Server + Entity Framework Core 9.0
- Authentication: JWT Bearer/Cookie + ASP.NET Identity
- Caching: Memory Cache / Redis
- File Storage: Imgur API
- Email: SMTP Gmail
- Documentation: Swagger/OpenAPI
- Framework: React 18.2.0
- Routing: React Router DOM 7.6.0
- UI Library: Shadcn UI + Radix UI
- Styling: Tailwind CSS 3.4.1
- Animation: Framer Motion 12.15.0
- HTTP Client: Axios 1.9.0
- Icons: Lucide React + Radix Icons
- Build Tool: Vite 5.1.0
- MoMo: E-wallet payment gateway
- VnPay: Bank payment gateway
- Security: HMAC-SHA256 encryption
- .NET SDK: 9.0 trở lên
- Node.js: 18.0 trở lên
- SQL Server: 2019 trở lên
- Visual Studio: 2022 (khuyến nghị)
git clone https://github.com/nghuuan2803/ShoeStore.git# appsettings.json
"ConnectionStrings": {
"SqlServer": "Server=.;Database=ShoeStore;Trusted_Connection=True;TrustServerCertificate=True;"# Sử dụng Migration
cd ShoeStore
cd WebApp
dotnet ef database update# Restore packages
dotnet restorecd shoestore-react
# Install dependencies
npm installTerminal 1 - Backend:
cd WebApp
dotnet run
# Backend sẽ chạy tại: https://localhost:5001
# Admin Panel: https://localhost:5001/adminTerminal 2 - Frontend:
cd shoestore-react
npm run dev
# Frontend sẽ chạy tại: http://localhost:3000- Design: Shadcn UI + Tailwind CSS
- Theme: Modern, minimal, responsive
- Components:
- Header with navigation & cart
- Product cards with promotion badges
- Cart drawer with real-time updates
- Checkout flow with payment integration
- Order tracking interface
- Design System: AntDesign 1.4.0
- Layout: Sidebar navigation + main content
- Features:
- Dashboard với charts & statistics
- Data tables với pagination & sorting
- Form validation & file uploads
- Real-time notifications
- Features: QR Code, App-to-app payment
- Security: HMAC-SHA256 signature
- Test Environment: Sandbox mode
- Features: ATM Cards, Internet Banking
- Security: SHA-256 hash validation
- Test Environment: Sandbox mode
- Chọn phương thức thanh toán
- Redirect đến gateway (MoMo/VnPay)
- Xử lý thanh toán trên gateway
- Callback về hệ thống
- Cập nhật trạng thái đơn hàng
- Thông báo kết quả cho khách hàng
- 🎯 Target Types: Product, Category, Brand, Global
- 💰 Discount Types: Percentage (%), Fixed Amount (VND)
- ⏰ Time-based: Start Date, End Date
- 🔢 Priority System: Áp dụng promotion có priority cao nhất
- 🚀 Auto-calculation: Tính toán tự động trong cart & product
- Badge Design: Purple gradient promotion badges
- Price Display:
Original PricePromotion Price - Cart Integration: Real-time promotion calculation
- Responsive: Mobile-friendly design
- Flash Sale 25% - Giảm 25% toàn bộ sản phẩm
- Sneaker Sale 15% - Giảm 15% giày sneaker
- Nike Sale 20% - Giảm 20% thương hiệu Nike
- Fixed 200K Off - Giảm 200,000 VND cố định
- VIP 30% - Giảm 30% (priority cao)
Made with ❤️ by annghdev