@extends('layouts.master') @section('css') @endsection @section('title') Stock Journal @endsection @section('content')
@isset($inventoryVoucher)
@method('put') @else @endisset @csrf
@isset($inventoryVoucher) Edit Stock Journal @else Add Stock Journal @endisset
@isset($inventoryVoucher) @endisset
@isset($inventoryVoucher) @if (str_contains($inventoryVoucher->voucher_number, '-')) {{ explode('-', $inventoryVoucher->voucher_number)[0] }} @else @endif @else @if ($voucherType->prefix != null) {{ $voucherType->prefix }} @else @endif @endisset

Note* : Extra consumptions/Buy products are added to be last and Extra consumptions only added after destination items.

Source/Input
@isset($sourceInventoryVoucherItems) @if (count($sourceInventoryVoucherItems) > 0) @foreach ($sourceInventoryVoucherItems as $key => $inventoryVoucherItem) @php $key = $key + 1; @endphp @endforeach @endif @endisset
Location Item Qty Unit Price Total
{{ isset($sourceInventoryVoucherItems) ? number_format($sourceInventoryVoucherItems->sum('total'), 2) : '0.00' }}
Add
Destination/Output
@isset($destinationInventoryVoucherItems) @if (count($destinationInventoryVoucherItems) > 0) @foreach ($destinationInventoryVoucherItems as $key => $inventoryVoucherItem) @php $key = $key + 1; @endphp @endforeach @endif @endisset
Location Item Qty Unit Cost Total
{{ isset($destinationInventoryVoucherItems) ? number_format($destinationInventoryVoucherItems->sum('total'), 2) : '0.00' }}
Add
@endsection @section('script')