add pendahuluan

This commit is contained in:
MUHD HAFIFIE
2021-08-23 16:58:56 +08:00
parent 59a3c012b3
commit de7bdaa3af
4 changed files with 83 additions and 26 deletions
@@ -111,12 +111,12 @@
</style>
</head>
<body>
<body onload="window.print()">
<page size="A4">
<h6 class="header">SULIT DAN PERSENDIRIAN</h6>
<table id="header">
<tr>
<th rowspan="4" style="width:50px"><br><img src="{{ asset('assets/img/icon_pkb.png') }}" style="width:70px"></img></th>
<th rowspan="4" style="width:50px"><br><img src="{{ asset('img/icon_pkb.png') }}" style="width:70px"></img></th>
<th colspan="1">KOPERASI PERMODALAN KELANTAN BERHAD</th>
</tr>
<tr>
@@ -198,13 +198,13 @@
</tr>
</table>
<div class="center">
<button onclick="window.print()">Cetak</button>
<button>Lihat Baki</button>
</div>
</page>
<script>
</script>
</body>
</html>
+3 -3
View File
@@ -38,7 +38,7 @@
<div class="inner">
<h3>RM {{ ($ringkasanharian['gadai'][0]['jumlahpinjaman']) ? number_format($ringkasanharian['gadai'][0]['jumlahpinjaman'],2) : "0.00" }}</h3>
<p style="font-weight:bold;">Gadai Hari Ini</p>
<p style="font-weight:bold;">Pembiayaan Hari Ini</p>
</div>
<div class="icon">
</div>
@@ -171,7 +171,7 @@
<div class="inner">
<h3>RM {{ ($dashboard[0]['variasi']) ? number_format((float)$dashboard[0]['variasi'],2) : "0.00" }}</h3>
<p>Varian</p>
<p>Varians</p>
</div>
<div class="icon">
</div>
@@ -231,7 +231,7 @@
<div class="inner">
<h3>RM {{ ($komuditicheck) ? number_format($komuditicheck['unit_komuditi'],2) : '0.00' }}</h3>
<p>Baki Komuditi</p>
<p>Baki Komoditi</p>
</div>
<div class="icon">
</div>
@@ -20,6 +20,17 @@
<div class="card-body">
@php
$dt = \Carbon\Carbon::now();
$date = $dt->format('Y-m-d');
@endphp
<div class="col-12 d-flex justify-content-end">
<button class="btn btn-danger fas fa-trash-alt" onclick="togglepadam();"></button>
</div>
<div class="mt-3 mx-auto">
{{-- @php $date = date('yy-m-d'); @endphp --}}
<table class='table table-hover table-striped table-bordered' id='table-pendahuluanserahan' style="width: 100%;">
@@ -29,7 +40,7 @@
<th>Description</th>
<th>Pendahuluan (RM)</th>
<th>Serahan (RM)</th>
{{-- <th>Tindakan</th> --}}
<th>Tindakan</th>
</tr>
</thead>
<tbody>
@@ -39,7 +50,7 @@
<td>{{ $gldetail['descpt'] }}</td>
<td>{{ ($gldetail['pendahuluan'] == 0 && ($gldetail['ktacct'] == '7000/102' || $gldetail['ktacct'] == '7000/106')) ? number_format($gldetail['amaun'],2) : number_format($gldetail['pendahuluan'],2) }}</td>
<td>{{ ($gldetail['serahan'] == 0 && ($gldetail['dtacct'] == '1000/026' || $gldetail['dtacct'] == '1000/020' || $gldetail['dtacct'] == '1000/090')) ? number_format($gldetail['amaun'],2) : number_format($gldetail['serahan'],2) }}</td>
{{-- @if($date === $gldetail['tarikh']) <td class="text-center"><button onclick="deletependser();" class="btn btn-danger fas fa-trash-alt"></button></td>@else<td></td> @endif --}}
@if($date === $gldetail['tarikh']) <td class="text-center"><button onclick="deletependser();" class="btn btn-danger fas fa-minus-square"></button></td>@else<td></td> @endif
</tr>
@endforeach
</tbody>
@@ -62,7 +73,14 @@
var tablependahuluanserahan = $('#table-pendahuluanserahan').DataTable({
"scrollX": true,
"order": [[ 0, "desc" ]]
"order": [[ 0, "desc" ]],
"columnDefs": [
{
"targets": [ 4 ],
"visible": false,
"searchable": false
}
]
});
let api = "{{ config('api.url') }}";
@@ -112,6 +130,15 @@
});
function togglepadam()
{
event.preventDefault();
var column = tablependahuluanserahan.column(4);
column.visible(!column.visible());
}
function deletependser()
{
Swal.fire({
@@ -124,14 +151,14 @@
cancelButtonColor: '#d33',
confirmButtonText: 'Teruskan!'
}).then((result) => {
if (result.isConfirmed) {
Swal.fire(
'Deleted!',
'Your file has been deleted.',
'success'
)
}
});
if (result.isConfirmed) {
Swal.fire(
'Deleted!',
'Your file has been deleted.',
'success'
)
}
});
}
function validateformat(evt)
+33 -3
View File
@@ -68,6 +68,17 @@
</head>
<body onload="startTime()" style="background-color:#BAC1C9;">
@php
$auth_user = Auth::user();
if($auth_user['role_harian'] == 'teller')
{
$api_url = config('api.url');
$gadai = Http::get( config('api.url') .'/api/gadai/serah_marhun/khazanah/'. $auth_user['cawangan'])->json();
$listserah = Http::get(config('api.url').'/api/listSerahMarhunController/'.$auth_user['cawangan'])->json();
}
@endphp
<div id="app">
<nav class="navbar navbar-expand-md navbar-light bg-white shadow-sm" style="height:100px;">
<div class="container">
@@ -268,10 +279,29 @@
@endguest
</ul>
</div>
</div>
</nav>
</div>
@php
if($auth_user['role_harian'] == 'teller')
{
echo '<div class="col-3">
<div class="col-12 pl-5">
<div class="row">
<h5 class="pr-3">G : <span class="text-success">' . count($gadai) . '</span></h5>
<h5>T : <span class="text-danger">' . count($listserah) . '</span></h5>
</div>
</div>
</div>';
}
@endphp
</div>
</nav>
<main class="py-4">