How vietanh123456/nong-san-ecommerce works
Nông Sản Việt is a Laravel marketplace for regional agricultural goods. Buyers discover products, manage a cart, check out, then track orders and review purchases; sellers maintain listings, batches, certificates, and fulfillment; administrators moderate users, sellers, products, certificates, reviews, coupons, and reporting. The graph keeps checkout, seller operations, administration, and traceability distinct, with the Eloquent domain models as a shared internal layer. Controller-to-model links are based on SOURCE INDEX references; broader capabilities and routes are documented in the README and routes/web.php. Unsampled implementation details are not inferred.
Main entry points: CheckoutController.php Checkout and payment · Product.php Product records · DashboardController.php Admin overview · ProductController.php Product catalog
Components 33
Buyer storefront
- Product catalog
app/Http/Controllers/ProductController.php - Shopping cart
app/Http/Controllers/CartController.php - Checkout and payment
app/Http/Controllers/CheckoutController.php - Order tracking
app/Http/Controllers/OrderController.php - Product reviews
app/Http/Controllers/ReviewController.php - Saved products
app/Http/Controllers/WishlistController.php
Seller operations
- Seller registration
app/Http/Controllers/SellerRegisterController.php - Product management
app/Http/Controllers/Seller/ProductController.php - Batch management
app/Http/Controllers/Seller/ProductBatchController.php - Seller order handling
app/Http/Controllers/Seller/OrderController.php
Administration
- Admin overview
app/Http/Controllers/Admin/DashboardController.php - Seller requests
app/Http/Controllers/Admin/SellerRequestController.php - User administration
app/Http/Controllers/Admin/AdminUserController.php - Coupon management
app/Http/Controllers/Admin/CouponController.php - Sales statistics
app/Http/Controllers/Admin/StatisticsController.php
Traceability
- Batch trace lookup
app/Http/Controllers/TraceController.php - Certificate access
app/Http/Controllers/CertificateFileController.php
Shared domain
- Product records
app/Models/Product.php - User accounts
app/Models/User.php - Cart records
app/Models/Cart.php - Orders
app/Models/Order.php - Order details
app/Models/OrderDetail.php - Addresses
app/Models/Address.php - Coupons
app/Models/Coupon.php - Categories
app/Models/Category.php - Product batches
app/Models/ProductBatch.php - Certificates
app/Models/Certificate.php - Reviews
app/Models/Review.php - Seller requests
app/Models/SellerRequest.php - Wishlist records
app/Models/Wishlist.php
Other components
- Buyer
- Seller
- Administrator
Connections 48
- Buyer → Product catalog: browse
- Buyer → Shopping cart: manage cart
- Buyer → Checkout and payment: place order
- Buyer → Order tracking: track orders
- Buyer → Product reviews: review purchase
- Buyer → Saved products: save products
- Seller → Seller registration: request seller role
- Seller → Product management: manage listings
- Seller → Batch management: manage batches
- Seller → Seller order handling: manage orders
- Administrator → Admin overview: review operations
- Administrator → Seller requests: review seller requests
- Administrator → User administration: manage users
- Administrator → Coupon management: manage coupons
- Administrator → Sales statistics: view statistics
- Buyer → Batch trace lookup: trace batch
- Product catalog → Product records: queries
app/Http/Controllers/ProductController.php - Product catalog → Categories: queries
app/Http/Controllers/ProductController.php - Product catalog → Reviews: queries
app/Http/Controllers/ProductController.php - Shopping cart → Cart records: uses cart records
- Checkout and payment → Addresses: loads
app/Http/Controllers/CheckoutController.php - Checkout and payment → Coupons: validates
app/Http/Controllers/CheckoutController.php - Checkout and payment → Orders: creates and updates
app/Http/Controllers/CheckoutController.php - Checkout and payment → Order details: creates and reads
app/Http/Controllers/CheckoutController.php - Checkout and payment → Product records: checks stock
app/Http/Controllers/CheckoutController.php - Order tracking → Orders: uses orders
- Product reviews → Product records: receives product
app/Http/Controllers/ReviewController.php - Product reviews → Reviews: creates or updates
app/Http/Controllers/ReviewController.php - Saved products → Wishlist records: uses wishlist records
- Product management → Product records: creates and updates
app/Http/Controllers/Seller/ProductController.php - Product management → Categories: loads choices
app/Http/Controllers/Seller/ProductController.php - Batch management → Product records: loads products
app/Http/Controllers/Seller/ProductBatchController.php - Batch management → Product batches: manages batches
app/Http/Controllers/Seller/ProductBatchController.php - Batch management → Certificates: manages certificates
app/Http/Controllers/Seller/ProductBatchController.php - Seller registration → Seller requests: submits request
- Seller order handling → Orders: handles orders
- Admin overview → User accounts: queries
app/Http/Controllers/Admin/DashboardController.php - Admin overview → Product records: queries
app/Http/Controllers/Admin/DashboardController.php - Admin overview → Certificates: reviews pending
app/Http/Controllers/Admin/DashboardController.php - Admin overview → Reviews: queries
app/Http/Controllers/Admin/DashboardController.php - Seller requests → Seller requests: reviews
app/Http/Controllers/Admin/SellerRequestController.php - Seller requests → User accounts: updates seller accounts
app/Http/Controllers/Admin/SellerRequestController.php - User administration → User accounts: manages
app/Http/Controllers/Admin/AdminUserController.php - Coupon management → Coupons: manages
app/Http/Controllers/Admin/CouponController.php - Sales statistics → Orders: aggregates
app/Http/Controllers/Admin/StatisticsController.php - Sales statistics → Order details: ranks products
app/Http/Controllers/Admin/StatisticsController.php - Sales statistics → User accounts: counts customers
app/Http/Controllers/Admin/StatisticsController.php - Batch trace lookup → Product batches: looks up batch