Merge pull request 'Added production quantity report logic' (#1436) from ranjith-dev into master
All checks were successful
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 16s
All checks were successful
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 16s
Reviewed-on: #1436
This commit was merged in pull request #1436.
This commit is contained in:
@@ -468,6 +468,14 @@ class SendProductionReport extends Command
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (strtolower($line->type) == 'base fg line') {
|
||||||
|
|
||||||
|
$productionQuantity = ProductionQuantity::where('plant_id', $plant->id)
|
||||||
|
->where('line_id', $line->id)
|
||||||
|
->whereBetween('created_at', [$startDate, $endDate])
|
||||||
|
->count();
|
||||||
|
}
|
||||||
|
|
||||||
$dayShiftEfficiency = $dayShiftPlanQuan > 0 ? ($dayproductionQuantity / $dayShiftPlanQuan) * 100 : 0;
|
$dayShiftEfficiency = $dayShiftPlanQuan > 0 ? ($dayproductionQuantity / $dayShiftPlanQuan) * 100 : 0;
|
||||||
|
|
||||||
$nightShiftEfficiency = $nightShiftPlanQuan > 0 ? ($nightproductionQuantity / $nightShiftPlanQuan) * 100 : 0;
|
$nightShiftEfficiency = $nightShiftPlanQuan > 0 ? ($nightproductionQuantity / $nightShiftPlanQuan) * 100 : 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user