Browse Source

Merge pull request 'staging upload 23-06-07' (#75) from staging into master

Reviewed-on: ordo/adw-backend#75
pull/3/head
ibnu 1 year ago
parent
commit
3d60e397ed
  1. 5
      app/Helpers/MasterFunctionsHelper.php

5
app/Helpers/MasterFunctionsHelper.php

@ -192,7 +192,10 @@ class MasterFunctionsHelper {
try {
$dataTempPlan [$x]['percentage'] = ($keyPlanM->qty_planning/$sumVolPlan->ttl_qty_plan)*$keyPlanM->bobot_planning;
$sumPercentagePlan+=($keyPlanM->qty_planning/$sumVolPlan->ttl_qty_plan)*$keyPlanM->bobot_planning;
$totalBCWP += (((($keyPlanM->persentase_progress*$keyPlanM->bobot_planning)/100)/$keyPlanM->duration)* $totalRencanaBudget)/100;
if(isset($keyPlanM->duration) && $keyPlanM->duration > 0)
$totalBCWP += (((($keyPlanM->persentase_progress*$keyPlanM->bobot_planning)/100)/$keyPlanM->duration)* $totalRencanaBudget)/100;
else
$totalBCWP = 0;
$dataTempPlan [$x]['totalBCWP'] = $totalBCWP;
} catch (\DivisionByZeroError $e) {
return response()->json(['message' => $e->getMessage()]);

Loading…
Cancel
Save