Filter Warehouse Combo in Direct Transfer

Hi guys,
this time i have a little problem, not urgent but i want to resolve it…
i have a Warehouse… that is assigned to a Part… this warehouse have all bins = Inactive, and when we do a “Direct Shipment” on “Transfer Order Shipment Entry”, this Warehouse appears on Warehouse List… how can i filter it? i’m dont worry if need to filter with code or description…


1

i see the trace for check what method is called:

<tracePacket>
  <businessObject>Ice.Proxy.Lib.BOReaderImpl</businessObject>
  <methodName>GetRows</methodName>
  ...
 <parameters>
    <parameter name="serviceNamespace" type="System.String"><![CDATA[Erp:BO:PartPlantWhseSearch]]></parameter>
    <parameter name="whereClause" type="System.String"><![CDATA[14409]]></parameter>
    <parameter name="columnList" type="System.String"><![CDATA[]]></parameter>
 </parameters>

But when i try to implement solution like that…

but when do i dont have the paramether “wereClause”


i tried too filtering on Customization of the form… but when do the all warehouses appears… (including the “inactive” warehouse).

any idea how can i resolve it?

i find the solution…

the solution was use the Post-Prosessing event, whit some custom code that delete the warehouse when it has no active bins:

bool tieneAlgoActivo = false;
List<int> aEliminar = new List<int>();

for (int index = result.PartPlantWhseSearch.Count-1; index >= 0; index--)
{
  Erp.Tablesets.PartPlantWhseSearchRow whse = result.PartPlantWhseSearch[index];
  tieneAlgoActivo = false;
  List<Erp.Tables.WhseBin> Whsebins = (from Whse_Bin in Db.WhseBin where     (Whse_Bin.WarehouseCode == whse.WarehouseCode) select Whse_Bin).ToList();
  
  foreach (Erp.Tables.WhseBin whseBin in Whsebins)
  {
      if (!whseBin.InActive)
      {
        tieneAlgoActivo = true;
      }
  }
  
 
  if (!tieneAlgoActivo)
  {
      aEliminar.Add(index);
  }
}

foreach (int index in aEliminar)
{
    result.PartPlantWhseSearch.RemoveAt(index);
}
1 Like