Esempio n. 1
0
        public async Task <IDataResult <CreateProductElementsDto> > GetCreateProductElements()
        {
            CreateProductElementsDto createProductElements = new CreateProductElementsDto();

            createProductElements.Brands = await _brandDAL.GetListAsync();

            createProductElements.Categories = (await _categoryDAL.GetListAsync(null, x => x.ChildCategories)).Where(x => x.ChildCategories.Count == 0).ToList();
            createProductElements.Colors     = await _colorDAL.GetListAsync();

            createProductElements.DemandTypes = await _demandTypeDAL.GetListAsync();

            return(new SuccessDataResult <CreateProductElementsDto>(createProductElements));
        }
Esempio n. 2
0
 public async Task <List <Color> > GetListAsync()
 {
     return(await _colorDAL.GetListAsync());
 }