File: D:/HostingSpaces/SBogers10/zelfverkopen.komma.pro/resources/views/site/pdfs/invoice.blade.php
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<style>
@import url('https://fonts.googleapis.com/css?family=Open+Sans:400,700');
.page-break {
page-break-after: always;
}
.pdf-container {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
padding-bottom: 45px;
font-family: 'Open Sans', sans-serif;
/*background: #efefef;*/
}
img{
display: block;
border: none;
}
.header {
height: 90px;
width: 100%;
text-align: right;
}
.header .logo {
display: block;
margin-left: auto;
width: 350px;
height: 50px;
text-align: right;
}
.header .logo img {
width: 100%;
}
.header .icons {
display: block;
width: 80px;
height: 40px;
margin-top: 5px;
margin-left: auto;
}
.header .icons img{
width: 100%;
margin: 0;
}
.footer{
position: absolute;
right: 0;
bottom: 0;
display: block;
width: 100%;
/*padding-left: 25%;*/
height: 45px;
padding-top: 5px;
/*background-color: yellow;*/
text-align: right;
}
.footer div{
display: inline-block;
width: 32%;
text-align: left;
}
/*.footer div + div{*/
/*}*/
.footer div table{
border: none;
}
.footer div table td {
border: none;
font-size: 12px;
line-height: 16px;
color: #6B7C93;
}
.footer div table td.title{
font-weight: bold;
padding-right: 10px;
}
.footer div p{
display: block;
width: 100%;
margin: 0;
font-size: 12px;
line-height: 16px;
color: #6B7C93;
}
.footer div p strong{
display: inline-block;
}
.footer .business-info strong{
width: 60px;
}
.main p{
font-size: 15px;
line-height: 19px;
color: #38414D;
}
.main .invoice-header{
font-size: 16px;
line-height: 21px;
color: #38414D;
font-weight: bold;
}
.main .invoice-address{
display: block;
margin-bottom: 40px;
}
.main table{
width: 100%;
}
.main table th{
font-size: 16px;
line-height: 21px;
color: #38414D;
}
.main table td{
font-size: 15px;
line-height: 19px;
color: #38414D;
}
</style>
<?php
$site = "https://zelfverkopen.nl";
?>
<div class="pdf-container">
<div class="header">
<div class="logo">
<img alt="zelfverkopen logo" src="{{$site}}/img/pdf/zelfverkopen_nl.svg"/>
</div>
<div class="icons">
<img alt="partner logos" src="{{$site}}/img/pdf/under_header.svg"/>
</div>
</div>
<div class="main">
<p class="invoice-header">
<strong>Factuur {{$order->order_id}} </strong><br/>
<strong>Datum: {{$order->created_at->format('d-m-y')}}</strong>
</p>
<p class="invoice-address">
@lang('site/form.salutation.options.'.$genderId) {{$lastName}}<br/>
{{$order->street . ' '. $order->house_number.$order->house_number_addition}}<br/>
{{$order->zip . ' ' . $order->city}}
</p>
<table>
<thead style="border-bottom: 1px solid black;">
<tr>
<th style="width: calc(100% - 100px); text-align: left;">Product</th>
<th style="width: 100px; text-align: left">Prijs</th>
</tr>
</thead>
<tbody style="border-bottom: 1px solid black;">
@php $totalPrice = 0; @endphp
@foreach($order->products as $product)
<tr>
<td style="width: 450px; text-align: left;">{{$product->pivot->name}}</td>
<td style="width: 80px; text-align: left">{{ \App\KommaApp\Facades\Format::asFlatPrice($product->pivot->price, ['currency' => '€']) }}</td>
</tr>
@php $totalPrice += $product->pivot->price @endphp
@endforeach
<tr>
<td> </td>
<td> </td>
</tr>
</tbody>
<tfoot>
<tr>
<td style="width: 450px; text-align: left;"><strong>Totaalprijs incl. BTW</strong></td>
<td style="width: 80px; text-align: left">{{ \App\KommaApp\Facades\Format::asFlatPrice($totalPrice, ['currency' => '€']) }}</td>
</tr>
<tr>
<td style="width: 450px; text-align: left;">BTW 21%</td>
<td style="width: 80px; text-align: left">{{ \App\KommaApp\Facades\Format::asFlatPrice($totalPrice - ($totalPrice/1.21), ['currency' => '€']) }}</td>
</tr>
</tfoot>
</table>
@if($order->status !== \App\KommaApp\Orders\Models\Order::ORDER_STATUS_REFUNDED && $order->status !== \App\KommaApp\Orders\Models\Order::ORDER_STATUS_CREDIT)
<p>Deze factuur is reeds voldaan.</p>
@endif
</div>
<div class="footer">
<div class="address-info">
<table cellspacing="0">
<tr>
<td class="title">Postadres</td>
</tr>
<tr>
<td class="value">{{\Config::get('site.company.postal_street')}}</td>
</tr>
<tr>
<td class="value">{{\Config::get('site.company.postal_zip')}} {{\Config::get('site.company.postal_city')}}</td>
</tr>
</table>
</div>
<div class="contact-info">
<table cellspacing="0">
<tr>
<td class="title">T</td>
<td class="value">{{\Config::get('site.company.phone_display')}}</td>
</tr>
<tr>
<td class="title">E</td>
<td class="value">{{\Config::get('site.company.mail')}}</td>
</tr>
<tr>
<td class="title">W</td>
<td class="value">www.zelfverkopen.nl</td>
</tr>
</table>
</div>
<div class="business-info">
<table cellspacing="0">
<tr>
<td class="title">KVK</td>
<td class="value">{{\Config::get('site.company.kvk')}}</td>
</tr>
<tr>
<td class="title">BTW</td>
<td class="value">{{\Config::get('site.company.btw_2')}}</td>
</tr>
<tr>
<td class="title">IBAN</td>
<td class="value">{{\Config::get('site.company.iban_2')}}</td>
</tr>
</table>
</div>
</div>
</div>