block sag

This commit is contained in:
Afiq
2022-02-27 23:59:16 +08:00
parent 04716a2a45
commit 955328c35e
46 changed files with 1567 additions and 1562 deletions
+19 -19
View File
@@ -9,14 +9,14 @@
}else{
$noic = $customer_info['kplama'];
}
$gadai_session = Http::get($api_url . '/api/check/sag',['kodcaw'=>$cawangan_info['kodcaw'],'norujukan'=>$norujukan,'nokp'=>$noic])->json();
$gadai_session = Http::withOptions(['verify' => config('app.api_verify')])->get($api_url . '/api/check/sag',['kodcaw'=>$cawangan_info['kodcaw'],'norujukan'=>$norujukan,'nokp'=>$noic])->json();
@endphp
@if($gadai_session != null)
<div class="container">
<div class="row justify-content-center">
<div class="col-md-12 col-lg-12">
<nav aria-label="breadcrumb">
<ol class="breadcrumb pb-3">
<li class="breadcrumb-item"><a href="#">Home</a></li>
@@ -28,7 +28,7 @@
<div class="form-group row col-12">
<input type="hidden" name="kodcaw" id="kodcaw" value="{{$cawangan_info['kodcaw']}}">
<input type="hidden" name="nokp" id="nokp" value="{{ $customer_info['kpbaru'] }}">
</div>
<div class="col-12 mb-2">
<div class="form-group row">
@@ -41,7 +41,7 @@
<input type="text" class="form-control" name="norujukan" id="norujukan" readonly value="{{ $norujukan }}">
</div>
</div>
</div>
</div>
<div class="col-6 text-right">
<button type="button" style="margin:auto" class="btn btn-primary" data-toggle="modal" data-target="#daftar_marhun">Daftar Marhun</button>
</div>
@@ -288,7 +288,7 @@
})
$('#batal_marhun').click(function(){
$('#nota').val('').trigger("change");
$('#marhun').val(0);
$('#karat').val(0);
@@ -392,7 +392,7 @@
$('#total_berat').val(formatter.format(total_berat));
$('#kadarkeuntungan').val(formatter.format(kadarupah));
$('#kuantiti_marhun').val(formatter.format(jumlah_marhun));
$.ajax({
method:'GET',
url: api_url + '/api/maxpinjaman',
@@ -544,7 +544,7 @@
text: 'Hanya 10 Marhun dibenarkan dalam 1 SAG'
});
$('#daftar_marhun').modal('hide');
}
}
}
}
}
@@ -628,7 +628,7 @@
$('#berat_emas').val("");
$('#harga').val("");
$('#nilai_marhun').val("");
jumlah_marhun += 1;
jumlah_nilai_marhun += Number(nilai_marhun);
$('#bilangan_marhun').val(formatter.format(jumlah_marhun));
@@ -677,7 +677,7 @@
var pembiyaan_max_pelulus = Number(pembiyaan_max_pelulus.replace(/[^0-9.-]+/g,""));
var min_pinjaman = nilai_marhun_total * 0.10;
var max_pinjaman = nilai_marhun_total * 0.80;
let teller = "{{ Auth::user()->name }}";
let bakiakhir = 0;
var kodcaw = $('#kodcaw').val();
@@ -797,7 +797,7 @@
reverseButtons: true
}).then((result) => {
if (result.isConfirmed) {
let norujukan = $('#norujukan').val();
let nm = parseFloat($('#total_nilai_marhun').val().replace(/[^0-9.-]+/g,""));let ber = $('#total_berat').val();let marg = $('.span-pinjaman').text();
let status = errortext;
@@ -838,7 +838,7 @@
var err = eval("(" + xhr.responseText + ")");
alert(xhr.responseText);
}
});
});
var pusher = new Pusher("{{ env('PUSHER_APP_KEY') }}", {
cluster: 'ap1',
@@ -881,7 +881,7 @@
});
}else if (result.dismiss === Swal.DismissReason.cancel){
$("#terima_gadai").prop('disabled', false);
swalWithBootstrapButtons.fire(
@@ -913,7 +913,7 @@
reverseButtons: true
}).then((result) => {
if (result.isConfirmed) {
let norujukan = $('#norujukan').val();
let nm = parseFloat($('#total_nilai_marhun').val().replace(/[^0-9.-]+/g,""));let ber = $('#total_berat').val();let marg = $('.span-pinjaman').text();
let status = "Pembiayaan Melebihi Margin " + pinjaman_teller + "%";
@@ -955,7 +955,7 @@
var err = eval("(" + xhr.responseText + ")");
alert(xhr.responseText);
}
});
});
//Try Pusher
@@ -976,7 +976,7 @@
icon: 'success',
title: 'Telah Disahkan'
}).then(function(){
$(func).attr("onSubmit","return true;");
$(func).submit();
@@ -1012,7 +1012,7 @@
}
});
event.preventDefault();
return false;
return false;
}
else if( pinjaman < 10000){
Swal.fire({
@@ -1024,7 +1024,7 @@
$(func).attr("onSubmit","return true;");
$(func).submit();
return true;
}
}
}
}
}
@@ -1087,7 +1087,7 @@
}
});
}
$('#terima_edit').on('click',function(){
@@ -1136,7 +1136,7 @@
}
})
}
});
$("#sltkarat").change(function(e){