@extends('frontend.layouts.app') @section('content')

{{ translate('1. My Cart') }}

{{ translate('2. Shipping info') }}

{{ translate('3. Delivery info') }}

{{ translate('4. Payment') }}

{{ translate('5. Confirmation') }}

@php $first_order = $combined_order->orders->first() @endphp

{{ translate('Thank You for Your Order!')}}

{{ translate('A copy or your order summary has been sent to') }} {{ json_decode($first_order->shipping_address)->email }}

{{ translate('Order Summary')}}
@php $shipping = json_decode($first_order->shipping_address); $billing = json_decode($first_order->billing_address); @endphp
{{ translate('Order date')}}: {{ date('d-m-Y H:i A', $first_order->date) }}
{{ translate('Name')}}: {{ json_decode($first_order->shipping_address)->name }}
{{ translate('Email')}}: {{ json_decode($first_order->shipping_address)->email }}
{{ translate('Shipping address')}}: {{ $shipping->address }}, {{ isset($shipping->city) && $shipping->city ? $shipping->city . ', ' : '' }} {{ isset($shipping->state) && $shipping->state ? $shipping->state . ', ' : '' }} {{ $shipping->country }}
{{ translate('Billing address')}}: {{ $billing->address }}, {{ isset($billing->city) && $billing->city ? $billing->city . ', ' : '' }} {{ isset($billing->state) && $billing->state ? $billing->state . ', ' : '' }} {{ $billing->country }}
{{ translate('Order status')}}: {{ translate(ucfirst(str_replace('_', ' ', $first_order->delivery_status))) }}
{{ translate('Total order amount')}}: {{ single_price($combined_order->grand_total) }}
{{ translate('Shipping')}}: {{ translate('Flat shipping rate')}}
{{ translate('Payment method')}}: {{ translate(ucfirst(str_replace('_', ' ', $first_order->payment_type))) }}
@foreach ($combined_order->orders as $order)

{{ translate('Order Code:')}} {{ $order->code }}

{{ translate('Delivery Type:')}} @if ($order->shipping_type != null && $order->shipping_type == 'home_delivery') {{ translate('Home Delivery') }} @elseif ($order->shipping_type != null && $order->shipping_type == 'carrier') {{ translate('Carrier') }} @elseif ($order->shipping_type == 'pickup_point') @if ($order->pickup_point != null) {{ $order->pickup_point->getTranslation('name') }} ({{ translate('Pickip Point') }}) @endif @endif
@if(get_seller_gstin($order) != null)
{{ translate('GSTIN:')}} {{get_seller_gstin($order)}}
@endif
{{ translate('Order Details')}}
@if(addon_is_activated('gst_system')) @if(same_state_shipping($order)) @else @endif @endif @foreach ($order->orderDetails as $key => $orderDetail) @if(addon_is_activated('gst_system')) @php $gst_amount = get_gst_by_price_and_rate($orderDetail->price - $orderDetail->coupon_discount , $orderDetail->gst_rate); $shipping_gst = get_gst_by_price_and_rate($orderDetail->shipping_cost, $orderDetail->gst_rate); @endphp @if(same_state_shipping($order)) @else @endif @endif @if(addon_is_activated('gst_system')) @else @endif @if(addon_is_activated('gst_system')) @if(same_state_shipping($order)) @else @endif @endif @endforeach
# {{ translate('Product')}} {{ translate('Qty')}}{{ translate('Gross Amount')}} {{ translate('Discount/ Coupon')}} {{ translate('Taxable Value')}}{{ translate('CGST')}} {{ translate('SGST')}}{{ translate('IGST')}}{{ translate('Price')}}
{{ $key+1 }} @if ($orderDetail->product != null) {{ $orderDetail->product->getTranslation('name') }} @php if($orderDetail->combo_id != null) { $combo = \App\ComboProduct::findOrFail($orderDetail->combo_id); echo '('.$combo->combo_title.')'; } @endphp

{{ $orderDetail->variation }}

@else {{ translate('Product Unavailable') }} @endif
{{ $orderDetail->quantity }} {{ single_price($orderDetail->price) }} {{ single_price($orderDetail->coupon_discount) }} {{ single_price($orderDetail->price - $orderDetail->coupon_discount) }} {{ single_price($gst_amount/2) }} {{ single_price($gst_amount/2) }} {{ single_price($gst_amount) }} {{ single_price($orderDetail->price - $orderDetail->coupon_discount + $gst_amount) }}{{ single_price($orderDetail->price) }}
{{translate('Shipping')}} 1 {{ single_price($orderDetail->shipping_cost) }} {{ single_price(0) }} {{ single_price($orderDetail->shipping_cost) }} {{ single_price($shipping_gst/2) }} {{ single_price($shipping_gst/2) }} {{ single_price($shipping_gst) }} {{ single_price($orderDetail->shipping_cost + (($orderDetail->shipping_cost* $orderDetail->gst_rate)/100)) }}
@if(addon_is_activated('gst_system')) @else @endif
{{ translate('Subtotal')}} {{ single_price($order->orderDetails->sum('price') + $order->orderDetails->sum('shipping_cost') - $order->orderDetails->sum('coupon_discount')) }}
{{ translate('GST Amount')}} {{ single_price($order->orderDetails->sum('gst_amount')) }}
{{ translate('Subtotal')}} {{ single_price($order->orderDetails->sum('price')) }}
{{ translate('Shipping')}} {{ single_price($order->orderDetails->sum('shipping_cost')) }}
{{ translate('Tax')}} {{ single_price($order->orderDetails->sum('tax')) }}
{{ translate('Coupon Discount')}} {{ single_price($order->coupon_discount) }}
{{ translate('Total')}} {{ single_price($order->grand_total) }}
@endforeach
@endsection @section('script') @if (get_setting('facebook_pixel') == 1) @endif @endsection