public IEnumerable <DetailTypeModel> GetAll() { IDetailTypeRepository detailTypesRepository = new DetailTypeRepository(); var types = detailTypesRepository.GetAll(); var result = types.Select(x => new DetailTypeModel { Id = x.Id, Name = x.Name }); return(result); }
public DetailTypeService() { detailTypeRepository = new DetailTypeRepository(); }