CmsWeb/Admin/wxRule/tuwenMgr.aspx.cs

(开头部分) 3KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Cms.Common;
using System.Text;


public partial class Admin_wxRule_tuwenMgr : System.Web.UI.Page
{
    Cms.BLL.wx_requestRuleContent rcbll = new Cms.BLL.wx_requestRuleContent();
    protected string keywords = string.Empty;

    protected void Page_Load(object sender, EventArgs e)
    {

        if (!Page.IsPostBack)
        {
            // ChkAdminLevel("manager_list", MXEnums.ActionEnum.View.ToString()); //检查权限
            int rid = MyCommFun.RequestInt("rid");
            Cms.BLL.wx_requestRule rbll = new Cms.BLL.wx_requestRule();
            Cms.Model.wx_requestRule rule = rbll.GetModel(rid);
            this.lblKeyWords.Text = MyCommFun.SubStrAddSuffix(rule.reqKeywords, 10, "...");
            hlAddTuWen.NavigateUrl = "editTuWen.aspx?rid=" + rid + "&action=" + Enums.ActionEnum.Add;
            RptBind();
        }
    }

    #region 数据绑定=================================
    private void RptBind()
    {
        int rid = MyCommFun.RequestInt("rid");
        string _strWhere = "rId=" + rid + " order by seq asc";
        this.rptList.DataSource = rcbll.GetList(_strWhere);
        this.rptList.DataBind();
    }
    #endregion


    //批量删除
    protected void btnDelete_Click(object sender, EventArgs e)
    {
        // ChkAdminLevel("manager_list", MXEnums.ActionEnum.Delete.ToString()); //检查权限
        int sucCount = 0;
        int errorCount = 0;

        for (int i = 0; i < rptList.Items.Count; i++)
        {
            int id = Convert.ToInt32(((HiddenField)rptList.Items[i].FindControl("hidId")).Value);
            CheckBox cb = (CheckBox)rptList.Items[i].FindControl("chkId");
            if (cb.Checked)
            {
                if (rcbll.Delete(id))
                {
                    sucCount += 1;
                }
                else
                {
后面还有 45 行代码,购买后查看完整代码

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

AI 解读

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

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