/// <summary> /// 苹果列表 /// </summary> /// <returns></returns> public ActionResult AppleList(Guid guid) { GoodsLogic goodsLogic = new GoodsLogic(); var categoryList = goodsLogic.GetCategoryByRank(0); ViewBag.Category = categoryList; ViewBag.Title = "苹果列表"; var apples = goodsLogic.GetGoodsList(guid); return(View(apples)); }
/// <summary> /// 葡萄列表 /// </summary> /// <returns></returns> public ActionResult PutaoList(Guid guid) { GoodsLogic goodsLogic = new GoodsLogic(); var categoryList = goodsLogic.GetCategoryByRank(0); ViewBag.Category = categoryList; ViewBag.Title = "葡萄列表"; var grapes = goodsLogic.GetGoodsList(guid); return(View(grapes)); }
/// <summary> /// 首页 /// </summary> /// <returns></returns> public ActionResult Index() { GoodsInfoModel model = new GoodsInfoModel(); GoodsLogic goodsLogic = new GoodsLogic(); var categoryList = goodsLogic.GetCategory(); var goodsList = goodsLogic.GetGoodsList(); model.DirectoryList = categoryList; model.GoodsList = goodsList; ViewBag.Category = categoryList.Where(m => m.Rank == 0).ToList(); return(View(model)); }