diff --git a/app/Http/Controllers/CallCenterController.php b/app/Http/Controllers/CallCenterController.php index e2f15c7..012be90 100644 --- a/app/Http/Controllers/CallCenterController.php +++ b/app/Http/Controllers/CallCenterController.php @@ -433,7 +433,7 @@ class CallCenterController extends Controller // $notis = Notis::select('tarikh_notis','id') // ->groupBy('tarikh_notis') // ->get(); - $notis = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/senarainotisperingatan')->json(); + $notis = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/senarainotisperingatankedua')->json(); // dd($notis); foreach($notis as $info) { @@ -583,5 +583,219 @@ class CallCenterController extends Controller return view('callcenter.detailnotisperingatankedua',compact('detailnotis','senarai','notisid')); } + public function kemaskininotisperingatanbycaw($kodcaw,$notisid) + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + + $senarai = []; + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $kodcaw)->json(); + $bycawnotisperingatan = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/bycawnotisperingatan/'.$kodcaw.'/'.$notisid)->json(); + $kemaskininotisperingatan = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url'). '/arcc/kemaskininotisperingatan', [ + 'kodcaw' => $kodcaw, + 'notisid' => $notisid + ])->json(); + if($kemaskininotisperingatan == 'success'){ + return view('callcenter.bycawdetailnotisperingatan',compact('cawangan_info','bycawnotisperingatan','kodcaw','notisid')); + // return redirect()->route('arcc.detailnotisperingatan',['notisid' => $notisid]) + // ->with('success','Data Telah Dikemaskini.'); + }elseif($kemaskininotisperingatan == 'failed'){ + return redirect()->route('arcc.detailnotisperingatan',['notisid' => $notisid]) + ->with('failed','Data Tidak Dikemaskini. Sila Semak Semula...'); + } + + // return view('callcenter.bycawdetailnotisperingatan',compact('cawangan_info','bycawnotisperingatan','kodcaw','notisid')); + } + + public function kemaskininotisperingatankeduabycaw($kodcaw,$notisid) + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + + $senarai = []; + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $kodcaw)->json(); + $bycawnotisperingatankedua = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/bycawnotisperingatankedua/'.$kodcaw.'/'.$notisid)->json(); + $kemaskininotisperingatan = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url'). '/arcc/kemaskininotisperingatan', [ + 'kodcaw' => $kodcaw, + 'notisid' => $notisid + ])->json(); + if($kemaskininotisperingatan == 'success'){ + return view('callcenter.bycawdetailnotisperingatankedua',compact('cawangan_info','bycawnotisperingatankedua','kodcaw','notisid','api_url')); + }elseif($kemaskininotisperingatan == 'failed'){ + return redirect()->route('arcc.detailnotisperingatankedua',['notisid' => $notisid]) + ->with('failed','Data Tidak Dikemaskini. Sila Semak Semula...'); + } + } + + public function notisJbg(){ + $api_url = config('api.url'); + $auth_user = Auth::user(); + $caw = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json(); + //dd('sini'); + return view('callcenter.cariangadaian',compact('api_url','caw')); + } + + public function carianJbg(Request $request){ + $current = Carbon::now(); + $current = new Carbon(); + $api_url = config('api.url'); + $auth_user = Auth::user(); + $jbgmula = $request->jbgmula; + $jbghingga = $request->jbghingga; + $tprint = $current->toDateString(); + + $caw_all = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/arcc/cawangan/')->json(); + $senarai = []; + foreach($caw_all as $cwgn) + { + $kodcaw = $cwgn['kodcaw']; + $datagadai = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url').'/arcc/gadaian/'.$kodcaw,[ + 'jbgmula' => $request->jbgmula, + 'jbghingga' => $request->jbghingga, + ])->json(); + + $data = [ + 'kodcaw'=>$cwgn['kodcaw'], + 'caw_name'=>$cwgn['details_caw'], + 'datagadai'=>$datagadai ? $datagadai : '', + ]; + array_push($senarai,$data); + } + // dd(1); + return view('callcenter.gadaianjbg', compact('kodcaw','senarai','jbgmula','jbghingga')); + } + + public function janadatanotisjbg(Request $request){ + $current = Carbon::now(); + $current = new Carbon(); + $currentNow = Carbon::now(); + $senarai = []; + $tarikh_savedaftarnotis = $current->toDateString(); + $jbgmula = $request->jbgmula; + $jbghingga = $request->jbghingga; + $kodcaw = $request->kodcaw; + $selected_caw = $request->caw; + // dd($selected_caw); + + $getbatchnotisjbg=Http::withOptions(['verify' => config('app.api_verify')])->get( config('api.url').'/arcc/getbatchnotisjbg',[ + 'jbgmula' => $jbgmula, + 'jbghingga' => $jbghingga, + ])->json(); + + $newbatchnotis=$getbatchnotisjbg; + + if(!empty($selected_caw)) + { + foreach($selected_caw as $index=>$caw){ + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $caw)->json(); + // dd($cawangan_info); + $insertdatagadai = Http::withOptions(['verify' => config('app.api_verify')])->post(config('api.url').'/arcc/insertdatagadaijbg/'.$caw ,[ + 'jbgmula' => $jbgmula, + 'jbghingga' => $jbghingga, + 'kodcaw' => $caw, + 'notisid' => $newbatchnotis + ])->json(); + + $data = [ + 'kodcaw'=>$caw, + 'caw_name'=>$cawangan_info['details_caw'], + 'datagadai' => $insertdatagadai ? $insertdatagadai : '', + ]; + + array_push($senarai,$data); + } + } + return redirect()->route('arcc.notisjbg')->with('success','Berjaya Daftar Notis Jbg.'); + } + + public function rekodnotisjbg(){ + $auth_user = Auth::user(); + $api_url = config('api.url'); + + $arrayinfo = []; + + // $notis = Notis::select('tarikh_notis','id') + // ->groupBy('tarikh_notis') + // ->get(); + $notisjbg = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/senarainotisjbg')->json(); + // dd($notisjbg); + foreach($notisjbg as $info) + { + $getcawnotisjbg = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/getcawnotisjbg/'.$info['id'])->json(); + + array_push($arrayinfo, ['info'=> $info,'cawnotis' => $getcawnotisjbg]); + } + // dd($arrayinfo); + return view('callcenter.rekodnotisjbg',compact('notisjbg','arrayinfo')); + } + + public function detailnotisjbg(Request $request){ + $auth_user = Auth::user(); + $api_url = config('api.url'); + + $senarai = []; + $notisid = $request->notisid; + + $detailnotisjbg = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/getcawnotisjbg/'.$notisid)->json(); + //dd($detailnotisjbg[0]); + foreach($detailnotisjbg as $info) + { + $getcawnotisjbgbycaw = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/getcawnotisjbgbycaw', [ + 'kodcaw' => $info[0]['kodcaw'], + 'notisid' => $notisid + ])->json(); + //dd($getcawnotisjbgbycaw); + $data = [ + // 'kodcaw'=>$info[0]['kodcaw'], + // 'caw_name'=>$info[0]['details_caw'], + 'getcawnotisjbgbycaw' => $getcawnotisjbgbycaw ? $getcawnotisjbgbycaw : '', + ]; + + array_push($senarai,$data); + } + + return view('callcenter.detailnotisjbg',compact('detailnotisjbg','senarai','notisid')); + } + + public function bycawnotisjbg($kodcaw,$notisid, Request $request) + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $kodcaw)->json(); + $bycawnotisjbg = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/bycawnotisjbg/'.$kodcaw.'/'.$notisid)->json(); + + return view('callcenter.bycawdetailnotisjbg',compact('cawangan_info','bycawnotisjbg','kodcaw','notisid')); + } + + public function detsagcallbyjbg($kodcaw, $notisid, $id) + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $kodcaw)->json(); + $bysagnotisjbg = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/arcc/bysagnotisjbg/'.$kodcaw.'/'.$notisid.'/'.$id)->json(); + $bysagnotisjbgCustomer = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/arcc/bysagnotisjbgcustomer/'.$kodcaw.'/'.$notisid.'/'.$id)->json(); + return view('callcenter.callnotisjbg',compact('cawangan_info','bysagnotisjbg','bysagnotisjbgCustomer')); + } + + public function bycawnotisjbg2($kodcaw,$notisid, Request $request) + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $kodcaw)->json(); + $bycawnotisjbg = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/bycawnotisjbg2/'.$kodcaw.'/'.$notisid)->json(); + return view('callcenter.bycawdetailnotisjbg2',compact('cawangan_info','bycawnotisjbg','kodcaw','notisid')); + } + + public function detsagcallbyjbg2($kodcaw, $notisid, $nokp) + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $kodcaw)->json(); + $bysagnotisjbg = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/arcc/bysagnotisjbg2/'.$kodcaw.'/'.$notisid.'/'.$nokp)->json(); + $bysagnotisjbgCustomer = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/arcc/bysagnotisjbgcustomer2/'.$kodcaw.'/'.$notisid.'/'.$nokp)->json(); + // dd($bysagnotisjbg); + return view('callcenter.callnotisjbg2',compact('cawangan_info','bysagnotisjbg','bysagnotisjbgCustomer','kodcaw','notisid','nokp','api_url')); + } + } diff --git a/app/Http/Controllers/KhazanahController.php b/app/Http/Controllers/KhazanahController.php index f83e488..71fa190 100644 --- a/app/Http/Controllers/KhazanahController.php +++ b/app/Http/Controllers/KhazanahController.php @@ -4427,6 +4427,72 @@ class KhazanahController extends Controller } } + public function notisperingatan(Request $request){ + $auth_user = Auth::user(); + $api_url = config('api.url'); + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'. $auth_user['cawangan'])->json(); + + return view('callcenter.khazanah.notisperingatan',compact('cawangan_info','api_url')); + } + + public function rekodnotisperingatanpertama() + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + + $arrayinfo = []; + + $notis = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/api/cawangan/senarainotisperingatan/'. $auth_user['cawangan'])->json(); + // dd($notis ); + foreach($notis as $info) + { + $getcawnotis = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/api/cawangan/getcawnotis/'. $auth_user['cawangan'].'/'.$info['notis_id'])->json(); + // dd($getcawnotis); + array_push($arrayinfo, ['info'=> $info,'cawnotis' => $getcawnotis]); + } + return view('callcenter.khazanah.rekodnotisperingatanpertama',compact('notis','arrayinfo')); + } + + public function detailnotisperingatan() + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + $kodcaw = $auth_user['cawangan']; + $senarai = []; + + $detailnotis = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/api/cawangan/getcawnotisall/'. $auth_user['cawangan'])->json(); + // dd($detailnotis); + foreach($detailnotis as $info) + { + // $getcawnotisbycaw = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/arcc/getcawnotisbycaw', [ + // 'kodcaw' => $info[0]['kodcaw'], + // 'notisid' => $notisid + // ])->json(); + + $data = [ + // 'detailnotis' => $info ? $info : '', + 'getcawnotisbycaw' => $info ? $info : '', + ]; + + array_push($senarai,$data); + // dd($data); + } + return view('callcenter.khazanah.detailnotisperingatan',compact('detailnotis','senarai','kodcaw')); + } + + public function bycawnotisperingatan($kodcaw,$notisid, Request $request) + { + $auth_user = Auth::user(); + $api_url = config('api.url'); + $kodcaw = $auth_user['cawangan']; + $cawangan_info = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url') . '/api/cawangan/'.$auth_user['cawangan'])->json(); + $bycawnotisperingatan = Http::withOptions(['verify' => config('app.api_verify')])->get(config('api.url'). '/api/cawangan/bycawnotisperingatan/'.$auth_user['cawangan'].'/'.$notisid)->json(); + + return view('callcenter.khazanah.bycawdetailnotisperingatan',compact('cawangan_info','bycawnotisperingatan','kodcaw','notisid','api_url')); + } + + + } diff --git a/resources/views/callcenter/bycawdetailnotisjbg2.blade.php b/resources/views/callcenter/bycawdetailnotisjbg2.blade.php new file mode 100644 index 0000000..3422817 --- /dev/null +++ b/resources/views/callcenter/bycawdetailnotisjbg2.blade.php @@ -0,0 +1,328 @@ +@extends('layouts.app_callcenter') + + + + +@section('content') +
+
+
+
+ + +
+
+
+
+
+
+
+ @if ($message = Session::get('success')) +
+

