|
|
@@ -2768,16 +2768,14 @@ class DealerController extends Controller |
|
|
|
$dataSeptember = $this->returnDataR($company,'2020','9'); |
|
|
|
$dataOctober = $this->returnDataR($company,'2020','10'); |
|
|
|
|
|
|
|
info(count($dataAugust)); |
|
|
|
foreach ($dataAugust as $key => $d) { |
|
|
|
if(date('d/m/Y', strtotime($d['activation'])) >= '11/8/2020'){ |
|
|
|
$combineData[] = $d; |
|
|
|
$countAugust[] = $d; |
|
|
|
} |
|
|
|
} |
|
|
|
info(count($combineData)); |
|
|
|
// Store to combineData New Incentive August |
|
|
|
foreach ($combineData as $key => $d) { |
|
|
|
if(count($combineData) >= 50){ |
|
|
|
foreach ($countAugust as $key => $d) { |
|
|
|
if(count($countAugust) >= 50){ |
|
|
|
if(date('m/Y', strtotime($d['activation'])) == $month.'/'.$year){ |
|
|
|
if($d['contract'] == '12'){ |
|
|
|
info("1". $d['wo']); |
|
|
@@ -2815,8 +2813,7 @@ class DealerController extends Controller |
|
|
|
)); |
|
|
|
} |
|
|
|
} |
|
|
|
info(">50" .count($combineData)); |
|
|
|
}else if(count($combineData) < 50){ |
|
|
|
}else if(count($countAugust) < 50){ |
|
|
|
if(date('m/Y', strtotime($d['activation'])) == $month.'/'.$year){ |
|
|
|
if($d['contract'] == '12'){ |
|
|
|
info("3". $d['wo']); |
|
|
@@ -2853,7 +2850,6 @@ class DealerController extends Controller |
|
|
|
)); |
|
|
|
} |
|
|
|
} |
|
|
|
info("<50" .count($combineData)); |
|
|
|
} |
|
|
|
} |
|
|
|
|