コード例 #1
0
ファイル: LogList.aspx.cs プロジェクト: 454240357/SmartLaw
        protected void Page_Load(object sender, EventArgs e)
        {
            _user = SessionUser.GetSession();
            _user.ValidateAuthority("Auth_Log");

            if (!IsPostBack)
            {
                DataSet ds = _su.GetList(4, "1");
                DataRow dr = ds.Tables[0].NewRow();
                dr[0] = "不限";
                dr[1] = "";
                dr[2] = "";
                dr[3] = "不限";
                dr[4] = 1;
                ds.Tables[0].Rows.InsertAt(dr, 0);
                RadComboBox1.DataTextField = "UserName";
                RadComboBox1.DataValueField = "UserId";
                RadComboBox1.DataSource = ds.Tables[0];
                RadComboBox1.DataBind();
                RadDatePicker1.DbSelectedDate = DateTime.Today;
                RadComboBox1.SelectedValue = _user.UserInfo.UserID;
                _selectedV = _user.UserInfo.UserID;
                RGrid_LogList.Visible = false;
            }
        }
コード例 #2
0
ファイル: Login.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Bt_Login_Click(object sender, EventArgs e)
 {
     string loginId = TB_LoginId.Text.Trim();
     string password = TB_Password.Text.Trim();
     if (CB_Storage.Checked)
         StoragePwd(loginId, password);
     SessionUser user = new SessionUser();
     user.SetSession(loginId, password, Session);
     if (SessionUser.IsLogined())
     {
         Model.Log logM = new Model.Log();
         logM.OperationItem = "操作员登录";
         logM.Operator = loginId;
         logM.OperationTime = DateTime.Now;
         logM.OperationDetail = "ip:【" + Request.UserHostAddress + "】";
         _log.Add(logM);
         if (Request.QueryString["returnurl"] == null)
             Response.Redirect("NewsManage/NewsList.aspx");
         else
             Response.Redirect(HttpUtility.UrlDecode(Request.QueryString["returnurl"].ToString()));
     }
     else
     {
         RadScriptManager.RegisterStartupScript(this.Page, this.GetType(), "c1", "OpenAlert('用户名不存在或密码错误!');", true);
     }
 }
コード例 #3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_Code_CRUD");
     if (!IsPostBack)
         RGrid_SysCode.Visible = false;
 }
コード例 #4
0
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     if (!IsPostBack)
     {
         SetInitialRowgrid();
     }
 }
コード例 #5
0
ファイル: GiftEdit.aspx.cs プロジェクト: 454240357/SmartLaw
        protected void Page_Load(object sender, EventArgs e)
        {
            _user = SessionUser.GetSession();
            if (!IsPostBack)
            {

            }
        }
コード例 #6
0
ファイル: GiftList.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Page_Load(object sender, EventArgs e)
 {
     _user = SessionUser.GetSession();
     if (!IsPostBack)
     {
         RGrid_GiftList.Visible = false;
     }
 }
コード例 #7
0
ファイル: LogDetail.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Page_Load(object sender, EventArgs e)
 {
     AutoId = Request.QueryString["AutoID"];
     _user = SessionUser.GetSession();
     _user.ValidateAuthority("Auth_Log");
     if (!IsPostBack)
         if (!ReadValue())
             Panel1.Visible = false;
 }
コード例 #8
0
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_Category_CRUD");
     cpautoID = long.Parse(Request.QueryString["CategoryParentID"]);
     if (!IsPostBack)
         if (!ReadValue())
             Panel1.Visible = false;
 }
コード例 #9
0
 protected void Page_Load(object sender, EventArgs e)
 {
     sysCodeId = Request.QueryString["SysCodeId"];
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_Code_CRUD");
     if (!IsPostBack)
         if (!ReadValue())
             Panel1.Visible = false;
 }
コード例 #10
0
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     if (!user.hasAuthority("Auth_SysUser_Add"))
     {
         href1.Visible = false;
     }
     if (!IsPostBack)
         RGrid_SysUserList.Visible = false;
 }
