59 Commits

Author SHA1 Message Date
nurafrinaalimi16 d6df3e744c fix resit tebus (diskaun promosi) 2026-09-02 16:16:15 +08:00
nurafrinaalimi16 166215b989 fix layout laporan on pc/ppc view 2026-09-02 11:32:57 +08:00
nurafrinaalimi16 f895ddb404 fix kadar rebet on teller page 2026-09-02 11:32:19 +08:00
nurafrinaalimi16 ac519f7a5f Merge remote-tracking branch 'origin/prod-kopkb' into annur-rebate 2026-09-01 11:08:05 +08:00
nurafrinaalimi16 8512205b87 logo for sag latest version 2026-05-26 10:09:42 +08:00
nurafrinaalimi16 1ba51d1158 pelarasan rebate on imbang duga 2025-08-17 16:03:10 +08:00
nurafrinaalimi16 e95e7671ed fix rounded diskaun rebate 2025-05-27 12:23:23 +08:00
nurafrinaalimi16 1d4c5d47f3 fix laporan tebus 2025-05-21 16:49:24 +08:00
nurafrinaalimi16 4e5d6d4d3d fix sag hilang 2025-05-18 09:59:10 +08:00
nurafrinaalimi16 7718b137c7 fix penebusan controller 2025-05-13 11:10:10 +08:00
nurafrinaalimi16 41bacebd54 sag new version 2025-05-11 16:34:30 +08:00
nurafrinaalimi16 302584f137 rebate annur 2025-05-11 16:32:30 +08:00
nurafrinaalimi16 4ed8067239 Merge branch 'production' of https://bitbucket.org/arrahn-pkb/kaunter into annur-rebate 2025-02-05 12:18:49 +08:00
nurafrinaalimi16 a0a50b42a0 imbang duga koperasi 2025-02-03 12:14:02 +08:00
BTMS3 14677ea777 newupdatesagv2.2 2025-02-03 12:13:35 +08:00
Ain Izazi 9e840c0439 remove command 2025-02-03 12:13:35 +08:00
Ain Izazi 3d66712c4e feat audit 2025-02-03 12:13:35 +08:00
Ain Izazi 1058ece282 audit di kaunter 2025-02-03 12:13:35 +08:00
BTMS3 e5666e1106 update sag v2.2 2025-02-03 12:13:35 +08:00
Hafifie PKB 59b0118100 restore 2025-01-14 2025-02-03 12:13:35 +08:00
BTMS2 9a40c39349 tutup whatsapp 2025-02-03 12:13:35 +08:00
Hafifie PKB cbd8ea5c52 fix commit notification bawah umur 2025-02-03 12:13:35 +08:00
hafifierahman 34c06649b7 added function to detect customers that underage 2025-02-03 12:13:35 +08:00
Ain Izazi 6974e48b6e update message di khazanah dan importan work 2025-02-03 12:13:35 +08:00
Ain Izazi d52eee991b update pekerjaan lain-lain 2025-02-03 12:13:34 +08:00
Ain Izazi f2ee3b8031 add auth user di barcodescannedtebus 2025-02-03 12:13:16 +08:00
Ain Izazi ce6c2c4f3e add auth user di wakilController 2025-02-03 12:13:16 +08:00
Ain Izazi a0ed815f8e add insert record utk pendahuluan dan serah 2025-02-03 12:13:16 +08:00
Ain Izazi 330cbadeff changes funct kakitangan di khazanahcontr 2025-02-03 12:13:16 +08:00
Ain Izazi fcc61171c5 add changes di tukarcawanganupdate 2025-02-03 12:13:16 +08:00
Ain Izazi 31aaca59a9 add record password 2025-02-03 12:13:16 +08:00
BTMS2 ae417aa90d feat Log Masuk & Keluar Sistem 2025-02-03 12:13:16 +08:00
Hafifie PKB 60aac19737 fix nobaucer handle if null 2025-02-03 12:13:16 +08:00
Hafifie PKB 7927e102df added rekod tunai in aliran tunai 2025-02-03 12:13:16 +08:00
hafifierahman 887922b7da remove + 2025-02-03 12:13:16 +08:00
hafifierahman 5606c892e3 added tempblock and * for khazanah 2025-02-03 12:13:16 +08:00
hafifierahman ef9882c9c4 added block specific cawangan transaction 2025-02-03 12:13:15 +08:00
Hafifie PKB a709104090 fix bakipembiayaan + keuntungan (based on shahmi operasi) 2025-02-03 12:12:21 +08:00
Hafifie PKB d20cfa1214 fix resit PS(based on shahmin operasi) 2025-02-03 12:12:21 +08:00
Hafifie PKB 1983de4e3b added tambahpinjam 2025-02-03 12:12:21 +08:00
Hafifie PKB c77e619be5 fix bug fix 2025-02-03 12:12:20 +08:00
Hafifie PKB c388782650 added wakil in tambah pinjaman 2025-02-03 12:11:32 +08:00
Hafifie PKB d671b634ea added parameter to call in api for tebus pinjaman and auto tawarruq 2025-02-03 12:11:32 +08:00
hafifierahman 36cfb10315 added tambah pinjaman 2025-02-03 12:11:10 +08:00
hafifierahman 4e67e10d0d commit error swal fire 2025-02-03 12:10:48 +08:00
Hafifie PKB 3d1b4c7643 test AT transaction 2025-02-03 12:10:47 +08:00
hafifierahman e9f8c7ac30 added function operasi can edit perubatan asal 2025-02-03 12:10:31 +08:00
hafifierahman 5a8bc6dfed finished notification 2025-02-03 12:10:31 +08:00
Hafifie PKB 4dc4a53cdb add function in perubatan.js 2025-02-03 12:10:31 +08:00
hafifierahman e31411ae71 add scaffold for perubatan 2025-02-03 12:10:30 +08:00
Hafifie PKB 365b614020 fix perubatan 2025-02-03 12:10:30 +08:00
Hafifie PKB 9128bdbc85 added panjar 2025-02-03 12:10:30 +08:00
hafifierahman 85510305e3 addded notification 2025-02-03 12:10:30 +08:00
hafifierahman b2dfd421a7 first commit for kaunter in fixing cash deposit 2025-02-03 12:10:30 +08:00
nurafrinaalimi16 fc15e555ec imbang duga koperasi 2025-02-02 16:36:31 +08:00
nurafrinaalimi16 9031e8d7d8 imbang duga koperasi 2025-02-02 16:35:17 +08:00
nurafrinaalimi16 1ba4a1fe19 add parameter kadar rebate on index blade 2025-02-02 16:34:15 +08:00
nurafrinaalimi16 a2350d36f3 Merge branch 'production' of https://bitbucket.org/arrahn-pkb/kaunter into annur-rebate 2024-12-03 12:50:30 +08:00
dev_kopkb 9307ea5e1d add kadar rebet annur at gadai page 2024-11-19 11:38:02 +08:00
9 changed files with 470 additions and 228 deletions
@@ -201,6 +201,8 @@ class GadaianController extends Controller
'onepercent' => $onepercent, 'onepercent' => $onepercent,
'margin_semasa' => $margin_pinjaman, 'margin_semasa' => $margin_pinjaman,
'nokp' => $request->nokp, 'nokp' => $request->nokp,
'kadar_rebate' => $request->kadar_rebate,
'rebate' => $request->rebate
])->json(); ])->json();
@@ -2459,6 +2459,7 @@ class KhazanahController extends Controller
$penghutangkaki = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/PenghutangKakitangan/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json(); $penghutangkaki = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/PenghutangKakitangan/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
$untungrugi = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/UntungRugiCalculation/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json(); $untungrugi = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/UntungRugiCalculation/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
$bayaranpendahuluan = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/BayaranPendahuluan/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json(); $bayaranpendahuluan = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/BayaranPendahuluan/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
$rebetpromo = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/RebetPromoCalculation/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
//Tanggungan Semasa //Tanggungan Semasa
$panjar = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/CalculationPanjar/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json(); $panjar = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/CalculationPanjar/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
@@ -2469,6 +2470,8 @@ class KhazanahController extends Controller
$cajperkhidmatan = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/cajperkhidmatanterkumpul/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json(); $cajperkhidmatan = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/cajperkhidmatanterkumpul/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
$hapuskira = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/CalculationHapusKira/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json(); $hapuskira = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/CalculationHapusKira/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
$xtra = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/Xtra/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json(); $xtra = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/Xtra/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
$rebetpromo = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/RebetPromoCalculation/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
$pelarasanrebate = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/api/PelarasanRebate/' . $auth_user['cawangan'],['tarikh' => $tarikh_imbangan2])->json();
//TunaiDitangan Sementara Upah //TunaiDitangan Sementara Upah
@@ -2520,6 +2523,8 @@ class KhazanahController extends Controller
if($imbangduga['pindahkekpkb'] > 0) array_push($hartasemasa,['glcode' => '1000/090','descpt' => 'Pindah Ke KPKB(IP)', 'amaun' => $imbangduga['pindahkekpkb']]); if($imbangduga['pindahkekpkb'] > 0) array_push($hartasemasa,['glcode' => '1000/090','descpt' => 'Pindah Ke KPKB(IP)', 'amaun' => $imbangduga['pindahkekpkb']]);
if($peruntukanhapuskira > 0) array_push($hartasemasa,['glcode' => '1000/015','descpt' => 'Peruntukan Hapus Kira', 'amaun' => $peruntukanhapuskira]); if($peruntukanhapuskira > 0) array_push($hartasemasa,['glcode' => '1000/015','descpt' => 'Peruntukan Hapus Kira', 'amaun' => $peruntukanhapuskira]);
if($belian1stop > 0) array_push($hartasemasa,['glcode' => '8000/501','descpt' => 'Belian 1 Stop', 'amaun' => $belian1stop]); if($belian1stop > 0) array_push($hartasemasa,['glcode' => '8000/501','descpt' => 'Belian 1 Stop', 'amaun' => $belian1stop]);
if($rebetpromo > 0) array_push($hartasemasa,['glcode' => '5000/242','descpt' => 'Diskaun Promosi', 'amaun' => ($rebetpromo * -1)]);
$totalhartasemasa = 0; $totalhartasemasa = 0;
foreach($hartasemasa as $index => $hs) foreach($hartasemasa as $index => $hs)
@@ -2551,6 +2556,8 @@ class KhazanahController extends Controller
if($utgterkumpulxtra > 0) array_push($tanggungansemasa,['glcode' => '7000/201','descpt' => 'Untung/Rugi Terkumpul Xtra','amaun' => $utgterkumpulxtra]); if($utgterkumpulxtra > 0) array_push($tanggungansemasa,['glcode' => '7000/201','descpt' => 'Untung/Rugi Terkumpul Xtra','amaun' => $utgterkumpulxtra]);
if($jualan1stop > 0) array_push($tanggungansemasa,['glcode' => '9000/501','descpt' => 'Jualan 1 Stop','amaun' => $jualan1stop]); if($jualan1stop > 0) array_push($tanggungansemasa,['glcode' => '9000/501','descpt' => 'Jualan 1 Stop','amaun' => $jualan1stop]);
if($hapuskira > 0) array_push($tanggungansemasa,['glcode' => '3000/011','descpt' => 'Hapus Kira','amaun' => -$hapuskira]); if($hapuskira > 0) array_push($tanggungansemasa,['glcode' => '3000/011','descpt' => 'Hapus Kira','amaun' => -$hapuskira]);
if($rebetpromo > 0) array_push($tanggungansemasa,['glcode' => '5000/242','descpt' => 'Diskaun Promosi', 'amaun' => ($rebetpromo * -1)]);
if($pelarasanrebate > 0) array_push($tanggungansemasa,['glcode' => '5000/243','descpt' => 'Pelarasan Rebate', 'amaun' => ($pelarasanrebate * -1)]);
$totaltanggungansemasa = 0; $totaltanggungansemasa = 0;
foreach($tanggungansemasa as $index => $ts) foreach($tanggungansemasa as $index => $ts)
+241 -166
View File
@@ -278,167 +278,6 @@ class PenebusanController extends Controller
$auth_user = Auth::user(); $auth_user = Auth::user();
////////////////////////
/// UPDATE TEBUS API////
///////////////////////
$updatetebus = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/updatetebus/'. $auth_user['cawangan'] .'/' . $request->norujukan,[
'nopelanggan' => $request->nopelanggan,
'jenistebus' => $request->jenistebus,
'jbg' => $request->jbg,
'kadarupah' => $request->kadarupah,
'nilai_marhun' => $request->nilai_marhun,
'pinjaman' => $request->pinjaman_lama,
'ansuran' => $request->ansuran,
'nowakil' => $request->nowakil,
'addpinjaman'=> $request->addpinjaman,
'bakipinjaman' => $request->bakipinjaman,
'bakiupah' => $request->bakiupah,
'historygadaian' => $request->historygadaian,
'marhun' => $request->marhun,
'jenisbayarantebus' => $request->jenisbayarantebus,
'jeniskeuntungan' => $request->jeniskeuntungan,
'teller' => $request->teller,
"duitpelanggan" => $request->bayaran,
"bakipelanggan" => $request->bakipelanggan,
])->json();
if($updatetebus == 'duplicate'){
return response()->json('duplicate');
}
//////////////////////
/// MAKING NEW SAG////
/////////////////////
$gadai_transaction = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/gadai/'. $auth_user['cawangan'] . '/' . $current->toDateString())->json();
if($gadai_transaction){
$new_sirig = $gadai_transaction['sirig'] + 1;
}else{
$new_sirig = 1;
}
$new_transaction = sprintf("%04d",$new_sirig);
$norujukanbaru = strtoupper($auth_user['cawangan']) . $curent_year . $curent_month . $current_day . '-' .$new_transaction;
$gadai = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/gadai/'.$auth_user['cawangan'],[
'norujukan' => $norujukanbaru,
'nopelanggan' => $request->nopelanggan,
'nokp' => $request->noic,
'sirig' => $new_sirig
]);
///////////////////////////
/// MARHUN UPDATE TABLE////
//////////////////////////
$arraymarhunbaru = [];
$marhunsediada = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/marhun/'. $request->norujukan)->json();
$marhunyangdiambil = $marhunsediada[0];
foreach($marhunyangdiambil as $index=>$marhunloop)
{
$karatbaru = str_replace('.','-',$marhunloop['karat']);
$hargabaru = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/harga_emas/'. $karatbaru)->json();
$nilaimarhun = (floatval($hargabaru['harga']) * floatval($marhunloop['berat']));
array_push($arraymarhunbaru, ["bil" => $marhunloop['bil'],"tag_permata" => $marhunloop['tag_permata'],"berat_batu_permata" => $marhunloop['berat_batu_permata'],"marhun" => $marhunloop['marhun'],"nota" => $marhunloop['nota'],"karat" => $marhunloop['karat'], "berat" => $marhunloop['berat'], "harga" => $hargabaru['harga'], "n_marhun" => $nilaimarhun]);
}
foreach($arraymarhunbaru as $array1){
$updatemarhun = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/marhun/'. $auth_user['cawangan'],[
'norujukan' => $norujukanbaru,
'marhun' => $array1['marhun'],
'nota' => $array1['nota'],
'karat' => $array1['karat'],
'berat_emas' => $array1['berat'],
'harga' => $array1['harga'],
'tag_permata' => $array1['tag_permata'],
'berat_batu_permata' => $array1['berat_batu_permata'],
'kuantiti' => $array1['bil']
])->json();
}
//////////////////////
////Update SAG BARU///
/////////////////////
$total_nilai_marhun = $request->nilai_marhun;
$margin_pinjaman = $request->pinjaman / $total_nilai_marhun;
$kadarupah = $request->kadarkeuntungan * 100;
$onepercent = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/onepercent',[
'pembiayaan' => $request->pinjaman,
'nilaimarhun' => $total_nilai_marhun,
'kadarujrah' => $request->kadarkeuntungan,
'margin' => ($margin_pinjaman*100),
'kodcaw' => Auth::user()->cawangan
])->json();
$keuntungan_sebln = $onepercent['keuntungan'];
$keuntungan_sebln = str_replace(',','',$keuntungan_sebln);
$keuntungan6bulan = $keuntungan_sebln * 6;
$keuntungan12bulan = $keuntungan_sebln * 12;
$hargajualan = $request->pinjaman + $keuntungan12bulan;
$gadai = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/gadai/norujukan/'. $auth_user['cawangan'] .'/' . $norujukanbaru,[
'kodcaw' => $auth_user['cawangan'],
'nilaimarhun' => round($total_nilai_marhun, 2),
'berat' => round($request->total_berat, 2),
'pinjaman' => round($request->pinjaman, 2),
'kadarupah' => round($kadarupah, 2),
'marhun' => $request->marhun,
'percentpinj' => $margin_pinjaman,
'teller'=> $auth_user['name'],
'upah6' => $keuntungan6bulan,
'upah12' => $keuntungan12bulan,
'hargajualan' => $hargajualan,
'kuantiti_marhun' => $request->kuantiti_marhun
])->json();
$komuditi = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/komuditi/transaksi',[
'unit_komuditi' => round($request->pinjaman, 2),
'norujukan' => $norujukanbaru,
'kodcaw' => $auth_user['cawangan'],
'teller' => $auth_user['name']
]);
////////////////////////////
////Update History Gadaian///
////////////////////////////
$updatehistorygadaian = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/gadai/updatehistory/'. $auth_user['cawangan'] .'/' . $norujukanbaru,[
'historygadaian' => $request->norujukan,
'jenistebus' => $request->jenistebus,
])->json();
event(new TebusNotify('lulus',Auth::user()->cawangan));
event(new GadaiNotify('lulus',Auth::user()->cawangan));
$this->AliranTunaiController->alirantunaiTebus($request);
}
public function tambahpinjaman_latest(Request $request)
{
$api_url = config('api.url');
$current = Carbon::now();
$current = new Carbon();
$curent_year = substr($current->year,2,2);
$curent_month = sprintf("%02d", $current->month);
$current_day = sprintf("%02d", $current->day);
$auth_user = Auth::user();
//////////////////////// ////////////////////////
/// UPDATE TEBUS API//// /// UPDATE TEBUS API////
/////////////////////// ///////////////////////
@@ -509,16 +348,252 @@ class PenebusanController extends Controller
'totalbayaran' => $request->totalbayaran, 'totalbayaran' => $request->totalbayaran,
"duitpelanggan" => $request->bayaran, "duitpelanggan" => $request->bayaran,
"bakipelanggan" => $request->bakipelanggan, "bakipelanggan" => $request->bakipelanggan,
"noic" => $request->noic,
"jenisAT" => $request->jenisAT,
])->json(); ])->json();
if($updatetebus['result'] == 'success'){
if($updatetebus == 'duplicate'){
return response()->json('duplicate');
}
//////////////////////
/// MAKING NEW SAG////
/////////////////////
$gadai_transaction = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/gadai/'. $auth_user['cawangan'] . '/' . $current->toDateString())->json();
if($gadai_transaction){
$new_sirig = $gadai_transaction['sirig'] + 1;
}else{
$new_sirig = 1;
}
$new_transaction = sprintf("%04d",$new_sirig);
$norujukanbaru = strtoupper($auth_user['cawangan']) . $curent_year . $curent_month . $current_day . '-' .$new_transaction;
$gadai = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/gadai/'.$auth_user['cawangan'],[
'norujukan' => $norujukanbaru,
'nopelanggan' => $request->nopelanggan,
'nokp' => $request->noic,
'sirig' => $new_sirig
]);
///////////////////////////
/// MARHUN UPDATE TABLE////
//////////////////////////
$arraymarhunbaru = [];
$marhunsediada = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/marhun/'. $request->norujukan)->json();
$marhunyangdiambil = $marhunsediada[0];
foreach($marhunyangdiambil as $index=>$marhunloop)
{
$karatbaru = str_replace('.','-',$marhunloop['karat']);
$hargabaru = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/harga_emas/'. $karatbaru)->json();
$harga = ($request->jenisAT == 'hargalama') ? $marhunloop['harga'] : $hargabaru['harga'];
$nilaimarhun = (floatval($harga) * floatval($marhunloop['berat']));
array_push($arraymarhunbaru, ["bil" => $marhunloop['bil'],"tag_permata" => $marhunloop['tag_permata'],"berat_batu_permata" => $marhunloop['berat_batu_permata'],"marhun" => $marhunloop['marhun'],"nota" => $marhunloop['nota'],"karat" => $marhunloop['karat'], "berat" => $marhunloop['berat'], "harga" => $harga, "n_marhun" => $nilaimarhun]);
}
foreach($arraymarhunbaru as $array1){
$updatemarhun = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/marhun/'. $auth_user['cawangan'],[
'norujukan' => $norujukanbaru,
'marhun' => $array1['marhun'],
'nota' => $array1['nota'],
'karat' => $array1['karat'],
'berat_emas' => $array1['berat'],
'harga' => $array1['harga'],
'nilai_marhun' => $array1['n_marhun'],
'tag_permata' => $array1['tag_permata'],
'berat_batu_permata' => $array1['berat_batu_permata'],
'jenisAT' => $request->jenisAT,
'kuantiti' => $array1['bil']
])->json();
}
//////////////////////
////Update SAG BARU///
/////////////////////
$total_nilai_marhun = $request->total_nilai_marhun;
$margin_pinjaman = ($request->pinjaman / $total_nilai_marhun);
$onepercent = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/onepercent',[
'pembiayaan' => $request->pinjaman,
'nilaimarhun' => $total_nilai_marhun,
'kadarujrah' => $request->kadarkeuntungan,
'margin' => ($margin_pinjaman*100),
'kodcaw' => Auth::user()->cawangan
])->json();
$keuntungan_sebln = $onepercent['keuntungan'];
$keuntungan_sebln = str_replace(',','',$keuntungan_sebln);
$kadarupah = $request->kadarkeuntungan * 100;
$keuntungan6bulan = $keuntungan_sebln * 6;
$keuntungan12bulan = $keuntungan_sebln * 12;
$hargajualan = $request->pinjaman + $keuntungan12bulan;
$gadai = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/gadai/norujukan/'. $auth_user['cawangan'] .'/' . $norujukanbaru,[
'kodcaw' => $auth_user['cawangan'],
'nilaimarhun' => round($total_nilai_marhun, 2),
'berat' => round($request->total_berat, 2),
'pinjaman' => round($request->pinjaman, 2),
'kadarupah' => round($kadarupah, 2),
'marhun' => $request->marhun_detail,
'percentpinj' => $margin_pinjaman,
'teller'=> $auth_user['name'],
'upah6' => $keuntungan6bulan,
'upah12' => $keuntungan12bulan,
'hargajualan' => $hargajualan,
'kuantiti_marhun' => $request->kuantiti_marhun,
]);
$komuditi = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/komuditi/transaksi',[
'unit_komuditi' => round($request->pinjaman, 2),
'norujukan' => $norujukanbaru,
'kodcaw' => $auth_user['cawangan'],
'teller' => $auth_user['name']
]);
////////////////////////////
////Update History Gadaian///
////////////////////////////
$updatehistorygadaian = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/gadai/updatehistory/'. $auth_user['cawangan'] .'/' . $norujukanbaru,[
'historygadaian' => $request->norujukan,
'jenistebus' => $request->jenistebus,
])->json();
if($updatetebus == 'duplicate'){
return response()->json('duplicate');
}
//////////////////////
/// MAKING NEW SAG////
/////////////////////
$gadai_transaction = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/gadai/'. $auth_user['cawangan'] . '/' . $current->toDateString())->json();
if($gadai_transaction){
$new_sirig = $gadai_transaction['sirig'] + 1;
}else{
$new_sirig = 1;
}
$new_transaction = sprintf("%04d",$new_sirig);
$norujukanbaru = strtoupper($auth_user['cawangan']) . $curent_year . $curent_month . $current_day . '-' .$new_transaction;
$gadai = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/gadai/'.$auth_user['cawangan'],[
'norujukan' => $norujukanbaru,
'nopelanggan' => $request->nopelanggan,
'nokp' => $request->noic,
'sirig' => $new_sirig
]);
///////////////////////////
/// MARHUN UPDATE TABLE////
//////////////////////////
$arraymarhunbaru = [];
$marhunsediada = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/marhun/'. $request->norujukan)->json();
$marhunyangdiambil = $marhunsediada[0];
foreach($marhunyangdiambil as $index=>$marhunloop)
{
$karatbaru = str_replace('.','-',$marhunloop['karat']);
$hargabaru = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/harga_emas/'. $karatbaru)->json();
$harga = ($request->jenisAT == 'hargalama') ? $marhunloop['harga'] : $hargabaru['harga'];
$nilaimarhun = (floatval($harga) * floatval($marhunloop['berat']));
array_push($arraymarhunbaru, ["bil" => $marhunloop['bil'],"tag_permata" => $marhunloop['tag_permata'],"berat_batu_permata" => $marhunloop['berat_batu_permata'],"marhun" => $marhunloop['marhun'],"nota" => $marhunloop['nota'],"karat" => $marhunloop['karat'], "berat" => $marhunloop['berat'], "harga" => $harga, "n_marhun" => $nilaimarhun]);
}
foreach($arraymarhunbaru as $array1){
$updatemarhun = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/marhun/'. $auth_user['cawangan'],[
'norujukan' => $norujukanbaru,
'marhun' => $array1['marhun'],
'nota' => $array1['nota'],
'karat' => $array1['karat'],
'berat_emas' => $array1['berat'],
'harga' => $array1['harga'],
'nilai_marhun' => $array1['n_marhun'],
'tag_permata' => $array1['tag_permata'],
'berat_batu_permata' => $array1['berat_batu_permata'],
'jenisAT' => $request->jenisAT,
'kuantiti' => $array1['bil']
])->json();
}
//////////////////////
////Update SAG BARU///
/////////////////////
$total_nilai_marhun = $request->total_nilai_marhun;
$margin_pinjaman = ($request->pinjaman / $total_nilai_marhun);
$onepercent = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/api/onepercent',[
'pembiayaan' => $request->pinjaman,
'nilaimarhun' => $total_nilai_marhun,
'kadarujrah' => $request->kadarkeuntungan,
'margin' => ($margin_pinjaman*100),
'kodcaw' => Auth::user()->cawangan
])->json();
$keuntungan_sebln = $onepercent['keuntungan'];
$keuntungan_sebln = str_replace(',','',$keuntungan_sebln);
$kadarupah = $request->kadarkeuntungan * 100;
$keuntungan6bulan = $keuntungan_sebln * 6;
$keuntungan12bulan = $keuntungan_sebln * 12;
$hargajualan = $request->pinjaman + $keuntungan12bulan;
$gadai = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/gadai/norujukan/'. $auth_user['cawangan'] .'/' . $norujukanbaru,[
'kodcaw' => $auth_user['cawangan'],
'nilaimarhun' => round($total_nilai_marhun, 2),
'berat' => round($request->total_berat, 2),
'pinjaman' => round($request->pinjaman, 2),
'kadarupah' => round($kadarupah, 2),
'marhun' => $request->marhun_detail,
'percentpinj' => $margin_pinjaman,
'teller'=> $auth_user['name'],
'upah6' => $keuntungan6bulan,
'upah12' => $keuntungan12bulan,
'hargajualan' => $hargajualan,
'kuantiti_marhun' => $request->kuantiti_marhun,
]);
$komuditi = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/komuditi/transaksi',[
'unit_komuditi' => round($request->pinjaman, 2),
'norujukan' => $norujukanbaru,
'kodcaw' => $auth_user['cawangan'],
'teller' => $auth_user['name']
]);
////////////////////////////
////Update History Gadaian///
////////////////////////////
$updatehistorygadaian = Http::withOptions(['verify' => config('app.api_verify')])->put(config('api.url').'/api/gadai/updatehistory/'. $auth_user['cawangan'] .'/' . $norujukanbaru,[
'historygadaian' => $request->norujukan,
'jenistebus' => $request->jenistebus,
])->json();
$alirantunai = new AliranTunaiController(); $alirantunai = new AliranTunaiController();
event(new TebusNotify('lulus',Auth::user()->cawangan)); event(new TebusNotify('lulus',Auth::user()->cawangan));
event(new GadaiNotify('lulus',Auth::user()->cawangan)); event(new GadaiNotify('lulus',Auth::user()->cawangan));
$alirantunai->alirantunaiTebusAutoTawarruq($request); $alirantunai->alirantunaiTebusAutoTawarruq($request);
}
return response()->json($updatetebus['result'],200); return response()->json($updatemarhun,200);
} }
public function tebusseparuh(Request $request) public function tebusseparuh(Request $request)
@@ -181,6 +181,17 @@
</div> </div>
</diV> </diV>
</div> </div>
<div class="col-4">
<div class="form-group row">
<div class="col-md-6">
Kadar Rebet
</div>
<div class="col-md-6">
<input type="text" class="form-control" readonly name="rebate" id="rebate">
<input type="text" class="form-control" readonly name="kadar_rebate" id="kadar_rebate">
</div>
</div>
</div>
<div class="col-12"> <div class="col-12">
<input type="text" name="norujukan_gadai" id="norujukan_gadai" value="{{ $norujukan }}" hidden> <input type="text" name="norujukan_gadai" id="norujukan_gadai" value="{{ $norujukan }}" hidden>
<input type="text" name="marhun_detail" id="marhun_detail" value="" hidden> <input type="text" name="marhun_detail" id="marhun_detail" value="" hidden>
@@ -663,12 +674,35 @@
var keuntungan_sebulan = getRoundedMethod(array_keuntungan['keuntungan']); var keuntungan_sebulan = getRoundedMethod(array_keuntungan['keuntungan']);
var keuntungan_6bln = getRoundedMethod(keuntungan_sebulan * 6); var keuntungan_6bln = getRoundedMethod(keuntungan_sebulan * 6);
var ujrah = getRoundedMethod(array_keuntungan['ujrah']);
var onepercent = getRoundedMethod(array_keuntungan['onepercent']);
// **Rebate Calculation**
let rebate, kadar_rebate;
if (pinjaman < 20000) {
rebate = keuntungan_sebulan * 0.05;
kadar_rebate = 5;
} else if (pinjaman >= 20000 && pinjaman <= 50000) {
rebate = keuntungan_sebulan * 0.10;
kadar_rebate = 10;
} else if (pinjaman > 50000 && pinjaman <= 100000) {
rebate = keuntungan_sebulan * 0.15;
kadar_rebate = 15;
} else {
rebate = keuntungan_sebulan * 0.20;
kadar_rebate = 20;
}
rebate = getRoundedMethod(rebate); // ✅ Round rebate before displaying
// **Display values**
$('.span-pinjaman').text(formatter.format(percent_pinjaman.toFixed(2)) + ' %'); $('.span-pinjaman').text(formatter.format(percent_pinjaman.toFixed(2)) + ' %');
$('#keuntungan_sebulan').val(formatter.format(keuntungan_sebulan.toFixed(2))); $('#keuntungan_sebulan').val(formatter.format(keuntungan_sebulan.toFixed(2)));
$('#keuntungan_6bln').val(formatter.format(keuntungan_6bln.toFixed(2))); $('#keuntungan_6bln').val(formatter.format(keuntungan_6bln.toFixed(2)));
$('#ujrah').val(formatter.format(getRoundedMethod(array_keuntungan['ujrah']).toFixed(2))); $('#ujrah').val(formatter.format(getRoundedMethod(array_keuntungan['ujrah']).toFixed(2)));
$('#onepercent').val(formatter.format(getRoundedMethod(array_keuntungan['onepercent']).toFixed(2))); $('#onepercent').val(formatter.format(getRoundedMethod(array_keuntungan['onepercent']).toFixed(2)));
$('#rebate').val(formatter.format(rebate.toFixed(2))); // Correctly displaying rebate
$('#kadar_rebate').val(formatter.format(kadar_rebate.toFixed(2)) + ' %');
}); });
+105 -5
View File
@@ -208,6 +208,15 @@
</div> </div>
</div> </div>
{{-- <div class="form-group row">
<div class="col-4">
JUMLAH PERLU DIBAYAR SELEPAS DISKAUN (RM)
</div>
<div class="col-8">
<input type="text" id="jumlahselepasdiskaun" class="form-control" readonly/>
</div>
</div> --}}
<div> <div>
<fieldset class="scheduler-border"> <fieldset class="scheduler-border">
<div class="form-group row" id="divduitPelanggan"> <div class="form-group row" id="divduitPelanggan">
@@ -313,6 +322,16 @@
</div> </div>
</div> </div>
<div class="form-group row" id="divtelahdibayar">
<div class="col-4">
REBET DISKAUN (RM)
</div>
<div class="col-8">
<input type="text" id="jumlahDiskaun" value="{{ number_format($gadai['diskaun'],2) }}" class="form-control" readonly/>
</div>
</div>
</div> </div>
</div> </div>
<div id="jenisS" class="col-12 form-group row"> <div id="jenisS" class="col-12 form-group row">
@@ -328,6 +347,14 @@
</div> </div>
</div> </div>
<div class="form-group row">
<div class="col-4">
JUMLAH PERLU DIBAYAR SELEPAS DISKAUN (RM)
</div>
<div class="col-8">
<input type="text" id="perludibayarAkhir" class="form-control" readonly/>
</div>
</div>
<div> <div>
<fieldset class="scheduler-border"> <fieldset class="scheduler-border">
@@ -428,6 +455,15 @@
</div> </div>
</div> </div>
<div class="form-group row" id="divtelahdibayar">
<div class="col-4">
REBET DISKAUN (RM)
</div>
<div class="col-8">
<input type="text" id="jumlahDiskaun" value="{{ number_format($gadai['diskaun'],2) }}" class="form-control" readonly/>
</div>
</div>
<div id="divbakipinjaman"> <div id="divbakipinjaman">
<div class="form-group row"> <div class="form-group row">
<div class="col-4"> <div class="col-4">
@@ -563,6 +599,16 @@
</div> </div>
</div> </div>
<div class="form-group row" id="divtelahdibayar">
<div class="col-4">
REBET DISKAUN (RM)
</div>
<div class="col-8">
<input type="text" id="jumlahDiskaun" value="{{ number_format($gadai['diskaun'],2) }}" class="form-control" readonly/>
</div>
</div>
</div> </div>
</div> </div>
@@ -1395,8 +1441,17 @@
dataType: 'json', dataType: 'json',
async:false, async:false,
success:function(harga_tebus){ success:function(harga_tebus){
// // Ambil nilai diskaun
// let diskaun = parseFloat($('#jumlahDiskaun').val().replace(/,/g, '')) || 0;
// // Tolak diskaun terus dari harga tebus
// let harga_tebus_akhir = parseFloat(harga_tebus) - diskaun;
// // Set balik ke input 'PERLU DIBAYAR'
$('#perludibayar').val(formatter.format(harga_tebus)); $('#perludibayar').val(formatter.format(harga_tebus));
} }
}); });
// Telah dibayar // Telah dibayar
@@ -1554,10 +1609,10 @@
function bayarkey(e){ function bayarkey(e){
$('#bakiPelanggan').val('0.00'); $('#bakiPelanggan').val('0.00');
$('#duitPelanggan').val(''); $('#duitPelanggan').val('');
if($('#sltjenistebus').find(":selected").val() == 'S'){ if($('#sltjenistebus').find(":selected").val() == 'S'){
let byr = $(e).val().replace(/[^0-9.-]+/g,""); let byr = $(e).val().replace(/[^0-9.-]+/g,"");
let total = 0; let total = 0;
let pdbyr = 0; let pdbyr = 0;
@@ -1615,8 +1670,15 @@
$('#bakipinjaman').val(total.toFixed(2)); $('#bakipinjaman').val(total.toFixed(2));
$('#basic-separuh').text(Number(totalcalculate.toFixed(2))); $('#basic-separuh').text(Number(totalcalculate.toFixed(2)));
} }
} }
function kiraPerluDibayarSelepasDiskaun() {
var perluDibayar = parseFloat(document.getElementById("perludibayar").value.replace(/,/g, '')) || 0;
var diskaun = parseFloat(document.getElementById("jumlahDiskaun").value.replace(/,/g, '')) || 0;
var akhir = perluDibayar - diskaun;
document.getElementById("perludibayarAkhir").value = akhir.toFixed(2);
}
function bayartawarruq(e){ function bayartawarruq(e){
var keuntungan = parseFloat($('#jumlahupah').val().replace(/[^0-9.-]+/g,"")); var keuntungan = parseFloat($('#jumlahupah').val().replace(/[^0-9.-]+/g,""));
var bayaran = parseFloat(e.value); var bayaran = parseFloat(e.value);
@@ -1835,6 +1897,25 @@
jeniskeuntungan = "asal"; jeniskeuntungan = "asal";
} }
//kira rebet diskaun
// let diskaun
// if (pinjaman < 20000) {
// diskaun = jumupah * 0.05;
// } else if (pinjaman >= 20000 && pinjaman <= 50000) {
// diskaun = jumupah * 0.10;
// } else if (pinjaman > 50000 && pinjaman <= 100000) {
// diskaun = jumupah * 0.15;
// } else {
// diskaun = jumupah * 0.20;
// }
//$('#jumdiskaun').val(formatter.format(diskaun.toFixed(2)));
var nopelanggan = "{{ $gadai['nopelanggan'] }}"; var nopelanggan = "{{ $gadai['nopelanggan'] }}";
var jenistebus = $('#sltjenistebus').find(":selected").val(); var jenistebus = $('#sltjenistebus').find(":selected").val();
var jbg = "{{ $gadai['tempoh'] }}"; var jbg = "{{ $gadai['tempoh'] }}";
@@ -1850,6 +1931,7 @@
var nowakil = nw; var nowakil = nw;
var duitpelanggan = $('#duitPelanggan').val().replace(/[^0-9.-]+/g,""); var duitpelanggan = $('#duitPelanggan').val().replace(/[^0-9.-]+/g,"");
var bakipelanggan = $('#bakiPelanggan').val().replace(/[^0-9.-]+/g,""); var bakipelanggan = $('#bakiPelanggan').val().replace(/[^0-9.-]+/g,"");
//var diskaun = $('#diskaun').val().replace(/[^0-9.-]+/g,"");
if(Number(duitpelanggan) < Number(bakipinjaman)){ if(Number(duitpelanggan) < Number(bakipinjaman)){
@@ -1878,6 +1960,7 @@
"addpinjaman" : addpinjaman, "addpinjaman" : addpinjaman,
"bakipinjaman" : bakipinjaman, "bakipinjaman" : bakipinjaman,
"bakiupah" : bakiupah, "bakiupah" : bakiupah,
//"diskaun": diskaun,
"historygadaian" : historygadaian, "historygadaian" : historygadaian,
"marhun" : marhun, "marhun" : marhun,
"nowakil" : nowakil, "nowakil" : nowakil,
@@ -1979,10 +2062,27 @@
let hadbayaransuran = (parseFloat("{{ $gadai['nilaimarhun']}}") * 0.1); let hadbayaransuran = (parseFloat("{{ $gadai['nilaimarhun']}}") * 0.1);
//kira rebet diskaun
// let diskaun
// if (pinjaman < 20000) {
// diskaun = jumupah * 0.05;
// } else if (pinjaman >= 20000 && pinjaman <= 50000) {
// diskaun = jumupah * 0.10;
// } else if (pinjaman > 50000 && pinjaman <= 100000) {
// diskaun = jumupah * 0.15;
// } else {
// diskaun = jumupah * 0.20;
// }
var bayar = Number(parseFloat($('#bayaran').val().replace(/[^0-9.-]+/g,"")).toFixed(2)); var bayar = Number(parseFloat($('#bayaran').val().replace(/[^0-9.-]+/g,"")).toFixed(2));
var bakipinjam = parseFloat("{{ $gadai['bakipjm'] }}") - hadbayaransuran + jumupah; var bakipinjam = parseFloat("{{ $gadai['bakipjm'] }}") - hadbayaransuran + jumupah;
var duitpelanggan = parseFloat($('#duitPelanggan').val().replace(/[^0-9.-]+/g,"")); var duitpelanggan = parseFloat($('#duitPelanggan').val().replace(/[^0-9.-]+/g,""));
var bakipelanggan = parseFloat($('#bakiPelanggan').val().replace(/[^0-9.-]+/g,"")); var bakipelanggan = parseFloat($('#bakiPelanggan').val().replace(/[^0-9.-]+/g,""));
//var diskaun = parseFloat($('#diskaun').val().replace(/[^0-9.-]+/g,""));
if(isNaN(duitpelanggan)) duitpelanggan = 0; if(isNaN(duitpelanggan)) duitpelanggan = 0;
@@ -230,6 +230,7 @@
<th>Lain-Lain Caj (RM)</th> <th>Lain-Lain Caj (RM)</th>
<th>Keuntungan 1% (RM)</th> <th>Keuntungan 1% (RM)</th>
<th>Keuntungan</th> <th>Keuntungan</th>
<th>Diskaun Rebet</th>
<th>Peratus (%)</th> <th>Peratus (%)</th>
</tr> </tr>
@php @php
@@ -301,6 +302,7 @@
<td>{{ number_format($item['ujrah']*12,2) }}</td> <td>{{ number_format($item['ujrah']*12,2) }}</td>
<td>{{ number_format($item['onepercent']*12,2) }}</td> <td>{{ number_format($item['onepercent']*12,2) }}</td>
<td>{{ number_format($item['upah12'],2) }}</td> <td>{{ number_format($item['upah12'],2) }}</td>
<td>{{ number_format($item['diskaun'],2) }}</td>
<td>{{ $item['percentpinj'] }}</td> <td>{{ $item['percentpinj'] }}</td>
</tr> </tr>
@php $counter++; @endphp @php $counter++; @endphp
@@ -241,6 +241,7 @@
<th>B.Pembiayaan(RM)</th> <th>B.Pembiayaan(RM)</th>
<th>Lain-Lain Caj (RM)</th> <th>Lain-Lain Caj (RM)</th>
<th>Untung 1% (RM)</th> <th>Untung 1% (RM)</th>
<th>Diskaun Rebet (RM)</th>
<th>Pendapatan(RM)</th> <th>Pendapatan(RM)</th>
<th>Bayaran(RM)</th> <th>Bayaran(RM)</th>
<th>Jumlah(RM)</th> <th>Jumlah(RM)</th>
@@ -254,6 +255,7 @@
$totalupah = 0; $totalupah = 0;
$totalujrah = 0; $totalujrah = 0;
$totalonepercent = 0; $totalonepercent = 0;
$totaldiskaunrebate = 0;
@endphp @endphp
@foreach ($tebus as $index => $item) @foreach ($tebus as $index => $item)
@@ -266,6 +268,7 @@
$totalnm += $item['nilaimarhun']; $totalnm += $item['nilaimarhun'];
$totalujrah += $item['ujrah']; $totalujrah += $item['ujrah'];
$totalonepercent += $item['onepercent']; $totalonepercent += $item['onepercent'];
$totaldiskaunrebate += $item['diskaun_rebate'];
@endphp @endphp
@@ -282,6 +285,7 @@
$totalbayaranteller = 0; $totalbayaranteller = 0;
$totalujrahteller = 0; $totalujrahteller = 0;
$totalonepercentteller = 0; $totalonepercentteller = 0;
$totaldiskaunrebateteller = 0;
@endphp @endphp
@endif @endif
@else @else
@@ -297,6 +301,7 @@
$totaljumlahteller = 0; $totaljumlahteller = 0;
$totalujrahteller = 0; $totalujrahteller = 0;
$totalonepercentteller = 0; $totalonepercentteller = 0;
$totaldiskaunrebateteller = 0;
@endphp @endphp
@endif @endif
@@ -337,6 +342,7 @@
<td>{{ number_format($item['ujrah'], 2) }}</td> <td>{{ number_format($item['ujrah'], 2) }}</td>
<td>{{ number_format($item['onepercent'], 2) }}</td> <td>{{ number_format($item['onepercent'], 2) }}</td>
{{-- <td>{{ number_format($item['bakiupah'], 2) }}</td> --}} {{-- <td>{{ number_format($item['bakiupah'], 2) }}</td> --}}
<td>{{ number_format($item['diskaun_rebate'], 2) }}</td>
<td> <td>
@php @php
if ($item['tagbaru']) { if ($item['tagbaru']) {
@@ -371,6 +377,7 @@
$totalbayaranteller += $item['bakipjm']; // $totalbayaranteller += $item['bakipjm']; //
$totalujrahteller += $item['ujrah']; $totalujrahteller += $item['ujrah'];
$totalonepercentteller += $item['onepercent']; $totalonepercentteller += $item['onepercent'];
$totaldiskaunrebateteller += $item['diskaun_rebate'];
@endphp @endphp
@php @php
@@ -388,6 +395,7 @@
<td><b>{{ number_format($totalpinjamanteller, 2) }} </b></td> <td><b>{{ number_format($totalpinjamanteller, 2) }} </b></td>
<td><b>{{ number_format($totalujrahteller, 2) }} </b></td> <td><b>{{ number_format($totalujrahteller, 2) }} </b></td>
<td><b>{{ number_format($totalonepercentteller, 2) }} </b></td> <td><b>{{ number_format($totalonepercentteller, 2) }} </b></td>
<td><b>{{ number_format($totaldiskaunrebateteller, 2) }} </b></td>
<td><b>{{ number_format($totalupahteller, 2) }} </b></td> <td><b>{{ number_format($totalupahteller, 2) }} </b></td>
<td><b>{{ number_format($totalbayaranteller, 2) }} </b></td> <td><b>{{ number_format($totalbayaranteller, 2) }} </b></td>
<td><b>{{ number_format($totaljumlahteller, 2) }} </b></td> <td><b>{{ number_format($totaljumlahteller, 2) }} </b></td>
@@ -402,6 +410,7 @@
$totaljumlahteller = 0; $totaljumlahteller = 0;
$totalujrahteller = 0; $totalujrahteller = 0;
$totalonepercentteller = 0; $totalonepercentteller = 0;
$totaldiskaunrebateteller = 0;
@endphp @endphp
@endif @endif
@else @else
@@ -412,6 +421,7 @@
<td><b>{{ number_format($totalpinjamanteller, 2) }} </b></td> <td><b>{{ number_format($totalpinjamanteller, 2) }} </b></td>
<td><b>{{ number_format($totalujrahteller, 2) }} </b></td> <td><b>{{ number_format($totalujrahteller, 2) }} </b></td>
<td><b>{{ number_format($totalonepercentteller, 2) }} </b></td> <td><b>{{ number_format($totalonepercentteller, 2) }} </b></td>
<td><b>{{ number_format($totaldiskaunrebateteller, 2) }} </b></td>
<td><b>{{ number_format($totalupahteller, 2) }} </b></td> <td><b>{{ number_format($totalupahteller, 2) }} </b></td>
<td><b>{{ number_format($totalbayaranteller, 2) }} </b></td> <td><b>{{ number_format($totalbayaranteller, 2) }} </b></td>
<td><b>{{ number_format($totaljumlahteller, 2) }} </b></td> <td><b>{{ number_format($totaljumlahteller, 2) }} </b></td>
@@ -646,12 +646,18 @@
<td style="width:10px">: RM <td style="width:10px">: RM
{{ number_format($totalrebate['ujrah'], 2) }} </td> {{ number_format($totalrebate['ujrah'], 2) }} </td>
</tr> </tr>
<tr> <tr>
<td style="width:10px">Jumlah Keuntungan + Lain-Lain Caj</td> <td style="width:10px">Jumlah Keuntungan + Lain-Lain Caj</td>
<td style="width:10px">: <strong>RM <td style="width:10px">: <strong>RM
{{ number_format($penebusan['onepercent'] + $penebusan['ujrah'], 2) }}</strong> {{ number_format($penebusan['onepercent'] + $penebusan['ujrah'], 2) }}</strong>
</td> </td>
</tr> </tr>
<tr>
<td style="width:10px">(-) Diskaun Promosi</td>
<td style="width:10px">: RM
{{ number_format($gadai['diskaun'], 2) }} </td>
</tr>
<tr> <tr>
<td></td> <td></td>
</tr> </tr>
@@ -879,12 +885,18 @@
<td style="width:10px">: RM <td style="width:10px">: RM
{{ number_format($totalrebate['ujrah'], 2) }} </td> {{ number_format($totalrebate['ujrah'], 2) }} </td>
</tr> </tr>
<tr> <tr>
<td style="width:10px">Jumlah Keuntungan + Lain-Lain Caj</td> <td style="width:10px">Jumlah Keuntungan + Lain-Lain Caj</td>
<td style="width:10px">: <strong>RM <td style="width:10px">: <strong>RM
{{ number_format($penebusan['onepercent'] + $penebusan['ujrah'], 2) }}</strong> {{ number_format($penebusan['onepercent'] + $penebusan['ujrah'], 2) }}</strong>
</td> </td>
</tr> </tr>
<tr>
<td style="width:10px">(-) Diskaun Promosi</td>
<td style="width:10px">: RM
{{ number_format($gadai['diskaun'], 2) }} </td>
</tr>
<tr> <tr>
<td></td> <td></td>
</tr> </tr>
+3 -3
View File
@@ -1145,7 +1145,7 @@
</tr> </tr>
<tr> <tr>
<td colspan="1"></td> <td colspan="1"></td>
<td colspan="1">v.</td> <td colspan="1">u.</td>
<td colspan="2">Jika berlaku kehilangan SAG ini, KoPKB hanya boleh mengeluarkan <td colspan="2">Jika berlaku kehilangan SAG ini, KoPKB hanya boleh mengeluarkan
salinan salinan
yang disahkan, yang disahkan,
@@ -1156,7 +1156,7 @@
</tr> </tr>
<tr> <tr>
<td colspan="1"></td> <td colspan="1"></td>
<td colspan="1">w.</td> <td colspan="1">v.</td>
<td colspan="2">SAG ini sah diperlakukan sepanjang tempoh matang (daripada tarikh <td colspan="2">SAG ini sah diperlakukan sepanjang tempoh matang (daripada tarikh
pembiayaan pembiayaan
sehingga tempoh matang) atau sehingga tempoh lanjutan (sekiranya layak) dan; sehingga tempoh matang) atau sehingga tempoh lanjutan (sekiranya layak) dan;
@@ -1164,7 +1164,7 @@
</tr> </tr>
<tr> <tr>
<td colspan="1"></td> <td colspan="1"></td>
<td colspan="1">x.</td> <td colspan="1">w.</td>
<td colspan="2">KoPKB berhak mengubah, mengubahsuai, menambah atau mengeluarkan <td colspan="2">KoPKB berhak mengubah, mengubahsuai, menambah atau mengeluarkan
terma terma
dan syarat ini atau dan syarat ini atau