protected void btnDelete_Click(object sender, EventArgs e) { GroupAuthorization clsGroup = new GroupAuthorization(); clsGroup.DeleteGroup((string)ViewState["GroupID"]); //记录操作员操作 RecordOperate.SaveRecord(Session["UserID"].ToString(), "组权限设置", "删除用户组权限信息"); Server.Transfer("System_GroupAuthorization_Index.aspx"); }
/// <summary> /// DataGrid选择项响应事件方法 /// </summary> /// <param name="source"></param> /// <param name="e"></param> protected void DataOperate(object source, DataGridCommandEventArgs e) { if (e.CommandName == "Delete") { GroupAuthorization clsGroup = new GroupAuthorization(); string GroupID = ((Label)e.Item.Cells[0].Controls[1]).Text; clsGroup.DeleteGroup(GroupID); //记录操作员操作 RecordOperate.SaveRecord(Session["UserID"].ToString(), "组权限设置", "删除用户组权限信息"); Server.Transfer("System_GroupAuthorization_Index.aspx"); } else { //使用弹出屏幕对话窗口方式快整录入房间 string Url = "System_GroupAuthorization_Edit.aspx?GroupID=" + ((Label)e.Item.Cells[0].Controls[1]).Text; Server.Transfer(Url); } }