added denominasi
This commit is contained in:
@@ -19,6 +19,14 @@ class DenominasiController extends Controller
|
||||
return response()->json($response);
|
||||
}
|
||||
|
||||
public function test2($kodcaw,Request $request){
|
||||
$teller = new TellerServices($kodcaw);
|
||||
$response = $teller->CashWithdrawals($request);
|
||||
|
||||
return response()->json($response);
|
||||
}
|
||||
|
||||
|
||||
public function listdenominasi($kodcaw)
|
||||
{
|
||||
$current = Carbon::now();
|
||||
|
||||
@@ -328,8 +328,8 @@ class TellerServices
|
||||
'tarikh' => $current->toDateString(),
|
||||
'kodcaw'=> $this->cawangan,
|
||||
'kodlaluan'=>$request->teller,
|
||||
'tambah'=>$request->amt,
|
||||
'kurang'=> 0,
|
||||
'tambah'=>0,
|
||||
'kurang'=> $request->amt,
|
||||
'nota'=>$request->nota,
|
||||
'created_at'=>$current
|
||||
]);
|
||||
@@ -347,7 +347,7 @@ class TellerServices
|
||||
}
|
||||
|
||||
$total_teller_deposit = $tunai['kurang'] + $request->amt;
|
||||
$remaining_teller_cashflow = $tunai['baki'] + $request->amt;
|
||||
$remaining_teller_cashflow = $tunai['baki'] - $request->amt;
|
||||
|
||||
Tunai::on($cawangan['mysql'])->where( [['tarikh','=', $current->toDateString()],['kodlaluan','=', $request->teller] ])->
|
||||
update(array(
|
||||
|
||||
@@ -648,6 +648,7 @@ $router->group(['prefix'=>'api'], function () use ($router){
|
||||
$router->get('/cawangan/bycawnotisperingatan/{kodcaw}/{notisid}',['uses'=>'CawanganCallCenterController@bycawnotisperingatan']);
|
||||
|
||||
$router->post('test/updatetunai/{kodcaw}',['uses'=>'DenominasiController@test']);
|
||||
$router->post('test/serahantunai/{kodcaw}',['uses'=>'DenominasiController@test2']);
|
||||
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user