{{ $message }}

+
+ @elseif ($message = Session::get('failed')) +
+

{{ $message }}

+
+ @endif + +
+ +
+ @csrf + + + + + + + + + + + + + + + + + + + + + + + + @php + $counter = 1; + $totalpinjaman = 0; + @endphp + + @foreach ($bycawnotisjbg['rekod'] as $index => $item) + @php + $totalpinjaman += $item['listsag'][0]['pinjaman']; + + if ($item['listnotis'][0]['statuscall'] == 0) { + $status = 'Belum Hubungi'; + } elseif ($item['listnotis'][0]['statuscall'] == 1) { + $status = 'Berjaya Hubungi'; + } else { + $status = 'Tidak Dapat Hubungi'; + } + + $nota = $item['listnotis'][0]['remark1']; + @endphp + + + + + + @php + $nokp = $item['info']['kpbaru'] ?? $item['info']['kplama']; + @endphp + + + + + + + + + + + + + + + + + @php $counter++; @endphp + @endforeach +
BilStatusNamaNo. KPNo. TelefonNorujukanTempohBaki Pembiayaan (RM)Keuntungan 6Bulan (RM)Amaun Telah Bayar (RM)Keuntungan Semasa (RM)Tarikh MatangTarikh Tamat KontrakTarikh PanggilanNotaTindakan
{{ $loop->iteration }}{{ $status ?? '-' }}{{ $item['info']['nama'] ?? '-' }}{{ $nokp }}{{ $item['info']['telefon'] ?? '-' }}@foreach($item['listsag'] as $item1){{ $item1['norujukan']}}
@endforeach
@foreach($item['listsag'] as $item1){{ $item1['jbg']}}
@endforeach
@foreach($item['listsag'] as $item1){{number_format($item1['bakipjm'], 2, '.', ',')}}
@endforeach
@foreach($item['listsag'] as $item1){{number_format($item1['bakiupah'], 2, '.', ',')}}
@endforeach
@foreach($item['listsag'] as $item1){{number_format($item1['hargajualan']-$item1['bakihargajualan'], 2, '.', ',')}}
@endforeach
@foreach($item['listsag'] as $item1){{number_format($item1['keuntungan'], 2, '.', ',')}}
@endforeach
@foreach($item['listsag'] as $item1) + @if($item1['t_matang'] == null) + + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item1['t_matang']); + $formattedtmatang = $myDateTime->format('d-m-Y'); + echo($formattedtmatang); + @endphp + @endif +
+ @endforeach +
+
@foreach($item['listsag'] as $item1) + @if($item1['t_matang1'] == null) + + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item1['t_matang1']); + $formattedtmatang1 = $myDateTime->format('d-m-Y'); + echo($formattedtmatang1); + @endphp + @endif +
+ @endforeach +
+
@foreach($item['listnotis'] as $item1) + @if($item1['tarikhcall1'] == null) + + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item1['tarikhcall1']); + $formattedweddingdate = $myDateTime->format('d-m-Y'); + echo($formattedweddingdate); + @endphp + @endif +
+ @endforeach +
+
{{$nota ?? ' '}} + + @if ($item['listnotis'][0]['statuscall'] == 0 || $item['listnotis'][0]['statuscall'] == 9) + Hubungi + + @else + - + @endif + +
+
+
+ + + +
+
+
+
+
+ + + + + +@endsection \ No newline at end of file diff --git a/resources/views/callcenter/callnotisjbg2.blade.php b/resources/views/callcenter/callnotisjbg2.blade.php new file mode 100644 index 0000000..4ff3478 --- /dev/null +++ b/resources/views/callcenter/callnotisjbg2.blade.php @@ -0,0 +1,301 @@ +@extends('layouts.app_callcenter') + +@section('content') +
+
+
+ + +
+ @csrf + + + + + +
+
+
+
+ Nama +
+
+ +
+
+
+
+
+
+ No Kad Pengenalan +
+
+ @php + if($bysagnotisjbgCustomer['kpbaru'] != null){ + $noic = $bysagnotisjbgCustomer['kpbaru']; + }else{ + $noic = $bysagnotisjbgCustomer['kplama']; + } + @endphp + +
+
+
+
+ +
+
+ No Telefon +
+
+ +
+
+ +
+
+ Status Panggilan +
+
+ + + +
+
+ +
+ +
+ +
+
+ Alamat +
+
+ +
+
+ +
+
+ Nota +
+
+ @foreach($bysagnotisjbg['getstatusremark'] as $index => $remark) + + @endforeach +
+
+ +
+
+ +
+
+
+ + + + + + + + + + + + + + + + + + @php + $counter = 1; + $totalpinjaman = 0; + @endphp + @foreach ($bysagnotisjbg['rekodnotis'] as $index => $item) + @php + $totalpinjaman += $item['listsag'][0]['pinjaman']; + + if ($item['listnotis'][0]['tarikhcall1'] == null) { + $status = 'Belum'; + } else { + $status = 'Selesai'; + } + @endphp + + + + + + + + + + + + + + + + + @php $counter++; @endphp + @endforeach +
BilNorujukanTempohBaki Pembiayaan (RM)Keuntungan 6Bulan (RM)Amaun Telah Bayar (RM)Keuntungan Semasa (RM)Tarikh MatangTarikh Tamat KontrakTarikh PanggilanNota
@foreach($item['listsag'] as $item1){{ $loop->iteration }}
@endforeach
@foreach($item['listsag'] as $item1){{ $item1['norujukan']}}
@endforeach
@foreach($item['listsag'] as $item1){{ $item1['jbg']}}
@endforeach
@foreach($item['listsag'] as $item1){{number_format($item1['bakipjm'], 2, '.', ',')}}
@endforeach
@foreach($item['listsag'] as $item1){{number_format($item1['bakiupah'], 2, '.', ',')}}
@endforeach
@foreach($item['listsag'] as $item1){{number_format($item1['hargajualan']-$item1['bakihargajualan'], 2, '.', ',')}}
@endforeach
@foreach($item['listsag'] as $item1){{number_format($item1['keuntungan'], 2, '.', ',')}}
@endforeach
@foreach($item['listsag'] as $item1) + @if($item1['t_matang'] == null) + + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item1['t_matang']); + $formattedtmatang = $myDateTime->format('d-m-Y'); + echo($formattedtmatang); + @endphp + @endif +
+ @endforeach +
+
@foreach($item['listsag'] as $item1) + @if($item1['t_matang1'] == null) + + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item1['t_matang1']); + $formattedtmatang1 = $myDateTime->format('d-m-Y'); + echo($formattedtmatang1); + @endphp + @endif +
+ @endforeach +
+
@foreach($item['listnotis'] as $item1) + @if($item1['tarikhcall1'] == null) + + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item1['tarikhcall1']); + $formattedweddingdate = $myDateTime->format('d-m-Y'); + echo($formattedweddingdate); + @endphp + @endif +
+ @endforeach +
+
@foreach($item['listnotis'] as $item1){{ $item1['remark1']}}
@endforeach
+
+
+
+
+
+ +
+
+
+
+ + + + +@endsection \ No newline at end of file diff --git a/resources/views/callcenter/detailnotisperingatan.blade.php b/resources/views/callcenter/detailnotisperingatan.blade.php index 199f73c..df960cf 100644 --- a/resources/views/callcenter/detailnotisperingatan.blade.php +++ b/resources/views/callcenter/detailnotisperingatan.blade.php @@ -144,13 +144,16 @@ @if($item['namacaw'][$index]['status'] == 2) @endif{{$item['namacaw'][$index]['details_caw']}} - {{$item['totalsag']}} - {{number_format($item['totalbakipjm'],2)}} - Lihat + @if($item['totalsag'] == 0){{$item['totalsag']}}@else {{$item['totalsag']}}@endif/{{$item['totalsagall']}} + @if($item['totalsag'] == 0){{number_format($item['totalbakipjm'],2)}}@else {{number_format($item['totalbakipjm'],2)}}@endif + + {{-- Lihat --}} + Kemaskini @endforeach +
*jika bilangan berkurang bermaksud telah masuk ke Notis Peringatan Kedua
diff --git a/resources/views/callcenter/detailnotisperingatankedua.blade.php b/resources/views/callcenter/detailnotisperingatankedua.blade.php index 4dbc646..32abc69 100644 --- a/resources/views/callcenter/detailnotisperingatankedua.blade.php +++ b/resources/views/callcenter/detailnotisperingatankedua.blade.php @@ -143,10 +143,13 @@ {{ $loop->iteration }} {{$item['namacaw'][$index]['details_caw']}} - {{$item['totalsag']}} - {{number_format($item['totalbakipjm'],2)}} - Lihat - + @if($item['totalsag'] == 0){{$item['totalsag']}}@else {{$item['totalsag']}}@endif/{{$item['totalsagall']}} + @if($item['totalsag'] == 0){{number_format($item['totalbakipjm'],2)}}@else {{number_format($item['totalbakipjm'],2)}}@endif + + {{-- Lihat --}} + Kemaskini + +Notis JBG @endforeach diff --git a/resources/views/callcenter/khazanah/bycawdetailnotisperingatan.blade.php b/resources/views/callcenter/khazanah/bycawdetailnotisperingatan.blade.php new file mode 100644 index 0000000..0c2f934 --- /dev/null +++ b/resources/views/callcenter/khazanah/bycawdetailnotisperingatan.blade.php @@ -0,0 +1,321 @@ +@extends('layouts.app_operasi') + + + + +@section('content') +
+
+
+
+ + +
+
+
+
+
+
+
+ @if ($message = Session::get('success')) +
+

