Merged in izzati-feat-laporangadaitebusharisama (pull request #324)
update upah12
This commit is contained in:
@@ -101,6 +101,7 @@ class GadaianController extends Controller
|
|||||||
->whereDate('g.t_gadai', '<=', $endDate)
|
->whereDate('g.t_gadai', '<=', $endDate)
|
||||||
->whereDate('t.t_tebus', '>=', $startDate)
|
->whereDate('t.t_tebus', '>=', $startDate)
|
||||||
->whereDate('t.t_tebus', '<=', $endDate)
|
->whereDate('t.t_tebus', '<=', $endDate)
|
||||||
|
->where('g.upah12', '>=', 0.00)
|
||||||
->selectRaw('
|
->selectRaw('
|
||||||
COUNT(DISTINCT g.norujukan) as total_gadai_tebus_samahari,
|
COUNT(DISTINCT g.norujukan) as total_gadai_tebus_samahari,
|
||||||
SUM(g.pinjaman) as jumlah_pinjaman
|
SUM(g.pinjaman) as jumlah_pinjaman
|
||||||
@@ -153,6 +154,7 @@ class GadaianController extends Controller
|
|||||||
})
|
})
|
||||||
->whereBetween('g.t_gadai', [$startDate, $endDate])
|
->whereBetween('g.t_gadai', [$startDate, $endDate])
|
||||||
->whereRaw('DATE(g.t_gadai) = DATE(trans.created_at)')
|
->whereRaw('DATE(g.t_gadai) = DATE(trans.created_at)')
|
||||||
|
->where('g.upah12', '>=', 0.00)
|
||||||
->selectRaw("
|
->selectRaw("
|
||||||
COUNT(*) as jumlah_transaksi,
|
COUNT(*) as jumlah_transaksi,
|
||||||
AVG(TIME_TO_SEC(TIMEDIFF(TIME(trans.created_at), g.masa))) as avg_duration_sec
|
AVG(TIME_TO_SEC(TIMEDIFF(TIME(trans.created_at), g.masa))) as avg_duration_sec
|
||||||
|
|||||||
Reference in New Issue
Block a user