Merged in feature/block-specific (pull request #219)
Feature/block specific
This commit is contained in:
@@ -518,8 +518,8 @@ class PenebusanController extends Controller
|
||||
'nilai_marhun' => $array1['n_marhun'],
|
||||
'tag_permata' => $array1['tag_permata'],
|
||||
'berat_batu_permata' => $array1['berat_batu_permata'],
|
||||
'jenisAT' => $request->jenisAT
|
||||
'kuantiti' => $array1['bil']
|
||||
'jenisAT' => $request->jenisAT,
|
||||
'kuantiti' => $array1['bil']
|
||||
])->json();
|
||||
}
|
||||
|
||||
@@ -686,8 +686,8 @@ class PenebusanController extends Controller
|
||||
'harga' => $array1['harga'],
|
||||
'tag_permata' => $array1['tag_permata'],
|
||||
'berat_batu_permata' => $array1['berat_batu_permata'],
|
||||
'nilai_marhun' => $array1['n_marhun']
|
||||
'kuantiti' => $array1['bil']
|
||||
'nilai_marhun' => $array1['n_marhun'],
|
||||
'kuantiti' => $array1['bil']
|
||||
])->json();
|
||||
|
||||
}
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
<?php
|
||||
return [
|
||||
'enable_tambahpinjam' => env('ENABLE_TAMBAHPINJAM',1),
|
||||
'enable_separuh' => env('ENABLE_SEPARUH',0),
|
||||
'enable_pembiayaansemula' => env('ENABLE_AUTOTAWARRUQ',0)
|
||||
'enable_separuh' => env('ENABLE_SEPARUH',1),
|
||||
'enable_pembiayaansemula' => env('ENABLE_AUTOTAWARRUQ',1),
|
||||
// 'enable_specific_block' => env('ENABLE_BLOCK',0),
|
||||
'cawangan_block' => explode(',', env('CAWANGAN_BLOCK', '1STOP,010915,010219,011013,011412,010621,010620,010617,010618')),
|
||||
];
|
||||
?>
|
||||
|
||||
@@ -157,7 +157,9 @@
|
||||
<nav class="mb-3">
|
||||
<!-- button -->
|
||||
<div class="mr-2 form-group d-flex justify-content-end">
|
||||
<a class="btn btn-primary button-spacing" id="daftar_gadai">Daftar Pembiayaan</a>
|
||||
@if(!in_array(Auth::user()->cawangan, config('redeemoption.cawangan_block', [])))
|
||||
<a class="btn btn-primary button-spacing" id="daftar_gadai">Daftar Pembiayaan</a>
|
||||
@endif
|
||||
</div>
|
||||
<div class="nav nav-tabs" id="nav-tab" role="tablist">
|
||||
@php
|
||||
@@ -598,6 +600,13 @@
|
||||
var pinjaman = $(data).data("pinjaman");
|
||||
var hargajualan = $(data).data("hargajualan");
|
||||
|
||||
let array_tempblock = ['011237240808-0003','011237240719-0015','011237240806-0011','011237240828-0001',
|
||||
'011237240904-0007','011237240904-0008','011237240904-0009','011237240719-0023','011237240719-0024',
|
||||
'011237240719-0025','011237240618-0026','011237240719-0027','011237240719-0028','011237240618-0020',
|
||||
'011237240719-0030','011237240618-0029','011237240731-0026','011237240715-0027','011237240912-0009',
|
||||
];
|
||||
|
||||
|
||||
Swal.fire({
|
||||
title: 'Memuatkan...',
|
||||
allowEscapeKey : false,
|
||||
@@ -607,6 +616,16 @@
|
||||
}
|
||||
});
|
||||
|
||||
if (array_tempblock.includes(norujukan)) {
|
||||
Swal.close();
|
||||
Swal.fire({
|
||||
icon: 'error',
|
||||
title: 'Amaran',
|
||||
text: 'Surat Pembiayaan Mengalami Masalah Sila Hubungi IT'
|
||||
});
|
||||
return false;
|
||||
+ }
|
||||
|
||||
if(hargajualan == pinjaman){
|
||||
Swal.fire({
|
||||
icon: 'error',
|
||||
|
||||
@@ -812,20 +812,39 @@
|
||||
var nokp = $('#noic').val();
|
||||
if(id_type=='nokp'){
|
||||
if($.isNumeric(nokp) == false){
|
||||
Swal.fire({
|
||||
icon: 'error',
|
||||
title: 'Amaran!',
|
||||
text: 'Sila Masukkan Nombor Sahaja Pada No KP Pelanggan'
|
||||
});
|
||||
event.preventDefault();
|
||||
return false;
|
||||
// Swal.fire({
|
||||
// icon: 'error',
|
||||
// title: 'Amaran!',
|
||||
// text: 'Sila Masukkan Nombor Sahaja Pada No KP Pelanggan'
|
||||
// });
|
||||
// event.preventDefault();
|
||||
// return false;
|
||||
if(nokp.substr(-1) != '*'){
|
||||
Swal.fire({
|
||||
icon: 'error',
|
||||
title: 'Amaran!',
|
||||
text: 'Sila Masukkan Nombor Sahaja Pada No KP Pelanggan'
|
||||
});
|
||||
event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if(nokp.length != 12){
|
||||
Swal.fire({
|
||||
icon: 'error',
|
||||
title: 'Amaran!',
|
||||
text: 'Sila Periksa No KP Pelanggan'
|
||||
});
|
||||
// Swal.fire({
|
||||
// icon: 'error',
|
||||
// title: 'Amaran!',
|
||||
// text: 'Sila Periksa No KP Pelanggan'
|
||||
// });
|
||||
if(nokp.substr(-1) != '*')
|
||||
{
|
||||
Swal.fire({
|
||||
icon: 'error',
|
||||
title: 'Amaran!',
|
||||
text: 'Sila Periksa No KP Pelanggan'
|
||||
});
|
||||
event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -91,16 +91,24 @@
|
||||
<select class="form-control" id="sltjenistebus">
|
||||
<option value="T">T = Penyelesaian Pembiayaan</option>
|
||||
@if($gadai['tagbaru'] == 1)
|
||||
<option value="A" {{ $gadai['tempoh'] >= 12 ? 'disabled' : '' }}>A = Ansuran Pembiayaan</option>
|
||||
@if(!in_array(Auth::user()->cawangan, config('redeemoption.cawangan_block', [])))
|
||||
<option value="A" {{ $gadai['tempoh'] >= 12 ? 'disabled' : '' }}>A = Ansuran Pembiayaan</option>
|
||||
@endif
|
||||
@if(config('redeemoption.enable_separuh') == 1)
|
||||
@if(!in_array(Auth::user()->cawangan, config('redeemoption.cawangan_block', [])))
|
||||
<option value="S">S = Sebahagian</option>
|
||||
@endif
|
||||
@endif
|
||||
@if(config('redeemoption.enable_tambahpinjam') == 1)
|
||||
@if(!in_array(Auth::user()->cawangan, config('redeemoption.cawangan_block', [])))
|
||||
<option value="P">P = Tambah Pembiayaan</option>
|
||||
@endif
|
||||
@endif
|
||||
@endif
|
||||
@if(config('redeemoption.enable_pembiayaansemula') == 1)
|
||||
@if(!in_array(Auth::user()->cawangan, config('redeemoption.cawangan_block', [])))
|
||||
<option value="AT">PS = Pembiayaan Semula</option>
|
||||
@endif
|
||||
@endif
|
||||
<option value="" disabled hidden>Pilih Jenis Penyelesaian Pembiayaan</option>
|
||||
</select>
|
||||
|
||||
Reference in New Issue
Block a user