ActionLabel/Channel.cs

(完整代码) 1KB

using System;
using System.Collections.Generic;
using System.Text;
using System.Data;
using Common;

namespace ActionLabel
{
    public class Channel
    {
        public static string ViewTxtList(int pId, int kId)
        {
            BLL.Channel bll = new BLL.Channel();
            StringBuilder strTxt = new StringBuilder();
            DataTable dt = bll.GetList(pId, kId);
            if (dt.Rows.Count > 0)
            {
                strTxt.Append("<option value=\"0\">请选择品牌</option>");
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    DataRow dr = dt.Rows[i];
                    strTxt.Append("<option value=\""+dr["Id"]+"\">"+dr["Title"]+"</option>");
                }
            }

            return strTxt.ToString();
        }

        //输出栏目名称
        public static string ViewChannelTitle(int classId)
        {
            BLL.Channel bll = new BLL.Channel();
            if (bll.Exists(classId))
            {
                Model.Channel model = bll.GetModel(classId);
                return model.Title;
            }
            return "所有列表";
        }
    }
}

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

AI 解读 AI

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

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