@extends('layouts.location') @section('title', 'SO Approval') @section('page-title', 'SO Approval') @section('content')
| SO No(s) | PIC ID | Status | Accept Remark | Reject Remark | Action | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| {{ $soLabel ?: '-' }} | {{ $picId ?? '-' }} | {{ $firstRow->status ?? '-' }} | {{ $firstRow->accept_remark_account ?? '' }} | {{ $firstRow->reject_remark_account ?? '' }} |
|
|||||||||||||
|
||||||||||||||||||
| No picklist records with status = inv-completed. | ||||||||||||||||||
| SO No | Total Boxes | Total Weight | Status | Accept Remark | Reject Remark | Action | |||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| {{ $soNo }} | {{ $boxCount }} | {{ $totalWeight }} | {{ $firstRow->status ?? '-' }} | {{ $firstRow->accept_remark_account ?? '' }} | {{ $firstRow->reject_remark_account ?? '' }} |
|
|||||||||||||||||
|
Short / Difference items for SO {{ $soNo }}:
@php
$unboxedDiffs = $diffsForSo->filter(function ($d) use ($allBoxKeys) {
$k = isset($d['item_key']) ? (string) $d['item_key'] : '';
return $k !== '' && !$allBoxKeys->contains($k);
})->values();
@endphp
@if($rows->isNotEmpty())
@foreach($rows as $r)
@php
$packId = (string) $r->id;
$keysForBox = isset($boxKeysByPackId[$packId]) ? $boxKeysByPackId[$packId] : collect();
if (!$keysForBox instanceof \Illuminate\Support\Collection) {
$keysForBox = collect($keysForBox);
}
$diffsForBox = $diffsForSo->filter(function ($d) use ($keysForBox) {
$k = isset($d['item_key']) ? (string) $d['item_key'] : '';
return $k !== '' && $keysForBox->contains($k);
})->values();
$boxVal = $r->box;
$boxDecoded = null;
try {
$boxDecoded = json_decode($r->box, true);
} catch (\Throwable $e) {
}
if (is_array($boxDecoded)) {
$boxVal = implode(', ', $boxDecoded);
}
@endphp
Box: {{ $boxVal }}
@if($diffsForBox->isNotEmpty())
No quantity differences for this box.
@endif
Box: -
No quantity differences for this SO.
@endif
|
|||||||||||||||||||||||
| No packlist records with status = inv-completed. | |||||||||||||||||||||||