Пример #1
0
        public async Task <IReadOnlyList <Product> > GetProductsAsync(ProductSpecParams productParams)
        {
            var spec = new ProductsWithTypesBrandsSpecification(productParams);

            return(await _repoProducts.GetWithSpecAsync(spec));
        }
Пример #2
0
        public async Task <Product> GetProductById(int id)
        {
            var spec = new ProductsWithTypesBrandsSpecification(id);

            return(await _repoProducts.GetEntityWithSpecAsync(spec));
        }