Web/class.aspx.cs

(开头部分) 2KB

这里只显示每个文件的开头 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
{
    public partial class _class : BasePage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!this.IsPostBack)
            {
                this.Bind();
            }
        }

        private void Bind()
        {
            ClothesShop.BLL.product pro = new ClothesShop.BLL.product();
            int typid = int.Parse(this.Request.QueryString["tid"].ToString());
            DataTable table = pro.selectproduct(0, typid, "", 2, 2);
            
            if (table.Rows.Count > 0)
            {
                this.searchdatalist.Visible = true;
                this.pagepanel.Visible = true;

                PagedDataSource objPds = new PagedDataSource();
                objPds.DataSource = table.DefaultView;
                objPds.AllowPaging = true;
                objPds.PageSize = 15;

                this.countlabel.Text = "共:" + objPds.PageCount.ToString() + "页";
                int CurPage;
                if (Request.QueryString["Page"] != null)
                    CurPage = Convert.ToInt32(Request.QueryString["Page"]);
                else
                    CurPage = 1;

                objPds.CurrentPageIndex = CurPage - 1;

                this.currentlabel.Text = "当前页:" + CurPage.ToString();

                if (!objPds.IsFirstPage)
                {
                    this.firstlinkbutton.NavigateUrl = Request.CurrentExecutionFilePath + "?Page=1";

                    this.prevlinkbutton.NavigateUrl = Request.CurrentExecutionFilePath + "?Page=" + Convert.ToString(CurPage - 1);
                }

                if (!objPds.IsLastPage)
                {
                    this.newlinkbutton.NavigateUrl = Request.CurrentExecutionFilePath + "?Page=" + Convert.ToString(CurPage + 1);
后面还有 15 行代码,购买后查看完整代码

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

AI 解读 AI

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

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