コード例 #1
0
 private void InitalPage()
 {
     linkDefaultIndex.HRef = ConstantsManager.DEFAULT_ADMINISTRATOR_INDEX;
     if (!DataValidateManager.ValidateIsNull(Session[ConstantsManager.SESSION_USER_GROUP_ID]))
     {
         string[] strArrUserGroupID = ((string)Session[ConstantsManager.SESSION_USER_GROUP_ID]).Split(new char[] { ',' }, StringSplitOptions.RemoveEmptyEntries);
         foreach (string strUserGroupID in strArrUserGroupID)
         {
             string strUserGroupName;
             RICH.Common.BM.T_PM_UserGroupInfo.T_PM_UserGroupInfoBusinessEntityBase t_PM_UserGroupInfoBusinessEntityBase = new RICH.Common.BM.T_PM_UserGroupInfo.T_PM_UserGroupInfoBusinessEntityBase();
             strUserGroupName = (string)t_PM_UserGroupInfoBusinessEntityBase.GetValueByFixCondition("UserGroupID", strUserGroupID, "UserGroupName");
             if (!DataValidateManager.ValidateIsNull(strUserGroupName))
             {
                 ddlUserGroupID.Items.Add(new RadComboBoxItem(strUserGroupName, strUserGroupID));
             }
         }
     }
 }
コード例 #2
0
 private void InitalPage()
 {
     if (!DataValidateManager.ValidateIsNull(Session[ConstantsManager.SESSION_USER_GROUP_ID]))
     {
         string[]  strArrUserGroupID = ((string)Session[ConstantsManager.SESSION_USER_GROUP_ID]).Split(new char[] { ',' }, StringSplitOptions.RemoveEmptyEntries);
         Hashtable htUserGroup       = new Hashtable();
         foreach (string strUserGroupID in strArrUserGroupID)
         {
             string strUserGroupName;
             RICH.Common.BM.T_PM_UserGroupInfo.T_PM_UserGroupInfoBusinessEntityBase t_PM_UserGroupInfoBusinessEntityBase = new RICH.Common.BM.T_PM_UserGroupInfo.T_PM_UserGroupInfoBusinessEntityBase();
             strUserGroupName = (string)t_PM_UserGroupInfoBusinessEntityBase.GetValueByFixCondition("UserGroupID", strUserGroupID, "UserGroupName");
             if (!DataValidateManager.ValidateIsNull(strUserGroupName))
             {
                 htUserGroup.Add(strUserGroupID, strUserGroupName);
             }
         }
         UserGroupList.DataSource = htUserGroup;
         UserGroupList.DataBind();
         GetMenu(Request.Cookies["LAST_MENU_USERGROUPID"] != null
                     ? Server.UrlDecode(Request.Cookies["LAST_MENU_USERGROUPID"].Value)
                     : strArrUserGroupID[0]);
     }
 }