protected virtual void INLotSerFilter_RowSelected(PXCache sender, PXRowSelectedEventArgs e) { INLotSerFilter filter = (INLotSerFilter)e.Row; if (filter != null) { PXUIFieldAttribute.SetVisible <INTranSplit.tranInventoryID>(Records.Cache, null, filter.InventoryID == null); PXUIFieldAttribute.SetVisible <INTranSplit.siteID>(Records.Cache, null, filter.SiteID == null); PXUIFieldAttribute.SetVisible <INTranSplit.locationID>(Records.Cache, null, filter.LocationID == null); } }
protected virtual void INTranSplit_RowSelected(PXCache sender, PXRowSelectedEventArgs e) { INTranSplit row = (INTranSplit)e.Row; INLotSerFilter filter = Filter.Current; if (row == null || filter == null) { return; } if (filter.ShowAdjUnitCost ?? false) { row.TranUnitCost = row.TotalQty == null || row.TotalQty == 0m ? 0m : (row.TotalCost + row.AdditionalCost) / row.TotalQty; } else { row.TranUnitCost = row.TotalQty == null || row.TotalQty == 0m ? 0m : (row.TotalCost) / row.TotalQty; } }