{{__('Pricing Summary')}}


{{ __("Product Price:") }}
{{ sprintf("%.2f",$product->vender_price) }}
@if($product->tax_r != '') ({{__("Incl. of tax")}}) @else {{__("(Excl. of Tax)")}} @endif

{{__("Commission Summary")}}


@php $commision_setting = \DB::table('commission_settings')->first(); $commissionRate = 0; $mpc = 0; $show_price = 0; $convert_price = 0; if($commision_setting->type == "flat"){ $commission_amount = $commision_setting->rate; $commissionRate = $commission_amount; if($commision_setting->p_type == 'f'){ $totalprice = $product->vender_price+$commission_amount; $totalsaleprice = $product->vender_offer_price + $commission_amount; if($product->vender_offer_price == 0){ $show_price = $totalprice; }else{ $totalsaleprice; $convert_price = $totalsaleprice =='' ? $totalprice:$totalsaleprice; $show_price = $totalprice; } }else{ $totalprice = ($product->vender_price)*$commission_amount; $totalsaleprice = ($product->vender_offer_price)*$commission_amount; $commissionRate = $totalprice/100; $mpc = $totalprice/100; $buyerprice = ($product->vender_price)+($totalprice/100); $buyersaleprice = ($product->vender_offer_price)+($totalsaleprice/100); if($product->vender_offer_price == NULL){ $show_price = round($buyerprice,2); }else{ round($buyersaleprice,2); $convert_price = $buyersaleprice=='' ? $buyerprice:$buyersaleprice; $show_price = $buyerprice; } } }else{ $comm = \DB::table('commissions')->where('category_id',$product->category_id)->first(); if(isset($comm)){ if($comm->type=='f'){ $commissionRate = $comm->rate; $price = $product->vender_price + $comm->rate; if($vender_offer_price != null){ $offer = $product->vender_offer_price + $comm->rate; } if($product->vender_offer_price == 0 || $product->vender_offer_price == null){ $show_price = $price; }else{ $convert_price = $offer; $show_price = $price; } }else{ $commissionRate = $comm->rate; $commission_amount = $comm->rate; $totalprice = ($product->vender_price)*$commission_amount; $totalsaleprice = ($product->vender_offer_price)*$commission_amount; $commissionRate = $totalprice/100; $mpc = $totalprice/100; $buyerprice = ($product->vender_price)+($totalprice/100); $buyersaleprice = ($product->vender_offer_price)+($totalsaleprice/100); if($product->vender_offer_price == 0){ $show_price = round($buyerprice,2); }else{ $convert_price = round($buyersaleprice,2); $convert_price = $buyersaleprice==''?$buyerprice:$buyersaleprice; $show_price = round($buyerprice,2); } } } } @endphp @php $ctax = 0; if($product->tax_r !=''){ $p=100; $taxrate_db = $product->tax_r; $vp = $p+$taxrate_db; $tam = $commissionRate/$vp*$taxrate_db; $tam = sprintf("%.2f",$tam); $ctax = $tam; } @endphp
{{ __("Net Commission") }}:
@if($product->tax_r =='') {{ sprintf("%.2f",$commissionRate) }} @else {{ sprintf("%.2f", $commissionRate-$ctax) }} @endif
@if($product->tax_r !='')
{{__("Commission Tax:")}}
{{ sprintf("%.2f", $ctax) }}
{{__("Gross Commission:")}}
{{ sprintf("%.2f", $commissionRate) }}
@if($product->tax_r !='') (Incl. of Tax) @endif
@endif
@if($product->vender_offer_price != '')

{{__("Offer Pricing Summary")}}


{{__("Product Offer Price:")}}
{{ sprintf("%.2f", $product->vender_offer_price) }}
@if($product->tax_r !='') ({{__("Incl. of tax")}}) @else {{__("(Excl. of Tax)")}} @endif

{{__('Commission Summary')}}


