1.1 KiB
1.1 KiB
Summary: Unified UMKM and Pasar Desa Model
Changes Made:
- Model Unification:
ProdukUmkmhas been removed.PasarDesanow includesstokand an optionalumkmId.PenjualanProdukis now directly related toPasarDesa.- Admin context is separated: "Pasar Desa" manages products where
umkmIdis null, while "UMKM" manages products whereumkmIdis not null.
- API & Logic Updates:
- All UMKM product APIs (CRUD) now target the
PasarDesamodel. - Sales transactions correctly decrement
stokin thePasarDesatable. - Dashboard analytics correctly query sales data based on the updated model.
- All UMKM product APIs (CRUD) now target the
- UI Enhancements:
- Added
src/app/admin/(dashboard)/ekonomi/umkm/data-umkm/create/page.tsxfor UMKM business profiles. - Added
src/app/admin/(dashboard)/ekonomi/umkm/produk/create/page.tsxfor UMKM products with category support. - Updated list views to separate "Pasar Murni" and "UMKM Produk" logically.
- Added
Verification:
- Database schema synchronized with
prisma db push. - API logic updated and tested for consistency.