{{--

@lang('Invoice')

--}} @if(!empty(config('settings.site_logo')))   @endif

@lang('Order') # {{$order->orderno}}

{{config('app.name')}}
@if(config('settings.address_block_address')) {{config('settings.address_block_address')}}
@endif @if(config('settings.toll_free_number')) @lang('PhoneNo:') {{config('settings.toll_free_number')}}
@endif @if(config('settings.gstin')) @lang('GST NO:') {{config('settings.gstin')}}
@endif
@lang('Customer Details:')
{{$order->address->first_name}} {{$order->address->last_name}}
{{$order->address->address}}
{{$order->address->city}}, {{$order->address->state}}, {{$order->address->country}}.
@lang('Pincode:') {{$order->address->zip}}, @lang('Mob:') {{$order->address->phone}}
@if ($order->user) @if ($order->user->gstin) @lang('GST NO:') {{$order->user->gstin}}
@endif @endif
@lang('Payment Method:')
{{$order->payment_method}}
@lang('Order Date:')
{{$order->created_at->toFormattedDateString()}} {{$order->created_at->format('H:i:s')}}

@if(!($order->is_processed)) @lang('Order Status:')
@if($order->stock_regained) @lang('Cancelled') @elseif($order->payment_method != 'Cash on Delivery' && $order->paid == 0) @lang('Failed') @else @lang('Pending') @endif @endif
@foreach($order->products as $key=>$product) @endforeach @if($order->coupon_amount && $order->coupon_amount > 0) @endif
Product Name Price. Unit Tax (%) Quantity Total
{{$product->name}} @if($product->pivot->spec && ($specs = unserialize($product->pivot->spec)))
@foreach($specs as $key => $spec) {{$spec['name']}}: {{$spec['value']}}@if(!$loop->last), @endif @endforeach @endif
{{currency_format($product->pivot->product_price ? $product->pivot->product_price : $product->price ,$order->currency)}} {{ $product->pivot->tax_rate ? $product->pivot->tax_rate : $product->tax_rate}}% {{$product->pivot->quantity}} {{currency_format($product->pivot->total, $order->currency)}}
@lang('Subtotal') {{currency_format($order->total, $order->currency)}}
Tax:({{$order->tax}}%) + {{currency_format((($order->total * $order->tax) / 100), $order->currency)}}
Shipping Cost {{isset($order->shipping_cost) ? currency_format($order->shipping_cost, $order->currency) : currency_format(0, $order->currency)}}
Coupon Discount - {{currency_format($order->coupon_amount, $order->currency)}}
Total @php $order_total = $order->shipping_cost + $order->total - $order->coupon_amount + ($order->total * $order->tax) / 100; @endphp {{currency_format($order_total, $order->currency)}}

@if ($order_total > 0) {{ $order->numberToWords(floor($order_total))}} @endif