コード例 #11
0
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     QnID = long.Parse(Request.QueryString["ID"]);
     if (!IsPostBack)
     {
         if (!ReadValue())
         {
             Panel1.Visible = false;
         }
     }
 }
コード例 #12
0
 protected override void OnLoad(EventArgs e)
 {
     user = SessionUser.GetSession();
     qnID = long.Parse(Request.QueryString["qnID"]);
     if (!IsPostBack)
     {
         if (!ReadValue())
         {
             Panel1.Visible = false;
         }
     }
 }
コード例 #13
0
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     LoginId = user.UserInfo.UserID;
     if (!IsPostBack)
     {
         DataSet ds = scd.GetListBySysCode(user.UserInfo.UserID, "Role");
         string role = "";
         if (ds.Tables[0].Rows.Count != 0)
         {
             role = ds.Tables[0].Rows[0]["SysCodeDetialContext"].ToString();
         }
         Ltr_OperatorInfo.Text =  "("+role+")";
     }
 }
コード例 #14
0
ファイル: AddEndUser.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_EndUser_Add");
     if (!IsPostBack)
     {
         List<Model.SysCodeDetail> identityList = scd.GetModelList(0, "Identity", -1, 1, false);
         identityList.RemoveAll(rt => rt.IsValid == false);
         RCB_Identity.DataTextField = "SYSCodeDetialContext";
         RCB_Identity.DataValueField = "SYSCodeDetialID";
         RCB_Identity.DataSource = identityList;
         RCB_Identity.DataBind();
         BindRegionTree();
     }
 }
コード例 #15
0
 protected void Page_Load(object sender, EventArgs e)
 {
     BhID = Request.QueryString["BhID"];
     uName = Request.QueryString["uName"];
     simCardNo = Request.QueryString["simCardNo"];
     ipAddr = Request.QueryString["ipAddr"];
     sTime = Request.QueryString["sTime"];
     eTime = Request.QueryString["eTime"];
     _user = SessionUser.GetSession();
     if (!IsPostBack)
     {
         if (!ReadValue())
             Panel1.Visible = false;
     }
 }
コード例 #16
0
ファイル: NewsCheck.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_News_Examine");
     if (!user.hasAuthority("Auth_News_Retrieve"))
     {
         href1.Visible = false;
     }
     if (!user.hasAuthority("Auth_News_Add"))
     {
         A1.Visible = false;
     }
     if (!IsPostBack)
     {
         ReadValue();
     }
 }
コード例 #17
0
ファイル: LeftMenu.ascx.cs プロジェクト: 454240357/SmartLaw
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                _user = SessionUser.GetSession();
                RadPanelItem radPanelItem3 = new RadPanelItem("终端用户管理");

                if (_user.hasAuthority("Auth_EndUser_Retrieve"))
                {
                    radPanelItem3.Items.Add(new RadPanelItem("检索终端用户", "EndUserList.aspx"));
                }
                if (_user.hasAuthority("Auth_EndUser_Add"))
                {
                    radPanelItem3.Items.Add(new RadPanelItem("添加终端用户", "AddEndUser.aspx"));
                }
                RadPanelBar1.Items.Add(radPanelItem3);
            }
        }
コード例 #18
0
ファイル: LeftMenu.ascx.cs プロジェクト: 454240357/SmartLaw
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                _user = SessionUser.GetSession();
                RadPanelItem radPanelItem3 = new RadPanelItem("条目管理");

                if (_user.hasAuthority("Auth_News_Retrieve"))
                {
                    radPanelItem3.Items.Add(new RadPanelItem("检索条目", "NewsList.aspx"));
                }
                if (_user.hasAuthority("Auth_News_Add"))
                {
                    radPanelItem3.Items.Add(new RadPanelItem("添加条目", "NewsEdit.aspx"));
                }
                if (_user.hasAuthority("Auth_News_Examine"))
                {
                    radPanelItem3.Items.Add(new RadPanelItem("条目审核", "NewsCheck.aspx"));
                }
                RadPanelBar1.Items.Add(radPanelItem3);
            }
        }
