Merge branch 'master' into 'apiaku'
# Conflicts: # app/Http/Controllers/LelongController.php
This commit is contained in:
@@ -238,18 +238,19 @@ class LelongController extends Controller
|
||||
$tarikhbaru = $request->mula;
|
||||
$cawangan = Cawangan::on('mysql7')->where('kodcaw','=',$kodcaw)->first();
|
||||
|
||||
$bakilelong = Lelong::on($cawangan['mysql'])
|
||||
->where('trkhtuntut','>=',$request->mula)
|
||||
->where('trkhtuntut','<=',$request->hingga)
|
||||
->where('baki','>=',0)
|
||||
->sum('baki');
|
||||
|
||||
$bakilelong = Lelong::on($cawangan['mysql'])
|
||||
->where('trkhtuntut','>=',$request->mula)
|
||||
->where('trkhtuntut','<=',$request->hingga)
|
||||
->where('baki','>=',0)
|
||||
->sum('baki');
|
||||
|
||||
$rugilelong = Lelong::on($cawangan['mysql'])
|
||||
->where('trkhtuntut','>=',$request->mula)
|
||||
->where('trkhtuntut','<=',$request->hingga)
|
||||
->where('baki','<',0)
|
||||
->sum('baki');
|
||||
|
||||
|
||||
$rugitotal = $rugilelong;
|
||||
|
||||
$arraylelong = ['bakilelong' => $bakilelong, 'rugilelong' => $rugitotal];
|
||||
|
||||
@@ -164,6 +164,8 @@ class TebusController extends Controller
|
||||
|
||||
public function getMoratorium(){
|
||||
$bln_mora = Moratorium::first();
|
||||
|
||||
return response()->json($bln_mora);
|
||||
}
|
||||
|
||||
public function updateMoratorium(Request $request){
|
||||
|
||||
@@ -102,6 +102,8 @@ $router->group(['prefix'=>'api'], function () use ($router){
|
||||
$router->get('tebus/laporan/{kodcaw}/{tarikh}',['uses'=>'TebusController@getLaporanTebus']);
|
||||
$router->get('tebus/laporanjenistawarruq/{kodcaw}',['uses'=>'TebusController@getLaporanTebusPengasingan']);
|
||||
|
||||
$router->get('moratorium/details',['uses'=>'TebusController@getMoratorium']);
|
||||
|
||||
//Maintenance API TEBUS
|
||||
// $router->get('rebet/{kodcaw}/{norujukan}',['uses' => 'TebusController@rebet']);
|
||||
$router->put('updatetebus/{kodcaw}/{norujukan}',['uses'=>'TebusController@tebusUpdate']);
|
||||
|
||||
Reference in New Issue
Block a user