public List <BodyTypeViewModel> GetAllBodyTypes() { var bodyTypes = _bodyTypeRepository.Get(); return(bodyTypes.Select(_ => new BodyTypeViewModel { BodyTypeNumber = _hashidsService.Encode(_.Id), BodyTypeName = _.Name }).ToList()); }
public List <SchoolClassViewModel> _getAllSchoolClass() { var SchoolClassList = _schoolClassRepository.GetSchoolClassList(); return(SchoolClassList.Select(p => new SchoolClassViewModel { SchoolClassName = p.Name, SchoolClassNumber = _hashidsService.Encode(p.Id) }).ToList()); }