コード例 #19
0
        protected void Page_Load(object sender, EventArgs e)
        {
            _user = SessionUser.GetSession();
            RadListBox1.Transferred += new RadListBoxTransferredEventHandler(RadListBox1_Transferred);
            if (!IsPostBack)
            {
                List<Model.SysCodeDetail> scdList1 = scd.GetModelList(0, "UserBehavior", -1, -1, false);
                scdList1.RemoveAll(at => at.IsValid == false);
                RadListBox1.DataTextField = "Memo";
                RadListBox1.DataValueField = "SYSCodeDetialID";
                RadListBox1.DataSource = scdList1;
                RadListBox1.DataBind();

                List<Model.SysCodeDetail> scdList0 = scd.GetModelList(0, "UserBehavior", -1, -1, false);
                scdList0.RemoveAll(at => at.IsValid == true);
                RadListBoxDestination.DataTextField = "Memo";
                RadListBoxDestination.DataValueField = "SYSCodeDetialID";
                RadListBoxDestination.DataSource = scdList0 ;
                RadListBoxDestination.DataBind();

            }
        }
コード例 #20
0
ファイル: LeftMenu.ascx.cs プロジェクト: 454240357/SmartLaw
        protected void Page_Load(object sender, EventArgs e)
        {
            _user = SessionUser.GetSession();
            if (!IsPostBack)
            {
                RadPanelItem radPanelItem3 = new RadPanelItem("系统代码管理");
                radPanelItem3.Items.Add(new RadPanelItem("查看系统代码", "SysCodeList.aspx"));
                radPanelItem3.Items.Add(new RadPanelItem("新建系统代码", "AddSysCode.aspx"));
                if (_user.hasAuthority("Auth_Code_CRUD"))
                {
                    RadPanelBar1.Items.Add(radPanelItem3);
                }

                RadPanelItem radPanelItem2 = new RadPanelItem("管理操作员");
                radPanelItem2.Items.Add(new RadPanelItem("查询操作员", "SysUserList.aspx"));
                if (_user.hasAuthority("Auth_SysUser_Add"))
                {
                    radPanelItem2.Items.Add(new RadPanelItem("添加操作员", "AddSysUser.aspx"));
                }
                RadPanelBar1.Items.Add(radPanelItem2);
            }
        }
コード例 #21
0
ファイル: NoticeEdit.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_Notice_Add");
     if (!IsPostBack)
     {
         RadDatePicker1.DbSelectedDate = DateTime.Today;
         List<Model.SysCodeDetail> msgTypeList = scd.GetModelList(0, "MessageType", -1, 1, false);
         msgTypeList.RemoveAll(rt => rt.IsValid == false);
         RCB_Type.DataTextField = "SYSCodeDetialContext";
         RCB_Type.DataValueField = "SYSCodeDetialID";
         RCB_Type.DataSource = msgTypeList;
         RCB_Type.DataBind();
         RCB_Type.SelectedValue = "Popup";
         List<Model.SysCodeDetail> popmsgDisTypeList = scd.GetModelList(0, "PopmsgCloseType", -1, 1, false);
         popmsgDisTypeList.RemoveAll(rt => rt.IsValid == false);
         RCB_DisType.DataTextField = "Memo";
         RCB_DisType.DataValueField = "SYSCodeDetialID";
         RCB_DisType.DataSource = popmsgDisTypeList;
         RCB_DisType.DataBind();
         Div1.Visible = true;
         List<Model.SysCodeDetail> identityList = scd.GetModelList(0, "Identity", -1, 1, false);
         identityList.RemoveAll(rt => rt.IsValid == false);
         RadListBox1.DataTextField = "SYSCodeDetialContext";
         RadListBox1.DataValueField = "SYSCodeDetialID";
         RadListBox1.DataSource = identityList;
         RadListBox1.DataBind();
         BindRegionTree();
     }
 }
