📄 mo_add.aspx.cs
字号:
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using Shop.Web.UI;
namespace YXShop.Web.Admin.Templates
{
public partial class Mo_Add : System.Web.UI.Page
{
BasePage bp = null;
protected void Page_Load(object sender, EventArgs e)
{
YXShop.Common.WebUtility.WebControlOnblur(this.ProgrammeName);//去除空格
YXShop.Common.WebUtility.WebControlOnblur(this.ProgrammeDes);//去除空格
if (!PowerTree.PowerPass.isPass("010001002", PowerTree.PowerPanel.PowerType.add))
{
bp = new BasePage();
bp.PageError("对不起,你没有添加模板方案的权限!", "../index.aspx");
}
}
protected void addBtn_Click(object sender, EventArgs e)
{
if (!string.IsNullOrEmpty(ProgrammeName.Text))//添加模板方案
{
try
{
YXShop.TemplateAction.TemplateModel templateAddObj = new YXShop.TemplateAction.TemplateModel(0, ProgrammeName.Text, ProgrammeDes.Text, 0);
int result = YXShop.TemplateAction.TemplateDo.AddTemplate(templateAddObj);
if (result > -1)
{
YXShop.Common.alert.showAndGo("恭喜你!添加模板方案成功!", "Mo_Manage.aspx");
}
}
catch { }
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -