Web/admin/type_2list.aspx.cs
(开头部分) 5KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
namespace ClothesShop.Web.admin
{
public partial class type_2list : BasePage
{
protected void Page_Load(object sender, EventArgs e)
{
if (user.IsLogin() == true && user.getUserRole() == 2)
{
if (!this.IsPostBack)
{
Bindtype_1(this.addtypeddl);
Bindtype_1(this.type_1ddl);
Bind();
}
}
else
{
this.Response.Redirect("logins.aspx");
}
}
ClothesShop.BLL.type_2 t_2 = new ClothesShop.BLL.type_2();
ClothesShop.BLL.type_1 t_1 = new ClothesShop.BLL.type_1();
ClothesShop.BLL.userinfo user = new ClothesShop.BLL.userinfo();
/// <summary>
/// 绑定一级分类
/// </summary>
private void Bindtype_1(DropDownList ddl)
{
DataTable table = t_1.type_1list("");
foreach (DataRow row in table.Rows)
{
ListItem li = new ListItem(row["typename"].ToString(), row["typeid_1"].ToString());
ddl.Items.Add(li);
}
ddl.Items.Insert(0, new ListItem("选择一级分类","0"));
}
/// <summary>
/// 二级分类绑定
/// </summary>
private void Bind()
{
DataTable tabel = t_2.type_2list(int.Parse(this.type_1ddl.SelectedValue.ToString()),this.typenameTb.Text.Trim());
this.type_2Gv.DataSource = tabel.DefaultView;
this.type_2Gv.DataBind();
后面还有 107 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。