{{ $message }}

+
+ @elseif ($message = Session::get('failed')) +
+

{{ $message }}

+
+ @endif + +
+ +
+ {{-- --}} + + @csrf + + + + + @php + $getfasa = Http::withOptions(['verify' => config('app.api_verify')]) + ->get($api_url . '/arcc/getfasa', ['kodcaw' => $kodcaw, 'notisid' => $notisid]) + ->json(); + @endphp + + + + + + + + + + + + + + + + + + + + + + + + + + {{-- {{dd($bycawnotisperingatankedua)}} --}} + @foreach ($bycawnotisperingatan as $index => $item) + + + + + + + + + + + + + + @endif + + @endif + + @endif + + @endif + + @endif + + @endif + + @endforeach +
BilNo.RujukanNamaNo.KPNo.TelefonTempohBaki Pembiayaan (RM)Keuntungan 6Bulan (RM)Amaun Telah Bayar (RM)Keuntungan Semasa (RM)Tarikh MatangTarikh Tamat KontrakT.Notis PertamaT.Notis KeduaTag SuratJenis Notis
{{ $loop->iteration }}{{$item['norujukan']}}{{$item['namacust']['nama'] ?? ''}}{{$item['nokp']}}{{$item['namacust']['telefon'] ?? ''}}{{$item['jbg']}}{{number_format($item['datagadai']['bakipjm'], 2, '.', ',')}}{{number_format($item['datagadai']['bakiupah'], 2, '.', ',')}}{{number_format($item['datagadai']['hargajualan']-$item['datagadai']['bakihargajualan'], 2, '.', ',')}}{{number_format($item['keuntungan'], 2, '.', ',')}} + @if($item['tmatang'] == null) + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item['tmatang']); + $formattedweddingdate = $myDateTime->format('d-m-Y'); + echo($formattedweddingdate); + @endphp + @if($item['tmatang1'] == null) + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item['tmatang1']); + $formattedweddingdate = $myDateTime->format('d-m-Y'); + echo($formattedweddingdate); + @endphp + @if($item['tarikhnotis1'] == null) + + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item['tarikhnotis1']); + $formattedweddingdate = $myDateTime->format('d-m-Y'); + echo($formattedweddingdate); + @endphp + @if($item['tarikhnotis2'] == null) + + @else + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item['tarikhnotis2']); + $formattedweddingdate = $myDateTime->format('d-m-Y'); + echo($formattedweddingdate); + @endphp + @if($item['tagsurat'] == 1) + Selesai + @elseif($item['tagsurat'] == 0) + Belum Hantar + + @if($item['peringatan'] == 1) + Pertama + @elseif($item['peringatan'] == 2) + Kedua +
+
+
+ + + + +
+
+
+
+
+ + + + +@endsection + diff --git a/resources/views/callcenter/khazanah/detailnotisperingatan.blade.php b/resources/views/callcenter/khazanah/detailnotisperingatan.blade.php new file mode 100644 index 0000000..885e27b --- /dev/null +++ b/resources/views/callcenter/khazanah/detailnotisperingatan.blade.php @@ -0,0 +1,251 @@ +@extends('layouts.app_operasi') + + + + +@section('content') +
+
+
+
+ + +
+
+
+
+
+
+
+ @if ($message = Session::get('success')) +
+

