⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 contentbatchmove.cs

📁 动易SiteFactory&#8482 网上商店系统1.0源代码
💻 CS
字号:
namespace PowerEasy.WebSite.Admin.Contents
{
    using PowerEasy.AccessManage;
    using PowerEasy.Common;
    using PowerEasy.Contents;
    using PowerEasy.Controls;
    using PowerEasy.Enumerations;
    using PowerEasy.Web.UI;
    using System;
    using System.Collections.Generic;
    using System.Web.UI.WebControls;

    public class ContentBatchMove : AdminPage
    {
        protected Button BtnCancel;
        protected DropDownList DropNode;
        protected Button EBtnBacthMove;
        protected ExtendedSiteMapPath SmpNavigator;
        protected TextBox TxtGeneralId;

        protected void BtnCancel_Click(object sender, EventArgs e)
        {
            BasePage.ResponseRedirect("ContentManage.aspx");
        }

        protected void EBtnBacthMove_Click(object sender, EventArgs e)
        {
            if (this.Page.IsValid)
            {
                int nodeId = DataConverter.CLng(this.DropNode.SelectedValue);
                string text = this.TxtGeneralId.Text;
                if (!DataValidator.IsValidId(text))
                {
                    AdminPage.WriteSuccessMsg("指定的内容ID不正确,请重新指定!", "ContentManage.aspx");
                }
                if (ContentManage.BatchMove(text, nodeId))
                {
                    AdminPage.WriteSuccessMsg("批量移动成功!", "ContentManage.aspx");
                }
                else
                {
                    AdminPage.WriteErrMsg("批量移动失败!", "ContentManage.aspx");
                }
            }
        }

        private void Initial()
        {
            string str = BasePage.RequestString("Id");
            if (!this.Page.IsPostBack)
            {
                IList<NodeInfo> nodeNameForContainerItems = Nodes.GetNodeNameForContainerItems();
                this.DropNode.DataSource = nodeNameForContainerItems;
                this.DropNode.DataBind();
            }
            this.TxtGeneralId.Text = str;
        }

        protected void Page_Load(object sender, EventArgs e)
        {
            RolePermissions.BusinessAccessCheck(OperateCode.ContentManage);
            this.Initial();
        }
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -