Merge branch 'pipi' into 'master'
fixes of kelulusan and resit and marhun and notifikasi See merge request online-sistem1/kaunter!37
This commit is contained in:
@@ -61,6 +61,7 @@ class CustomersController extends Controller
|
||||
$cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json();
|
||||
$bank = Http::get(config('api.url') . '/api/bank')->json();
|
||||
$customers_info = Http::get(config('api.url') . '/api/customers/'. $noic)->json();
|
||||
|
||||
if($customers_info){
|
||||
$customer_info = $customers_info[0];
|
||||
}else{
|
||||
|
||||
@@ -2,6 +2,10 @@
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
//Events
|
||||
use App\Events\StatusLiked;
|
||||
use App\Events\NotifikasiPembayaran;
|
||||
|
||||
use Illuminate\Http\Request;
|
||||
use App\Services\CustomerService;
|
||||
use Illuminate\Support\Facades\Session;
|
||||
@@ -116,7 +120,7 @@ class GadaianController extends Controller
|
||||
$auth_user = Auth::user();
|
||||
|
||||
$gadaiannorujukan = Http::put(config('api.url') . '/api/gadai/edit/marhun/'. $auth_user['cawangan'] . '/' . $request->norujukan,[
|
||||
"marhun" => $request->marhun
|
||||
"recno" => $request->recno
|
||||
])->json();
|
||||
|
||||
return $gadaiannorujukan;
|
||||
@@ -128,18 +132,16 @@ class GadaianController extends Controller
|
||||
|
||||
$auth_user = Auth::user();
|
||||
|
||||
dd(request()->all());
|
||||
|
||||
$gadaiannorujukan = Http::put(config('api.url') . '/api/gadai/ubah/marhun/'. $auth_user['cawangan'] . '/' . $request->norujukan,[
|
||||
'marhun' => $request->valmarhun,
|
||||
'karat' => $request->karat,
|
||||
$gadaiannorujukan = Http::put(config('api.url') . '/api/gadai/ubah/marhun/'. $auth_user['cawangan'] . '/' . $request->norujukedit,[
|
||||
'recno' => $request->recno,
|
||||
'karat' => $request->sltkarat,
|
||||
'berat' => $request->berat,
|
||||
'harga' => $request->harga,
|
||||
'n_marhun' => $request->n_marhun
|
||||
'n_marhun' => $request->nilaimarhun
|
||||
|
||||
])->json();
|
||||
|
||||
return $gadaiannorujukan;
|
||||
return redirect()->back();
|
||||
}
|
||||
|
||||
public function store(Request $request){
|
||||
@@ -147,6 +149,8 @@ class GadaianController extends Controller
|
||||
$total_nilai_marhun = $request->total_nilai_marhun;
|
||||
$total_nilai_marhun = str_replace(',','',$total_nilai_marhun);
|
||||
|
||||
|
||||
|
||||
$margin_pinjaman = $request->pinjaman / $total_nilai_marhun;
|
||||
$kadarupah = $request->kadarkeuntungan * 100;
|
||||
$keuntungan6bulan = $request->keuntungan_6bln;
|
||||
@@ -166,6 +170,7 @@ class GadaianController extends Controller
|
||||
'hargajualan' => $hargajualan,
|
||||
'kuantiti_marhun' => $request->kuantiti_marhun
|
||||
])->json();
|
||||
|
||||
$request->session()->forget('page_reload');
|
||||
$request->session()->forget('norujukan');
|
||||
return redirect()->route('customer_info');
|
||||
@@ -290,9 +295,53 @@ class GadaianController extends Controller
|
||||
return view('print.resitansuran',compact('transaction','gadai','customers_info'));
|
||||
}
|
||||
|
||||
public function resitansurans($id)
|
||||
{
|
||||
|
||||
$totaltransaction = 0;
|
||||
|
||||
if(sizeof($transaction) != 0)
|
||||
$transaction = $transaction[0];
|
||||
|
||||
$gadai = Http::get(config('api.url') . '/api/gadai/norujukan/'. $id)->json();
|
||||
|
||||
if(sizeof($gadai) != 0)
|
||||
$gadai = $gadai[0][0];
|
||||
|
||||
$customers_info = Http::get(config('api.url') . '/api/customers/'. $gadai['nokp'])->json();
|
||||
|
||||
if(sizeof($customers_info) != 0)
|
||||
$customers_info = $customers_info[0];
|
||||
|
||||
return view('print.resitansuran',compact('transaction','gadai','customers_info'));
|
||||
}
|
||||
|
||||
public function resitbelumansurans($id)
|
||||
{
|
||||
|
||||
$totaltransaction = 0;
|
||||
|
||||
if(sizeof($transaction) != 0)
|
||||
$transaction = $transaction[0];
|
||||
|
||||
$gadai = Http::get(config('api.url') . '/api/gadai/norujukan/'. $id)->json();
|
||||
|
||||
if(sizeof($gadai) != 0)
|
||||
$gadai = $gadai[0][0];
|
||||
|
||||
$customers_info = Http::get(config('api.url') . '/api/customers/'. $gadai['nokp'])->json();
|
||||
|
||||
if(sizeof($customers_info) != 0)
|
||||
$customers_info = $customers_info[0];
|
||||
|
||||
return view('print.resitansuransebelum',compact('transaction','gadai','customers_info'));
|
||||
}
|
||||
|
||||
public function resittebus($id)
|
||||
{
|
||||
|
||||
$auth_user = Auth::user();
|
||||
|
||||
$gadai = Http::get(config('api.url') . '/api/gadai/norujukan/'. $id)->json();
|
||||
|
||||
$totaltransaction = 0;
|
||||
@@ -314,12 +363,12 @@ class GadaianController extends Controller
|
||||
$customers_info = $customers_info[0];
|
||||
|
||||
|
||||
$penebusan = Http::get(config('api.url') . '/api/listpenebusanhistory/ALS',[ "norujukan" => $id])->json();
|
||||
$penebusan = Http::get(config('api.url') . '/api/listpenebusanhistory/' . $auth_user['cawangan'],[ "norujukan" => $id])->json();
|
||||
|
||||
if(sizeof($penebusan) != 0)
|
||||
$penebusan = $penebusan[0];
|
||||
|
||||
$wakil = Http::get(config('api.url') . '/api/getwakil/ALS/code/' . $penebusan['nowakil'])->json();
|
||||
$wakil = Http::get(config('api.url') . '/api/getwakil/' . $auth_user['cawangan'] . '/code/' . $penebusan['nowakil'])->json();
|
||||
|
||||
// dd($wakil);
|
||||
if(sizeof($wakil) != 0)
|
||||
@@ -328,6 +377,45 @@ class GadaianController extends Controller
|
||||
return view('print.resittebus',compact('transaction','gadai','customers_info','penebusan','wakil','totaltransaction'));
|
||||
}
|
||||
|
||||
public function resitbelumtebus($id)
|
||||
{
|
||||
|
||||
$auth_user = Auth::user();
|
||||
|
||||
$gadai = Http::get(config('api.url') . '/api/gadai/norujukan/'. $id)->json();
|
||||
|
||||
|
||||
if(sizeof($gadai) != 0)
|
||||
$gadai = $gadai[0][0];
|
||||
|
||||
$customers_info = Http::get(config('api.url') . '/api/customers/'. $gadai['nokp'])->json();
|
||||
|
||||
if(sizeof($customers_info) != 0)
|
||||
$customers_info = $customers_info[0];
|
||||
|
||||
|
||||
$penebusan = Http::get(config('api.url') . '/api/listpenebusanhistory/' . $auth_user['cawangan'] ,[ "norujukan" => $id])->json();
|
||||
|
||||
if(sizeof($penebusan) != 0)
|
||||
$penebusan = $penebusan[0];
|
||||
|
||||
// dd($penebusan['nowakil']);
|
||||
|
||||
if($penebusan['nowakil'] != 0)
|
||||
{
|
||||
$wakil = Http::get(config('api.url') . '/api/getwakil/' . $auth_user['cawangan'] . '/code/' . $penebusan['nowakil'])->json();
|
||||
|
||||
if(sizeof($wakil) != 0)
|
||||
$wakil = $wakil[0];
|
||||
}
|
||||
else
|
||||
{
|
||||
$wakil = [];
|
||||
}
|
||||
|
||||
return view('print.resittebussebelum',compact('gadai','customers_info','penebusan','wakil','totaltransaction'));
|
||||
}
|
||||
|
||||
public function history(Request $request)
|
||||
{
|
||||
$auth_user = Auth::user();
|
||||
@@ -359,5 +447,69 @@ class GadaianController extends Controller
|
||||
return response()->json($arrayhist,200);
|
||||
}
|
||||
|
||||
|
||||
/// KELULUSAN///
|
||||
|
||||
public function getkelulusan(Request $request)
|
||||
{
|
||||
$auth_user = Auth::user();
|
||||
$api_url = config('api.url');
|
||||
|
||||
$norujukan = $request->norujukan;
|
||||
|
||||
$cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json();
|
||||
|
||||
$kelulusan = Http::get(config('api.url') . '/api/GetLulus/' . $auth_user['cawangan'],[
|
||||
"norujukan" => $norujukan
|
||||
])->json();
|
||||
|
||||
if(sizeof($kelulusan) > 0)
|
||||
{
|
||||
$kelulusan = $kelulusan['benar'];
|
||||
}
|
||||
else
|
||||
{
|
||||
$kelulusan = '';
|
||||
}
|
||||
|
||||
return response($kelulusan);
|
||||
}
|
||||
|
||||
public function updatekelulusan(Request $request)
|
||||
{
|
||||
$auth_user = Auth::user();
|
||||
|
||||
$api_url = config('api.url');
|
||||
|
||||
$norujukan = $request->norujukan;
|
||||
|
||||
$cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json();
|
||||
|
||||
$updatelulus = Http::put(config('api.url') . '/api/UpdateKelulusan/kepohonan/' . $auth_user['cawangan'] . '/' . $norujukan)->json();
|
||||
|
||||
return response()->json($updatelulus,200);
|
||||
}
|
||||
|
||||
public function createkelulusan(Request $request)
|
||||
{
|
||||
$auth_user = Auth::user();
|
||||
$api_url = config('api.url');
|
||||
|
||||
$norujukan = $request->norujukan;
|
||||
|
||||
$cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json();
|
||||
|
||||
$createlulus = Http::post(config('api.url') . '/api/CreateLulus/' . $auth_user['cawangan'] . '/' . $norujukan, [
|
||||
'mohon' => $request->mohon,
|
||||
'teller' => $auth_user['name']
|
||||
])->json();
|
||||
|
||||
event(new StatusLiked('Penghantaran kepada Khazanah!'));
|
||||
|
||||
return response()->json($createlulus,201);
|
||||
}
|
||||
|
||||
///END KELULUSAN///
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -236,8 +236,9 @@ class KhazanahController extends Controller
|
||||
$cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json();
|
||||
|
||||
$kelulusan = Http::get(config('api.url') . '/api/SenaraiKelulusan/' . $auth_user['cawangan'])->json();
|
||||
$kelulusanmohonid = Http::get(config('api.url') . '/api/GetLulusAll/' . $auth_user['cawangan'])->json();
|
||||
|
||||
return view('khazanah.kelulusan',compact('cawangan_info','api_url','kelulusan'));
|
||||
return view('khazanah.kelulusan',compact('cawangan_info','api_url','kelulusan','kelulusanmohonid'));
|
||||
|
||||
}
|
||||
|
||||
@@ -276,7 +277,18 @@ class KhazanahController extends Controller
|
||||
|
||||
$cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json();
|
||||
|
||||
$updatelulus = Http::put(config('api.url') . '/api/UpdateKelulusan/' . $auth_user['cawangan'] . '/' . $norujukan)->json();
|
||||
|
||||
if($request->khazanah != null)
|
||||
{
|
||||
$updatelulus = Http::put(config('api.url') . '/api/UpdateKelulusan/kepohonan/' . $auth_user['cawangan'] . '/' . $norujukan,[
|
||||
"khazanah" => $request->khazanah
|
||||
])->json();
|
||||
}
|
||||
else
|
||||
{
|
||||
$updatelulus = Http::put(config('api.url') . '/api/UpdateKelulusan/' . $auth_user['cawangan'] . '/' . $norujukan)->json();
|
||||
}
|
||||
|
||||
|
||||
return response()->json($updatelulus,200);
|
||||
}
|
||||
|
||||
@@ -23,7 +23,19 @@ class OperasiController extends Controller
|
||||
$api_url = config('api.url');
|
||||
$cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json();
|
||||
|
||||
$kelulusan = Http::get(config('api.url') . '/api/SenaraiKelulusan/' . $auth_user['cawangan'])->json();
|
||||
$kelulusan = Http::get(config('api.url') . '/api/ListOperasi/')->json();
|
||||
|
||||
|
||||
if(sizeof($kelulusan) != 0)
|
||||
{
|
||||
$kelulusan = $kelulusan[0];
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
return view('operasi.kelulusan',compact('cawangan_info','api_url','kelulusan'));
|
||||
}
|
||||
@@ -58,10 +70,11 @@ class OperasiController extends Controller
|
||||
$api_url = config('api.url');
|
||||
|
||||
$norujukan = $request->norujukan;
|
||||
|
||||
|
||||
$cawangan_info = Http::get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json();
|
||||
|
||||
$updatelulus = Http::put(config('api.url') . '/api/UpdateKelulusan/' . $auth_user['cawangan'] . '/' . $norujukan)->json();
|
||||
$updatelulus = Http::put(config('api.url') . '/api/UpdateKelulusan/' . $request->kodcaw . '/' . $norujukan)->json();
|
||||
|
||||
return response()->json($updatelulus,200);
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
<div class="card-body">
|
||||
<div class="text-center">
|
||||
<h5 class="text-uppercase">masukkan nombor kad pengenalan</h5>
|
||||
<form action="{{ route('customer.search') }}" method="GET">
|
||||
<form name="frmsearch" action="{{ route('customer.search') }}" method="GET" onsubmit="verifyIC()">
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-md-7">
|
||||
<div class="input-group my-3">
|
||||
@@ -248,6 +248,14 @@
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
function verifyIC()
|
||||
{
|
||||
var a = $('input[name="noic"]').val();
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
function identifyIC(noic){
|
||||
|
||||
@@ -217,26 +217,35 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group row">
|
||||
<div class="col-md-6">
|
||||
Jumlah Pembiayaan Semasa / Limit Pembiayaan Semasa
|
||||
<div class="col-md-4">
|
||||
Pembiayaan Semasa
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="col-md-8">
|
||||
@php
|
||||
$outstanding_semasa = Http::get($api_url . '/api/gadai/customers/'. $customer_info['kpbaru'] .'/outstandingsemasa')->json();
|
||||
@endphp
|
||||
<input type="text" class="form-control" name="outstanding_semasa" id="outstanding_semasa" readonly value="{{ number_format($outstanding_semasa,2) }}">
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<div class="col-md-4">
|
||||
Limit Pembiayaan
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
@php
|
||||
$limit_pinjaman_semasa = 0;
|
||||
@endphp
|
||||
<input type="text" class="form-control" name="outstanding_semasa" id="outstanding_semasa" readonly value="{{ number_format($limit_pinjaman_semasa,2) }}">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
|
||||
<div class="col-md-6">
|
||||
|
||||
<div class="form-group row">
|
||||
<div class="col-md-4">
|
||||
No Telefon
|
||||
@@ -245,8 +254,7 @@
|
||||
<input type="text" class="form-control" name="nota_semasa" id="nota_semasa" readonly value="{{ $customer_info['telefon'] }}">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
|
||||
<div class="form-group row">
|
||||
<div class="col-md-4">
|
||||
Nota
|
||||
@@ -255,9 +263,8 @@
|
||||
<input type="text" class="form-control" name="nota_semasa" id="nota_semasa" readonly value="{{ $customer_info['nota'] }}">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="col-md-12 mt-md-3 justify-content-between form-group row">
|
||||
<div class="btn-group btn-group-toggle col-md-6" data-toggle="buttons">
|
||||
@@ -607,10 +614,80 @@
|
||||
}).then((result) => {
|
||||
if (result.isConfirmed) {
|
||||
|
||||
var urlroute = '{{ route("gadaian.edit", ":id") }}';
|
||||
urlroute = urlroute.replace(':id', ubahid);
|
||||
Swal.fire({
|
||||
title: 'Tunggu Pengesahan Daripada Khazanah.',
|
||||
icon: 'info',
|
||||
width: 600,
|
||||
padding: '3em',
|
||||
background: '#fffff',
|
||||
showCancelButton: false,
|
||||
showConfirmButton: false,
|
||||
allowOutsideClick: false,
|
||||
allowEscapeKey: false,
|
||||
allowEnterKey: false
|
||||
})
|
||||
|
||||
let mohon = "Ubah Gadai";
|
||||
|
||||
$.ajax({
|
||||
method:'post',
|
||||
url: '{{ route("teller.createkelulusan") }}',
|
||||
data: {
|
||||
"_token": "{{ csrf_token() }}",
|
||||
"norujukan" : ubahid,
|
||||
"mohon" : mohon
|
||||
},
|
||||
success:function(data){
|
||||
|
||||
console.log(data);
|
||||
|
||||
},error: function(xhr, status, error) {
|
||||
var err = eval("(" + xhr.responseText + ")");
|
||||
alert(xhr.responseText);
|
||||
}
|
||||
});
|
||||
|
||||
//TIME INTERVAL
|
||||
let timerInterval;
|
||||
|
||||
timerInterval = setInterval(function()
|
||||
{
|
||||
$.ajax({
|
||||
method:'get',
|
||||
url: "{{ route('teller.getkelulusan') }}",
|
||||
data: {
|
||||
"norujukan" : ubahid
|
||||
},
|
||||
success:function(data){
|
||||
console.log(data);
|
||||
if(data != 0)
|
||||
{
|
||||
console.log('berjaya');
|
||||
clearInterval(timerInterval);
|
||||
Swal.fire({
|
||||
icon: 'success',
|
||||
title: 'Anda Berjaya Menerima Pengesahan'
|
||||
}).then(function(){
|
||||
|
||||
var urlroute = '{{ route("gadaian.edit", ":id") }}';
|
||||
urlroute = urlroute.replace(':id', ubahid);
|
||||
|
||||
window.location.replace(urlroute);
|
||||
|
||||
return true;
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
},error: function(xhr, status, error) {
|
||||
var err = eval("(" + xhr.responseText + ")");
|
||||
alert(xhr.responseText);
|
||||
}
|
||||
});
|
||||
|
||||
}, 3000);
|
||||
|
||||
|
||||
window.location.replace(urlroute);
|
||||
|
||||
|
||||
}else if (result.dismiss === Swal.DismissReason.cancel) {
|
||||
@@ -670,6 +747,71 @@
|
||||
reverseButtons: true
|
||||
}).then((result) => {
|
||||
if (result.isConfirmed) {
|
||||
|
||||
Swal.fire({
|
||||
title: 'Tunggu Pengesahan Daripada Khazanah.',
|
||||
icon: 'info',
|
||||
width: 600,
|
||||
padding: '3em',
|
||||
background: '#fffff',
|
||||
showCancelButton: false,
|
||||
showConfirmButton: false,
|
||||
allowOutsideClick: false,
|
||||
allowEscapeKey: false,
|
||||
allowEnterKey: false
|
||||
})
|
||||
|
||||
let mohon = "Hapus Gadai";
|
||||
let id = 0;
|
||||
if($("input[name='options']:checked").val() == 'belum_tebus')
|
||||
{
|
||||
id = hapusid;
|
||||
}
|
||||
else if($("input[name='options']:checked").val() == 'sudah_tebus')
|
||||
{
|
||||
id = hapusidsudah;
|
||||
}
|
||||
|
||||
$.ajax({
|
||||
method:'post',
|
||||
url: '{{ route("teller.createkelulusan") }}',
|
||||
data: {
|
||||
"_token": "{{ csrf_token() }}",
|
||||
"norujukan" : id,
|
||||
"mohon" : mohon
|
||||
},
|
||||
success:function(data){
|
||||
|
||||
console.log(data);
|
||||
|
||||
},error: function(xhr, status, error) {
|
||||
var err = eval("(" + xhr.responseText + ")");
|
||||
alert(xhr.responseText);
|
||||
}
|
||||
});
|
||||
|
||||
//TIME INTERVAL
|
||||
let timerInterval;
|
||||
|
||||
timerInterval = setInterval(function()
|
||||
{
|
||||
$.ajax({
|
||||
method:'get',
|
||||
url: "{{ route('teller.getkelulusan') }}",
|
||||
data: {
|
||||
"norujukan" : id
|
||||
},
|
||||
success:function(data){
|
||||
console.log(data);
|
||||
if(data != 0)
|
||||
{
|
||||
console.log('berjaya');
|
||||
clearInterval(timerInterval);
|
||||
Swal.fire({
|
||||
icon: 'success',
|
||||
title: 'Anda Berjaya Menerima Pengesahan'
|
||||
}).then(function(){
|
||||
|
||||
if($("input[name='options']:checked").val() == 'belum_tebus')
|
||||
{
|
||||
|
||||
@@ -700,7 +842,7 @@
|
||||
|
||||
$.ajax({
|
||||
method:'put',
|
||||
url:api_url+'/api/tebus/hapus/' + kodcaw + '/' + hapusid,
|
||||
url:api_url+'/api/tebus/hapus/' + kodcaw + '/' + hapusidsudah,
|
||||
success:function(data)
|
||||
{
|
||||
if(data != "Bukan-Tebus")
|
||||
@@ -729,6 +871,21 @@
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
},error: function(xhr, status, error) {
|
||||
var err = eval("(" + xhr.responseText + ")");
|
||||
alert(xhr.responseText);
|
||||
}
|
||||
});
|
||||
|
||||
}, 3000);
|
||||
|
||||
|
||||
}else if (result.dismiss === Swal.DismissReason.cancel) {
|
||||
swalWithBootstrapButtons.fire(
|
||||
'Cancelled',
|
||||
|
||||
@@ -53,6 +53,7 @@
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Bil</th>
|
||||
<th>Recno</th>
|
||||
<th>Marhun</th>
|
||||
<th>Nilai Marhun</th>
|
||||
<th>Karat</th>
|
||||
@@ -103,7 +104,7 @@
|
||||
Pembiayaan
|
||||
</div>
|
||||
<div class="col-7 input-group">
|
||||
<input type="text" class="form-control" name="pinjaman" id="pinjaman">
|
||||
<input type="text" class="form-control" name="pinjaman" value="{{ $gadaiannorujukan['pinjaman'] }}" id="pinjaman">
|
||||
<div class="input-group-append">
|
||||
<span class="input-group-text span-pinjaman">0 %</span>
|
||||
</div>
|
||||
@@ -230,8 +231,6 @@
|
||||
<script>
|
||||
var api_url = "<?php echo $api_url ?>";
|
||||
|
||||
$('#pinjaman').val(parseFloat("{{ $gadaiannorujukan['pinjaman'] }}"));
|
||||
|
||||
function disableF5(e) { if ((e.which || e.keyCode) == 116) e.preventDefault(); };
|
||||
$(document).ready( function () {
|
||||
$(document).on("keydown", disableF5);
|
||||
@@ -309,7 +308,14 @@
|
||||
}
|
||||
|
||||
var tablemarhun = $('#myTable').DataTable({
|
||||
"ordering": false
|
||||
"ordering": false,
|
||||
"columnDefs": [
|
||||
{
|
||||
"targets": [ 1 ],
|
||||
"visible": false,
|
||||
"searchable": false
|
||||
}
|
||||
]
|
||||
});
|
||||
|
||||
$(".select2").select2({
|
||||
@@ -389,7 +395,7 @@
|
||||
|
||||
function deletemarhun(e)
|
||||
{
|
||||
let marhun = $(e).closest('tr').children('td:eq(1)').text();
|
||||
let marhun = $(e).closest('tr').children('td:eq(1)').text();let selectedrow = $(e).closest('tr');let recnozz = tablemarhun.row(selectedrow).data();
|
||||
let norujuk = $('#norujukan').val();
|
||||
|
||||
$.ajax({
|
||||
@@ -398,7 +404,7 @@
|
||||
data: {
|
||||
"_token": "{{ csrf_token() }}",
|
||||
"norujukan" : norujuk,
|
||||
"marhun" : marhun
|
||||
"recno" : recnozz[1]
|
||||
},
|
||||
success:function(data)
|
||||
{
|
||||
@@ -413,11 +419,10 @@
|
||||
|
||||
function editmarhun(e)
|
||||
{
|
||||
let marhun = $(e).closest('tr').children('td:eq(1)').text();
|
||||
let norujuk = $('#norujukan').val();
|
||||
let norujuk = $('#norujukan').val();let selectedrow = $(e).closest('tr');let recno = tablemarhun.row(selectedrow).data();
|
||||
|
||||
$('#norujukedit').val(norujuk);
|
||||
$('#valmarhun').val(marhun);
|
||||
$('#recno').val(recno[1]);
|
||||
$('#editMarhunModal').modal();
|
||||
}
|
||||
|
||||
|
||||
@@ -33,16 +33,26 @@
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($kelulusan as $index=>$k)
|
||||
|
||||
<tr>
|
||||
<td>{{ $k['norujukan'] }}</td>
|
||||
<td>{{ $k['tarikh'] }}</td>
|
||||
<td>{{ $cawangan_info['details_caw'] }}</td>
|
||||
<td>{{ $k['norujukan'] }}</td>
|
||||
<td>{{ $k['komen'] }}</td>
|
||||
<td><button class="btn btn-primary mr-2" onclick="updatelulus(this)" data-norujukan="{{ $k['norujukan'] }}"><i class="fas fa-thumbs-up"></i></button><button class="btn btn-danger"><i class="fas fa-thumbs-down"></i></button></td>
|
||||
<td>{{ $k['norujukan'] }}</td>
|
||||
<td>{{ $k['tarikh'] }}</td>
|
||||
<td>{{ $cawangan_info['details_caw'] }}</td>
|
||||
<td>{{ $k['norujukan'] }}</td>
|
||||
<td>{{ $k['komen'] }}</td>
|
||||
<td><button class="btn btn-primary mr-2" onclick="updatelulus(this)" data-norujukan="{{ $k['norujukan'] }}"><i class="fas fa-thumbs-up"></i></button><button class="btn btn-danger"><i class="fas fa-thumbs-down"></i></button></td>
|
||||
</tr>
|
||||
|
||||
@endforeach
|
||||
@foreach($kelulusanmohonid as $index=>$km)
|
||||
|
||||
<tr>
|
||||
<td>{{ $km['norujukan'] }}</td>
|
||||
<td>{{ $km['tarikh'] }}</td>
|
||||
<td>{{ $cawangan_info['details_caw'] }}</td>
|
||||
<td>{{ $km['norujukan'] }}</td>
|
||||
<td>{{ $km['mohon'] }}</td>
|
||||
<td><button class="btn btn-primary mr-2" onclick="updatelulusmohon(this)" data-norujukan="{{ $km['norujukan'] }}"><i class="fas fa-thumbs-up"></i></button><button class="btn btn-danger"><i class="fas fa-thumbs-down"></i></button></td>
|
||||
</tr>
|
||||
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -82,7 +92,38 @@
|
||||
icon: 'success',
|
||||
title: 'Anda Berjaya Mengesahkan Pengesahan'
|
||||
}).then(function(){
|
||||
// location.reload();
|
||||
location.reload();
|
||||
});
|
||||
|
||||
},error: function(xhr, status, error) {
|
||||
var err = eval("(" + xhr.responseText + ")");
|
||||
alert(xhr.responseText);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function updatelulusmohon(e)
|
||||
{
|
||||
let norujukan = $(e).data('norujukan');
|
||||
let namakhazanah = "{{ $auth_user = Auth::user()->name }}";
|
||||
|
||||
alert(namakhazanah);
|
||||
|
||||
$.ajax({
|
||||
method:'put',
|
||||
url: "{{ route('khazanah.updatekelulusan') }}",
|
||||
data: {
|
||||
"_token": "{{ csrf_token() }}",
|
||||
"norujukan" : norujukan,
|
||||
"khazanah" : namakhazanah
|
||||
},
|
||||
success:function(data){
|
||||
|
||||
Swal.fire({
|
||||
icon: 'success',
|
||||
title: 'Anda Berjaya Mengesahkan Pengesahan'
|
||||
}).then(function(){
|
||||
location.reload();
|
||||
});
|
||||
|
||||
},error: function(xhr, status, error) {
|
||||
|
||||
@@ -94,8 +94,10 @@
|
||||
<!-- Right Side Of Navbar -->
|
||||
<ul class="navbar-nav ml-auto">
|
||||
|
||||
|
||||
|
||||
@php $auth_user = Auth::user(); @endphp
|
||||
@if ($auth_user['roles'] == 'khazanah')
|
||||
@if ($auth_user['roles'] == 'ppc' || $auth_user['roles'] == 'pc')
|
||||
<li class="nav-item dropdown" style="margin-right:10px;">
|
||||
<a id="navbarDropdown" class="nav-link " href="#" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" v-pre>
|
||||
<i id="bell" class="fa fa-bell"></i>
|
||||
@@ -113,7 +115,7 @@
|
||||
<script>
|
||||
|
||||
// Enable pusher logging - don't include this in production
|
||||
Pusher.logToConsole = true;
|
||||
// Pusher.logToConsole = true;
|
||||
|
||||
var pusher = new Pusher('26b0ec2f297f94b7aa9b', {
|
||||
cluster: 'ap1',
|
||||
@@ -170,7 +172,7 @@
|
||||
<script>
|
||||
|
||||
// Enable pusher logging - don't include this in production
|
||||
Pusher.logToConsole = true;
|
||||
// Pusher.logToConsole = true;
|
||||
|
||||
var pusher = new Pusher('26b0ec2f297f94b7aa9b', {
|
||||
cluster: 'ap1',
|
||||
@@ -226,7 +228,7 @@
|
||||
@endif
|
||||
@else
|
||||
<li class="nav-item dropdown">
|
||||
<a id="navbarDropdown" class="nav-link dropdown-toggle" onclick="trigbiasa()" href="#" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" v-pre>
|
||||
<a id="navbarDropdown" class="nav-link dropdown-toggle" href="#" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" v-pre>
|
||||
{{ Auth::user()->name }}
|
||||
</a>
|
||||
|
||||
|
||||
@@ -197,6 +197,65 @@
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
@elseif($auth_user['roles'] == 'operasi')
|
||||
<li class="nav-item dropdown" style="margin-right:10px;">
|
||||
<a id="navbarDropdown" class="nav-link " href="#" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" v-pre>
|
||||
<i id="bell" class="fa fa-bell"></i>
|
||||
</a>
|
||||
|
||||
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="navbarDropdown">
|
||||
<div id="divbiasa">
|
||||
<a class="dropdown-item" id="gadailinkz" href="#">
|
||||
Tiada Data
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<script>
|
||||
|
||||
// Enable pusher logging - don't include this in production
|
||||
Pusher.logToConsole = true;
|
||||
|
||||
var pusher = new Pusher('26b0ec2f297f94b7aa9b', {
|
||||
cluster: 'ap1',
|
||||
encrypted: true
|
||||
});
|
||||
|
||||
var channel = pusher.subscribe('status-liked');
|
||||
channel.bind('my-event', function(data) {
|
||||
let message = JSON.stringify(data);
|
||||
|
||||
$('#bell').css("color", "red");
|
||||
$('#linkz').text("Teller Pohon Kelulusan");
|
||||
$("#linkz").attr("href", "{{ url('kelulusan') }}");
|
||||
|
||||
const Toast = Swal.mixin({
|
||||
toast: true,
|
||||
position: 'top-end',
|
||||
showConfirmButton: false,
|
||||
timer: 5000,
|
||||
timerProgressBar: true,
|
||||
didOpen: (toast) => {
|
||||
toast.addEventListener('mouseenter', Swal.stopTimer)
|
||||
toast.addEventListener('mouseleave', Swal.resumeTimer)
|
||||
}
|
||||
})
|
||||
|
||||
Toast.fire({
|
||||
icon: 'error',
|
||||
title: 'Kelulusan Dipohon Sekarang!'
|
||||
})
|
||||
});
|
||||
|
||||
|
||||
$("#navbarDropdown").click(function(){
|
||||
$('#bell').css("color", "grey");
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
|
||||
@endif
|
||||
|
||||
|
||||
@@ -18,8 +18,8 @@
|
||||
|
||||
<form name="ubahmarhunform" method="put" action='{{ route('gadai.ubahmarhun') }}'>
|
||||
@csrf
|
||||
<input type="text" name="norujukedit" id="norujukedit"/>
|
||||
<input type="text" name="valmarhun" id="valmarhun"/>
|
||||
<input type="hidden" name="norujukedit" id="norujukedit"/>
|
||||
<input type="hidden" name="recno" id="recno"/>
|
||||
<div class="form-group row">
|
||||
<div class="col-6 form-group row">
|
||||
<label class="col-4">Karat</label>
|
||||
|
||||
@@ -31,14 +31,24 @@
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($kelulusan as $index=>$k)
|
||||
@php
|
||||
|
||||
if(sizeof($kelulusan) != 0)
|
||||
{
|
||||
$cawangan = $kelulusan['cawangan'];
|
||||
$kodcaw = $kelulusan['cawangankod'];
|
||||
$kelulusan = $kelulusan['kelulusanall'];
|
||||
}
|
||||
|
||||
@endphp
|
||||
|
||||
@foreach($kelulusan as $index=>$k)}
|
||||
<tr>
|
||||
<td>{{ $k['norujukan'] }}</td>
|
||||
<td>{{ $k['tarikh'] }}</td>
|
||||
<td>{{ $cawangan_info['details_caw'] }}</td>
|
||||
<td>{{ $cawangan }}</td>
|
||||
<td>{{ $k['komen'] }}</td>
|
||||
<td><button class="btn btn-primary mr-2" onclick="updatelulus(this)" data-norujukan="{{ $k['norujukan'] }}"><i class="fas fa-thumbs-up"></i></button><button class="btn btn-danger"><i class="fas fa-thumbs-down"></i></button></td>
|
||||
<td><button class="btn btn-primary mr-2" onclick="updatelulus(this)" data-kodcaw="{{ $kodcaw }}" data-norujukan="{{ $k['norujukan'] }}"><i class="fas fa-thumbs-up"></i></button><button class="btn btn-danger"><i class="fas fa-thumbs-down"></i></button></td>
|
||||
</tr>
|
||||
|
||||
@endforeach
|
||||
@@ -66,21 +76,25 @@
|
||||
function updatelulus(e)
|
||||
{
|
||||
let norujukan = $(e).data('norujukan');
|
||||
let cawangankod = $(e).data('kodcaw');
|
||||
|
||||
alert(cawangankod);
|
||||
|
||||
$.ajax({
|
||||
method:'put',
|
||||
url: "{{ route('operasi.updatekelulusan') }}",
|
||||
data: {
|
||||
"_token": "{{ csrf_token() }}",
|
||||
"norujukan" : norujukan
|
||||
"norujukan" : norujukan,
|
||||
"kodcaw" : cawangankod
|
||||
},
|
||||
success:function(data){
|
||||
|
||||
console.log(data);
|
||||
Swal.fire({
|
||||
icon: 'success',
|
||||
title: 'Anda Berjaya Mengesahkan Pengesahan'
|
||||
}).then(function(){
|
||||
// location.reload();
|
||||
location.reload();
|
||||
});
|
||||
|
||||
},error: function(xhr, status, error) {
|
||||
|
||||
@@ -262,7 +262,7 @@
|
||||
<div class="col-12">
|
||||
<input type="button" class="float-right btn btn-danger mr-2" value="BATAL" onclick="window.location.replace('{{ url()->previous() }}')">
|
||||
<input type="button" class="float-right btn btn-primary mr-2" value="TERIMA" onclick="bayaransemua()">
|
||||
<input type="button" class="float-left btn btn-warning mr-2" value="HISTORY" onclick="historybayaran()">
|
||||
<input type="button" class="float-left btn btn-warning mr-2" value="HISTORY" id="histbtn" onclick="historybayaran()">
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
@@ -328,6 +328,7 @@ function tebusan()
|
||||
$('#divpembiayaanasal').hide();
|
||||
$('#divbakihargajualan').show();
|
||||
$('#divtelahdibayar').show();
|
||||
$('#histbtn').show();
|
||||
|
||||
//Upah Tawarruq
|
||||
$.ajax({
|
||||
@@ -362,6 +363,7 @@ function tebusan()
|
||||
$('#divpembiayaanasal').show();
|
||||
$('#divbakihargajualan').hide();
|
||||
$('#divtelahdibayar').hide();
|
||||
$('#histbtn').hide();
|
||||
|
||||
//Upah Bukan Tawarruq
|
||||
$.ajax({
|
||||
@@ -725,9 +727,15 @@ function bayaransemua()
|
||||
if(tarikhgadai < tarikhtawarruq)
|
||||
{
|
||||
jenisbayarantebus = "nottawarruq";
|
||||
|
||||
var urlroute = '{{ route("resit.belumtebus", ":id") }}';
|
||||
urlroute = urlroute.replace(':id', norujukan);
|
||||
}
|
||||
else if (tarikhgadai >= tarikhtawarruq){
|
||||
jenisbayarantebus = "tawarruq";
|
||||
|
||||
var urlroute = '{{ route("resit.tebus", ":id") }}';
|
||||
urlroute = urlroute.replace(':id', norujukan);
|
||||
}
|
||||
|
||||
var nopelanggan = "{{ $gadai['nopelanggan'] }}";
|
||||
@@ -739,16 +747,15 @@ function bayaransemua()
|
||||
var ansuran = 0;
|
||||
var addpinjaman = 0;
|
||||
var bakipinjaman = $('#perludibayar').val();
|
||||
var bakiupah = 0;
|
||||
var bakiupah = $('#jumlahupah').val();
|
||||
var historygadaian = 0;
|
||||
var marhun = "{{ $gadai['marhun'] }}";
|
||||
var nowakil = nw;
|
||||
|
||||
var urlroute = '{{ route("resit.tebus", ":id") }}';
|
||||
urlroute = urlroute.replace(':id', norujukan);
|
||||
|
||||
|
||||
$.ajax({
|
||||
method:'PUT',
|
||||
method:'put',
|
||||
url: api + '/api/updatetebus/' + kodcaw + '/' + norujukan,
|
||||
data:{
|
||||
"nopelanggan" : nopelanggan,
|
||||
@@ -788,6 +795,8 @@ function bayaransemua()
|
||||
else if($('#sltjenistebus').find(":selected").val() == 'A')
|
||||
{
|
||||
let jenisbayarantebus = '';
|
||||
let hadbayaransuran = (parseFloat("{{ $gadai['nilaimarhun']}}") * 0.1);
|
||||
|
||||
if(tarikhgadai < tarikhtawarruq)
|
||||
{
|
||||
jenisbayarantebus = "nottawarruq";
|
||||
@@ -796,9 +805,24 @@ function bayaransemua()
|
||||
jenisbayarantebus = "tawarruq";
|
||||
}
|
||||
|
||||
|
||||
if(tarikhgadai >= tarikhtawarruq)
|
||||
{
|
||||
var bayar = $('#bayaran').val();
|
||||
var bakipinjam = parseFloat("{{ $gadai['bakipjm'] }}") - hadbayaransuran;
|
||||
|
||||
|
||||
|
||||
if(bayar > bakipinjam)
|
||||
{
|
||||
Swal.fire(
|
||||
'Amaran!',
|
||||
'Bayaran tidak boleh melebihi 10% nilai marhun!',
|
||||
'error'
|
||||
)
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
$.ajax({
|
||||
method:'PUT',
|
||||
@@ -807,11 +831,16 @@ function bayaransemua()
|
||||
"bayaran" : bayar
|
||||
},
|
||||
success:function(success_data){
|
||||
|
||||
var urlroute = '{{ route("resit.ansurans", ":id") }}';
|
||||
urlroute = urlroute.replace(':id', norujukan);
|
||||
|
||||
Swal.fire(
|
||||
'Good job!',
|
||||
'You clicked the button!',
|
||||
'success'
|
||||
).then(function() {
|
||||
window.open(urlroute, '_blank');
|
||||
window.location.replace("{{ url()->previous() }}");
|
||||
})
|
||||
}
|
||||
@@ -830,6 +859,20 @@ function bayaransemua()
|
||||
// return false;
|
||||
// }
|
||||
|
||||
var bakpin = parseFloat("{{ $gadai['pinjaman'] }}") - hadbayaransuran;
|
||||
|
||||
var bayar = $('#bayaran').val();
|
||||
|
||||
if(bayar > bakpin)
|
||||
{
|
||||
Swal.fire(
|
||||
'Amaran!',
|
||||
'Bayaran tidak boleh melebihi 10% nilai marhun!',
|
||||
'error'
|
||||
)
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
var lebihan = parseFloat($('#perludibayar').val()) - parseFloat($('#jumlahupah').val());
|
||||
|
||||
@@ -1387,7 +1430,7 @@ function historybayaran()
|
||||
{
|
||||
$.ajax({
|
||||
method: 'get',
|
||||
url: 'http://localhost:8000/api/transaction/' + norujukan,
|
||||
url: api + '/api/transaction/' + norujukan,
|
||||
success: function(data)
|
||||
{
|
||||
historybayarantable(data);
|
||||
|
||||
@@ -0,0 +1,563 @@
|
||||
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
|
||||
|
||||
<style>
|
||||
/* Red border */
|
||||
hr.new1 {
|
||||
border-top: 1px solid red;
|
||||
}
|
||||
|
||||
/* Dashed red border */
|
||||
hr.new2 {
|
||||
border-top: 1px dashed red;
|
||||
}
|
||||
|
||||
/* Dotted red border */
|
||||
hr.new3 {
|
||||
border-top: 1px dotted red;
|
||||
}
|
||||
|
||||
/* Thick red border */
|
||||
hr.new4 {
|
||||
border: 1px solid red;
|
||||
}
|
||||
|
||||
/* Large rounded green border */
|
||||
hr.new5 {
|
||||
border: 10px solid green;
|
||||
border-radius: 5px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<style>
|
||||
|
||||
#cust {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width:20%;
|
||||
font-size:10px;
|
||||
border: 1px solid black;
|
||||
|
||||
}
|
||||
|
||||
#cust td, #cust th {
|
||||
border: 0px solid;
|
||||
padding: 3px;
|
||||
font-size:9px;
|
||||
text-align:right;
|
||||
|
||||
}
|
||||
|
||||
#cust tr:nth-child(even){background-color: #ffffff;}
|
||||
|
||||
#cust tr:hover {background-color: #ddd;}
|
||||
|
||||
#cust th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
text-align:right;
|
||||
background-color: #d9deda;
|
||||
color: black;
|
||||
padding:2px;
|
||||
}
|
||||
|
||||
#cust {
|
||||
margin-left: auto;
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
</style>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<style>
|
||||
hr.new1 {
|
||||
border-top: 1px dotted black;
|
||||
}
|
||||
.khazanah{
|
||||
border:1px solid black;
|
||||
margin-left:20px;
|
||||
padding:10px;
|
||||
width : 250px;
|
||||
transform: rotate(-90deg);
|
||||
font-size:11px;
|
||||
}
|
||||
|
||||
#inside {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width:100%;
|
||||
font-size:10px;
|
||||
}
|
||||
|
||||
#inside td, #inside th {
|
||||
border: 1px solid #ddd;
|
||||
padding: 2px;
|
||||
}
|
||||
|
||||
#inside tr:nth-child(even){background-color: #ffffff;}
|
||||
|
||||
#inside tr:hover {background-color: #ddd;}
|
||||
|
||||
#inside th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 10px;
|
||||
text-align: left;
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
#semakan {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width:100%;
|
||||
font-size:10px;
|
||||
}
|
||||
|
||||
#semakan td, #semakan th {
|
||||
border: 1px solid #ddd;
|
||||
padding: 2px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#semakan tr:nth-child(even){background-color: #ffffff;}
|
||||
|
||||
#semakan tr:hover {background-color: #ddd;}
|
||||
|
||||
#semakan th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 10px;
|
||||
text-align: left;
|
||||
background-color: #4CAF50;
|
||||
color: white;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#salinan {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width:100%;
|
||||
font-size:11px;
|
||||
}
|
||||
|
||||
#salinan td, #salinan th {
|
||||
padding: 2px;
|
||||
}
|
||||
|
||||
|
||||
#salinan tr:nth-child(even){background-color: #ffffff;}
|
||||
|
||||
#salinan tr:hover {background-color: #ffffff;}
|
||||
|
||||
#salinan th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 10px;
|
||||
text-align: right;
|
||||
background-color: #ffffff;
|
||||
color: black;
|
||||
padding:2px;
|
||||
}
|
||||
#perjanjian {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width: 100%;
|
||||
font-size:10px;
|
||||
|
||||
}
|
||||
|
||||
#perjanjian td, #perjanjian th {
|
||||
border: 1px solid #ddd;
|
||||
padding: 2px;
|
||||
font-size:9px;
|
||||
}
|
||||
|
||||
#perjanjian tr:nth-child(even){background-color:#ffffff}
|
||||
|
||||
#perjanjian tr:hover {background-color: #ddd;}
|
||||
|
||||
#perjanjian th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
text-align: center;
|
||||
background-color: #d9deda;
|
||||
color: black;
|
||||
padding:5px;
|
||||
}
|
||||
#keuntungan {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width: 100%;
|
||||
font-size:10px;
|
||||
|
||||
}
|
||||
|
||||
#keuntungan td, #keuntungan th {
|
||||
border: 1px solid #ddd;
|
||||
padding: 2px;
|
||||
font-size:9px;
|
||||
}
|
||||
|
||||
#keuntungan tr:nth-child(even){background-color: #ffffff;}
|
||||
|
||||
#keuntungan tr:hover {background-color: #ddd;}
|
||||
|
||||
#keuntungan th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
text-align: center;
|
||||
background-color: #d9deda;
|
||||
color: black;
|
||||
padding:2px;
|
||||
}
|
||||
|
||||
#payment {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width: 45%;
|
||||
font-size:10px;
|
||||
border: 1px solid black;
|
||||
|
||||
}
|
||||
|
||||
#payment td, #payment th {
|
||||
border: 0px solid;
|
||||
padding: 3px;
|
||||
font-size:9px;
|
||||
text-align: left;
|
||||
|
||||
}
|
||||
|
||||
#payment tr:nth-child(even){background-color: #ffffff;}
|
||||
|
||||
#payment tr:hover {background-color: #ddd;}
|
||||
|
||||
#payment th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
text-align:left;
|
||||
background-color: #d9deda;
|
||||
color: black;
|
||||
padding:2px;
|
||||
}
|
||||
|
||||
#payment {
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
|
||||
#akuan td, #akuan th {
|
||||
padding: 7px;
|
||||
font-size:9px;
|
||||
padding:4px;
|
||||
}
|
||||
|
||||
#akuan tr:nth-child(even){background-color:#ffffff;}
|
||||
|
||||
#akuan tr:hover {background-color: #ddd;}
|
||||
|
||||
#akuan th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
text-align: center;
|
||||
background-color: #d9deda;
|
||||
color: black;
|
||||
padding:3px;
|
||||
}
|
||||
.page-break{
|
||||
page-break-before:always;
|
||||
}
|
||||
|
||||
.formula{
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size:12px;
|
||||
}
|
||||
|
||||
#copy_cust {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width:10%;
|
||||
font-size:10px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
#copy_cust tr:nth-child(even){background-color: #ffffff;}
|
||||
|
||||
#copy_cust tr:hover {background-color:#ffffff}
|
||||
|
||||
#copy_cust th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
text-align: center;
|
||||
background-color: #d9deda;
|
||||
color: black;
|
||||
padding:4px;
|
||||
}
|
||||
|
||||
|
||||
#copy_cust {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
border-collapse:collapse;
|
||||
width: 50%;
|
||||
font-size:10px;
|
||||
|
||||
|
||||
}
|
||||
|
||||
#copy_cust td, #copy_cust th {
|
||||
border: 1px solid #ddd;
|
||||
padding: 2px;
|
||||
font-size:9px;
|
||||
text-align:right;
|
||||
width: 10%;
|
||||
|
||||
}
|
||||
|
||||
#copy_cust {
|
||||
margin-right:0px;margin-left:auto
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#inside tr:nth-child(even){background-color: #ffffff;}
|
||||
|
||||
#inside tr:hover {background-color: #ddd;}
|
||||
|
||||
#inside th {
|
||||
padding-top: 12px;
|
||||
padding-bottom: 12px;
|
||||
text-align: center;
|
||||
background-color: #d9deda;
|
||||
color: black;
|
||||
padding:4px;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<table>
|
||||
|
||||
<td rowspan="4" style="width:50px;"> <img src="{{ asset('img/ARRAHN1.png') }}" style="width:50px" alt="User Image" class="center" > </td>
|
||||
<td rowspan="4" style="width:50px;"><img src="{{ asset('img/pkb.png') }}" style="width:50px" alt="User Image" class="center" > </td>
|
||||
|
||||
|
||||
|
||||
|
||||
</table>
|
||||
|
||||
<table id="cust">
|
||||
<tr>
|
||||
<th style="width:5px;"> Salinan Pelanggan</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:5px;"> RESIT BAYARAN </td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
|
||||
<br>
|
||||
|
||||
<table id="inside">
|
||||
|
||||
<tr>
|
||||
<td colspan="3">Marhun</td> <td>: {{ $gadai['marhun'] }} </td> <td colspan="3"> </td> <td> </td><td> </td><td> No SAG</td><td> {{ $gadai['norujukan'] }} </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3">Nama</td> <td>: {{ $customers_info['nama'] }} </td> <td colspan="3"> </td> <td> </td><td> </td><td> Tarikh Bayar</td><td>@php $time = new DateTime($penebusan['t_tebus']); $date = $time->format('n/j/Y'); echo $date; @endphp</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="3">No K/P </td> <td>: {{ $customers_info['kpbaru'] }} </td> <td colspan="3"> </td> <td> </td><td> </td><td> Tempoh Simpan</td><td> {{ $gadai['tempoh'] }} </td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="3">Nama Wakil </td> <td>: @php if(sizeof($wakil) != 0){ echo $wakil['NAMA'];} else echo ''; @endphp </td> <td colspan="3"> </td> <td> </td><td> </td><td> </td><td> </td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="3">No K/P Wakil </td> <td>: @php if(sizeof($wakil) != 0) echo $wakil['NOKP']; else echo ''; @endphp </td> <td colspan="3"> </td> <td> </td><td> </td><td> </td><td> </td>
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
|
||||
|
||||
<table id="payment">
|
||||
|
||||
<tr>
|
||||
<td style="width:10px"> Tarikh Bayaran</td><td style="width:5px"> </td><td style="width:10px">@php $time = new DateTime($penebusan['t_tebus']); $date = $time->format('n/j/Y'); echo $date; @endphp</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:10px">Pembiayaan</td><td style="width:5px"> </td><td style="width:10px">RM {{ number_format(($gadai['pinjaman']),2) }} </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:10px">Jumlah Upah</td><td style="width:5px"> </td><td style="width:10px">RM {{ number_format($penebusan['bakiupah'],2) }} </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:10px"><b>Tebus Keseluruhan</b></td><td style="width:5px"> </td><td style="width:10px">RM {{ number_format(($gadai['pinjaman'] + $penebusan['bakiupah']),2) }}</td>
|
||||
</tr>
|
||||
|
||||
|
||||
</table>
|
||||
|
||||
<br>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<table id="semakan">
|
||||
<tr>
|
||||
<td colspan="3">.................................................... </td>
|
||||
<td></td>
|
||||
<td colspan="3">.................................................... </td>
|
||||
<td></td>
|
||||
<td colspan="3">.................................................... </td>
|
||||
<td></td>
|
||||
<td colspan="3">.................................................... </td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
<td colspan="3">DiSemak </td>
|
||||
<td></td>
|
||||
<td colspan="3"> Cagaran Di Keluarkan</td>
|
||||
<td></td>
|
||||
<td colspan="3">Cagaran Diterima </td>
|
||||
<td></td>
|
||||
<td colspan="3"> Ar-Rahn</td>
|
||||
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
<br>
|
||||
<hr class="new2"></hr>
|
||||
|
||||
<br>
|
||||
<br>
|
||||
|
||||
</table>
|
||||
|
||||
|
||||
<table id="cust">
|
||||
<tr>
|
||||
<th style="width:5px;"> Salinan Pejabat</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:5px;"> RESIT BAYARAN </td>
|
||||
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
|
||||
<br>
|
||||
<table id="inside">
|
||||
|
||||
<tr>
|
||||
<td colspan="3">Marhun</td> <td>: {{ $gadai['marhun'] }} </td> <td colspan="3"> <t/d> <td> </td><td> </td><td> No SAG</td><td> {{ $gadai['norujukan'] }} </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3">Nama</td> <td>: {{ $customers_info['nama'] }} </td> <td colspan="3"> <t/d> <td> </td><td> </td><td> Tarikh Bayar</td><td> @php $time = new DateTime($penebusan['t_tebus']); $date = $time->format('n/j/Y'); echo $date; @endphp </td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="3">No K/P </td> <td>: {{ $customers_info['kpbaru'] }} </td> <td colspan="3"> <t/d> <td> </td><td> </td><td> Tempoh Simpan</td><td> {{ $gadai['tempoh'] }} </td>
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
<tr>
|
||||
<td colspan="3">Nama Wakil </td> <td>: @php if(sizeof($wakil) != 0){ echo $wakil['NAMA'];} else echo ''; @endphp </td> <td colspan="3"> <t/d> <td> </td><td> </td><td> </td><td> </td>
|
||||
</tr>
|
||||
|
||||
|
||||
<tr>
|
||||
<td colspan="3">No K/P Wakil </td> <td>: @php if(sizeof($wakil) != 0) echo $wakil['NOKP']; else echo ''; @endphp</td> <td colspan="3"> <td> </td><td> </td><td> </td><td> </td>
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
|
||||
|
||||
<table id="payment">
|
||||
|
||||
<tr>
|
||||
<td style="width:10px"> Tarikh Bayaran</td><td style="width:5px"> </td><td style="width:10px">@php $time = new DateTime($penebusan['t_tebus']); $date = $time->format('n/j/Y'); echo $date; @endphp</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:10px">Pembiayaan</td><td style="width:5px"> </td><td style="width:10px">RM {{ number_format(($gadai['pinjaman']),2) }} </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:10px">Jumlah Upah</td><td style="width:5px"> </td><td style="width:10px">RM {{ number_format($penebusan['bakiupah'],2) }} </td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:10px"><b>Tebus Keseluruhan</b></td><td style="width:5px"> </td><td style="width:10px">RM {{ number_format(($gadai['pinjaman'] + $penebusan['bakiupah']),2) }}</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
|
||||
<br>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<table id="semakan">
|
||||
<tr>
|
||||
<td colspan="3">.................................................... </td>
|
||||
<td></td>
|
||||
<td colspan="3">.................................................... </td>
|
||||
<td></td>
|
||||
<td colspan="3">.................................................... </td>
|
||||
<td></td>
|
||||
<td colspan="3">.................................................... </td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
||||
<td colspan="3">DiSemak </td>
|
||||
<td></td>
|
||||
<td colspan="3"> Cagaran Di Keluarkan</td>
|
||||
<td></td>
|
||||
<td colspan="3">Cagaran Diterima </td>
|
||||
<td></td>
|
||||
<td colspan="3"> Ar-Rahn</td>
|
||||
|
||||
|
||||
</tr>
|
||||
</table>
|
||||
<br>
|
||||
@@ -111,26 +111,21 @@
|
||||
|
||||
<script>
|
||||
|
||||
// // Enable pusher logging - don't include this in production
|
||||
// Pusher.logToConsole = true;
|
||||
// Enable pusher logging - don't include this in production
|
||||
Pusher.logToConsole = true;
|
||||
|
||||
// var pusher = new Pusher('26b0ec2f297f94b7aa9b', {
|
||||
// cluster: 'ap1',
|
||||
// encrypted: true
|
||||
// });
|
||||
var pusher = new Pusher('26b0ec2f297f94b7aa9b', {
|
||||
cluster: 'ap1',
|
||||
encrypted: true
|
||||
});
|
||||
|
||||
// var channel = pusher.subscribe('status-liked');
|
||||
// channel.bind('my-event', function(data) {
|
||||
// let message = JSON.stringify(data);
|
||||
var channel = pusher.subscribe('status-liked');
|
||||
channel.bind('my-event', function(data) {
|
||||
let message = JSON.stringify(data);
|
||||
|
||||
// alert(message);
|
||||
// });
|
||||
|
||||
function trigtest()
|
||||
{
|
||||
pusher.bind();
|
||||
}
|
||||
|
||||
console.log(data);
|
||||
console.log(message);
|
||||
});
|
||||
|
||||
</script>
|
||||
</html>
|
||||
|
||||
+15
-5
@@ -15,14 +15,14 @@ use Illuminate\Support\Facades\Route;
|
||||
|
||||
Route::get('/',['as'=>'login','uses'=>'HomeController@index']);
|
||||
|
||||
Route::get('/welcome',function(){
|
||||
Route::get('/testtry',function(){
|
||||
|
||||
return view('welcome');
|
||||
return view('test');
|
||||
});
|
||||
|
||||
//Testing Jer
|
||||
Route::get('test', function () {
|
||||
event(new App\Events\StatusLiked('Someone'));
|
||||
event(new App\Events\StatusLiked('KOK LANAS'));
|
||||
return "Event has been sent!";
|
||||
});
|
||||
|
||||
@@ -37,7 +37,7 @@ Route::get('test', function () {
|
||||
|
||||
Route::get('/welcome',function(){
|
||||
|
||||
return view('test');
|
||||
return view('print.resittebus');
|
||||
});
|
||||
|
||||
|
||||
@@ -126,7 +126,13 @@ Route::post('/createpanjar',['as'=>'khazanah.createpanjar','uses'=>'KhazanahCont
|
||||
Route::get('/gadaian/edit/{norujukan}',['as'=>'gadaian.edit','uses'=>'GadaianController@edit'])->middleware('auth','teller');
|
||||
Route::post('/gadai/edit/store',['as'=>'gadai.editstore','uses'=>'GadaianController@editstore'])->middleware('auth','teller');
|
||||
Route::put('/gadai/edit/deletemarhun',['as'=>'gadai.editmarhun','uses'=>'GadaianController@editmarhun'])->middleware('auth','teller');
|
||||
Route::put('/gadai/edit/editmarhun',['as'=>'gadai.ubahmarhun','uses'=>'GadaianController@ubahmarhun'])->middleware('auth','teller');
|
||||
Route::get('/gadai/edit/editmarhun',['as'=>'gadai.ubahmarhun','uses'=>'GadaianController@ubahmarhun'])->middleware('auth','teller');
|
||||
|
||||
//Ubah dan Hapus
|
||||
Route::get('/getkelulu',['as'=>'teller.getkelulusan','uses'=>'GadaianController@getkelulusan'])->middleware('auth','teller');
|
||||
Route::post('/createkelulu',['as'=>'teller.createkelulusan','uses'=>'GadaianController@createkelulusan'])->middleware('auth','teller');
|
||||
Route::put('/updatekelulu',['as'=>'teller.updatekelulusan','uses'=>'GadaianController@updatekelulusan'])->middleware('auth','khazanah');
|
||||
|
||||
|
||||
//Laporan Baru
|
||||
Route::get('/laporan/lelongan',['as'=>'laporan.lelongan','uses'=>'KhazanahController@laporanLelongan'])->middleware('auth','khazanah');
|
||||
@@ -150,7 +156,11 @@ Route::get('laporan/ringkasanterkumpul/cetak',['as'=>'ringkasanterkumpul.laporan
|
||||
|
||||
//Resit Ansurans
|
||||
Route::get('/resit/{id}',['as'=>'resit.ansuran','uses'=>'GadaianController@resit'])->middleware('auth','teller');
|
||||
Route::get('/resitansurans/{id}',['as'=>'resit.ansurans','uses'=>'GadaianController@resitansurans'])->middleware('auth','teller');
|
||||
Route::get('/resitbelumansurans/{id}',['as'=>'resit.belumansurans','uses'=>'GadaianController@resitbelumansurans'])->middleware('auth','teller');
|
||||
Route::get('/resit/tebus/{id}',['as'=>'resit.tebus','uses'=>'GadaianController@resittebus'])->middleware('auth','teller');
|
||||
Route::get('/resit/belumtebus/{id}',['as'=>'resit.belumtebus','uses'=>'GadaianController@resitbelumtebus'])->middleware('auth','teller');
|
||||
|
||||
|
||||
Route::post('/barcodescanned',['as'=>'barcode.scanned','uses'=>'KhazanahController@barcodescanned'])->middleware('auth','khazanah');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user