fix last keuntungan_rebet
This commit is contained in:
@@ -736,9 +736,6 @@ class TebusController extends Controller
|
||||
$dateSM = new Carbon('2021-04-21');
|
||||
$dateSM->addDays(1);
|
||||
|
||||
$dateRM = new Carbon('2021-04-22');
|
||||
$dateRM->addDays(1);
|
||||
|
||||
$current = Carbon::now();
|
||||
$current = new Carbon();
|
||||
|
||||
@@ -754,12 +751,10 @@ class TebusController extends Controller
|
||||
->join($cawangan['db_name'].'.gadai as db2','transaksi_keuntungan.norujukan','=','db2.norujukan')
|
||||
// ->where('transaksi_keuntungan.tarikh_bayaran' ,'>=', $datetawarruq)
|
||||
->where('transaksi_keuntungan.tarikh_bayaran' ,'<=', $daterequest)
|
||||
->where('transaksi_keuntungan.tarikh_bayaran' ,'>=', $dateRM)
|
||||
->whereYear('tarikh_bayaran','=',$current->year)
|
||||
->whereNotNull('db2.hargajualan')
|
||||
->sum('keuntungan_rebet');
|
||||
|
||||
|
||||
$total = $keuntungan + $keuntunganreducing;
|
||||
|
||||
return response($total);
|
||||
|
||||
Reference in New Issue
Block a user