<html>
<head>
<meta charset="UTF-8">
<title><?php echo e(ucwords('invoice')); ?></title>
<meta http-equiv="Content-Type" content="text/html;"/>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="<?php echo e(theme_asset(path: 'public/assets/front-end/css/invoice.css')); ?>">
</head>
<body>
<?php ($companyName = getWebConfig(name: 'company_name')); ?>
<div class="first">
<table class="content-position mb-30">
<tr>
<th class="p-0 text-left font-size-26px">
<?php echo e(ucwords('order Invoice')); ?>
</th>
<th class="p-0 text-right">
<img height="40" src="<?php echo e(dynamicStorage(path: "storage/app/public/company/".getWebConfig(name: 'company_web_logo'))); ?>"
alt="">
</th>
</tr>
</table>
<table class="bs-0 mb-30 px-10">
<tr>
<th class="content-position-y text-left">
<h4 class="text-uppercase mb-1 fz-14">
<?php echo e(ucwords('Order')); ?> #<?php echo e($order->id); ?>
</h4>
<br>
<h4 class="text-uppercase mb-1 fz-14">
<?php echo e(ucwords('shop Name')); ?>
: <?php echo e($order->seller_is == 'admin' ? $companyName : (isset($order->seller->shop) ? $order->seller->shop->name : ucwords('not found'))); ?>
</h4>
<?php if($order['seller_is']!='admin' && isset($order['seller']->gst) != null): ?>
<h4 class="text-capitalize fz-12">
<?php echo e(ucwords('GST')); ?> : <?php echo e($order['seller']->gst); ?>
</h4>
<?php endif; ?>
</th>
<th class="content-position-y text-right">
<h4 class="fz-14">
<?php echo e(ucwords('date')); ?> : <?php echo e(date('d-m-Y h:i:s a',strtotime($order['created_at']))); ?>
</h4>
</th>
</tr>
</table>
</div>
<?php if($order->order_type == 'default_type'): ?>
<div class="">
<section>
<table class="content-position-y fz-12">
<tr>
<td class="font-weight-bold p-1">
<table>
<tr>
<td>
<?php if($order->shipping_address_data): ?>
<?php
$shipping_address = $order->shipping_address_data;
?>
<span class="h2 m-0"><?php echo e(ucwords('shipping to')); ?> </span>
<div class="h4">
<p class="mt-6px mb-0"><?php echo e($shipping_address->contact_person_name); ?></p>
<p class="mt-6px mb-0"><?php echo e($shipping_address->phone); ?></p>
<p class="mt-6px mb-0"><?php echo e($shipping_address->address); ?></p>
<p class="mt-6px mb-0"><?php echo e($shipping_address->city); ?> <?php echo e($shipping_address->zip); ?> </p>
</div>
<?php else: ?>
<span class="h2 m-0"><?php echo e(ucwords('customer info')); ?> </span>
<div class="h4">
<?php if($order->is_guest): ?>
<p class="mt-6px mb-0">Guest User</p>
<?php else: ?>
<p class="mt-6px mb-0">
<?php echo e($order->customer !=null? $order->customer['f_name'].' '.$order->customer['l_name']:'Name not found'); ?>
</p>
<?php endif; ?>
<?php if(isset($order->customer) && $order->customer['id']!=0): ?>
<p class="mt-6px mb-0">
<?php echo e($order->customer !=null? $order->customer['email']: ucwords('email not found')); ?>
</p>
<p class="mt-6px mb-0">
<?php echo e($order->customer !=null? $order->customer['phone']: ucwords('phone not found')); ?>
</p>
<?php endif; ?>
</div>
<?php endif; ?>
</td>
</tr>
</table>
</td>
<td>
<table>
<tr>
<td class="text-right">
<?php if(!$order->is_guest && $order->billing_address_data): ?>
<?php
$billingAddress = $order->billing_address_data
?>
<span class="h2"><?php echo e(ucwords('billing address')); ?> </span>
<div class="h4">
<p class="font-weight-normal mt-6px mb-0">
<?php echo e($billingAddress->contact_person_name); ?>
</p>
<p class="font-weight-normal mt-6px mb-0">
<?php echo e($billingAddress->phone); ?>
</p>
<p class="font-weight-normal mt-6px mb-0">
<?php echo e($billingAddress->address); ?>
</p>
<p class="font-weight-normal mt-6px mb-0">
<?php echo e($billingAddress->city); ?> <?php echo e($billingAddress->zip); ?>
</p>
</div>
<?php endif; ?>
</td>
</tr>
</table>
</td>
</tr>
</table>
</section>
</div>
<?php else: ?>
<div class="row">
<section>
<table class="content-position-y w-100">
<tr>
<td class="text-center" valign="top">
<span class="h2 m-0"><?php echo e(ucwords('POS order')); ?> </span>
</td>
</tr>
</table>
</section>
</div>
<?php endif; ?>
<br>
<div>
<div class="content-position-y">
<table class="customers bs-0">
<thead>
<tr>
<th><?php echo e(ucwords('no.')); ?></th>
<th><?php echo e(ucwords('item description')); ?></th>
<th>
<?php echo e(ucwords('unit price')); ?>
</th>
<th>
<?php echo e(ucwords('qty')); ?>
</th>
<th class="text-right">
<?php echo e(ucwords('total')); ?>
</th>
</tr>
</thead>
<?php
$total = 0;
$subTotal = 0;
$totalTax = 0;
$totalShippingCost = 0;
$totalDiscountOnProduct = 0;
$extraDiscount = 0;
?>
<tbody>
<?php $__currentLoopData = $order->details; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key=>$details): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
<?php $subTotal = ($details['price']) * $details->qty ?>
<tr>
<td><?php echo e($key+1); ?></td>
<td>
<?php echo e($details['product']?$details['product']->name:''); ?>
<?php if($details['variant']): ?>
<br>
<?php echo e(ucwords('variation')); ?> : <?php echo e($details['variant']); ?>
<?php endif; ?>
</td>
<td><?php echo e(webCurrencyConverter(amount: $details['price'])); ?></td>
<td><?php echo e($details->qty); ?></td>
<td class="text-right"><?php echo e(webCurrencyConverter(amount: $subTotal)); ?></td>
</tr>
<?php
$subTotal += $details['price'] * $details['qty'];
$totalTax += $details['tax'];
$totalShippingCost += $details->shipping ? $details->shipping->cost : 0;
$totalDiscountOnProduct += $details['discount'];
$total += $subTotal;
?>
<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
</tbody>
</table>
</div>
</div>
<?php
if ($order['extra_discount_type'] == 'percent') {
$extraDiscount = ($subTotal / 100) * $order['extra_discount'];
} else {
$extraDiscount = $order['extra_discount'];
}
?>
<?php ($shipping=$order['shipping_cost']); ?>
<div class="content-position-y">
<table class="fz-12">
<tr>
<th class="text-left width-60">
<h4 class="fz-12 mb-1"><?php echo e(ucwords('payment details')); ?></h4>
<h5 class="fz-12 mb-1 font-weight-normal"><?php echo e(str_replace('_',' ',$order->payment_method)); ?></h5>
<p class="fz-12 font-weight-normal"><?php echo e($order->payment_status); ?>
, <?php echo e(date('y-m-d',strtotime($order['created_at']))); ?></p>
<?php if($order->delivery_type): ?>
<h4 class="fz-12 mb-1"><?php echo e(ucwords('delivery_info')); ?> </h4>
<?php if($order->delivery_type == 'self_delivery' && $order->deliveryMan): ?>
<p class="fz-12 font-normal">
<span class="font-weight-normal">
<?php echo e(ucwords('self delivery')); ?>
</span>
<br>
<span class="font-weight-normal">
<?php echo e(ucwords('deliveryman name')); ?> : <?php echo e($order->deliveryMan['f_name'].' '.$order->deliveryMan['l_name']); ?>
</span>
<br>
<span class="font-weight-normal">
<?php echo e(ucwords('deliveryman phone')); ?> : <?php echo e($order->deliveryMan['phone']); ?>
</span>
</p>
<?php else: ?>
<p>
<span class="font-weight-normal">
<?php echo e($order->delivery_service_name); ?>
</span>
<br>
<span class="font-weight-normal">
<?php echo e(ucwords('tracking id')); ?> : <?php echo e($order->third_party_delivery_tracking_id); ?>
</span>
</p>
<?php endif; ?>
<?php endif; ?>
</th>
<th class="calc-table">
<table>
<tbody>
<tr>
<td class="p-1 text-left"><b><?php echo e(ucwords('sub total')); ?></b></td>
<td class="p-1 text-right"><?php echo e(webCurrencyConverter(amount: $subTotal)); ?></td>
</tr>
<tr>
<td class="p-1 text-left"><b><?php echo e(ucwords('tax')); ?></b></td>
<td class="p-1 text-right"><?php echo e(webCurrencyConverter(amount: $totalTax)); ?></td>
</tr>
<?php if($order->order_type == 'default_type'): ?>
<tr>
<td class="p-1 text-left"><b><?php echo e(ucwords('shipping')); ?></b></td>
<td class="p-1 text-right"><?php echo e(webCurrencyConverter(amount: $shipping - ($order->is_shipping_free ? $order->extra_discount : 0))); ?></td>
</tr>
<?php endif; ?>
<tr>
<td class="p-1 text-left"><b><?php echo e(ucwords('coupon discount')); ?></b></td>
<td class="p-1 text-right">
- <?php echo e(webCurrencyConverter(amount: $order->discount_amount)); ?></td>
</tr>
<tr>
<td class="p-1 text-left"><b><?php echo e(ucwords('discount on product')); ?></b></td>
<td class="p-1 text-right">
- <?php echo e(webCurrencyConverter(amount: $totalDiscountOnProduct)); ?></td>
</tr>
<?php if($order->order_type != 'default_type'): ?>
<tr>
<td class="p-1 text-left"><b><?php echo e(ucwords('extra discount')); ?></b></td>
<td class="p-1 text-right">
- <?php echo e(webCurrencyConverter(amount: $extraDiscount)); ?></td>
</tr>
<?php endif; ?>
<tr>
<td class="border-dashed-top font-weight-bold text-left"><b><?php echo e(ucwords('total')); ?></b></td>
<td class="border-dashed-top font-weight-bold text-right">
<?php echo e(webCurrencyConverter(amount: $order->order_amount)); ?>
</td>
</tr>
</tbody>
</table>
</th>
</tr>
</table>
</div>
<br>
<br><br><br>
<div class="row">
<section>
<table>
<tr>
<th class="content-position-y bg-light py-4">
<div class="d-flex justify-content-center gap-2">
<div class="mb-2">
<img height="10" src="<?php echo e(theme_asset(path: 'public/assets/front-end/img/icons/telephone.png')); ?>"
alt="">
<?php echo e(ucwords('phone')); ?>
: <?php echo e(getWebConfig(name: 'company_phone')); ?>
</div>
<div class="mb-2">
<img height="10" src="<?php echo e(theme_asset(path: 'public/assets/front-end/img/icons/email.png')); ?>" alt="">
<?php echo e(ucwords('email')); ?>
: <?php echo e(getWebConfig(name: 'company_email')); ?>
</div>
</div>
<div class="mb-2">
<img height="10" src="<?php echo e(theme_asset(path: 'public/assets/front-end/img/icons/web.png')); ?>" alt="">
<?php echo e(ucwords('website')); ?>
: <?php echo e(url('/')); ?>
</div>
<div>
<?php echo e(ucwords('all copy right reserved © '.date('Y').' ').$companyName); ?>
</div>
</th>
</tr>
</table>
</section>
</div>
</body>
</html>
<?php /**PATH /home/amkworld/public_html/resources/themes/default/web-views/order/invoice.blade.php ENDPATH**/ ?>