srp admin dashboad fix
This commit is contained in:
@@ -79,13 +79,14 @@ class SRPAdminController extends Controller
|
|||||||
foreach($fleetTypes as $f) {
|
foreach($fleetTypes as $f) {
|
||||||
if($r['fleet_type'] == $f->code) {
|
if($r['fleet_type'] == $f->code) {
|
||||||
$temp['fleet_type'] = $f->description;
|
$temp['fleet_type'] = $f->description;
|
||||||
|
$temp['cost_code'] = $f->code;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//Calculate the recommended srp amount
|
//Calculate the recommended srp amount
|
||||||
foreach($payouts as $p) {
|
foreach($payouts as $p) {
|
||||||
if($r['ship_type'] == $p->code) {
|
if($r['ship_type'] == $p->code) {
|
||||||
$temp['actual_srp'] = $r['loss_value'] * ($p->payout / 100.00 );
|
$temp['actual_srp'] = $r['loss_value'] * ($p->payout / 100.00 );
|
||||||
$temp['cost_code'] = $p->payout;
|
$temp['payout'] = $p->payout;
|
||||||
$sum_actual += $temp['actual_srp'];
|
$sum_actual += $temp['actual_srp'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,10 +41,10 @@
|
|||||||
</td>
|
</td>
|
||||||
<td><!-- Ship Type -->
|
<td><!-- Ship Type -->
|
||||||
{{ Form::select('ship_type', $viewShipTypes, $row['ship_type']) }}
|
{{ Form::select('ship_type', $viewShipTypes, $row['ship_type']) }}
|
||||||
{!! $row['ship_type'] !!}
|
{!! $row['cost_code'] !!}
|
||||||
</td>
|
</td>
|
||||||
<td><!-- Payout percentage -->
|
<td><!-- Payout percentage -->
|
||||||
{{ $row['cost_code'] }}
|
{{ $row['payout'] }}
|
||||||
</td>
|
</td>
|
||||||
<td><!-- Fleet Type -->
|
<td><!-- Fleet Type -->
|
||||||
{{ $row['fleet_type'] }}
|
{{ $row['fleet_type'] }}
|
||||||
|
|||||||
Reference in New Issue
Block a user