update sttebus
This commit is contained in:
@@ -3413,4 +3413,19 @@ class GadaiController extends Controller
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public function updateTebusGadai(){
|
||||
$cawangan_all = Cawangan::on('mysql7')->get();
|
||||
|
||||
foreach($cawangan_all as $index=>$cawangan){
|
||||
$gadai_all = Gadai::on($cawangan['mysql'])->join('tebus','tebus.norujukan','=','gadai.norujukan')->where('gadai.sttebus','=','')->get();
|
||||
|
||||
foreach($gadai_all as $index=>$gadai){
|
||||
Gadai::on($cawangan['mysql'])->where('norujukan',$gadai['norujukan'])->update([
|
||||
'sttebus' => 'T'
|
||||
]);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -531,6 +531,7 @@ $router->group(['prefix'=>'api'], function () use ($router){
|
||||
$router->get('check/wtd',['uses'=>'WTDController@getDraftWTD']);
|
||||
|
||||
$router->get('check/lelong/tawarruq',['uses'=>'GadaiController@updateLelongTawarruq']);
|
||||
$router->get('update/sttebus/gadaian',['uses'=>'GadaiController@updateTebusGadai']);
|
||||
});
|
||||
|
||||
$router->group(['prefix'=>'e-arrahn'], function () use ($router){
|
||||
|
||||
Reference in New Issue
Block a user