171 lines
7.5 KiB
PHP
171 lines
7.5 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="col-md-11 mx-auto card p-4"> --}}
|
|
@if ($message = Session::get('success'))
|
|
<div class="alert alert-success">
|
|
<p>{{ $message }}</p>
|
|
</div>
|
|
@endif
|
|
<div class="card-body">
|
|
<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 Pemenang : @foreach($datacaw as $data1)
|
|
{{$data1['caw_name']}}
|
|
@endforeach
|
|
</div>
|
|
</div>
|
|
<div class="card-body">
|
|
{{-- <div class="col-md-11 mx-auto card p-4"> --}}
|
|
{{-- <div class="col-6"> --}}
|
|
<table class="table text-center table-bordered" id="tablekaunter" style="width:100%">
|
|
<thead class="bg-primary text-white">
|
|
<tr>
|
|
<th>No</th>
|
|
<th align = 'text-center'>Nama</th>
|
|
<th>No Kad Pengenalan</th>
|
|
<th>No Telefon</th>
|
|
<th>Bilangan Surat</th>
|
|
<th>Jumlah Bidaan (RM)</th>
|
|
<th>Amaun Telah Dibayar (RM)</th>
|
|
<th>Status Bayaran</th>
|
|
{{-- <th>Penyata Bayaran</th>
|
|
<th>Slip Serahan</th>
|
|
<th>Resit Pembayaran</th> --}}
|
|
<th class="text-center">Tindakan</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@php $totalsurat = 0;
|
|
$totalbid = 0;
|
|
$totalpay = 0;
|
|
@endphp
|
|
@forelse($listwinner as $winner)
|
|
<tr>
|
|
<td> {{ $loop->iteration }} </td>
|
|
<td style="white-space: nowrap;" align = 'left'>{{ $winner['details']['name']}}</td>
|
|
<td>{{ $winner['details']['nokp']}}</td>
|
|
<td>{{ $winner['details']['notelbimbit']}}</td>
|
|
<td>{{ $winner['total_surat']}}</td>
|
|
<td>{{ number_format($winner['totalBid'], 2, '.', ',')}}</td>
|
|
<td>{{ number_format($winner['totalPay'], 2, '.', ',')}}</td>
|
|
<td align="center">
|
|
@if($winner['totalPay'] < $winner['totalBid'])
|
|
<button class="btn btn-danger btn-sm" disabled>BELUM SELESAI</button>
|
|
@elseif($winner['totalPay'] == $winner['totalBid'])
|
|
<button class="btn btn-success btn-sm" disabled>SELESAI</button>
|
|
@endif
|
|
</td>
|
|
{{-- <td>
|
|
<a href="{{ route('serahan.penyatabayaran',['user_id'=>$winner['details']['id'],'lelong_id'=>$lelong_id]) }}" target = "blank" data-toggle="tooltip" data-placement="top" title="Muat Turun Penyata Bayaran" ><i class="fas fa-download"></i></a>
|
|
</td>
|
|
|
|
<td>
|
|
<a href="{{ route('serahan.slipserahan',['user_id'=>$winner['details']['id'],'lelong_id'=>$lelong_id]) }}" target = "blank" data-toggle="tooltip" data-placement="top" title="Muat Turun Penyata Bayaran" ><i class="fas fa-download"></i></a>
|
|
</td>
|
|
|
|
<td>
|
|
<a href=" {{ route('serahan.resit', ['user_id'=>$winner['details']['id'], 'lelong_id'=>$lelong_id]) }} " data-toggle="tooltip" data-placement="top" title="Resit Pembayaran"><i class="far fa-edit"></i></a>
|
|
</td> --}}
|
|
<td align="center">
|
|
<a class="btn m-1 btn-info" href=" {{ route('pembida.SAGBidItembycaw', ['user_id'=>$winner['details']['id'], 'lelong_id'=>$lelong_id, 'kodcaw'=>$caw_code]) }} " data-toggle="tooltip" data-placement="top" title="Buat Pembayaran"><i class="far fa-edit"></i></a>
|
|
</td>
|
|
</tr>
|
|
@php
|
|
$totalsurat += $winner['total_surat'];
|
|
$totalbid += $winner['totalBid'];
|
|
$totalpay += $winner['totalPay'];
|
|
@endphp
|
|
@empty
|
|
<td colspan="9"> No Data </td>
|
|
@endforelse
|
|
</tbody>
|
|
<tfoot>
|
|
<tr>
|
|
<td colspan="4"><b>JUMLAH KESELURUHAN</b></td>
|
|
<td align='center'><b><b>{{$totalsurat}}</b></td>
|
|
<td align='center'><b>{{ number_format($totalbid, 2, '.', ',') }}</b></td>
|
|
<td colspan="6"></td>
|
|
</tr>
|
|
</tfoot>
|
|
</table>
|
|
{{-- <div class="modal-footer" style="margin-top:2%;">
|
|
<a href="{{ route('pembida.kebenaranbayarantunai') }}" class="btn btn-primary">Kembali</a>
|
|
</div> --}}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<script>
|
|
//Enable tooltips everywhere
|
|
$(function () {
|
|
$('[data-toggle="tooltip"]').tooltip()
|
|
})
|
|
var tablekaunter = $('#tablekaunter').DataTable({
|
|
"columnDefs": [
|
|
{
|
|
"targets": 0,
|
|
"orderable": false
|
|
},
|
|
{
|
|
"targets": 8,
|
|
"orderable": false
|
|
},
|
|
{
|
|
"targets": 9,
|
|
"orderable": false
|
|
},
|
|
{
|
|
"targets": 10,
|
|
"orderable": false
|
|
}
|
|
],
|
|
order: [[0, '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: 'Export to CSV',
|
|
// 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
|
|
|