public override async Task <List <ProductDosage> > AllAsync() { return(await RepositoryDbSet .Include(c => c.Dosage) .Include(r => r.Product) .Select(e => ProductDosageMapper.MapFromDomain(e)).ToListAsync()); }
public async Task <ProductDosage> FindAllPerEntity(int id) { var productDosage = await RepositoryDbSet .Include(c => c.Dosage) .Include(r => r.Product) .FirstOrDefaultAsync(m => m.Id == id); return(ProductDosageMapper.MapFromDomain(productDosage)); }