Пример #1
0
 protected void Page_Load(object sender, EventArgs e)
 {
     BLL.ProductsCate bllProCate = new BLL.ProductsCate();
     List<MODEL.ProductsCate> list = bllProCate.GetAllProCate();
     foreach (MODEL.ProductsCate model in list)
     {
         cateHtml.Append("<option value=");
         cateHtml.Append(model.Id).Append(">");
         cateHtml.Append(model.Catname);
         cateHtml.Append("</option>");
     }
 }
Пример #2
0
 void LoadLeftMenu()
 {
     BLL.ProductsCate bllProCate = new BLL.ProductsCate();
     List<MODEL.ProductsCate> list = bllProCate.GetAllProCate();
     foreach (MODEL.ProductsCate model in list)
     {
         sbLeft.Append("<ul class='l_top'>");
         sbLeft.Append("<li class='first'>");
         sbLeft.Append(model.Catname).Append("</li>");
         sbLeft.Append("<li><a href='Products.aspx?cid=" + model.Id + "'>");
         sbLeft.Append(model.Catname).Append("</a></li></ul>");
     }
 }
Пример #3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     BLL.ProductsCate bllPcate = new BLL.ProductsCate();
     List<MODEL.ProductsCate> list= bllPcate.GetAllProCate();
     BLL.Products bllPro = new BLL.Products();
           //<li><a href="html/lhq2.html">好斯基 <span class="ui-li-count">62</span></a></li>
     foreach (var item in list)
     {
         int ProductCount = bllPro.GetRecordCount(item.Id);
         productTitle.Append("<li><a href='Products.aspx?cid=" + item.Id + "'>");
         productTitle.Append(item.Catname);
         productTitle.Append("<span class='ui-li-count'>");
         productTitle.Append(ProductCount);
         productTitle.Append("</span></a></li>");
     }
     GenerateNewsTitle();
 }