Files
lelong/resources/views/excel/listnotis_excel2.blade.php
T

133 lines
3.8 KiB
PHP

<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<script src="{{ asset('js/table2excel.js') }}"></script>
<style>
.letter{
font-family:'Times New Roman', Times, serif;
}
.row::after {
content: "";
clear: both;
display: table;
}
.first-prgph{
float: left;
width: 10%;
padding: 2px;
}
.first-prgph1{
float: left;
width: 30%;
padding-left: 50px;
}
.page-break {
page-break-before: always;
}
.name{
padding-top: 40px;
}
</style>
<body>
<div class = "letter">
{{-- <div class="row">
<div class="first-prgph">
<img src="{{ asset('img/icon_pkb.png') }}" alt="PKB LOGO" width="100" height="100">
</div> --}}
<div class="first-prgph1">
<p> {{$caw['caw_name']}}<br>
{{$caw['alamat1']}}<br>
{{$caw['alamat2']}}<br>
No Tel: {{$caw['notel']}}<br>
No Faks: {{$caw['nofaks']}}
</p><br>
</div>
<br>
</div>
<table width="100%" height="168" id="customers">
<thead>
<tr>
<th align="left">No</th>
<th align="left">Nama</th>
<th align="left">No KP</th>
<th align="left">No Telefon</th>
<th align="left">Alamat 1</th>
<th align="left">Alamat 2</th>
<th align="left">Alamat 3</th>
<th align="left">No Rujukan</th>
<th>Tempoh</th>
<th>Pembiayaan (RM)</th>
<th>Keuntungan 6 Bulan (RM)</th>
<th>Bayaran Telah Dibuat (RM)</th>
<th>Baki Lelong (simulasi) (RM)</th>
</tr>
</thead>
@foreach($customers as $customer)
<tr>
<td>{{$loop->iteration}}</td>
<td>{{$customer->nama}}</td>
<td>{{$customer->kpbaru ? $customer->kpbaru : $customer->kplama}}</td>
<td>{{$customer->telefon ? '6'.$customer->telefon : ""}}</td>
<td>{{$customer->alamat1}}</td>
<td>{{$customer->alamat2}}</td>
<td>{{$customer->alamat3}}</td>
<td style="white-space: nowrap;">@foreach($customer['gadai'] as $data)
{{$data->norujukan}}<br>
@endforeach
</td>
<td>@foreach($customer['gadai'] as $data)
{{$data->tempoh}}<br>
@endforeach
</td>
<td align = "right">@foreach($customer['gadai'] as $data)
{{number_format($data->bakipjm, 2, '.', ',')}}<br>
@endforeach
</td>
<td align = "right">@foreach($customer['gadai'] as $data)
{{number_format($data->bakiupah, 2, '.', ',')}}<br>
@endforeach
</td>
<td align = "right">@foreach($customer['gadai'] as $data)
{{$data->ktlhbyr}}<br>
@endforeach
</td>
<td align = "right"><b>@foreach($customer['gadai'] as $data)
{{$data->bakilelong}}<br>
@endforeach
</b>
</td>
</tr>
@endforeach
</div>
</body>
<script src="{{ asset('js/jquery.min.js') }}"></script>
<script>
$(document).ready(function () {
var table2excel = new Table2Excel();
table2excel.export(document.querySelectorAll("#customers"),'senarai_notis');
setTimeout(function(){ window.close() }, 10);
});
</script>