Changed logic in item overview page
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 13s
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (pull_request) Successful in 16s
Gemini PR Review / Gemini PR Review (pull_request) Failing after 19s
Laravel Pint / pint (pull_request) Successful in 5m12s
Laravel Larastan / larastan (pull_request) Failing after 6m11s

This commit is contained in:
dhanabalan
2026-10-29 11:03:01 +05:30
parent 92beb31874
commit 40a893fbe9

View File

@@ -186,10 +186,8 @@ class ItemOverview extends ChartWidget
$weeklyPlanQuantity = \DB::table('production_plans') $weeklyPlanQuantity = \DB::table('production_plans')
->where('plant_id', $selectedPlant) ->where('plant_id', $selectedPlant)
->where('line_id', $selectedLine) ->where('line_id', $selectedLine)
->whereBetween('created_at', [ ->whereYear('created_at', $startDate->year)
$startDate, ->whereMonth('created_at', $startDate->month)
$endDate
])
->sum('plan_quantity'); ->sum('plan_quantity');
$daysCount = count($orderedData); $daysCount = count($orderedData);