@extends('layouts.master') @section('css') @endsection @section('title') Sales @endsection @section('content')
@isset($accountingVoucher)
@method('put') @else @endisset @csrf
@isset($accountingVoucher) Edit Sales @else Add Sales @endisset
@isset($accountingVoucher) @if (str_contains($accountingVoucher->voucher_number, '-')) @php $explode = explode('-', $accountingVoucher->voucher_number); $voucherNumber = end($explode); $prefix = array_pop($explode); $prefix = implode('-', $explode); @endphp {{ $prefix }} @else @endif @else @if ($voucherType->prefix != null) {{ $voucherType->prefix }} @else @endif @endisset
@if ($companyProfile->show_date_of_supply)
@endif
@if ($companyProfile->customer_source == 1) @endif
Report
Add Items
@isset($accountingVoucherItems) @php $tabIndex = 0; @endphp @if (count($accountingVoucherItems) > 0) @php $grouped = $accountingVoucherItems->groupBy([ 'stock_item_id', 'unit_id', ]); $key = 0; @endphp @foreach ($grouped as $units) @foreach ($units as $accountingVoucherItem) @php $key = $key + 1; @endphp @php $price = $accountingVoucherItem->sum('gross_value') / $accountingVoucherItem->sum('quantity'); $gst = $accountingVoucherItem[0]->stockItem->gst; $price_incl_tax = $price + ($price * $gst) / 100; @endphp {{-- @dd($accountingVoucherItem->count()); --}} @php $tabIndex = $tabIndex + 8; @endphp @endforeach @endforeach @endif @endisset
SN    Item MRP Unit Qty Price Price(Inc GST) Gross Value Disc% Taxable Value Total Tax CGST SGST IGST CESS Total
{{ $key }}
{{ isset($accountingVoucherItems) ? $accountingVoucherItems->sum('total') : '0.00' }}
Discount :
Freight/Etc :
Round Off :
{{ isset($accountingVoucher) ? $accountingVoucher->round_off : '0.00' }}
Grand Total :
{{ isset($accountingVoucher) ? $accountingVoucher->amount : '0.00' }}
{{-- Modal --}} {{-- variant search modal --}} {{-- NeW Variant Modal --}} {{-- variant search modal --}} @endsection @section('script') @endsection