{{ $message }}

+
+ @elseif ($message = Session::get('failed')) +
+

{{ $message }}

+
+ @endif + +
+ +
+ @csrf + + + + + + + + + + + {{-- --}} + + + + @foreach ($senarai as $index => $item) + {{-- {{dd($item['getcawnotisbycaw'])}} --}} + + + + + + + {{-- --}} + + + @endforeach +
BilNotis IDCawanganBil.Surat Notis PertamaBil.Surat Notis KeduaBaki Pembiayaan (RM)Maklumat Lanjut
{{ $loop->iteration }}{{$item['getcawnotisbycaw']['namacaw'][$index]['notis_id']}} @if($item['getcawnotisbycaw']['namacaw'][0]['status'] == 2) + + @endif{{$item['getcawnotisbycaw']['namacaw'][$index]['details_caw']}}{{$item['getcawnotisbycaw']['totalsagpertama']}}{{$item['getcawnotisbycaw']['totalsagkedua']}}{{number_format($item['getcawnotisbycaw']['totalbakipjm'],2)}}Lihat +
+
+
+ + + +
+
+
+
+
+ + + + +@endsection + diff --git a/resources/views/callcenter/khazanah/notisperingatan.blade.php b/resources/views/callcenter/khazanah/notisperingatan.blade.php new file mode 100644 index 0000000..39c18b0 --- /dev/null +++ b/resources/views/callcenter/khazanah/notisperingatan.blade.php @@ -0,0 +1,233 @@ +@extends('layouts.app_operasi') + + + + +@section('content') +
+
+
+
+ + +
+
+
+
+
+
+
+ @if ($message = Session::get('success')) +
+

