/// <summary> /// 初始化页面 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> /// <returns></returns> protected void Page_Load(object sender, EventArgs e) { string username = Request.QueryString["username"]; if (!userLogin.CheckLogin(username)) { string js = "alert('" + GetLangStr("Department18", "您没有登录或操作超时,请重新登录!") + "');window.top.location.href='" + StaticInfo.LoginPage + "'"; System.Web.HttpContext.Current.Response.Write("<script type='text/javascript'>" + js + "</script>"); return; } if (!X.IsAjaxRequest) { SystemID = "00"; StoreClass.DataSource = GetRedisData.GetData("t_sys_code:140004"); StoreClass.DataBind(); DataTable dt = settingManager.GetConfigDepartment(SystemID);//Bll.Common.ChangColName(ToDataTable(GetRedisData.GetData("t_cfg_department").Select("", "class asc,departid asc"))); while (dt.Columns.Count > 3) { dt.Columns.RemoveAt(3); } dtSsjg = dt; Storedepart.DataSource = dt; jgname = dt.Rows[0]["col2"].ToString(); Storedepart.DataBind(); FirstGetSysConfig(); UserInfo userinfo = Session["Userinfo"] as UserInfo; uName = userinfo.UserName; nowIp = userinfo.NowIp; logManager.InsertLogRunning(userinfo.UserName, GetLangStr("Department18", "访问:") + Request.QueryString["funcname"], userinfo.NowIp, "0"); } this.DataBind(); }