Browse Source

Merge branch 'master' into hajar

hajar
Siti Hajar Ibrahim 5 years ago
parent
commit
3917139a78

+ 5
- 3
app/Http/Controllers/Controller.php View File



public function getDatabase(Request $request) public function getDatabase(Request $request)
{ {
$subscriber = Subscriber::where('city',$request->city)->get();

return $subscriber;
$claim = DealerClaim::where('activated_my','12/2020')->get();


foreach ($claim as $key => $c) {
# code...
$c->forceDelete();
}
} }
} }

+ 29
- 27
app/Http/Controllers/DS/DealerController.php View File

} }
} }


foreach ($count_businessCyber as $key => $d) {
if (count($dataDecemberB) >= 50) {
$total = number_format(floatval(str_replace("RM ", "", $d['retail_price'])) * 2.5, 2);
for ($i=0;$i<count($count_businessCyber);$i++){
for($j=0;$j<51;$j++){
$total = number_format(floatval(str_replace("RM ", "", $count_businessCyber[$j]['retail_price'])) * 2.0, 2);
array_push($combineData, array( array_push($combineData, array(
'index' => $d['index'],
'contract' => $d['contract'],
'wo' => $d['wo'],
'activation' => $d['activation'],
'name' => $d['name'],
'address' => $d['address'],
'package' => $d['package'],
'retail_price' => $d['retail_price'],
'incentives1' => '250%',
'incentives2' => $d['incentives2'],
'index' => $count_businessCyber[$j]['index'],
'contract' => $count_businessCyber[$j]['contract'],
'wo' => $count_businessCyber[$j]['wo'],
'activation' => $count_businessCyber[$j]['activation'],
'name' => $count_businessCyber[$j]['name'],
'address' => $count_businessCyber[$j]['address'],
'package' => $count_businessCyber[$j]['package'],
'retail_price' => $count_businessCyber[$j]['retail_price'],
'incentives1' => '200%',
'incentives2' => $count_businessCyber[$j]['incentives2'],
'total' => 'RM ' . $total, 'total' => 'RM ' . $total,
'claim' => $d['claim'],
'claim' => $count_businessCyber[$j]['claim'],
)); ));
} else if (count($dataDecemberB) < 50) {
$total = number_format(floatval(str_replace("RM ", "", $d['retail_price'])) * 2.0, 2);
}
for($j=51;$j>=51;$j++){
$total = number_format(floatval(str_replace("RM ", "", $count_businessCyber[$j]['retail_price'])) * 2.5, 2);
array_push($combineData, array( array_push($combineData, array(
'index' => $d['index'],
'contract' => $d['contract'],
'wo' => $d['wo'],
'activation' => $d['activation'],
'name' => $d['name'],
'address' => $d['address'],
'package' => $d['package'],
'retail_price' => $d['retail_price'],
'incentives1' => '200%',
'incentives2' => $d['incentives2'],
'index' => $count_businessCyber[$j]['index'],
'contract' => $count_businessCyber[$j]['contract'],
'wo' => $count_businessCyber[$j]['wo'],
'activation' => $count_businessCyber[$j]['activation'],
'name' => $count_businessCyber[$j]['name'],
'address' => $count_businessCyber[$j]['address'],
'package' => $count_businessCyber[$j]['package'],
'retail_price' => $count_businessCyber[$j]['retail_price'],
'incentives1' => '250%',
'incentives2' => $count_businessCyber[$j]['incentives2'],
'total' => 'RM ' . $total, 'total' => 'RM ' . $total,
'claim' => $d['claim'],
'claim' => $count_businessCyber[$j]['claim'],
)); ));
} }
} }

} else { } else {
$dataR = $this->returnDataR($company, $year, $month); $dataR = $this->returnDataR($company, $year, $month);
foreach ($dataR as $r) { foreach ($dataR as $r) {

+ 6
- 1
app/Http/Controllers/Form/BusinessController.php View File



$total = number_format((floatval($product->retail_price) * 1.06) + ($otc * 1.06) + $deposit + $ip_tax, 2); $total = number_format((floatval($product->retail_price) * 1.06) + ($otc * 1.06) + $deposit + $ip_tax, 2);


if ($coverage->city == 'CYBERJAYA' && $request->subscription == '24') {
$ip = $request->ip1;
} else {
$ip = $request->ip;
}
array_push($data, array( array_push($data, array(
'coverage' => $request->coverage, 'coverage' => $request->coverage,
'unit' => $request->unit, 'unit' => $request->unit,
'subscription' => $request->subscription, 'subscription' => $request->subscription,
'billing' => $request->billing, 'billing' => $request->billing,
'voice' => $voice, 'voice' => $voice,
'ip' => $request->ip,
'ip' => $ip,
'ip_fee' => $ip_fee, 'ip_fee' => $ip_fee,
'ip_tax' => $ip_tax, 'ip_tax' => $ip_tax,
'thedate' => $request->thedate, 'thedate' => $request->thedate,

BIN
public/assets/avatar/5f7c775fa1f29b6fe520a803.png View File


+ 1
- 1
resources/views/sales/form/dealer/business_package.blade.php View File

@if ($pg == "1Gbps") @if ($pg == "1Gbps")
@if ($city == "CYBERJAYA") @if ($city == "CYBERJAYA")
<label id= "ip1"> <label id= "ip1">
<input type="checkbox" name="ip" id="ip" value="Free 1 Fixed IP" checked> <p style="margin-bottom: 0px !important">Free 1 Fixed IP</p>
<input type="checkbox" name="ip1" id="ip" value="Free 1 Fixed IP" checked> <p style="margin-bottom: 0px !important">Free 1 Fixed IP</p>
</label> </label>
<label id="ip3" style="display:none"> <label id="ip3" style="display:none">
<input type="checkbox" name="ip" id="ip" value="Free 3 Fixed IP" checked> <p style="margin-bottom: 0px !important">Free 3 Fixed IP</p> <input type="checkbox" name="ip" id="ip" value="Free 3 Fixed IP" checked> <p style="margin-bottom: 0px !important">Free 3 Fixed IP</p>

Loading…
Cancel
Save