public ProductsReponse Get(Category.CategoryType category) { var productsBll = Bll.Products.CreateInstance(); productsBll.GetData(category, out IQueryable <Product> datos, out int hiddenProducts, out int shownProducts); var productsReponse = new ProductsReponse(category.ToString(), shownProducts, hiddenProducts, datos.ToList()); return(productsReponse); }
public ActionResult <IEnumerable <ProductsReponse> > GetProdutcs() { var productsResponse = new ProductsReponse(_repository.GetProducts()); return(Ok(productsResponse)); }