Changed monthly plan logic in target plan
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 16s
Gemini PR Review / Gemini PR Review (pull_request) Failing after 19s
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (pull_request) Successful in 13s
Laravel Pint / pint (pull_request) Successful in 2m48s
Laravel Larastan / larastan (pull_request) Failing after 5m43s

This commit is contained in:
dhanabalan
2026-09-30 15:03:52 +05:30
parent c533e4eaae
commit b4461fad34

View File

@@ -631,11 +631,13 @@ class ProductionTargetPlan extends Component
$this->records = $records;
$this->monthlyRecords = ProductionPlan::where('plant_id', $plantId)
->where('line_id', $lineId)
->whereYear('created_at', $year)
->whereMonth('created_at', $month)
->sum('plan_quantity');
// $this->monthlyRecords = ProductionPlan::where('plant_id', $plantId)
// ->where('line_id', $lineId)
// ->whereYear('created_at', $year)
// ->whereMonth('created_at', $month)
// ->sum('plan_quantity');
$this->monthlyRecords = $plans->sum('plan_quantity');
}
// public function loadMonthlyPlan($year, $month, $plantId, $lineId){