tambahan hapus ansuran
This commit is contained in:
@@ -96,7 +96,7 @@ class PanjarServices
|
||||
if (!$vault) throw new \Exception('Custom Exception: Vault Does Not Exist!');
|
||||
if (!$deno_panjar) throw new \Exception('Custom Exception: Denominasi Panjar Does Not Exist!');
|
||||
|
||||
DB::transaction(function () use ($cawangan,$deno_panjar,$panjar,$denominasi,$current,$vault) {
|
||||
DB::transaction(function () use ($cawangan,$deno_panjar,$panjar,$denominasi,$current,$vault,$request) {
|
||||
|
||||
$return_data = $this->calculation_denominasi($deno_panjar,$denominasi,'masuk');
|
||||
if($return_data == 'no data') throw new \Exception('Custom Exception: Denominasi Panjar Not Return Data');
|
||||
@@ -297,9 +297,20 @@ class PanjarServices
|
||||
$audit->updated_at = $current;
|
||||
$audit->save();
|
||||
|
||||
$array_response = [
|
||||
'result' => 'success',
|
||||
'data' => 1
|
||||
];
|
||||
return response()->json($array_response);
|
||||
|
||||
});
|
||||
}catch(\Exception $e){
|
||||
dd($e->getMessage());
|
||||
$array_response = [
|
||||
'result' => 'error',
|
||||
'data' => $e->getMessage()
|
||||
];
|
||||
return response()->json($array_response);
|
||||
Log::error('Exception: ' , $e->getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user