コード例 #22
0
ファイル: MainMenu.ascx.cs プロジェクト: 454240357/SmartLaw
        protected void Page_Load(object sender, EventArgs e)
        {
            user = SessionUser.GetSession();
            if (!IsPostBack)
            {

                RadMenuItem radMenuItem1 = new RadMenuItem("功能(F)");
                radMenuItem1.AccessKey = "F";
                radMenuItem1.Items.Add(new RadMenuItem("注销(E)"));
                radMenuItem1.Items.Add(new RadMenuItem("关闭(X)"));
                radMenuItem1.PostBack = false;

                RadMenuItem radMenuItem4 = new RadMenuItem("系统代码管理(M)");
                radMenuItem4.AccessKey = "M";
                if (user.hasAuthority("Auth_Code_CRUD"))
                {
                    radMenuItem4.Items.Add(new RadMenuItem("查看系统代码(V)", "SystemManage/SysCodeList.aspx") { AccessKey = "V" });
                    radMenuItem4.Items.Add(new RadMenuItem("新建系统代码(N)", "SystemManage/AddSysCode.aspx") { AccessKey = "N" });
                    radMenuItem4.Items.Add(new RadMenuItem() { IsSeparator = true });
                }
                radMenuItem4.Items.Add(new RadMenuItem("查看操作员(V)", "SystemManage/SysUserList.aspx") { AccessKey = "V" });
                if (user.hasAuthority("Auth_SysUser_Add"))
                {
                    radMenuItem4.Items.Add(new RadMenuItem("新建操作员(N)", "SystemManage/AddSysUser.aspx") { AccessKey = "N" });
                }
                radMenuItem4.PostBack = false;

                RadMenuItem radMenuItem3 = new RadMenuItem("条目管理(P)");
                radMenuItem3.AccessKey = "P";
                bool newsTag = false;

                if (user.hasAuthority("Auth_News_Retrieve"))
                {
                    newsTag = true;
                    radMenuItem3.Items.Add(new RadMenuItem("检索条目(B)", "NewsManage/NewsList.aspx") { AccessKey = "B" });
                }
                if (user.hasAuthority("Auth_News_Add"))
                {
                    newsTag = true;
                    radMenuItem3.Items.Add(new RadMenuItem("添加条目(J)", "NewsManage/NewsEdit.aspx") { AccessKey = "J" });
                }

                if (user.hasAuthority("Auth_News_Examine"))
                {
                    newsTag = true;
                    radMenuItem3.Items.Add(new RadMenuItem("条目审核(E)", "NewsManage/NewsCheck.aspx") { AccessKey = "E" });

                }
                RadMenuItem radMenuItem8 = new RadMenuItem("公告管理(P)");
                radMenuItem8.AccessKey = "N";
                radMenuItem8.Items.Add(new RadMenuItem("公告添加(K)", "NoticeManage/NoticeEdit.aspx") { AccessKey = "K" });
                radMenuItem8.Items.Add(new RadMenuItem("公告列表(H)", "NoticeManage/NoticeList.aspx") { AccessKey = "H" });

                RadMenuItem radMenuItem9 = new RadMenuItem("积分管理(I)");
                radMenuItem9.AccessKey = "I";
                radMenuItem9.Items.Add(new RadMenuItem("积分历史(K)", "IntegralManage/IntegralList.aspx") { AccessKey = "K" });
                radMenuItem9.Items.Add(new RadMenuItem("积分配置(C)", "IntegralManage/IntegralConfiguration.aspx") { AccessKey = "C" });
                radMenuItem9.Items.Add(new RadMenuItem("礼品查询(L)", "IntegralManage/GiftList.aspx") { AccessKey = "L" });
                radMenuItem9.Items.Add(new RadMenuItem("礼品定义(D)", "IntegralManage/GiftEdit.aspx") { AccessKey = "D" });
                radMenuItem9.Items.Add(new RadMenuItem("积分兑换记录(H)", "IntegralManage/IntegralExchangeRecords.aspx") { AccessKey = "H" });

                RadMenuItem radMenuItem10 = new RadMenuItem("问卷管理(Q)");
                radMenuItem10.AccessKey = "Q";
                radMenuItem10.Items.Add(new RadMenuItem("检索问卷(C)", "QuestionnaireManage/QuestionnaireList.aspx") { AccessKey = "C" });
                radMenuItem10.Items.Add(new RadMenuItem("添加问卷(A)", "QuestionnaireManage/QuestionnaireEdit.aspx") { AccessKey = "A" });

                RadMenuItem radMenuItem6 = new RadMenuItem("分类管理(C)");
                radMenuItem6.AccessKey = "C";
                radMenuItem6.Items.Add(new RadMenuItem("分类查询(S)", "CategoryManage/CategoryView.aspx") { AccessKey = "S" });

                RadMenuItem radMenuItem7 = new RadMenuItem("终端用户管理(C)");
                radMenuItem7.AccessKey = "U";

                bool userTag = false;

                if (user.hasAuthority("Auth_EndUser_Retrieve"))
                {
                    userTag = true;
                    radMenuItem7.Items.Add(new RadMenuItem("查询终端用户(R)", "EndUserManage/EndUserList.aspx") { AccessKey = "R" });
                }
                if (user.hasAuthority("Auth_News_Add"))
                {
                    userTag = true;
                    radMenuItem7.Items.Add(new RadMenuItem("添加终端用户(A)", "EndUserManage/AddEndUser.aspx") { AccessKey = "A" });

                }

                RadMenuItem radMenuItem11 = new RadMenuItem("用户行为分析(C)");
                radMenuItem11.AccessKey = "C";
                radMenuItem11.Items.Add(new RadMenuItem("用户行为统计(A)", "UserBehaviorManage/UserBehaviorStatistics.aspx") { AccessKey = "A" });

                RadMenuItem radMenuItem5 = new RadMenuItem("日志管理(L)");
                radMenuItem5.AccessKey = "L";
                radMenuItem5.Items.Add(new RadMenuItem("日志查询(R)", "LogManage/LogList.aspx") { AccessKey = "R" });

                RadMenuItem skinMenu = new RadMenuItem("皮肤(T)");
                skinMenu.AccessKey = "T";
                skinMenu.Items.Add(new RadMenuItem("Windows7") { AccessKey = "W" });
                skinMenu.Items.Add(new RadMenuItem("Black") { AccessKey = "B" });
                skinMenu.Items.Add(new RadMenuItem("Metro") { AccessKey = "M" });
                skinMenu.PostBack = false;

                AddRadMenuItem(radMenuItem1);

                if (newsTag)
                {
                    AddRadMenuItem(radMenuItem3);
                }
                AddRadMenuItem(radMenuItem8);
                if (userTag)
                {
                    AddRadMenuItem(radMenuItem7);
                }
                AddRadMenuItem(radMenuItem10);
                AddRadMenuItem(radMenuItem9);
                AddRadMenuItem(radMenuItem11);
                AddRadMenuItem(radMenuItem6);
                AddRadMenuItem(radMenuItem4);
                if (user.hasAuthority("Auth_Log"))
                {
                    AddRadMenuItem(radMenuItem5);
                }

                AddRadMenuItem(skinMenu);
            }
        }
