Resolve conflicts

This commit is contained in:
Afiq Hamzah
2024-09-02 16:05:55 +08:00
parent caa473bcb0
commit c1df8012f4
3 changed files with 20 additions and 13 deletions
+9 -5
View File
@@ -555,6 +555,8 @@ class AkaunController extends Controller
$tarikh_akhir = $request->datehingga;
}
$request->hostname = config('app.env') == 'production' ? 'http://apiujrah.arrahn' : $request->hostname;
$tuntutbaki = Http::get($request->hostname. '/api/TuntutBakiRangeDate/'. $request->kodcaw,['mula' => $tarikh_mula,'akhir' => $tarikh_akhir])->json();
$cawangan=Http::get($request->hostname.'/api/cawangan/detail/'.$request->kodcaw)->json();
@@ -1011,7 +1013,8 @@ class AkaunController extends Controller
$tarikh_cetak = $current->toDateString();
if($request->datemula == null){
$mula_date = '2017-01-01';
$mula_date = $current->toDateString();
}else{
$split_date = explode('-', $request->datemula);
// $mula_date = $split_date[2] . '-' . $split_date[1] . '-' . $split_date[0];
@@ -1257,7 +1260,7 @@ class AkaunController extends Controller
$tarikh_cetak = $current->toDateString();
if($request->datemula == null){
$datemula = '2017-01-01';
$datemula = $current->toDateString();
}else{
$split_date = explode('-', $request->datemula);
$datemula = $request->datemula;
@@ -1294,7 +1297,7 @@ class AkaunController extends Controller
$tarikh_cetak = $current->toDateString();
if($request->datemula == null){
$datemula = '2017-01-01';
$datemula = $current->toDateString();
}else{
$split_date = explode('-', $request->datemula);
$datemula = $request->datemula;
@@ -1319,7 +1322,7 @@ class AkaunController extends Controller
$cawangan = Http::get($request->hostname.'/api/cawangan/detail/'. $request->kodcaw)->json();
$cawangan_detail=$cawangan[0];
return view('akaun.laporan_serahpetibesigadai', compact('cawangan_detail','api_url','serahmarhun','cawangan_info','datemula','datehingga','tarikh_cetak'));
return view('akaun.laporan_serahmarhun', compact('cawangan_detail','api_url','serahmarhun','cawangan_info','datemula','datehingga','tarikh_cetak'));
}
@@ -1478,7 +1481,7 @@ class AkaunController extends Controller
$tarikh_cetak = $current->toDateString();
if($request->datemula == null){
$mula_date = '2017-01-01';
$mula_date = $current->toDateString();
}else{
$split_date = explode('-', $request->datemula);
$mula_date = $request->datemula;
@@ -1631,6 +1634,7 @@ class AkaunController extends Controller
$split_date2 = explode('-',$request->datehingga);
$hingga_date = $request->datehingga;
}
$request->hostname = config('app.env') == 'production' ? 'http://apiujrah.arrahn' : $request->hostname;
$tebus = Http::get($request->hostname. '/api/ansuranujrah/laporan/'. $request->kodcaw,['mula' => $mula_date,'akhir' => $hingga_date])->json();
$cawangan=Http::get($request->hostname.'/api/cawangan/detail/'.$request->kodcaw)->json();
$cawangan_detail=$cawangan[0];
+2 -2
View File
@@ -65,7 +65,7 @@
data(){
return{
jenisgenerate:'none',
selected:'',
selected:'pekerja',
kodcaw:''
}
@@ -107,4 +107,4 @@
}
}
</script>
</script>
@@ -236,12 +236,15 @@
@endphp
@foreach($gadai as $index=>$item)
@php
$ujrah = isset($item['ujrah']) ? $item['ujrah'] : 0;
$onepercent = isset($item['onepercent']) ? $item['onepercent'] : 0;
$totalpinjaman += $item['pinjaman'];
$totalberat += $item['berat'];
$totalnm += $item['nilaimarhun'];
$totalupah += $item['upah12'];
$full_total_ujrah += $item['ujrah']*12;
$full_total_onepercent += $item['onepercent']*12;
$full_total_ujrah += $ujrah * 12;
$full_total_onepercent += $onepercent * 12;
@endphp
@if($index > 0)
@if($item['teller'] != $gadai[$index - 1]['teller'])
@@ -283,8 +286,8 @@
<td>{{ number_format($item['berat'],2) }}</td>
<td>{{ number_format($item['nilaimarhun'],2) }}</td>
<td>{{ number_format($item['pinjaman'],2) }}</td>
<td>{{ number_format($item['ujrah']*12,2) }}</td>
<td>{{ number_format($item['onepercent']*12,2) }}</td>
<td>{{ number_format($ujrah*12,2) }}</td>
<td>{{ number_format($onepercent*12,2) }}</td>
<td>{{ number_format($item['upah12'],2) }}</td>
<td>{{ $item['percentpinj'] }}</td>
</tr>
@@ -294,8 +297,8 @@
$totalnmteller += $item['nilaimarhun'];
$totalberatteller += $item['berat'];
$totalupah12 += $item['upah12'];
$totalujrah += $item['ujrah']*12;
$totalonepercent += $item['onepercent']*12;
$totalujrah += $ujrah*12;
$totalonepercent += $onepercent*12;
@endphp
@if($index+1 < sizeof($gadai))
@if($item['teller'] != $gadai[$index + 1]['teller'])