@extends('layouts.main') @section('content')

Quotation Management


@include('layouts/invoicePIQuotation/head')
@include('layouts/invoicePIQuotation/header')
@php $count=1; $rowtotal=0.0; $i_show=0; $cs_show=0; $gstvalue=0.0; $rowgst=0.0; $price=0.0; $rowttl=0.0; $subtotal=0.0; $gsttotal=0.0; $grandtotalbfround=0.0; $grandtotal=0.0; @endphp @foreach( $product_details as $value ) @php if($value->c_s_gst=="null") { $i_show=1; $gstvalue=trim($value->i_gst,"%"); $rowgst=($value->unit_cost/100)*($gstvalue)*($value->quantity); $rowgst=number_format($rowgst,2); } elseif($value->i_gst=="null") { $cs_show=1; $gststring=preg_replace('/[^A-Za-z0-9-+-.\-]/', ' ', $value->c_s_gst); $gstvalue=strtok($gststring, '+'); $display=((float)$gstvalue*2); $rowgst=($value->unit_cost/100)*(((int)$gstvalue)*2)*($value->quantity); $rowgst=number_format($rowgst,2); } $rowtotal=$value->unit_cost*$value->quantity; $rowttl=$rowtotal; $rowtotal=number_format($rowtotal,2); $subtotal=($subtotal+$rowttl); $gsttotal=((float)$gsttotal+((float)$rowgst)); $grandtotalbfround=($subtotal)+($gsttotal); $bfround=round($grandtotalbfround); $roundvalue=($grandtotalbfround-$bfround); $roundvalue=number_format($roundvalue,2); if($roundvalue < 0) { $grandtotal=$grandtotalbfround+-($roundvalue); $grandttl=$grandtotalbfround+-($roundvalue); $roundvalue=-($roundvalue); $grandtotal=number_format($grandtotal,2); } else if($roundvalue > 0) { $grandtotal=$grandtotalbfround-($roundvalue); $grandttl=$grandtotalbfround-($roundvalue); $roundvalue=-($roundvalue); $grandtotal=number_format($grandtotal,2); } else { $grandtotal=$grandtotalbfround; $grandttl=$grandtotalbfround; $grandtotal=number_format($grandtotal,2); } $words=getIndianCurrency($grandttl); $price=number_format($value->unit_cost,2); @endphp @if($value->c_s_gst=="null") @elseif($value->i_gst=="null") @endif @php $count++; @endphp @endforeach
Sr NO. Product Name HSN GST(%) Quantity Unit Cost Total
{{$count}} {{ $value->name }} {{ $value->HSN }}{{ $value->i_gst }}{{ $display }}%{{ $value->quantity }} ₹{{ $price }} ₹{{ $rowtotal }}
OUR GSTIN: 24AALFT2125L1Z3
{{$data->note ? $data->note : ""}}
RS. {{ucwords($words)}}
@if($i_show==1) @elseif($cs_show==1) @endif
Sub Total: ₹{{ $subtotal }}
IGST: ₹{{ $gsttotal }}
SGST: ₹{{ $gsttotal/2 }}
CGST: ₹{{ $gsttotal/2 }}
Round Off: ₹{{ $roundvalue }}
Grand Total: ₹{{ $grandtotal }}
For, Tanna TechBiz LLP
@endsection