public async Task <IReadOnlyList <Product> > GetProductsAsync(ProductSpecParams productParams) { var spec = new ProductsWithTypesBrandsSpecification(productParams); return(await _repoProducts.GetWithSpecAsync(spec)); }
public async Task <Product> GetProductById(int id) { var spec = new ProductsWithTypesBrandsSpecification(id); return(await _repoProducts.GetEntityWithSpecAsync(spec)); }