protected void Page_Load(object sender, EventArgs e) { string roleId = Request.QueryString["role"]; this.Page.Response.CacheControl = "no-cache"; this.calcProgress.Tag = roleId; if (Page.IsPostBack == false) { SCRole role = (SCRole)MCS.Library.SOA.DataObjects.Security.Adapters.SchemaObjectAdapter.Instance.Load(roleId); if (role == null || role.Status != SchemaObjectStatus.Normal) { throw new ObjectNotFoundException("未查询到指定的角色或角色已不再有效"); } SCApplication app = DbUtil.LoadApplicationForRole(role); this.RoleAndAppObject = new RoleAndAppData() { AppID = app.ID, AppCodeName = app.CodeName, AppName = app.Name, RoleCodeName = role.CodeName, RoleID = role.ID, RoleName = role.Name, RoleDisplayName = role.DisplayName }; this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = this.grid2.PageSize = ProfileUtil.PageSize; this.views.ActiveViewIndex = ProfileUtil.GeneralViewModeIndex; } this.binding1.Data = this.RoleAndAppObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { this.Response.Cache.SetCacheability(HttpCacheability.NoCache); Util.InitSecurityContext(this.notice); if (this.IsPostBack == false) { SCBase obj = (SCBase)PC.Adapters.SchemaObjectAdapter.Instance.Load(Request.QueryString["id"]); if (obj is SCUser) { var userRoles = PC.Adapters.SCSnapshotAdapter.Instance.QueryUserBelongToRoles(new string[] { "Roles" }, string.Empty, new string[] { obj.ID }, false, DBTimePointActionContext.Current.TimePoint); string[] additionIds = new string[userRoles.Count]; for (int i = additionIds.Length - 1; i >= 0; i--) { additionIds[i] = userRoles[i].ID; } this.AdditionIds = additionIds; } this.appName.Text = obj.Name; this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(thisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = ProfileUtil.PageSize; } this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { string roleId = Request.QueryString["role"]; Util.InitSecurityContext(this.notice1); this.Page.Response.CacheControl = "no-cache"; if (Page.IsPostBack == false) { var role = (SCRole)DbUtil.GetEffectiveObject(roleId, null); var app = role.CurrentApplication; this.RoleAndAppObject = new RoleAndAppData() { AppID = app.ID, AppCodeName = app.CodeName, AppDisplayName = app.DisplayName, RoleCodeName = role.CodeName, RoleDisplayName = role.DisplayName, RoleID = role.ID, RoleName = role.Name }; this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = this.grid2.PageSize = ProfileUtil.PageSize; this.views.ActiveViewIndex = ProfileUtil.GeneralViewModeIndex; } this.binding1.Data = this.RoleAndAppObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { string appID = GetAppIDFromRequestOrRedirect(); this.ctlUpload.Tag = appID; Util.InitSecurityContext(this.notice); this.Page.Response.CacheControl = "no-cache"; if (Page.IsPostBack == false) { this.AppObject = SchemaObjectAdapter.Instance.Load(appID).ToSimpleObject(); if (this.AppObject == null && this.AppObject.Status != SchemaObjectStatus.Normal) { throw new ObjectNotFoundException("指定的应用不存在或已删除"); } this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = ProfileUtil.PageSize; } this.binding1.Data = this.AppObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { string userId = Request.QueryString["id"]; this.Page.Response.CacheControl = "no-cache"; Util.InitSecurityContext(this.notice); if (Page.IsPostBack == false) { var user = (SCUser)DbUtil.GetEffectiveObject(userId, null); this.UserObject = user.ToSimpleObject(); this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = this.grid2.PageSize = ProfileUtil.PageSize; this.views.ActiveViewIndex = ProfileUtil.GeneralViewModeIndex; } if (Request.QueryString["view"] == "boss") { this.tabBosses.Attributes.Add("class", "pc-active"); this.grid2.GridTitle = this.gridMain.GridTitle = "上司列表"; } else { this.tabSecretaries.Attributes.Add("class", "pc-active"); this.grid2.GridTitle = this.gridMain.GridTitle = "秘书列表"; } this.binding1.Data = this.UserObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
internal static void SaveSearchCondition(MCS.Web.WebControls.SearchEventArgs e, MCS.Web.WebControls.DeluxeSearch control, string pageKey, object dataToSave) { if (e.IsSaveCondition && string.IsNullOrEmpty(e.ConditionName) == false) { UserCustomSearchCondition condition = Util.NewSearchCondition(pageKey, "Default", e.ConditionName); condition.ConditionContent = JSONSerializerExecute.Serialize(dataToSave); UserCustomSearchConditionAdapter.Instance.Update(condition); control.UserCustomSearchConditions = DbUtil.LoadSearchCondition(pageKey, "Default"); } }
protected override void OnLoad(EventArgs e) { Util.InitSecurityContext(this.notice); base.OnLoad(e); if (Page.IsPostBack == false) { this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = ProfileUtil.PageSize; } this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { Util.InitSecurityContext(this.notice); if (Page.IsPostBack == false) { this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.views.ActiveViewIndex = ProfileUtil.GeneralViewModeIndex; this.grid2.PageSize = this.gridMain.PageSize = ProfileUtil.PageSize; } this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { Util.InitSecurityContext(this.notice); this.hfOuId.Value = PC.SCOrganization.RootOrganizationID; if (Page.IsPostBack == false) { this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = ProfileUtil.PageSize; } this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { Util.InitSecurityContext(this.notice); if (Page.IsPostBack == false) { this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.hfViewMode.Value = ProfileUtil.UserBrowseModeIndex.ToString(); this.views.ActiveViewIndex = this.hfViewMode.Value == "2" ? 1 : 0; this.gridView2.PageSize = ProfileUtil.PageSize; this.gridViewUsers.PageSize = ProfileUtil.PageSize; } this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected override void OnLoad(EventArgs e) { base.OnLoad(e); if (this.Page.IsPostBack == false) { this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.grid2.PageSize = this.gridMain.PageSize = ProfileUtil.PageSize; this.gridViews.ActiveViewIndex = ProfileUtil.GeneralViewModeIndex; } this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { this.Page.Response.CacheControl = "no-cache"; if (this.IsPostBack == false) { this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); if (string.IsNullOrEmpty(this.gridMain.SortExpression)) { this.gridMain.Sort("CreateTime", SortDirection.Descending); } this.gridMain.PageSize = ProfileUtil.PageSize; } this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { string userId = Request.QueryString["id"]; Util.InitSecurityContext(this.notice); this.Page.Response.CacheControl = "no-cache"; if (Page.IsPostBack == false) { this.UserObject = DbUtil.GetEffectiveObject <SCUser>(userId).ToSimpleObject(); this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = ProfileUtil.PageSize; } this.binding1.Data = this.UserObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { Response.Cache.SetCacheability(HttpCacheability.NoCache); if (Page.IsPostBack == false && Page.IsCallback == false) { this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = this.gridMain.PageSize = ProfileUtil.PageSize; if (this.InitState() == false) { this.Server.Transfer("~/lists/OUNotFound.aspx"); return; } } this.binding1.Data = this.ParentOrganization; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { string appId = Request.QueryString["app"]; Util.InitSecurityContext(this.notice); this.Page.Response.CacheControl = "no-cache"; if (Page.IsPostBack == false) { this.AppObject = SchemaObjectAdapter.Instance.Load(appId).ToSimpleObject(); this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = ProfileUtil.PageSize; } this.binding1.Data = this.AppObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; this.ctlUpload.Tag = appId; }
protected void Page_Load(object sender, EventArgs e) { this.Response.Cache.SetCacheability(HttpCacheability.NoCache); Util.InitSecurityContext(this.notice); this.Page.Response.CacheControl = "no-cache"; if (Page.IsPostBack == false) { ControllerHelper.ExecuteMethodByRequest(this); this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = this.grid2.PageSize = ProfileUtil.PageSize; this.views.ActiveViewIndex = ProfileUtil.GeneralViewModeIndex; } this.binding1.Data = this.UserObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { string id = Request.QueryString["id"]; Util.InitSecurityContext(this.notice); this.Page.Response.CacheControl = "no-cache"; if (Page.IsPostBack == false) { this.UserObject = DbUtil.GetEffectiveObject(id, string.Format("指定的群组(ID:{0})无效", id)).ToSimpleObject(); this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = this.grid2.PageSize = ProfileUtil.PageSize; this.views.ActiveViewIndex = ProfileUtil.GeneralViewModeIndex; } this.binding1.Data = this.UserObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }
protected void Page_Load(object sender, EventArgs e) { string groupId = Request.QueryString["id"]; Util.InitSecurityContext(this.notice); this.Page.Response.CacheControl = "no-cache"; if (Page.IsPostBack == false) { this.GroupObject = DbUtil.GetEffectiveObject(groupId, null).ToSimpleObject(); this.GroupParentId = SchemaRelationObjectAdapter.Instance.LoadByObjectID(this.GroupObject.ID).Find(m => m.Status == SchemaObjectStatus.Normal).ParentID; this.DeluxeSearch.UserCustomSearchConditions = DbUtil.LoadSearchCondition(ThisPageSearchResourceKey, "Default"); this.CurrentAdvancedSearchCondition = new PageAdvancedSearchCondition(); this.gridMain.PageSize = this.grid2.PageSize = ProfileUtil.PageSize; this.views.ActiveViewIndex = ProfileUtil.GeneralViewModeIndex; } this.binding1.Data = this.GroupObject; this.searchBinding.Data = this.CurrentAdvancedSearchCondition; }