/// <summary> /// return list of all products /// </summary> /// <returns></returns> public IList <IProductDTO> GetAllProducts() { var config = new MapperConfiguration(cfg => cfg.CreateMap <IProduct, IProductDTO>()); var mapper = config.CreateMapper(); return(mapper.Map <IList <IProductDTO> >(_productDataAccess.GetProducts())); }
public Dictionary <string, double> GetProducts() { Dictionary <string, double> products = _productDataAccess.GetProducts(); foreach (var namePrice in products) { products[namePrice.Key] = CalculateSellPrice(namePrice.Value); } return(products); }
/// <summary> /// Get all products in the data source /// </summary> /// <returns>Products</returns> public IEnumerable <Product> GetProducts() { return(productDataAccess.GetProducts()); }
public List <ProductInfo> GetProducts(string sqlWhere) { return(productDataAccess.GetProducts(sqlWhere)); }
public void LoadProducts() { this.grid_PetShopDB.DataSource = _productRepo.GetProducts(); }
public List <ProductInfo> GetProducts(int pageSize, int pageIndex, string strWhere) { return(_dataAccess.GetProducts(pageSize, pageIndex, strWhere)); }
public IList <ProductModel> GetProducts() { return(productDataAccess.GetProducts()); }
public List <Product> GetProducts() { return(_productData.GetProducts()); }
public PagedList <ProductModel> GetProducts(int pageIndex, int pageSize) { return(productDataAccess.GetProducts(pageIndex, pageSize)); }