merge yang lejer am
This commit is contained in:
@@ -505,12 +505,12 @@ class TebusController extends Controller
|
||||
// ->whereNotNull('rebate')
|
||||
// ->sum('rebate');
|
||||
|
||||
$keuntunganselepastawarruqupah = Tebus::on($cawangan['mysql'])
|
||||
->where('t_tebus','<=',$request->tarikh)
|
||||
->where('t_tebus','>','2021-04-13')
|
||||
->whereYear('t_tebus','=',$current->year)
|
||||
->whereNotNull('bakiupah')
|
||||
->sum('bakiupah');
|
||||
// $keuntunganselepastawarruqupah = Tebus::on($cawangan['mysql'])
|
||||
// ->where('t_tebus','<=',$request->tarikh)
|
||||
// ->where('t_tebus','>','2021-04-13')
|
||||
// ->whereYear('t_tebus','=',$current->year)
|
||||
// ->whereNotNull('bakiupah')
|
||||
// ->sum('bakiupah');
|
||||
|
||||
$upahtebus = Tebus::on($cawangan['mysql'])
|
||||
->where([['t_tebus','<=',$request->tarikh],['t_tebus','>','2013-12-31']])
|
||||
@@ -530,10 +530,11 @@ class TebusController extends Controller
|
||||
|
||||
$keuntungansebelumtawarruq = $upahtebus + $upahlelong + $upahansur;
|
||||
|
||||
$keuntunganselepastawarruq = $keuntunganselepastawarruqupah;
|
||||
// $keuntunganselepastawarruq = $keuntunganselepastawarruqupah;
|
||||
|
||||
// $total = $keuntungansebelumtawarruq + $keuntunganselepastawarruq;
|
||||
|
||||
|
||||
$total = $keuntungansebelumtawarruq + $keuntunganselepastawarruq;
|
||||
$total = $keuntungansebelumtawarruq;
|
||||
|
||||
return response()->json($total,200);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user