192 lines
8.3 KiB
PHP
192 lines
8.3 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">
|
|
<div class="header-style-title">
|
|
Butiran Lelongan Mengikut Cawangan
|
|
</div>
|
|
</div>
|
|
<div class="card-body">
|
|
@if ($message = Session::get('failed'))
|
|
<div class="alert alert-danger" style="margin-top:1%;">
|
|
<p>{{ $message }}</p>
|
|
</div>
|
|
@endif
|
|
|
|
{{-- @if (Session::has('message'))
|
|
<div class="alert alert-info">{{ Session::get('message') }}</div>
|
|
@endif --}}
|
|
|
|
{{-- <h3 class="pt-3" style="margin-left:1%;">Butiran Gadaian Mengikut Cawangan Lelongan Fasa {{$fasa}}</h3> --}}
|
|
<!-- <form action="{{route('analisa.janadata')}}" method="POST" enctype="multipart/form-data"> -->
|
|
<form id="exportpdf" action="{{route('reportbydate.docaribydate')}}" method="POST" enctype="multipart/form-data">
|
|
<!-- <form action="{{route('analisa.importgadaifrommaster')}}" method="POST" enctype="multipart/form-data"> -->
|
|
|
|
@csrf
|
|
|
|
<input type="hidden" class="form-control" id="tarikh_dari" name="tarikh_dari" value="{{$tarikh_dari}}">
|
|
<input type="hidden" class="form-control" id="tarikh_hingga" name="tarikh_hingga" value="{{$tarikh_hingga}}">
|
|
<input type="hidden" name="type" id="typedonwload" value="">
|
|
<div class="container">
|
|
<div>
|
|
<div style="margin-top:2%; margin-bottom:2%;">
|
|
|
|
<p> Dari: @php $trkh_dari = date('d-m-Y', strtotime($tarikh_dari)); @endphp {{$trkh_dari}}
|
|
Hingga: @php $trkh_hingga = date('d-m-Y', strtotime($tarikh_hingga)); @endphp {{$trkh_hingga}}<br><br> </p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<table class="table text-right table-bordered" id="senaraitemplaporanbydate" style="width:100%">
|
|
<thead class="bg-primary text-white">
|
|
<tr>
|
|
{{-- <th><input type="checkbox" aria-label="Checkbox for following text input" id="checkall"></th> --}}
|
|
<th>Bil</th>
|
|
<th>Kod Cawangan</th>
|
|
<th>Cawangan</th>
|
|
<th>Bil Lelong</th>
|
|
<th>Berat (gm)</th>
|
|
<th>Nilai Marhun Asal(RM)</th>
|
|
<th>Pembiayaan (RM)</th>
|
|
<th>Keuntungan (RM)</th>
|
|
<th>Harga Jual (RM)</th>
|
|
<th>Caj Lelong (RM)</th>
|
|
<th>Baki Lelong (RM)</th>
|
|
<th>Rugi Lelong (RM)</th>
|
|
{{-- <th class="text-center">Tindakan</th> --}}
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@php $count = 1; @endphp
|
|
@foreach($senarai as $send)
|
|
@if($send['bil_lelong'] > 0)
|
|
|
|
<tr>
|
|
{{-- <td><input type="checkbox" aria-label="Checkbox for following text input" name="caw[]" id="caw" value = "{{ $send['kodcaw'] }}" class="checkbox"></td> --}}
|
|
<td>{{ $count++ }}</td>
|
|
<td>{{ $send['kodcaw'] }}</td>
|
|
<td style="white-space: nowrap;">{{ $send['caw_name'] }}</td>
|
|
<td>{{ $send['bil_lelong'] }} </td>
|
|
<td>{{ number_format($send['total_berat'], 2) }} </td>
|
|
<td>{{ number_format($send['total_nilaimarhun'], 2) }} </td>
|
|
<td>{{ number_format($send['total_pembiayaan'], 2) }} </td>
|
|
<td>{{ number_format($send['total_bakiupah'] , 2) }} </td>
|
|
<td>{{ number_format($send['total_hargajual'] , 2) }} </td>
|
|
<td>{{ number_format($send['total_cajlelong'] , 2) }} </td>
|
|
<td>{{ number_format($send['total_baki'] , 2) }} </td>
|
|
<td>{{ number_format(-$send['total_rugi'] , 2) }} </td>
|
|
|
|
|
|
{{-- <td>
|
|
<a href=" {{ route('analisa.tempbycawsimulasi', [$send['kodcaw'],$t_gadai1,$fasa]) }} " data-toggle="tooltip" data-placement="top" title="Butiran Gadaian"><i class="far fa-edit"></i></a>
|
|
</td>--}}
|
|
</tr>
|
|
@endif
|
|
@endforeach
|
|
</tbody>
|
|
<tfoot>
|
|
<tr>
|
|
<td colspan="3"><b>JUMLAH KESELURUHAN</b></td>
|
|
<td><b>{{ $jum_billelong }}</b></td>
|
|
<td><b>{{ number_format($jum_berat, 2) }}</b></td>
|
|
<td><b>{{ number_format($jum_nilaimarhun, 2) }}</b></td>
|
|
<td><b>{{ number_format($jum_pembiayaan, 2) }}</b></td>
|
|
<td><b>{{ number_format($jum_bakiupah, 2) }}</b></td>
|
|
<td><b>{{ number_format($jum_hargajual, 2) }}</b></td>
|
|
<td><b>{{ number_format($jum_cajlelong, 2) }}</b></td>
|
|
<td><b>{{ number_format($jum_baki, 2) }}</b></td>
|
|
<td><b>-{{ number_format($jum_rugi, 2) }}</b></td>
|
|
</tr>
|
|
</tfoot>
|
|
</table>
|
|
|
|
<div class="modal-footer; text-center" style="margin-top:2%; margin-bottom:2%;">
|
|
<a href="{{ route('reportbydate.laporanlelongbydate') }}" class="btn btn-primary" style="width:8%;">Kembali</a>
|
|
{{-- <button type="submit" class="btn btn-success">Jana Simulasi</button> --}}
|
|
</div>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<script>
|
|
//Enable tooltips everywhere
|
|
$(function () {
|
|
$('[data-toggle="tooltip"]').tooltip()
|
|
})
|
|
var tablesenaraitemp = $('#senaraitemplaporanbydate').DataTable({
|
|
"columnDefs": [
|
|
{
|
|
"targets": 0,
|
|
"orderable": false
|
|
},
|
|
{
|
|
"targets": 8,
|
|
"orderable": false
|
|
}
|
|
],
|
|
order: [[0, 'asc']],
|
|
"info": false,
|
|
"lengthChange": false,
|
|
"pageLength": 15,
|
|
dom: 'Bfrtip',
|
|
buttons: [
|
|
{
|
|
className: 'btn btn-outline-danger pl-4 pr-4 btn-sm export',
|
|
titleAttr: 'Export to PDF',
|
|
text: '<h8><b>PDF</b></h8>',
|
|
action: function ( e, dt, node, config ) {
|
|
$('#typedonwload').val('pdf');
|
|
$("#exportpdf").submit();
|
|
}
|
|
}
|
|
]
|
|
});
|
|
|
|
// $('.addcaw').tooltip();
|
|
// $('.export').tooltip();
|
|
// // $( '.dt-buttons').addClass('btn-group');
|
|
// $( '.addcaw').removeClass('dt-button');
|
|
// $( '.export').removeClass('dt-button');
|
|
</script>
|
|
<script type='text/javascript'>
|
|
$(document).ready(function(){
|
|
// Check or Uncheck All checkboxes
|
|
$("#checkall").change(function(){
|
|
var checked = $(this).is(':checked');
|
|
if(checked){
|
|
$(".checkbox").each(function(){
|
|
$(this).prop("checked",true);
|
|
});
|
|
}else{
|
|
$(".checkbox").each(function(){
|
|
$(this).prop("checked",false);
|
|
});
|
|
}
|
|
});
|
|
|
|
// Changing state of CheckAll checkbox
|
|
$(".checkbox").click(function(){
|
|
|
|
if($(".checkbox").length == $(".checkbox:checked").length) {
|
|
$("#checkall").prop("checked", true);
|
|
} else {
|
|
$("#checkall").prop("checked", false);
|
|
}
|
|
|
|
});
|
|
});
|
|
</script>
|
|
<script>
|
|
$(function() {
|
|
$( "form" ).submit(function() {
|
|
$('#loader').show();
|
|
|
|
});
|
|
});
|
|
</script>
|
|
|
|
@endsection
|