@extends('layouts.admin') @push('styles') @endpush @section('content') Product Distribution Update Distribution List @csrf @method('PUT') Date: * @error('disDate') {{ $message }} @enderror Department: * Select Department @foreach($departments as $v) dep_id == $v->id) ? "selected" : "" }} >{{$v->department_name}} @endforeach @error('dep_id') {{ $message }} @enderror Delivery Date: * @error('deliveryDate') {{ $message }} @enderror Sl Product Quantity (stock : ) Unit Rate Amount Action 1 Select Product @foreach($products as $v) {{$v->product_name}}-({{$v->product_code}}) @endforeach Add Loading... @if(!empty($disDetils)) @php $sl = 1; $total_amt = 0; $disItem['disItem'] = []; @endphp @foreach($disDetils as $v) @php $product_id = $v->product_id; $quantity = $v->quantity; $price = $v->rate; $total = $v->total; $unit_name = $v->unit_name; $pname = $v->product_name; $total_amt = $total_amt + $total; $sl=$sl+1; $disItem['disItem'][$product_id] = [ 'product_id' => $product_id, 'quantity' => $quantity, 'price' => $price, 'total' => $total, 'unit_name' => $unit_name, 'pname' => $pname ]; @endphp {{$sl}} {{$pname}} {{$quantity}} {{$unit_name}} {{$price}} {{$total}} Edit Delete @endforeach @php session(['disItem' => $disItem]); Request::session()->save(); @endphp Total: {{$total_amt}} @endif Note: {{$distribution->description}} @endsection @push('scripts') @endpush