fix: remove date filter when getting adjustment eggs

This commit is contained in:
Adnan Zahir
2026-04-24 11:51:23 +07:00
parent 878b8ccce9
commit 50ce780c2c
@@ -897,7 +897,6 @@ func (r *HppV2RepositoryImpl) GetEggProduksiBreakdownByProjectFlockKandangIds(ct
Joins("JOIN product_warehouses AS pw ON pw.id = ast.product_warehouse_id"). Joins("JOIN product_warehouses AS pw ON pw.id = ast.product_warehouse_id").
Where("pw.project_flock_kandang_id IN (?)", projectFlockKandangIDs). Where("pw.project_flock_kandang_id IN (?)", projectFlockKandangIDs).
Where("ast.function_code = ?", string(utils.AdjustmentTransactionSubtypeRecordingEggIn)). Where("ast.function_code = ?", string(utils.AdjustmentTransactionSubtypeRecordingEggIn)).
Where("ast.created_at <= ?", *date).
Scan(&adjustmentTotals).Error Scan(&adjustmentTotals).Error
if err != nil { if err != nil {
return 0, 0, 0, 0, err return 0, 0, 0, 0, err
@@ -1154,7 +1153,6 @@ CROSS JOIN lokasi_rec_totals lrt
string(utils.AdjustmentTransactionTypeRecording), string(utils.AdjustmentTransactionTypeRecording),
). ).
Scan(&totals).Error Scan(&totals).Error
if err != nil { if err != nil {
return 0, 0, err return 0, 0, err
} }