Example #1
0
		private void Page_Load(object sender, System.EventArgs e)
		{
			this.AuthenticatePage(new string[] {Globals.PermissionLevels.EditUsers, Globals.PermissionLevels.AddUsers, Globals.PermissionLevels.ViewUsers});
			if (this.OryxUser.RolePermission(Globals.PermissionLevels.AddUsers) != 2)
			{
				btnAddUser.Visible = false;
			}

			// Put user code to initialize the page here
			if (IsNewSession)
			{
				AddToListIfAdmin();
				IsNewSession = false;
			}

			if (!Page.IsPostBack)
			{
				BPGroups bp = new BPGroups();
				dsGroups = bp.SelectAllAdminGroups();
				lstGroups.DataBind();
				lstGroups.Items.Insert(0, new ListItem("(All Permission Groups)", "-1"));

				dgUsers.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue);
				BindDSUsers();
			}		
		}
Example #2
0
		protected void BindGroupsList()
		{
			BPGroups groups = new BPGroups();

			dsGroups = groups.SelectAllAdminGroups();

			dgGroups.DataBind();
		}