{{ $message }}

+
+ @elseif ($message = Session::get('failed')) +
+

{{ $message }}

+
+ @endif + +
+ + + + + + +
+ + + +
+
+
+
+
+ + + + +@endsection + diff --git a/resources/views/callcenter/khazanah/rekodnotisperingatanpertama.blade.php b/resources/views/callcenter/khazanah/rekodnotisperingatanpertama.blade.php new file mode 100644 index 0000000..8e71098 --- /dev/null +++ b/resources/views/callcenter/khazanah/rekodnotisperingatanpertama.blade.php @@ -0,0 +1,263 @@ +@extends('layouts.app_operasi') + + + + +@section('content') +
+
+
+
+ + +
+
+
+
+
+
+
+ @if ($message = Session::get('success')) +
+

{{ $message }}

+
+ @elseif ($message = Session::get('failed')) +
+

{{ $message }}

+
+ @endif + +
+ +
+ @csrf + + + + + + + + + + + + + @foreach ($arrayinfo as $index => $item) + {{-- {{dd($item['cawnotis'])}} --}} + + + @php + $myDateTime = DateTime::createFromFormat('Y-m-d', $item['info']['tarikh_notis']); + $datez = $myDateTime->format('d-m-Y'); + @endphp + + + + {{-- --}} + + + + @endforeach +
Notis IDTarikh NotisCawanganFasaMaklumat Lanjut
{{ $item['info']['notis_id'] ?? '-' }} {{$datez}}@foreach($item['cawnotis'] as $item1) + @foreach($item1 as $item2) + @if($item2['status'] == 2) + + @endif + {{ $item2['details_caw']}}
+ @endforeach + @endforeach
@if($item['info']['daritempoh'] == '5' ) + 1 + @elseif($item['info']['daritempoh'] == '11' ) + 2 + @endif{{ $item['info']['hinggatempoh'] ?? '-' }} + {{-- Lihat --}} + Lihat
+
+
+ + + +
+
+
+
+
+ + + + +@endsection + diff --git a/resources/views/callcenter/rekodnotisperingatan.blade.php b/resources/views/callcenter/rekodnotisperingatan.blade.php index bd81684..b702cc2 100644 --- a/resources/views/callcenter/rekodnotisperingatan.blade.php +++ b/resources/views/callcenter/rekodnotisperingatan.blade.php @@ -129,7 +129,7 @@ - + @@ -151,7 +151,7 @@ @if($item2['status'] == 2) @endif - {{ $item2['details_caw']}}
+ {{ $item2['details_caw']}} : {{ $item2['bakitotalsag']}}/{{ $item2['totalsag']}}
@endforeach @endforeach {{-- --}} + Lihat + {{-- Kemaskini --}} @endforeach
BilID Notis Tarikh Notis Cawangan Fasa @if($item['info']['daritempoh'] == '5' ) @@ -161,12 +161,13 @@ @endif{{ $item['info']['hinggatempoh'] ?? '-' }} - {{-- Lihat --}} - Kemaskini
+
*jika bilangan berkurang bermaksud telah masuk ke Notis Peringatan Kedua
diff --git a/resources/views/callcenter/rekodnotisperingatankedua.blade.php b/resources/views/callcenter/rekodnotisperingatankedua.blade.php index 5bdeae4..52caab6 100644 --- a/resources/views/callcenter/rekodnotisperingatankedua.blade.php +++ b/resources/views/callcenter/rekodnotisperingatankedua.blade.php @@ -152,7 +152,9 @@ @if($item2['status'] == 3) @endif - {{ $item2['details_caw']}}
+ @if($item2['bakitotalsagkedua'] > 0){{ $item2['details_caw']}} : {{ $item2['bakitotalsagkedua']}}/{{ $item2['totalsag']}} + @else {{ $item2['details_caw']}} : {{ $item2['bakitotalsagkedua']}}/{{ $item2['totalsag']}} + @endif
@endforeach @endforeach @if($item['info']['daritempoh'] == '5' ) @@ -162,7 +164,8 @@ @endif {{-- Lihat --}} - Kemaskini + Lihat + {{-- Kemaskini --}} @endforeach diff --git a/resources/views/customers/v2/info.blade.php b/resources/views/customers/v2/info.blade.php index 1789026..f1c51dc 100644 --- a/resources/views/customers/v2/info.blade.php +++ b/resources/views/customers/v2/info.blade.php @@ -573,7 +573,7 @@ }) .then(historygadaian => { - if(historygadaian === '0' || historygadaian === null || historygadaian.length === 0) { + if(historygadaian == '0' || historygadaian === null || historygadaian.length === 0) { return false; } @@ -1402,14 +1402,23 @@ $.each(data,function(index,bayaran){ var urlroute = '{{ route("resit.ansuran", ":id") }}'; + var bayaranteller; + + if(bayaran['teller'] != 'Online') + bayaranteller = 'KT'; + + if(bayaran['teller'] == 'Online') + bayaranteller = 'ON'; + urlroute = urlroute.replace(':id', bayaran['id']); historybayarandatatable.row.add([ - counter, - bayaran['created_at'], - "RM " + bayaran['duit_masuk'], - 'Cetak' - ]).draw(); - counter = counter + 1; + counter, + bayaran['created_at'], + "RM " + bayaran['duit_masuk'], + bayaranteller, + 'Cetak' + ]).draw(); + counter = counter + 1; }); } @@ -1626,7 +1635,7 @@ let isPS = checkPS(selected.value) - if(isPS){ + if(isPS === true){ Swal.fire({ icon: 'error', title: 'Amaran', diff --git a/resources/views/gadaian/v2/index.blade.php b/resources/views/gadaian/v2/index.blade.php index 92ab7cb..bf19f2b 100644 --- a/resources/views/gadaian/v2/index.blade.php +++ b/resources/views/gadaian/v2/index.blade.php @@ -733,7 +733,24 @@ } }); - function verifyGadai(func){ + function getDataCawangan(){ + + let header = { + 'pragma': 'no-cache', + 'cache-control': 'no-store', + }; + + let kodcaw = $('#kodcaw').val(); + let teller = "{{ Auth::user()->name }}"; + let apiUrl = api_url + '/api/GetCurrentTunai/' + kodcaw + '?kodlaluan=' + teller; + + return fetch(apiUrl, { + header: header, + }) + .then(response => response.json()); + } + + async function verifyGadai(func){ $("#terima_gadai").prop('disabled', true); event.preventDefault(); var kodcaw = $('#kodcaw').val(); @@ -765,21 +782,11 @@ event.preventDefault(); return false; } - $.ajax({ - method: 'get', - url: api_url + '/api/GetCurrentTunai/' + kodcaw, - async: false, - dataType:'json', - data:{ - 'kodlaluan': teller - }, - success:function(data){ - bakiakhir = data.baki; - } - }); + let dataCawangan = await getDataCawangan(); + let bakiAkhir = dataCawangan.baki; - if(bakiakhir < pinjaman){ + if(bakiAkhir < pinjaman){ $("#terima_gadai").prop('disabled', false); Swal.fire({ icon: 'error', diff --git a/resources/views/khazanah/laporan/index.blade.php b/resources/views/khazanah/laporan/index.blade.php index a589684..783684f 100644 --- a/resources/views/khazanah/laporan/index.blade.php +++ b/resources/views/khazanah/laporan/index.blade.php @@ -96,6 +96,9 @@
Serah Marhun Tebus
+
+ Notis Peringatan +
diff --git a/resources/views/khazanah/laporan/rekodblast.blade.php b/resources/views/khazanah/laporan/rekodblast.blade.php index 9a0e561..a95775e 100644 --- a/resources/views/khazanah/laporan/rekodblast.blade.php +++ b/resources/views/khazanah/laporan/rekodblast.blade.php @@ -70,7 +70,7 @@ #details th { padding: 8px; - font-size: 11px; + font-size: 13px; } #details tr:nth-child(even) { @@ -92,7 +92,7 @@ @section('content') -
+
@@ -122,7 +122,7 @@
@endif -
+
@csrf diff --git a/resources/views/khazanah/laporan/rekodblastsms.blade.php b/resources/views/khazanah/laporan/rekodblastsms.blade.php index 57e3ef9..6abf3e3 100644 --- a/resources/views/khazanah/laporan/rekodblastsms.blade.php +++ b/resources/views/khazanah/laporan/rekodblastsms.blade.php @@ -70,7 +70,7 @@ #details th { padding: 8px; - font-size: 11px; + font-size: 13px; } #details tr:nth-child(even) { @@ -92,7 +92,7 @@ @section('content') -
+
@@ -122,7 +122,7 @@
@endif -
+
@csrf diff --git a/resources/views/khazanah/v2/info.blade.php b/resources/views/khazanah/v2/info.blade.php index 3bdb1e4..68cc3a5 100644 --- a/resources/views/khazanah/v2/info.blade.php +++ b/resources/views/khazanah/v2/info.blade.php @@ -1489,6 +1489,15 @@ $.each(data,function(index,gadai_detail){ console.log(xhRequest); } }); + + + }); + + document.addEventListener('DOMContentLoaded', function(){ + $('a[data-toggle="tab"]').on('shown.bs.tab', function(e){ + $($.fn.dataTable.tables(true)).DataTable() + .columns.adjust(); + }); }); @endsection diff --git a/resources/views/layouts/app_callcenter.blade.php b/resources/views/layouts/app_callcenter.blade.php new file mode 100644 index 0000000..ddda734 --- /dev/null +++ b/resources/views/layouts/app_callcenter.blade.php @@ -0,0 +1,253 @@ + + + + + + + + + + + SISTEM AR-RAHN + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + {{-- jquery validation --}} + + + + {{-- Pusher --}} + + + + + + + +
+ + + @if(session()->has('iklan') && session()->get('iklan') == 0) + + + + @endif + + + +
+ @yield('content') +
+
+ @yield('footer') + + diff --git a/resources/views/modal/historytebus.blade.php b/resources/views/modal/historytebus.blade.php index d5a27cf..affe7fc 100644 --- a/resources/views/modal/historytebus.blade.php +++ b/resources/views/modal/historytebus.blade.php @@ -25,13 +25,13 @@
@@ -43,6 +43,7 @@ Bil Tarikh Bayaran Bayaran + Jenis Bayaran Action diff --git a/resources/views/print/laporan_stokauditkhas.blade.php b/resources/views/print/laporan_stokauditkhas.blade.php index 6077840..de4b78f 100644 --- a/resources/views/print/laporan_stokauditkhas.blade.php +++ b/resources/views/print/laporan_stokauditkhas.blade.php @@ -170,7 +170,7 @@ #details th { padding: 8px; - font-size: 11px; + font-size: 13px; } #details tr:nth-child(even) { @@ -227,7 +227,7 @@ @section('content') -
+
diff --git a/routes/web.php b/routes/web.php index 8e52a2a..0882f4e 100644 --- a/routes/web.php +++ b/routes/web.php @@ -420,7 +420,15 @@ Route::get('/detailnotisperingatankedua/{notisid}',['as'=>'arcc.detailnotisperin Route::get('/bycawnotisperingatankedua/{kodcaw}/{notisid}',['as'=>'arcc.bycawnotisperingatankedua','uses'=>'CallCenterController@bycawnotisperingatankedua'])->middleware('auth','callcenter'); Route::post('/blastkedua/{kodcaw}/{notisid}',['as'=>'arcc.blastkedua','uses'=>'CallCenterController@blastkedua'])->middleware('auth','callcenter'); Route::get('/kemaskininotisperingatankedua/{notisid}',['as'=>'arcc.kemaskininotisperingatankedua','uses'=>'CallCenterController@kemaskininotisperingatankedua'])->middleware('auth','callcenter'); +Route::get('/kemaskininotisperingatanbycaw/{kodcaw}/{notisid}',['as'=>'arcc.kemaskininotisperingatanbycaw','uses'=>'CallCenterController@kemaskininotisperingatanbycaw'])->middleware('auth','callcenter'); +Route::get('/kemaskininotisperingatankeduabycaw/{kodcaw}/{notisid}',['as'=>'arcc.kemaskininotisperingatankeduabycaw','uses'=>'CallCenterController@kemaskininotisperingatankeduabycaw'])->middleware('auth','callcenter'); +//taraf pc atau ppc +Route::get('/cawangan/notisperingatan',['as'=>'laporan.notisperingatan','uses'=>'KhazanahController@notisperingatan'])->middleware('auth','khazanah'); +Route::get('/cawangan/rekodnotisperingatanpertama',['as'=>'laporan.rekodnotisperingatanpertama','uses'=>'KhazanahController@rekodnotisperingatanpertama'])->middleware('auth','khazanah'); +Route::get('/cawangan/rekodnotisperingatankedua',['as'=>'laporan.rekodnotisperingatankedua','uses'=>'KhazanahController@rekodnotisperingatankedua'])->middleware('auth','khazanah'); +Route::get('/cawangan/detailnotisperingatan',['as'=>'laporan.detailnotisperingatan','uses'=>'KhazanahController@detailnotisperingatan'])->middleware('auth','khazanah'); +Route::get('/cawangan/bycawnotisperingatan/{kodcaw}/{notisid}',['as'=>'laporan.bycawnotisperingatan','uses'=>'KhazanahController@bycawnotisperingatan'])->middleware('auth','khazanah'); @@ -432,7 +440,15 @@ Route::get('/khazanah/print.suratwakil/{norujukan}',['as'=>'khazanah.print.surat Route::get('/penilai/print.suratwakil/{norujukan}',['as'=>'penilai.print.suratwakil','uses'=>'WakilController@printSuratWakilPenilai'])->middleware('auth','penilai'); - +Route::get('/notisjbg',['as'=>'arcc.notisjbg','uses'=>'CallCenterController@notisJbg'])->middleware('auth','callcenter'); +Route::get('/carianjbg',['as'=>'arcc.carianjbg','uses'=>'CallCenterController@carianJbg'])->middleware('auth','callcenter'); +Route::post('/janadatanotisjbg',['as'=>'arcc.janadatanotisjbg','uses'=>'CallCenterController@janadatanotisjbg'])->middleware('auth','callcenter'); +Route::get('/rekodnotisjbg',['as'=>'arcc.rekodnotisjbg','uses'=>'CallCenterController@rekodnotisjbg'])->middleware('auth','callcenter'); +Route::get('/detailnotisjbg/{notisid}',['as'=>'arcc.detailnotisjbg','uses'=>'CallCenterController@detailnotisjbg'])->middleware('auth','callcenter'); +Route::get('/bycawnotisjbg/{kodcaw}/{notisid}',['as'=>'arcc.bycawnotisjbg','uses'=>'CallCenterController@bycawnotisjbg'])->middleware('auth','callcenter'); +Route::get('/detsagcallbyjbg/{kodcaw}/{notisid}/{id}',['as'=>'arcc.detsagcallbyjbg','uses'=>'CallCenterController@detsagcallbyjbg'])->middleware('auth','callcenter'); +Route::get('/bycawnotisjbg2/{kodcaw}/{notisid}',['as'=>'arcc.bycawnotisjbg2','uses'=>'CallCenterController@bycawnotisjbg2'])->middleware('auth','callcenter'); +Route::get('/detsagcallbyjbg2/{kodcaw}/{notisid}/{nokp}',['as'=>'arcc.detsagcallbyjbg2','uses'=>'CallCenterController@detsagcallbyjbg2'])->middleware('auth','callcenter'); Route::get('supports/driver/mykad-reader',['as'=>'mykadreader.driver', function(){