added config for redeemoptions and changes from 'tebus separuh to tebus sebahagian'
This commit is contained in:
@@ -0,0 +1,7 @@
|
|||||||
|
<?php
|
||||||
|
return [
|
||||||
|
'enable_tambahpinjam' => env('ENABLE_TAMBAHPINJAM',1),
|
||||||
|
'enable_separuh' => env('ENABLE_SEPARUH',1),
|
||||||
|
'enable_pembiayaansemula' => env('ENABLE_AUTOTAWARRUQ',1)
|
||||||
|
];
|
||||||
|
?>
|
||||||
@@ -3384,7 +3384,7 @@
|
|||||||
urlroute = urlroute.replace(':id', norujukan);
|
urlroute = urlroute.replace(':id', norujukan);
|
||||||
Swal.fire(
|
Swal.fire(
|
||||||
'Berjaya!',
|
'Berjaya!',
|
||||||
'Tebus Separuh Berjaya',
|
'Tebus Sebahagian Berjaya',
|
||||||
'success'
|
'success'
|
||||||
) .then(function() {
|
) .then(function() {
|
||||||
window.open(urlroute, '_blank');
|
window.open(urlroute, '_blank');
|
||||||
|
|||||||
@@ -246,7 +246,7 @@
|
|||||||
<button class="btn btn-primary" onclick="ubahfunc(this)" id="button-edit-gadaian">Ubah</button>
|
<button class="btn btn-primary" onclick="ubahfunc(this)" id="button-edit-gadaian">Ubah</button>
|
||||||
<button class="btn btn-primary" onclick="hapusfunc()">Hapus</button>
|
<button class="btn btn-primary" onclick="hapusfunc()">Hapus</button>
|
||||||
<button class="btn btn-primary" onclick="histfunc()">Rekod Gadaian</button>
|
<button class="btn btn-primary" onclick="histfunc()">Rekod Gadaian</button>
|
||||||
{{-- <button class="btn btn-primary" onclick="removeansuran(this)" id="button-remove-ansuran">Hapus Ansuran</button> --}}
|
<button class="btn btn-primary" onclick="removeansuran(this)" id="button-remove-ansuran">Hapus Ansuran</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -830,33 +830,33 @@
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}else if(id_type=='passport'){
|
}else if(id_type=='passport'){
|
||||||
if(nokp.length < 5){
|
// if(nokp.length < 5){
|
||||||
Swal.fire({
|
// Swal.fire({
|
||||||
icon: 'error',
|
// icon: 'error',
|
||||||
title: 'Amaran!',
|
// title: 'Amaran!',
|
||||||
text: 'Sila Periksa Passport Pelanggan'
|
// text: 'Sila Periksa Passport Pelanggan'
|
||||||
});
|
// });
|
||||||
event.preventDefault();
|
// event.preventDefault();
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
if(nokp.indexOf(' ') > 0){
|
// if(nokp.indexOf(' ') > 0){
|
||||||
Swal.fire({
|
// Swal.fire({
|
||||||
icon: 'error',
|
// icon: 'error',
|
||||||
title: 'Amaran!',
|
// title: 'Amaran!',
|
||||||
text: 'Sila Masukkan Passport Tanpa Ruang \'Kosong\' \n e.g(AP1111111)'
|
// text: 'Sila Masukkan Passport Tanpa Ruang \'Kosong\' \n e.g(AP1111111)'
|
||||||
});
|
// });
|
||||||
event.preventDefault();
|
// event.preventDefault();
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
if(regex.test(nokp) == false){
|
// if(regex.test(nokp) == false){
|
||||||
Swal.fire({
|
// Swal.fire({
|
||||||
icon: 'error',
|
// icon: 'error',
|
||||||
title: 'Amaran!',
|
// title: 'Amaran!',
|
||||||
text: 'Sila Periksa Passport Pelanggan'
|
// text: 'Sila Periksa Passport Pelanggan'
|
||||||
});
|
// });
|
||||||
event.preventDefault();
|
// event.preventDefault();
|
||||||
return false;
|
// return false;
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -2539,7 +2539,7 @@
|
|||||||
urlroute = urlroute.replace(':id', norujukan);
|
urlroute = urlroute.replace(':id', norujukan);
|
||||||
Swal.fire(
|
Swal.fire(
|
||||||
'Berjaya!',
|
'Berjaya!',
|
||||||
'Tebus Separuh Berjaya',
|
'Tebus Sebahagian Berjaya',
|
||||||
'success'
|
'success'
|
||||||
) .then(function() {
|
) .then(function() {
|
||||||
window.open(urlroute, '_blank');
|
window.open(urlroute, '_blank');
|
||||||
|
|||||||
@@ -2800,7 +2800,7 @@
|
|||||||
urlroute = urlroute.replace(':id', norujukan);
|
urlroute = urlroute.replace(':id', norujukan);
|
||||||
Swal.fire(
|
Swal.fire(
|
||||||
'Berjaya!',
|
'Berjaya!',
|
||||||
'Tebus Separuh Berjaya',
|
'Tebus Sebahagian Berjaya',
|
||||||
'success'
|
'success'
|
||||||
) .then(function() {
|
) .then(function() {
|
||||||
window.open(urlroute, '_blank');
|
window.open(urlroute, '_blank');
|
||||||
|
|||||||
@@ -3011,7 +3011,7 @@
|
|||||||
urlroute = urlroute.replace(':id', norujukan);
|
urlroute = urlroute.replace(':id', norujukan);
|
||||||
Swal.fire(
|
Swal.fire(
|
||||||
'Berjaya!',
|
'Berjaya!',
|
||||||
'Tebus Separuh Berjaya',
|
'Tebus Sebahagian Berjaya',
|
||||||
'success'
|
'success'
|
||||||
) .then(function() {
|
) .then(function() {
|
||||||
window.open(urlroute, '_blank');
|
window.open(urlroute, '_blank');
|
||||||
|
|||||||
@@ -92,10 +92,16 @@
|
|||||||
<option value="T">T = Tebus</option>
|
<option value="T">T = Tebus</option>
|
||||||
<option value="A" {{ $gadai['tempoh'] >= 12 ? 'disabled' : '' }}>A = Ansuran</option>
|
<option value="A" {{ $gadai['tempoh'] >= 12 ? 'disabled' : '' }}>A = Ansuran</option>
|
||||||
@if($gadai['tagbaru'] == 1)
|
@if($gadai['tagbaru'] == 1)
|
||||||
<option value="S">S = Sebahagian</option>
|
@if(config('redeemoption.enable_separuh') == 1)
|
||||||
<option value="P">P = Tambah Pembiayaan</option>
|
<option value="S">S = Sebahagian</option>
|
||||||
|
@endif
|
||||||
|
@if(config('redeemoption.enable_tambahpinjam') == 1)
|
||||||
|
<option value="P">P = Tambah Pembiayaan</option>
|
||||||
|
@endif
|
||||||
|
@endif
|
||||||
|
@if(config('redeemoption.enable_pembiayaansemula') == 1)
|
||||||
|
<option value="AT">PS = Pembiayaan Semula</option>
|
||||||
@endif
|
@endif
|
||||||
<option value="AT">PS = Pembiayaan Semula</option>
|
|
||||||
<option value="" disabled hidden>Pilih Jenis Tebus</option>
|
<option value="" disabled hidden>Pilih Jenis Tebus</option>
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</div>
|
||||||
@@ -1740,14 +1746,14 @@
|
|||||||
function bayaransemua()
|
function bayaransemua()
|
||||||
{
|
{
|
||||||
$("#terima_transaksi").prop('disabled', true);
|
$("#terima_transaksi").prop('disabled', true);
|
||||||
Swal.fire({
|
// Swal.fire({
|
||||||
title: 'Memuatkan...',
|
// title: 'Memuatkan...',
|
||||||
allowEscapeKey : false,
|
// allowEscapeKey : false,
|
||||||
allowOutsideClick: false,
|
// allowOutsideClick: false,
|
||||||
didOpen: function () {
|
// didOpen: function () {
|
||||||
Swal.showLoading();
|
// Swal.showLoading();
|
||||||
}
|
// }
|
||||||
});
|
// });
|
||||||
|
|
||||||
var jumupah = parseFloat($('#jumlahupah').val().replace(/[^0-9.-]+/g,""));
|
var jumupah = parseFloat($('#jumlahupah').val().replace(/[^0-9.-]+/g,""));
|
||||||
|
|
||||||
@@ -2432,6 +2438,7 @@
|
|||||||
var check_komuditi = Object.keys(komoditi).length;
|
var check_komuditi = Object.keys(komoditi).length;
|
||||||
if(check_komuditi == 0){
|
if(check_komuditi == 0){
|
||||||
$("#terima_transaksi").prop('disabled', false);
|
$("#terima_transaksi").prop('disabled', false);
|
||||||
|
Swal.close();
|
||||||
Swal.fire({
|
Swal.fire({
|
||||||
icon: 'error',
|
icon: 'error',
|
||||||
title: 'Unit Komuditi Berbaki Minumum',
|
title: 'Unit Komuditi Berbaki Minumum',
|
||||||
@@ -2443,6 +2450,7 @@
|
|||||||
}else{
|
}else{
|
||||||
if(Number(komoditi['unit_komuditi']) < pinjaman_baru){
|
if(Number(komoditi['unit_komuditi']) < pinjaman_baru){
|
||||||
$("#terima_transaksi").prop('disabled', false);
|
$("#terima_transaksi").prop('disabled', false);
|
||||||
|
Swal.close();
|
||||||
Swal.fire({
|
Swal.fire({
|
||||||
icon: 'error',
|
icon: 'error',
|
||||||
title: 'Baki Unit Komuditi Tidak Mencukupi',
|
title: 'Baki Unit Komuditi Tidak Mencukupi',
|
||||||
@@ -2485,7 +2493,8 @@
|
|||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
}
|
}
|
||||||
|
|
||||||
if( $('#tambahpinjam').val() <= 0 && $('#tambahpinjam').val() === ''){
|
|
||||||
|
if( $('#tambahpinjam').val() <= 0 || $('#tambahpinjam').val() === ''){
|
||||||
$("#terima_transaksi").prop('disabled', false);
|
$("#terima_transaksi").prop('disabled', false);
|
||||||
Swal.fire(
|
Swal.fire(
|
||||||
'Amaran!',
|
'Amaran!',
|
||||||
@@ -2495,13 +2504,14 @@
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if(parseFloat($('#basic-addon2').text()) > 75 && parseFloat($('#basic-addon2').text()) <= 80){
|
if(parseFloat($('#basic-addon2').text()) > 75 && parseFloat($('#basic-addon2').text()) <= 80){
|
||||||
const swalWithBootstrapButtons = Swal.mixin({
|
const swalWithBootstrapButtons = Swal.mixin({
|
||||||
customClass: {
|
customClass: {
|
||||||
confirmButton: 'btn btn-success',
|
confirmButton: 'btn btn-success',
|
||||||
cancelButton: 'btn btn-danger'
|
cancelButton: 'btn btn-danger'
|
||||||
},
|
},
|
||||||
buttonsStyling: false
|
buttonsStyling: false,
|
||||||
});
|
});
|
||||||
|
|
||||||
swalWithBootstrapButtons.fire({
|
swalWithBootstrapButtons.fire({
|
||||||
@@ -3455,7 +3465,7 @@
|
|||||||
urlroute = urlroute.replace(':id', norujukan);
|
urlroute = urlroute.replace(':id', norujukan);
|
||||||
Swal.fire(
|
Swal.fire(
|
||||||
'Berjaya!',
|
'Berjaya!',
|
||||||
'Tebus Separuh Berjaya',
|
'Tebus Sebahagian Berjaya',
|
||||||
'success'
|
'success'
|
||||||
) .then(function() {
|
) .then(function() {
|
||||||
window.open(urlroute, '_blank');
|
window.open(urlroute, '_blank');
|
||||||
|
|||||||
@@ -225,8 +225,8 @@
|
|||||||
$totalduitmasuk += $item['duit_masuk'];
|
$totalduitmasuk += $item['duit_masuk'];
|
||||||
$totalkeuntungan += $item['bayaran_keuntungan'];
|
$totalkeuntungan += $item['bayaran_keuntungan'];
|
||||||
$totalpendahuluan += $item['bayaran_pembiayaan'];
|
$totalpendahuluan += $item['bayaran_pembiayaan'];
|
||||||
$totalujrah += bcdiv(round($item['ansuranujrah'],2),1,1);
|
$totalujrah += round($item['ansuranujrah'],2);
|
||||||
$totalonepercent += bcdiv(round($item['ansuranonepercent'],2),1,1);
|
$totalonepercent += round($item['ansuranonepercent'],2);
|
||||||
@endphp
|
@endphp
|
||||||
|
|
||||||
@if($index > 0)
|
@if($index > 0)
|
||||||
@@ -267,8 +267,8 @@
|
|||||||
<td>{{ $item['tempoh'] }}</td>
|
<td>{{ $item['tempoh'] }}</td>
|
||||||
<td>{{ number_format($item['bakipjm'],2) }}</td>
|
<td>{{ number_format($item['bakipjm'],2) }}</td>
|
||||||
<td>{{ number_format($item['bayaran_pembiayaan'],2) }}</td>
|
<td>{{ number_format($item['bayaran_pembiayaan'],2) }}</td>
|
||||||
<td>{{ number_format(bcdiv(round($item['ansuranujrah'],2),1,1),2) }}</td>
|
<td>{{ number_format(round($item['ansuranujrah'],2),2) }}</td>
|
||||||
<td>{{ number_format(bcdiv(round($item['ansuranonepercent'],2),1,1),2) }}</td>
|
<td>{{ number_format(round($item['ansuranonepercent'],2),2) }}</td>
|
||||||
<td>{{ number_format($item['bayaran_keuntungan'],2) }}</td>
|
<td>{{ number_format($item['bayaran_keuntungan'],2) }}</td>
|
||||||
<td>{{ number_format($item['duit_masuk'],2) }}</td>
|
<td>{{ number_format($item['duit_masuk'],2) }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@@ -277,8 +277,8 @@
|
|||||||
$totaldmteller += $item['duit_masuk'];
|
$totaldmteller += $item['duit_masuk'];
|
||||||
$totalupahteller += $item['bayaran_keuntungan'];
|
$totalupahteller += $item['bayaran_keuntungan'];
|
||||||
$totalpendhteller += $item['bayaran_pembiayaan'];
|
$totalpendhteller += $item['bayaran_pembiayaan'];
|
||||||
$totalujrahteller += bcdiv(round($item['ansuranujrah'],2),1,1);
|
$totalujrahteller += round($item['ansuranujrah'],2);
|
||||||
$totalonepercentteller += bcdiv(round($item['ansuranonepercent'],2),1,1);
|
$totalonepercentteller += round($item['ansuranonepercent'],2);
|
||||||
@endphp
|
@endphp
|
||||||
|
|
||||||
@if($index+1 < sizeof($tebus))
|
@if($index+1 < sizeof($tebus))
|
||||||
|
|||||||
Reference in New Issue
Block a user