Merge branch 'master' of https://gitlab.com/online-sistem1/api_arrahn into adminapi

This commit is contained in:
hafifierahman
2022-04-12 12:17:18 +08:00
2 changed files with 37 additions and 10 deletions
+17 -7
View File
@@ -321,7 +321,12 @@ class GadaiController extends Controller
->where('norujukan','=',$norujukan)
->first();
$bilang_bln = $gadai_data['tempoh'] - $gadai_data['tempohbayar'];
if($gadai_data['tempoh'] >= 12.0){
$tempoh = 12;
}else{
$tempoh = $gadai_data['tempoh'];
}
$bilang_bln = $tempoh - $gadai_data['tempohbayar'];
$upahsemasa_raw = $bilang_bln * (($gadai_data['kadarupah']/100 )* $gadai_data['pinjaman']);
@@ -343,7 +348,12 @@ class GadaiController extends Controller
->where('norujukan','=',$norujukan)
->first();
$bilang_bln = $gadai_data['tempoh'] - $gadai_data['tempohbayar'];
if($gadai_data['tempoh'] >= 12.0){
$tempoh = 12;
}else{
$tempoh = $gadai_data['tempoh'];
}
$bilang_bln = $tempoh - $gadai_data['tempohbayar'];
$upahrebet_raw = $bilang_bln * (($gadai_data['kadarupah']/100 )* $gadai_data['bakipjm']);
@@ -3286,14 +3296,14 @@ class GadaiController extends Controller
if($gadai['t_gadai'] == $current->toDateString()){
$tempoh_gadai = 0.5;
}
if($tempoh_gadai >= 6.0){
if($gadai['t_matang'] >= $current->toDateString()){
$tempoh_gadai = 6.0;
}
}else if($tempoh_gadai >= 12){
if($tempoh_gadai >= 12.0){
if($gadai['t_matang1'] >= $current->toDateString()){
$tempoh_gadai = 12.0;
}
}else if($tempoh_gadai >= 6.0){
if($gadai['t_matang'] >= $current->toDateString()){
$tempoh_gadai = 6.0;
}
}
$upah_semasa = $this->kiraupahTawarruqStokAudit($tempoh_gadai,$gadai['tempohbayar'],$gadai['kadarupah'],$gadai['bakipjm']);
+20 -3
View File
@@ -81,7 +81,12 @@ class TebusController extends Controller
->where('norujukan','=',$norujukan)
->first();
$bilang_bln = $gadai_data['tempoh'] - $gadai_data['tempohbayar'];
if($gadai_data['tempoh'] >= 12.0){
$tempoh = 12;
}else{
$tempoh = $gadai_data['tempoh'];
}
$bilang_bln = $tempoh - $gadai_data['tempohbayar'];
$upahsemasa_raw = $bilang_bln * (($gadai_data['kadarupah']/100 )* $gadai_data['pinjaman']);
@@ -106,7 +111,13 @@ class TebusController extends Controller
->where('norujukan','=',$norujukan)
->first();
$bilang_bln = $gadai_data['tempoh'] - $gadai_data['tempohbayar'];
if($gadai_data['tempoh'] >= 12.0){
$tempoh = 12;
}else{
$tempoh = $gadai_data['tempoh'];
}
$bilang_bln = $tempoh - $gadai_data['tempohbayar'];
$upahrebet_raw = $bilang_bln * (($gadai_data['kadarupah']/100 )* $gadai_data['bakipjm']);
@@ -131,6 +142,12 @@ class TebusController extends Controller
->where('norujukan','=',$norujukan)
->first();
if($gadai_data['tempoh'] >= 12.0){
$tempoh = 12;
}else{
$tempoh = $gadai_data['tempoh'];
}
$bilang_bln = $gadai_data['tempoh'] - $gadai_data['tempohbayar'];
$upahrebet_raw = $bilang_bln * (($gadai_data['kadarupah']/100 )* $gadai_data['bakipjm']);
@@ -658,7 +675,7 @@ class TebusController extends Controller
->orderBy('tebus.sirit')
->get();
$tebus = [];
$tebus = [];
if($tebus_data){
foreach($tebus_data as $index=>$tebusData){
$customer_info = Customer::on('mysql7')->where('kplama','=',$tebusData['nokp'])->orWhere('kpbaru','=',$tebusData['nokp'])->first();