loaded pending pallet list against plant and customer po #814

Merged
jothi merged 1 commits from ranjith-dev into master 2026-07-07 07:09:44 +00:00

View File

@@ -169,13 +169,19 @@ class WireMasterPackingResource extends Resource
->options(function ($get) {
$plantId = $get('plant_id');
$customerPo = $get('customer_po_master_id');
if (! $plantId) {
if (!$plantId || !$customerPo) {
return [];
}
$customerPoIds = CustomerPoMaster::where('plant_id', $plantId)
->where('customer_po', $customerPo)
->pluck('id');
return WireMasterPacking::query()
->where('plant_id', $plantId)
->whereIn('customer_po_master_id', $customerPoIds)
->where(function ($query) {
$query->whereNull('wire_packing_status')
->orWhere('wire_packing_status', '');