Files
exchange/resources/views/pdf/po.blade.php
T
2020-09-09 13:14:36 +08:00

171 lines
4.3 KiB
PHP

<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>document</title>
<style>
body {
font-family: simhei, sans-serif;
}
.details {
float: right;
max-width: 30%;
padding: 2em;
border: 1px solid black;
}
.buyer {
max-width: 45%;
float: left;
}
.seller {
max-width: 45%;
float: right;
}
.buyer-seller-container {
}
.buyer-company {
display: block;
font-size: 16px;
font-weight: bolder;
}
.reg {
display: block;
font-size: 14px;
}
.address {
display: block;
font-size: 14px;
word-wrap: break-word;
}
.gst {
display: block;
font-size: 14px;
}
.contact-no {
display: block;
font-size: 14px;
}
.seller {
width: 45%;
}
table {
width: 100%;
}
.clear-fix::after {
content: "";
clear: both;
display: table;
}
td {
padding: 0.4em;
text-align: center;
}
td.description, th.description {
text-align: left;
}
td, th {
margin-top: 0.6em;
margin-right: 0.6em;
}
.buyer-seller-title {
font-size: 1.2em;
/* text-decoration-line: underline; */
/* text-decoration-style: double; */
margin-bottom: 0.2em;
}
</style>
</head>
<body>
<div class="header">
<h1>{{ $title }}</h1>
</div>
<div class="buyer-seller-container clear-fix">
<div class="buyer">
<div class="buyer-seller-title">
Buyer
</div>
<span class="buyer-company">
{{ $buyer['buyer_company'] }}
</span>
<span class="reg">
{{ $buyer['reg_no'] }}
</span>
<span class="address">
{{ $buyer['address'] }}
</span>
<!-- <span class="gst">
GST: 12345678
</span> -->
<span class="contact-no">
Phone: {{ $buyer['phone'] }}
</span>
</div>
<div class="seller">
<div class="buyer-seller-title">
Seller
</div>
<span class="buyer-company">
{{ $seller['seller_company'] }}
</span>
<div class="address">
{{ $seller['address'] }}
</div>
<div class="contact-no">
Phone: {{ $seller['phone'] }}
</div>
<div class="contact-no">
Date: {{ $seller['date'] }}
</div>
<div class="contact-no">
PO#: {{ $seller['po_number'] }}
</div>
<div class="contact-no">
Order#: {{ $seller['order_number'] }}
</div>
</div>
</div>
<br>
<br>
<br>
{{$lines[0]->description}}
<table>
<caption>
<h3>Billing Detail</h3>
</caption>
<thead>
<tr>
<th>No</th>
<th class="description">Description</th>
<th>Quantity</th>
<th>Unit Price (RM)</th>
<th>Total Amount (RM)</th>
</tr>
</thead>
<tbody>
@foreach ($lines as $line)
<tr>
<td>{{$line->order}}</td>
<td class="description">{{$line->description}}</td>
<td>{{$line->quantity}}</td>
<td>{{number_format($line->unit_price_rm, 2)}}</td>
<td>{{number_format($line->total, 2)}}</td>
</tr>
@endforeach
</tbody>
<tfoot>
<tr>
<td colspan="3"></td>
<td>Subtotal</td>
<td>{{ number_format($amount, 2) }}</td>
</tr>
<tr>
<td colspan="3"></td>
<td>Total</td>
<td>{{ number_format($amount, 2) }}</td>
</tr>
</tfoot>
</table>
</body>
</html>