@php $commision_setting = \DB::table('commission_settings')->first(); $commissionRate = 0; $mpc = 0; if($commision_setting->type == "flat"){ $commission_amount = $commision_setting->rate; $commissionRate = $commission_amount; if($commision_setting->p_type == 'f'){ $totalprice = $product->vender_price+$commission_amount; $totalsaleprice = $product->vender_offer_price + $commission_amount; if($product->vender_offer_price == 0){ $show_price = $totalprice; }else{ $totalsaleprice; $convert_price = $totalsaleprice =='' ? $totalprice:$totalsaleprice; $show_price = $totalprice; } }else{ $totalprice = ($product->vender_price)*$commission_amount; $totalsaleprice = ($product->vender_offer_price)*$commission_amount; if(!($totalsaleprice)){ $commissionRate = $totalprice/100; $mpc = $totalprice/100; }else{ $commissionRate = $totalsaleprice/100; $mpc = $totalprice/100; } $buyerprice = ($product->vender_price)+($totalprice/100); $buyersaleprice = ($product->vender_offer_price)+($totalsaleprice/100); if($product->vender_offer_price == NULL){ $show_price = round($buyerprice,2); }else{ round($buyersaleprice,2); $convert_price = $buyersaleprice=='' ? $buyerprice:$buyersaleprice; $show_price = $buyerprice; } } }else{ $comm = \DB::table('commissions')->where('category_id',$product->category_id)->first(); if(isset($comm)){ if($comm->type=='f'){ $commissionRate = $comm->rate; $mpc = $comm->rate; $price = $product->vender_price + $comm->rate; if($product->vender_offer_price != null){ $offer = $product->vender_offer_price + $comm->rate; } if($product->vender_offer_price == 0 || $product->vender_offer_price == null){ $show_price = $price; }else{ $convert_price = $offer; $show_price = $price; } }else{ $commissionRate = $comm->rate; $commission_amount = $comm->rate; $totalprice = $product->vender_price*$commission_amount; $totalsaleprice = $product->vender_offer_price*$commission_amount; if(!($totalsaleprice)){ $commissionRate = $totalprice/100; $mpc = $totalprice/100; }else{ $commissionRate = $totalsaleprice/100; $mpc = $totalprice/100; } $buyerprice = ($product->vender_price)+($totalprice/100); $buyersaleprice = ($product->vender_offer_price)+($totalsaleprice/100); if($product->vender_offer_price == 0){ $show_price = round($buyerprice,2); }else{ $convert_price = round($buyersaleprice,2); $convert_price = $buyersaleprice==''?$buyerprice:$buyersaleprice; $show_price = round($buyerprice,2); } } } } @endphp @php $ctax = 0; if($product->tax_r !=''){ $p=100; $taxrate_db = $product->tax_r; $vp = $p+$taxrate_db; $tam = $commissionRate/$vp*$taxrate_db; $tam = sprintf("%.2f",$tam); $ctax = $tam; } @endphp
Net Commission:
@if($product->tax_r =='') {{ sprintf("%.2f", $commissionRate) }} @else {{ sprintf("%.2f",$commissionRate-$ctax) }} @endif
@if($product->tax_r !='')
{{__("Commission Tax:") }}
{{ sprintf("%.2f", $ctax) }}
{{__("Gross Commission:")}}
{{ sprintf("%.2f", $commissionRate) }}
@if($product->tax_r !='') ({{__("Incl. of Tax")}}) @endif
@endif
@endif

{{__("Final Selling Price")}}


@if($product->tax_r !='')
Selling Price:
{{ sprintf("%.2f", $product->vender_price+$mpc ) }}
(Incl. of Tax)
@else
{{__("Selling Priced:")}}
{{ sprintf("%.2f", $show_price) }}
({{__("Excl. of Tax")}})
@endif
@if($product->vender_offer_price != '')

{{__("Final Selling Offer Price:")}}


@if($product->tax_r !='')
{{__('Selling Offer Price:')}}
{{ sprintf("%.2f", $product->vender_offer_price+$commissionRate) }}
(Incl. of Tax)
@else
{{__("Selling Offer Price:")}}
{{ sprintf("%.2f", $convert_price) }}
({{__("Excl. of Tax")}})
@endif
@endif