Files
lelong/resources/views/pembida/detailsbidaan.blade.php
Nur Izzati Zulkifli ad6a01c7e3 update table
2022-12-04 15:28:57 +08:00

138 lines
5.7 KiB
PHP

@extends('layouts.app')
@section('content')
<div class="container-fluid">
<div class="row ">
<div class="col mx-auto p-4">
<div class="card">
<div class="card-header header-style">
<a href="javascript:window.history.go(-1);" class="header-style-icon">
<i class="fas fa-arrow-left"></i>
</a>
<div class="header-style-title">
senarai SAG Menang
</div>
</div>
<div class="card-body">
@if ($message = Session::get('failed'))
<div class="alert alert-danger">
<p>{{ $message }}</p>
</div>
@endif
<div class="container">
<!-- <div class="row mb-2">
<div class="col-md-12 mx-auto card p-4" style="margin-top:2%; margin-bottom:2%;">
<p> <b>Tarikh Lelong : </b> {{ $infos[0]['t_lelong'] }}</p>
<p> <b>Cawangan : </b>{{ $infos[0]['caw_name'] }}</p>
<p> <b>Nama Pembida : </b>{{ $userdetail['name'] }}</p>
<p> <b>No Kad Pengenalan : </b>{{ $userdetail['nokp'] }}</p>
<p> <b>No Tel Bimbit : </b>{{ $infos[0]['notelbimbit'] }}</p>
</div>
</div> -->
</div>
<table class="table table-bordered table-xl text-center" id="butirangadai" style="width:100%; margin-top:1%;">
<thead class="bg-primary text-white">
<tr>
<th>Bil</th>
<th>No Rujukan</th>
<th>Marhun</th>
<th>Harga Asas (RM)</th>
<th>Harga Bida (RM)</th>
<th>Masa Bidaan</th>
<th>Kaedah Pembayaran</th>
<th>No Resit</th>
</tr>
</thead>
<tbody>
@foreach($infos as $inf)
<tr>
<td>{{ $loop->iteration }}</td>
<td>{{ $inf['info']['norujukan'] }}</td>
<td>{{ $inf['info']['marhun'] }}</td>
<td>{{ number_format($inf['info']['hargaasas'], 2, '.', ',') }}</td>
<td>{{ number_format($inf['info']['hargabida'], 2, '.', ',') }}</td>
<td>{{ $inf['info']['masa_bidaan'] }}</td>
<td>
@foreach($inf['butiran_bidaan'] as $butiran_bidaan)
{{ $butiran_bidaan['remark'] }}
@endforeach
</td>
<td>
@foreach($inf['butiran_bidaan'] as $butiran_bidaan)
{{ $butiran_bidaan['reference_no'] }}
@endforeach
</td>
</tr>
@endforeach
</tbody>
</table>
</div>
</div>
</div>
<script>
//Enable tooltips everywhere
$(function () {
$('[data-toggle="tooltip"]').tooltip()
})
var tablebutirangadai = $('#butirangadai').DataTable({
"columnDefs": [
{
"targets": 0,
"orderable": false
},
{
"targets": 8,
"orderable": true
}
],
order: [[1, 'asc']],
"info": false,
"lengthChange": false,
"pageLength": 15,
dom: 'Bfrtip',
// buttons: [
// {
// className: 'btn btn-outline-success pl-4 pr-4 btn-sm addcaw',
// text: '<i class="fas fa-plus" id="test"></i>',
// titleAttr: 'Tambah Cawangan',
// action: function ( e, dt, node, config ) {
// // alert( 'Button activated' );
// // console.log('hye');
// $('#myModal').modal("show");
// $('#myModal').on('shown.bs.modal', function () {
// $('#rolename').trigger('focus')
// })
// }
// },
// {
// className: 'btn btn-outline-secondary pl-4 pr-4 btn-sm export',
// titleAttr: 'Senarai Gadaian Excel',
// text: '<i class="fas fa-download"></i>',
// action: function ( e, dt, node, config ) {
// $("#exportform").submit();
// }
// },
// {
// className: 'btn btn-outline-secondary pl-4 pr-4 btn-sm export',
// titleAttr: 'Senarai Gadaian PDF',
// text: '<i class="fas fa-download"></i>',
// action: function ( e, dt, node, config ) {
// $("#exportform").submit();
// }
// }
// ]
});
$('.addcaw').tooltip();
$('.export').tooltip();
// $( '.dt-buttons').addClass('btn-group');
$( '.addcaw').removeClass('dt-button');
$( '.export').removeClass('dt-button');
</script>
@endsection