Exemplo n.º 1
0
        public void fillSite()
        {
            iUCCommonFilterClient UCCommonFilter = new iUCCommonFilterClient();
            CustomProfile         profile        = CustomProfile.GetProfile();

            ddlFrmSite.DataSource = UCCommonFilter.GetSiteNameByUserID_Transfer(profile.Personal.UserID, profile.DBConnection._constr);
            ddlFrmSite.DataBind();
            ListItem lstfrm = new ListItem();

            lstfrm.Text  = "--Select--";
            lstfrm.Value = "0";
            ddlFrmSite.Items.Insert(0, lstfrm);

            iUCCommonFilterClient          objService = new iUCCommonFilterClient();
            List <vGetUserProfileByUserID> UsersList  = new List <vGetUserProfileByUserID>();

            UsersList = objService.GetUserListBySiteID(1, profile.DBConnection._constr).ToList();
            UsersList = UsersList.Distinct().ToList();
            vGetUserProfileByUserID select = new vGetUserProfileByUserID()
            {
                userID = 0, userName = "******"
            };

            UsersList.Insert(0, select);

            ddlTransferedBy.DataSource = null;
            ddlTransferedBy.DataBind();
            ddlTransferedBy.DataSource = UsersList;
            ddlTransferedBy.DataBind();
        }
Exemplo n.º 2
0
        public void FillUserList()
        {
            iUCCommonFilterClient          objService = new iUCCommonFilterClient();
            List <vGetUserProfileByUserID> UsersList  = new List <vGetUserProfileByUserID>();

            try
            {
                CustomProfile profile = CustomProfile.GetProfile();
                UsersList = objService.GetUserListBySiteID(Convert.ToInt64(hdnSiteID.Value), profile.DBConnection._constr).ToList();
                UsersList = UsersList.Distinct().ToList();
                vGetUserProfileByUserID select = new vGetUserProfileByUserID()
                {
                    userID = 0, userName = "******"
                };
                UsersList.Insert(0, select);

                ddlReceivedBy.DataSource = null;
                ddlReceivedBy.DataBind();
                ddlReceivedBy.DataSource = UsersList;
                ddlReceivedBy.DataBind();
                ddlReceivedBy.SelectedIndex = ddlReceivedBy.Items.IndexOf(ddlReceivedBy.Items.FindByValue(profile.Personal.UserID.ToString()));
            }
            catch { }
            finally { objService.Close(); }
        }
        public static List <vGetUserProfileByUserID> WMFillUserList(long SiteID)
        {
            iUCCommonFilterClient          objService = new iUCCommonFilterClient();
            List <vGetUserProfileByUserID> UsersList  = new List <vGetUserProfileByUserID>();

            try
            {
                CustomProfile profile = CustomProfile.GetProfile();
                UsersList = objService.GetUserListBySiteID(SiteID, profile.DBConnection._constr).ToList();
                UsersList = UsersList.Distinct().ToList();
                vGetUserProfileByUserID select = new vGetUserProfileByUserID()
                {
                    userID = 0, userName = "******"
                };
                UsersList.Insert(0, select);
            }
            catch { }
            finally { objService.Close(); }
            return(UsersList);
        }
        public void FillUserList(long SiteID)
        {
            iUCCommonFilterClient          objService = new iUCCommonFilterClient();
            List <vGetUserProfileByUserID> UsersList  = new List <vGetUserProfileByUserID>();

            try
            {
                CustomProfile profile = CustomProfile.GetProfile();
                UsersList = objService.GetUserListBySiteID(SiteID, profile.DBConnection._constr).ToList();
                UsersList = UsersList.Distinct().ToList();
                vGetUserProfileByUserID select = new vGetUserProfileByUserID()
                {
                    userID = 0, userName = "******"
                };
                UsersList.Insert(0, select);

                ddlIssuedBy.DataSource = null;
                ddlIssuedBy.DataBind();
                ddlIssuedBy.DataSource = UsersList;
                ddlIssuedBy.DataBind();
            }
            catch { }
            finally { objService.Close(); }
        }