public IEnumerable <DrugUnitDTO> GetAll() { IEnumerable <DrugUnitDTO> allDrugUnits = drugUnits.GetAll().ToList().Select(drug => drug.ToDTO()).ToList(); foreach (var drug in allDrugUnits) { AddDepotToUnit(drug); AddDrugTypeToUnit(drug); } return(allDrugUnits); }
IEnumerable <DrugUnit> IDrugUnitService.getAll() { return(_drugUnitRepository.GetAll()); }