protected void Page_Load(object sender, EventArgs e) { if (!PEContext.Current.Admin.IsSuperAdmin) { AdminPage.WriteErrMsg("<li>本模块只有超级管理员身份才能访问!</li>"); } RolePermissions.BusinessAccessCheck(OperateCode.AdministratorManage); string str = BasePage.RequestString("UserName"); if (!string.IsNullOrEmpty(str)) { this.TxtUserName.Text = str; } if (!base.IsPostBack) { int adminId = BasePage.RequestInt32("AdminId"); this.RadPurview1.Attributes.Add("onclick", "javascript:RadPurview(0);"); this.RadPurview2.Attributes.Add("onclick", "javascript:RadPurview(1);"); this.NotBelongRoleDataBind(this.LstNotBelongRole, adminId); this.BelongToRole(this.LstBelongToRole, adminId); this.BtnSubmit.OnClientClick = "return GetBelongToRole(" + this.LstBelongToRole.ClientID + ");"; if (string.Compare(BasePage.RequestString("Action"), "Modify", StringComparison.OrdinalIgnoreCase) == 0) { this.InitModify(); } } }
protected void Page_Load(object sender, EventArgs e) { RolePermissions.BusinessAccessCheck(OperateCode.SpecialManage); this.specialId = BasePage.RequestInt32("SpecialID"); this.specialCategoryId = BasePage.RequestInt32("SpecialCategoryID"); this.InitialText(); }
protected void Page_Load(object sender, EventArgs e) { if (!this.Page.IsPostBack) { RolePermissions.BusinessAccessCheck(OperateCode.CreateHtmlManage); this.ListDataBind(this.LstNodes); } }
protected void Page_Load(object sender, EventArgs e) { if (!base.IsPostBack) { RolePermissions.BusinessAccessCheck(OperateCode.CreateHtmlManage); RolePermissions.BusinessAccessCheck(OperateCode.SpecialManage); this.ListDataBind(this.LstSpecialsCategory); } }
protected void EBtnDelete_Click(object sender, EventArgs e) { RolePermissions.BusinessAccessCheck(OperateCode.NodeContentManage, DataConverter.CLng(this.contentDataTable.Rows[0]["NodeId"])); if (ContentManage.UpdateStatus(this.m_GeneralId, -3)) { AdminPage.WriteSuccessMsg("<li>删除成功!</li>", "ContentManage.aspx?NodeID=" + this.contentDataTable.Rows[0]["NodeId"].ToString()); } else { AdminPage.WriteErrMsg("<li>删除失败!</li>"); } }
protected void Page_Load(object sender, EventArgs e) { try { RolePermissions.BusinessAccessCheck(OperateCode.CategoryInfoManage); } catch (CustomException exception) { AdminPage.WriteErrMsg("<li>您没有此功能权限,错误原因:" + exception.Message + "!</li>"); } this.Initial(); }
protected void Page_Load(object sender, EventArgs e) { try { RolePermissions.BusinessAccessCheck(OperateCode.SpecialInfoManage); } catch (CustomException exception) { AdminPage.WriteErrMsg("<li>您没有此功能权限,错误原因:" + exception.Message + "!</li>"); } this.action = BasePage.RequestStringToLower("Action", "special"); this.Initial(); }
public static bool Delete(int id) { RolePermissions.BusinessAccessCheck(OperateCode.UserGroupManage); if (dal.Delete(id)) { DeleteUserGroupRelation(id); } foreach (UserInfo info in Users.GetUsersByGroupId(id.ToString())) { info.GroupId = 1; Users.Update(info); } return(true); }
protected void Page_Load(object sender, EventArgs e) { RolePermissions.BusinessAccessCheck(OperateCode.CreateHtmlManage); if (!base.IsPostBack) { foreach (NodeInfo info in Nodes.GetNodesList(NodeType.Single)) { ListItem item = new ListItem(); item.Text = info.NodeName; item.Value = info.NodeId.ToString(); item.Enabled = info.IsCreateListPage; this.LstSinglePage.Items.Add(item); } } }
protected void Page_Load(object sender, EventArgs e) { this.m_UrlReferrer = base.Request.UrlReferrer.ToString(); this.nodeList = this.xmlDoc.SelectNodes("CreateWork/WorkId"); this.xmlDoc.Load(this.path); RolePermissions.BusinessAccessCheck(OperateCode.CreateHtmlManage); this.HdnWorkId.Value = BaseUserControl.RequestString("WorkId"); if (this.nodeList.Count > 0) { this.BtnStopCreate.Visible = true; } else { this.BtnStopCreate.Visible = false; } }
protected void Page_Load(object sender, EventArgs e) { RolePermissions.BusinessAccessCheck(OperateCode.CreateHtmlManage); this.HdnIsCreateHtml.Value = BasePage.RequestString("isCreateHtml"); string nodeValue = XmlManage.Instance("Config/CreateCollectionWork.config", XmlType.File).GetNodeValue("CollectionWork/WorkId"); this.m_UrlReferrer = base.Request.UrlReferrer.ToString(); if (base.Application[nodeValue] != null) { this.BtnStopCreate.Visible = true; } else { this.BtnStopCreate.Visible = false; } }
protected void EBtnPass_Click(object sender, EventArgs e) { this.PermissionDetection(this.m_isCheck); StringBuilder selectList = this.EgvContent.SelectList; if (selectList.Length == 0) { AdminPage.WriteErrMsg("<li>对不起,您还没选择要审核的项目!</li>", "ContentManage.aspx?NodeID=" + BasePage.RequestInt32("NodeID")); } else { int nodeWorkFlowId = Nodes.GetNodeWorkFlowId(this.m_NodeId); RolePermissions.BusinessAccessCheck(OperateCode.NodeContentCheck, this.m_NodeId); if (this.m_Administrator) { UpdateStatus(selectList.ToString(), 0x63, SiteConfig.SmsConfig.IsAutoSendStateMessage, this.EgvContent, this.m_Administrator); } else if (Nodes.GetNodeById(BasePage.RequestInt32("NodeID")).Child == 0) { UpdateStatus(selectList.ToString(), UserPass(nodeWorkFlowId), SiteConfig.SmsConfig.IsAutoSendStateMessage, this.EgvContent, this.m_Administrator); } else { CommonModelInfo info2 = new CommonModelInfo(); if (selectList.ToString().IndexOf(",", StringComparison.Ordinal) > 0) { foreach (string str in selectList.ToString().Split(new string[] { "," }, StringSplitOptions.RemoveEmptyEntries)) { nodeWorkFlowId = Nodes.GetNodeWorkFlowId(Nodes.GetNodeById(ContentManage.GetCommonModelInfoById(DataConverter.CLng(str)).NodeId).WorkFlowId); ContentManage.UpdateStatus(str, UserPass(nodeWorkFlowId)); } AdminPage.WriteSuccessMsg("<li>审核通过!</li>", "ContentManage.aspx?NodeID=" + BasePage.RequestInt32("NodeID")); } else { nodeWorkFlowId = Nodes.GetNodeWorkFlowId(Nodes.GetNodeById(ContentManage.GetCommonModelInfoById(DataConverter.CLng(selectList.ToString())).NodeId).WorkFlowId); UpdateStatus(selectList.ToString(), UserPass(nodeWorkFlowId), SiteConfig.SmsConfig.IsAutoSendStateMessage, this.EgvContent, this.m_Administrator); } } } }
protected void EBtnModify_Click(object sender, EventArgs e) { RolePermissions.BusinessAccessCheck(OperateCode.NodeContentManage, DataConverter.CLng(this.contentDataTable.Rows[0]["NodeId"])); StringBuilder builder = new StringBuilder(); if (ModelManager.GetModelInfoById(DataConverter.CLng(this.contentDataTable.Rows[0]["ModelID"].ToString())).IsEshop) { builder.Append("../shop/Product.aspx"); } else { builder.Append("Content.aspx"); } builder.Append("?Action=Modify&NodeID="); builder.Append(this.contentDataTable.Rows[0]["NodeId"].ToString()); builder.Append("&GeneralID="); builder.Append(this.m_GeneralId.ToString()); builder.Append("&ModelID="); builder.Append(this.contentDataTable.Rows[0]["ModelID"].ToString()); builder.Append("&LinkType="); builder.Append(this.contentDataTable.Rows[0]["LinkType"].ToString()); BasePage.ResponseRedirect(builder.ToString()); }
protected void Page_Load(object sender, EventArgs e) { RolePermissions.BusinessAccessCheck(OperateCode.SpecialManage); if (!this.Page.IsPostBack) { switch (BasePage.RequestStringToLower("Action", "")) { case "clear": this.ClearSpecialInfos(); break; case "delete": this.DeleteSpecial(); break; } this.DropRescentQuery.SelectedValue = BasePage.RequestStringToLower("ListType"); this.HdnListType.Value = BasePage.RequestStringToLower("ListType"); if (BasePage.RequestInt32("SpecialCategoryID") > 0) { this.LblOrderType.Visible = false; this.DropRescentQuery.Visible = false; } } }
protected override void OnInit(EventArgs e) { base.OnInit(e); RolePermissions.BusinessAccessCheck(OperateCode.AdManage); }
protected void Page_Load(object sender, EventArgs e) { RolePermissions.BusinessAccessCheck(OperateCode.SpecialManage); this.Initial(); }