default.aspx.cs
(完整代码) 1KBusing System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using BLL.Article;
using CSA.DAL;
public partial class _Default : System.Web.UI.Page
{
protected DataTable dtNewPro, dtPromotePro, dtHotSalesPro;
protected void Page_Load(object sender, EventArgs e)
{
getList();
}
private void getList()
{
dtHotSalesPro = DBAccess.getRS("select top 8 * from bs_products where bs_proKindCode like '09%' and ishomeshow=1 order by Addtime desc ");
// dtHotSalesPro =BLL.Product.Product.getList("09", 8);
//dtPromotePro = BLL.Product.Product.getList("08", 4);
dtPromotePro = DBAccess.getRS("select top 4 * from bs_products where bs_proKindCode like '01%' and ishomeshow=1 order by Addtime desc ");
//dtNewPro = BLL.Product.Product.getList("", 15, " and isNew=1 ");
dtNewPro = DBAccess.getRS("select top 15 * from bs_products where (bs_proKindCode like '02%' or bs_proKindCode like '10%' or bs_proKindCode like '03%') and ishomeshow=1 order by Addtime desc ");
}
protected string getNewsList(string code)
{
//DataTable dt = BLL.Article.Article.getList(code, 5);
DataTable dt = DBAccess.getRS("select top 5 * from bs_news where bs_NewsKindCode like '" + code + "' order by Addtime desc");
string str = "";
foreach (DataRow dr in dt.Rows)
{
str += "<li>·<a title='" + dr["Title"] + "' href='Newsd.aspx?id=" + dr["id"] + "&code=" + dr["bs_NewsKindCode"] + "'>" + CSA.Text.Util.SubString(42, dr["Title"]) + "</a></li>";
}
return str;
}
}
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。
