public V_WMS_GetWareLocationByLocID GetWarehouseLocByID(long LocationID, long WarehouseID, string[] conn)
        {
            BISPL_CRMDBEntities          ce       = new BISPL_CRMDBEntities(svr.GetEntityConnection(conn));
            V_WMS_GetWareLocationByLocID Location = new V_WMS_GetWareLocationByLocID();

            Location = (from p in ce.V_WMS_GetWareLocationByLocID
                        where p.ID == LocationID && p.WarehouseID == WarehouseID
                        select p).FirstOrDefault();
            return(Location);
        }
Example #2
0
        public void GetLocationDetailByID(long LocationID, long WarehouseID)
        {
            CustomProfile                profile         = CustomProfile.GetProfile();
            iWarehouseClient             Warehouseclient = new iWarehouseClient();
            V_WMS_GetWareLocationByLocID Location        = new V_WMS_GetWareLocationByLocID();

            Location = Warehouseclient.GetWarehouseLocByID(LocationID, WarehouseID, profile.DBConnection._constr);
            if (Location.Code != null)
            {
                txtlocationCode.Text = Location.Code.ToString();
            }
            if (Location.AliasCode != null)
            {
                txtaliascode.Text = Location.AliasCode.ToString();
            }
            if (Location.SortCode != null)
            {
                txtsortCode.Text = Location.SortCode.ToString();
            }
            if (Location.Capacity != null)
            {
                txtcapacity.Text = Location.Capacity.ToString();
            }
            if (Location.LocationType != null)
            {
                ddllocationtype.SelectedIndex = ddllocationtype.Items.IndexOf(ddllocationtype.Items.FindByValue(Location.LocationType.ToString()));
            }
            if (Location.CapacityIn != null)
            {
                ddlcapacityin.SelectedIndex = ddlcapacityin.Items.IndexOf(ddlcapacityin.Items.FindByValue(Location.CapacityIn.ToString()));
            }
            if (Location.VelocityType != null)
            {
                ddlvelocityType.SelectedIndex = ddlvelocityType.Items.IndexOf(ddlvelocityType.Items.FindByValue(Location.VelocityType.ToString()));
            }
            if (Location.shelfID != null)
            {
                hdnShelfID.Value = Location.shelfID.ToString();
            }
            if (Location.Building != null)
            {
                txtbuilding.Text = Location.Building.ToString();
            }
            if (Location.Floar != null)
            {
                txtfloar.Text = Location.Floar.ToString();
            }
            if (Location.Passage != null)
            {
                txtpathway.Text = Location.Passage.ToString();
            }
            if (Location.Section != null)
            {
                txtsection.Text = Location.Section.ToString();
            }
            if (Location.Shelf != null)
            {
                txtshelf.Text = Location.Shelf.ToString();
            }
            if (Location.Active.Trim() == "Yes")
            {
                radiochannelY.Checked = true;
            }
            else
            {
                radiochannelN.Checked = true;
            }
        }