Feat[BE]: add multilpple type of chickin growing and laying, make convertion product when chickin approved, add projectflockkandangid on projectflock api

This commit is contained in:
aguhh18
2025-11-03 09:16:29 +07:00
parent 20f1be2ef8
commit 86f37a89c1
9 changed files with 485 additions and 346 deletions
+11
View File
@@ -574,6 +574,7 @@ func seedProductCategories(tx *gorm.DB, createdBy uint) (map[string]uint, error)
{"Bahan Baku", "RAW"},
{"Day Old Chick", "DOC"},
{"Pullet", "PULLET"},
{"Layer", "LAYER"},
}
result := make(map[string]uint, len(seeds))
@@ -808,6 +809,16 @@ func seedProducts(tx *gorm.DB, createdBy uint, uoms map[string]uint, categories
Suppliers: []string{"PT CHAROEN POKPHAND INDONESIA Tbk"},
Flags: []utils.FlagType{utils.FlagPullet},
},
{
Name: "Ayam Layer",
Brand: "MBU Layer",
Sku: "LAY0001",
Uom: "Ekor",
Category: "Layer",
Price: 20000,
Suppliers: []string{"PT CHAROEN POKPHAND INDONESIA Tbk"},
Flags: []utils.FlagType{utils.FlagLayer},
},
}
for _, seed := range seeds {