public List <Calbee.WMS.Services.MasterService.ItemUom> UOMDDLSingleBinding(string itemNumber) { try { List <Calbee.WMS.Services.MasterService.ItemUom> _listUOM = new List <Calbee.WMS.Services.MasterService.ItemUom>(); Calbee.WMS.Services.MasterService.ItemUom _master; _listUOM = Calbee.WMS.Services.Masters.MasterServiceProxy.WS.GetItemUoms(itemNumber, string.Empty).ToList(); if (_listUOM != null) { if (_listUOM.Count() > 1) { _master = new Calbee.WMS.Services.MasterService.ItemUom(); _master.Uom = Calbee.Infra.Common.Constants.WConstants.defaultDropdownSelect; _listUOM.Insert(0, _master); } } else { _listUOM = null; } return(_listUOM); } catch (Exception) { throw; } }
private void UOMBinding(string itemNumber) { try { List <Calbee.WMS.Services.MasterService.ItemUom> _listUOM = new List <Calbee.WMS.Services.MasterService.ItemUom>(); Calbee.WMS.Services.MasterService.ItemUom _master; _listUOM = Calbee.WMS.Services.Masters.MasterServiceProxy.WS.GetItemUoms(itemNumber, string.Empty).ToList(); if (_listUOM != null) { _master = new Calbee.WMS.Services.MasterService.ItemUom(); _master.Uom = Calbee.Infra.Common.Constants.WConstants.defaultDropdownSelect; _listUOM.Insert(0, _master); ComboBoxBinding.BindEntityToCombobox(_listUOM, this.cmbUOM, "Uom", "ItemUomId", ""); } else { this.cmbUOM.DataSource = null; } } catch (Exception ex) { if (ex.InnerException != null) { MsgBox.DialogError(ex.InnerException.Message.ToString()); } else { if (Calbee.Infra.Common.Constants.IConstants.CatchFlag.Equals("Y")) { // Show error description detail MsgBox.DialogError(ex.GetBaseException().ToString()); } else { // Show message error MsgBox.DialogError(ex.Message.ToString()); } } } }
public List <Calbee.WMS.Services.MasterService.ItemUom> UOMDDLDefault(string itemNumber) { try { List <Calbee.WMS.Services.MasterService.ItemUom> _listUOM = new List <Calbee.WMS.Services.MasterService.ItemUom>(); Calbee.WMS.Services.MasterService.ItemUom _master; _listUOM = Calbee.WMS.Services.Masters.MasterServiceProxy.WS.GetItemUoms(itemNumber, string.Empty).ToList(); if (_listUOM != null) { _master = new Calbee.WMS.Services.MasterService.ItemUom(); _listUOM.Insert(0, _master); } else { _listUOM = null; } return(_listUOM); } catch (Exception) { throw; } }