28 lines
975 B
Markdown
28 lines
975 B
Markdown
# Market Module
|
|
|
|
## Purpose
|
|
Manages product and store operations for the multi-vendor marketplace. Handles product CRUD, store management, and transaction tracking.
|
|
|
|
## Key Files
|
|
- `app/Http/Controllers/Market/ProductController.php` - Product controller
|
|
- `app/Http/Controllers/Market/StoreController.php` - Store controller
|
|
- `app/Models/Market/Product.php` - Product model
|
|
- `app/Models/Market/Store.php` - Store model
|
|
|
|
## Public APIs
|
|
- `createNew_Admin()` - Create product for admin
|
|
- `editProductAdmin()` - Edit product
|
|
- `AddProducttoStore()` / `RemoveProductFromStore()`
|
|
- `store()` - Create new store
|
|
- `update()` - Update store
|
|
|
|
## Dependencies
|
|
- `App\Models\Market\Product`
|
|
- `App\Models\Market\Store`
|
|
- `App\Models\User`
|
|
|
|
## Important Behavior
|
|
- Products can belong to multiple stores (belongsToMany)
|
|
- Supports categories and subcategories via enums
|
|
- Tracks transaction sessions per store
|
|
- Store-product relationship with pivot data (available, price, is_active) |