@php $offer_exist_in_cart=false; $cart_products=$data['cart_products_details']['product_array']; $product_grand_total=0; $product_grand_total_with_discount=0; $out_fit_ids=array(); $inactive_product_count=0; $inactive_product_array=array(); $appendcheck=$data['appendarray']; @endphp @if($appendcheck == 0) @endif @if(count($cart_products)>0)
@foreach ($cart_products as $cart_product) @endforeach
Product Price Quantity Amount

{{$cart_product['product_name']}}
Variant : {{$cart_product['product_size_name']}}
Color : {{$cart_product['product_color']}}

@php $product_price=$cart_product['product_price']; $product_quantity=$cart_product['product_quantity']; $product_total_price= $product_price*$product_quantity; $product_grand_total=$product_grand_total+$product_total_price; @endphp @php @endphp @if($cart_product['offer_datas']) @php $offer_exist_in_cart=true; $offer_details=$cart_product['offer_datas']; $offer_prc_once=$offer_details['product_offer_amount']; $offer_price=$offer_details['product_offer_amount']*$product_quantity; $offer_percentage=$offer_details['product_offer_percentage']; $product_grand_total_with_discount=$product_grand_total_with_discount+$offer_price; @endphp QAR {{sprintf("%.2f",$product_price)}} {{sprintf("%.2f",$offer_prc_once)}} @else @php $offer_prc_once=0; @endphp QAR {{sprintf("%.2f",$product_price)}} @php $product_grand_total_with_discount=$product_grand_total_with_discount+$product_total_price; @endphp @endif
+
-
QAR @if($offer_prc_once!=0){{sprintf("%.2f",$offer_prc_once*$cart_product['product_quantity'])}}@else {{sprintf("%.2f",$product_price*$cart_product['product_quantity'])}} @endif

Cart Total

Sub-Total QAR {{sprintf("%.2f", $product_grand_total )}}
Discount QAR @if($offer_exist_in_cart==true) {{sprintf("%.2f", $product_grand_total - $product_grand_total_with_discount)}} @else{{ sprintf("%.2f",'00') }}@endif
Total Amount QAR {{sprintf("%.2f",$product_grand_total_with_discount)}}
@else
@endif