Revert "Merge branch 'fix/implement-fifo-v2' into 'dev/fifo-v2'"

This reverts merge request !340
This commit is contained in:
Hafizh A. Y.
2026-02-27 09:37:03 +00:00
parent 915302c445
commit f6c88b773d
28 changed files with 163 additions and 1468 deletions
@@ -58,17 +58,17 @@ type SapronakReportDTO struct {
// Simplified view for project-level sapronak response
type SapronakCategoryRowDTO struct {
ID int `json:"id"`
Date string `json:"date"`
ReferenceNumber string `json:"reference_number"`
QtyIn float64 `json:"qty_in"`
QtyOut float64 `json:"qty_out"`
QtyUsed float64 `json:"qty_used"`
Description string `json:"description"`
ID int `json:"id"`
Date string `json:"date"`
ReferenceNumber string `json:"reference_number"`
QtyIn float64 `json:"qty_in"`
QtyOut float64 `json:"qty_out"`
QtyUsed float64 `json:"qty_used"`
Description string `json:"description"`
ProductCategory []string `json:"product_category"`
UnitPrice float64 `json:"unit_price"`
TotalAmount float64 `json:"total_amount"`
Notes string `json:"notes"`
UnitPrice float64 `json:"unit_price"`
TotalAmount float64 `json:"total_amount"`
Notes string `json:"notes"`
}
type SapronakCategoryTotalDTO struct {
@@ -148,7 +148,7 @@ func ToSapronakProjectAggregatedFromReport(report *SapronakReportDTO, flag strin
normalizeFlag := func(raw string) string {
normalized := strings.ToUpper(strings.TrimSpace(raw))
if normalized == "AYAM" || normalized == "PULLET" {
if normalized == "PULLET" {
return "DOC"
}
return normalized
@@ -177,7 +177,6 @@ func ToSapronakProjectAggregatedFromReport(report *SapronakReportDTO, flag strin
}
flagOrder := map[string]int{
"AYAM": 0,
"DOC": 0,
"PAKAN": 0,
"OVK": 0,