コード例 #23
0
ファイル: NewsEdit.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Page_Load(object sender, EventArgs e)
 {
     Model.SysCodeDetail widthModel = scd.GetModel("img_width");
     if (widthModel != null)
     {
         img_width = int.Parse(widthModel.SYSCodeDetialContext);
     }
     Model.SysCodeDetail heightModel = scd.GetModel("img_height");
     if (heightModel != null)
     {
         img_height = int.Parse(heightModel.SYSCodeDetialContext);
     }
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_News_Add");
     if (!user.hasAuthority("Auth_News_Retrieve"))
     {
         href1.Visible = false;
     }
     if (!user.hasAuthority("Auth_News_Examine"))
     {
         A1.Visible = false;
     }
     contentEditor.EditModes = EditModes.All;
     contentEditor.EditModes = contentEditor.EditModes ^ EditModes.Preview;
     contentEditor.ImageManager.ContentProviderTypeName = typeof(ChangeImageSizeProvider).AssemblyQualifiedName;
     if (!user.hasAuthority("Auth_Image_Upload"))
     {
         string[] a = { "" };
         contentEditor.ImageManager.UploadPaths = a;
         contentEditor.ImageManager.DeletePaths = a;
         contentEditor.ImageManager.ViewPaths = a;
     }
     if (!IsPostBack)
     {
         List<Category> cgList = cg.DataTableToList(cg.GetList(5, "1", -1, 0, false).Tables[0]);
         cgList.RemoveAll(CT => !CT.Memo.Contains("RW"));
         DataTable table = new DataTable();
         table.Columns.Add("AutoID");
         table.Columns.Add("ParentCategoryID");
         table.Columns.Add("CategoryName");
         foreach (Category cgm in cgList)
         {
             if (cgm.ParentCategoryID==-1)
             {
                 table.Rows.Add(new String[] { cgm.AutoID.ToString(), null, cgm.CategoryName });
             }
             else
             {
                 table.Rows.Add(new String[] { cgm.AutoID.ToString(), cgm.ParentCategoryID.ToString(), cgm.CategoryName });
             }
         }
         RadDropDownTree2.DataFieldID = "AutoID";
         RadDropDownTree2.DataFieldParentID = "ParentCategoryID";
         RadDropDownTree2.DataValueField = "AutoID";
         RadDropDownTree2.DataTextField = "CategoryName";
         RadDropDownTree2.DataSource = table;
         RadDropDownTree2.DataBind();
         RadTreeView categoryTreeView = RadDropDownTree2.Controls[0] as RadTreeView;
         categoryTreeView.Nodes[0].Expanded = true;
         categoryTreeView.ShowLineImages = false;
     }
 }
