@extends('layouts.master') @section('css') @endsection @section('title') Stock Transfer @endsection @section('content') @isset($inventoryVoucher) @method('put') @else @endisset @csrf @isset($inventoryVoucher) Edit Stock Transfer @else Add Stock Transfer @endisset @isset($inventoryVoucher) Go Back @endisset Voucher Number @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 Voucher Type Select voucher type Voucher Date Source Select location @foreach ($stockLocations as $stockLocation) source_location_id == $stockLocation->id ? 'selected' : '') : '' }}> {{ $stockLocation->name }} @endforeach Destination Select location @foreach ($stockLocations as $stockLocation) destination_location_id == $stockLocation->id ? 'selected' : '') : '' }}> {{ $stockLocation->name }} @endforeach Remarks {{ isset($inventoryVoucher) ? $inventoryVoucher->remarks : '' }} Stock Transfer Item Variant Qty Unit Price Total @isset($inventoryVoucherItems) @php $tabIndex = 0; @endphp @if (count($inventoryVoucherItems) > 0) @foreach ($inventoryVoucherItems as $key => $inventoryVoucherItem) @php $key = $key + 1; @endphp Select item {{ $inventoryVoucherItem->stockItem->name }} Select Variant @foreach ($inventoryVoucherItem->stockItem->variants as $variant) variant_id == $variant->id ? 'selected' : '' }}> {{ $variant->name }} @endforeach unit_id == $inventoryVoucherItem->unit->id ? 'selected' : '') : '' }}> {{ $inventoryVoucherItem->unit->symbol }} @if ($inventoryVoucherItem->stockItem->stockItemUnits->isNotEmpty()) @foreach ($inventoryVoucherItem->stockItem->stockItemUnits as $unit) {{ $unit->unit->symbol }} @endforeach @endif @php $tabIndex = $tabIndex + 4; @endphp @endforeach @endif @endisset {{ isset($inventoryVoucherItems) ? number_format($inventoryVoucherItems->sum('total'), 2) : '0.00' }} Add Submit @endsection @section('script') @endsection