add update gadai for online
This commit is contained in:
@@ -114,6 +114,17 @@ class GadaiController extends Controller
|
||||
return response()->json($gadai);
|
||||
}
|
||||
|
||||
public function updateGadaiMarhunOnline($kodcaw,$norujukan,Request $request)
|
||||
{
|
||||
$cawangan = Cawangan::on('mysql7')->where('kodcaw','=',$kodcaw)->first();
|
||||
$gadai = Gadai::on($cawangan['mysql'])->where('norujukan','=',$norujukan)->update(array(
|
||||
'bakipjm' => $request->baki_pinjaman,
|
||||
'jbg' => $request->tempoh,
|
||||
't_update' => $request->tarikh_bayar
|
||||
));
|
||||
return response()->json($gadai, 200);
|
||||
}
|
||||
|
||||
public function delete($id)
|
||||
{
|
||||
Gadai::findOrFail($id)->delete();
|
||||
|
||||
Reference in New Issue
Block a user