コード例 #24
0
ファイル: Login.aspx.cs プロジェクト: 454240357/SmartLaw
        private void ValidatePwd()
        {
            HttpCookie cookie = Request.Cookies["Login"];
            if (cookie == null)
                return;
            string loginId = cookie.Values["loginId"];
            string password;
            try
            {
                string psw = cookie.Values["pwd"].Replace(' ', '+');
                password = Encoding.UTF8.GetString(Convert.FromBase64String(psw));
            }
            catch
            {
                return;
            }

            SessionUser user = new SessionUser();
            user.SetSession(loginId, password, Session);
            if (SessionUser.IsLogined())
            {
                string skinValue = "Windows7";
                Session["SkinId"] = skinValue;
                Model.Log logM = new Model.Log();
                logM.OperationItem = "操作员登录";
                logM.Operator = loginId;
                logM.OperationTime = DateTime.Now;
                logM .OperationDetail = "ip:【" + Request.UserHostAddress + "】";
                _log.Add(logM);
                if (Request.QueryString["returnurl"] == null)
                    Response.Redirect("NewsManage/NewsList.aspx");
                else
                    Response.Redirect(HttpUtility.UrlDecode(Request.QueryString["returnurl"].ToString()));
            }
            TB_LoginId.Text = loginId;
        }
コード例 #25
0
 protected void Page_Load(object sender, EventArgs e)
 {
     SimID = Request.QueryString["SimID"];
     _user = SessionUser.GetSession();
     if (!IsPostBack)
         if (!ReadValue())
             Panel1.Visible = false;
 }
コード例 #26
0
 protected void Page_Load(object sender, EventArgs e)
 {
     _user = SessionUser.GetSession();
     if (!IsPostBack)
     {
         List<Model.SysCodeDetail> scdList = scd.GetModelList(0, "UserBehavior", -1, -1, false);
         SmartLaw.Model.SysCodeDetail scdM = new Model.SysCodeDetail();
         scdM.SYSCodeDetialID = "-1";
         scdM.Memo = "不限";
         scdList.Insert(0, scdM);
         RCB_Behaviour.DataTextField = "Memo";
         RCB_Behaviour.DataValueField = "SYSCodeDetialID";
         RCB_Behaviour.DataSource = scdList;
         RCB_Behaviour.DataBind();
         RGrid_List.Visible = false;
     }
 }
コード例 #27
0
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_EndUser_Edit");
     AutoID = long.Parse(Request.QueryString["AutoID"]);
     if (!IsPostBack)
     {
         if (!ReadValue())
         {
             Panel1.Visible = false;
         }
     }
 }
