Ejemplo n.º 1
0
        public virtual ActionResult KitchensList(int category, int?brand, int?page, int?count, string article = "")
        {
            if (!string.IsNullOrEmpty(article))
            {
                ShowKitchenModel result = db.GetThing(article);
                if (result != null)
                {
                    return(View("product", result));
                }
            }

            if (page == null || page.Value == 0)
            {
                page = 1;
            }
            if (count == null || count.Value == 0)
            {
                count = 10;
            }

            var model = new ShowKitchensList(category, brand == null ? 0 : brand.Value, page.Value, count.Value);

            return(View(model));
        }
Ejemplo n.º 2
0
 public virtual ActionResult ShowKitchensList(ShowKitchensList model)
 {
     db.ShowKitchens(ref model);
     return(View(model));
 }