WebApp/Admin/Online_Services.aspx.cs

(完整代码) 1KB

using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

namespace RM.WebApp.Admin 
{
    public partial class Online_Services :  AdminBasic
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                LoadModel();
                this.IsAuthority(0);
            }
        }

        private void LoadModel()
        {
            RM.BLL.SysConfig sbll = new RM.BLL.SysConfig();
            RM.Entity.SysConfig SysCfg = sbll.GetEntity(5);
            TextBox1.Text = SysCfg.Email;
            TextBox2.Text = SysCfg.Telephone;
            TextBox3.Text = SysCfg.Address;
            TextBox4.Text = SysCfg.CopyRight;
        }

        protected void btnAdd_Click(object sender, EventArgs e)
        {
            this.IsAuthority(1);
            RM.BLL.SysConfig sbll = new RM.BLL.SysConfig();
            RM.Entity.SysConfig SysCfg = sbll.GetEntity(5);
            SysCfg.Email = TextBox1.Text.Trim();
            SysCfg.Telephone = TextBox2.Text.Trim();
            SysCfg.Address = TextBox3.Text.Trim();
            SysCfg.CopyRight = TextBox4.Text.Trim();
            if (sbll.Update(SysCfg))
            {
                this.WriteJs(Common.JS.Alert("修改成功") + Common.JS.Redirect(Request.Url.PathAndQuery));
            }
        }
    }
}

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。