コード例 #28
0
ファイル: AddSysUser.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_SysUser_Add");
     if (!IsPostBack)
     {
         DataSet dsRole = scd.GetListBySysCode(user.UserInfo.UserID, "Role");
         String role = dsRole.Tables[0].Rows[0]["SYSCodeDetialID"].ToString();
         List<Model.SysCodeDetail> scdList = scd.GetModelList(0, "Role", -1, 3, true);
         scdList.RemoveAll(st => st.IsValid==false);
         RCB_Role.DataTextField = "SYSCodeDetialContext";
         RCB_Role.DataValueField = "SYSCodeDetialID";
         RCB_Role.DataSource = scdList;
         RCB_Role.DataBind();
     }
 }
コード例 #29
0
ファイル: NewsList.aspx.cs プロジェクト: 454240357/SmartLaw
        protected void Page_Load(object sender, EventArgs e)
        {
            user = SessionUser.GetSession();
            //user.ValidateAuthority("Auth_News_Retrieve");
            if (!user.hasAuthority("Auth_News_Add"))
            {
                href1.Visible = false;
            }
            if (!user.hasAuthority("Auth_News_Examine"))
            {
                A1.Visible = false;
            }
            if (!IsPostBack)
            {
                RGrid_NewsList.Visible = false;
                //初始化分类选择下拉树
                List<Model.Category> cgList = cg.DataTableToList(cg.GetList(5, "1", -1, 0, false).Tables[0]);
                cgList.RemoveAll(CT => !CT.Memo.Contains("R"));
                DataTable table = new DataTable();
                table.Columns.Add("AutoID");
                table.Columns.Add("ParentCategoryID");
                table.Columns.Add("CategoryName");
                foreach (Model.Category cgm in cgList)
                {
                    if (cgm.ParentCategoryID == -1)
                    {
                        table.Rows.Add(new String[] { cgm.AutoID.ToString(), null, cgm.CategoryName });
                    }
                    else
                    {
                        table.Rows.Add(new String[] { cgm.AutoID.ToString(), cgm.ParentCategoryID.ToString(), cgm.CategoryName });
                    }
                }
                RadDropDownTree2.DataFieldID = "AutoID";
                RadDropDownTree2.DataFieldParentID = "ParentCategoryID";
                RadDropDownTree2.DataValueField = "AutoID";
                RadDropDownTree2.DataTextField = "CategoryName";
                RadDropDownTree2.DataSource = table;
                RadDropDownTree2.DataBind();
                RadTreeView categoryTreeView = RadDropDownTree2.Controls[0] as RadTreeView;
                //categoryTreeView.Nodes[0].Expanded = true;
                categoryTreeView.ShowLineImages = false;

                List<Model.SysCodeDetail> dataSoucerList = scd.GetModelList(0, "DataSource", -1, -1, false);
                dataSoucerList.RemoveAll(rt => rt.IsValid == false);
                Model.SysCodeDetail dsModel = new Model.SysCodeDetail();
                dsModel.SYSCodeDetialID = "0";
                dsModel.SYSCodeDetialContext = "不限";
                dataSoucerList.Insert(0, dsModel);
                RCB_DataSource.DataValueField = "SYSCodeDetialID";
                RCB_DataSource.DataTextField = "SYSCodeDetialContext";
                RCB_DataSource.DataSource = dataSoucerList;
                RCB_DataSource.DataBind();

                List<Model.SysUser> suList = su.GetModelList(-1, "", -1, 4, true);
                Model.SysUser sm = new Model.SysUser();
                sm.UserID = "0";
                sm.UserName = "******";
                suList.Insert(0, sm);
                suList.ForEach(st => st.UserName = st.UserName + " [" + st.UserID + "]");
                RCB_Publisher.DataValueField = "UserID";
                RCB_Publisher.DataTextField = "USerName";
                RCB_Publisher.DataSource = suList;
                RCB_Publisher.DataBind();
                RCB_Publisher.SelectedValue = user.UserInfo.UserID;
            }
        }
コード例 #30
0
ファイル: AddSysCode.aspx.cs プロジェクト: 454240357/SmartLaw
 protected void Page_Load(object sender, EventArgs e)
 {
     user = SessionUser.GetSession();
     user.ValidateAuthority("Auth_Code_CRUD");
 }