public List <TypeVm> GetAllPlaceTypes() { var db = PlaceTypeDb.GetAllPlaceTypes(); var types = new List <TypeVm>(); foreach (DataRow row in db.Rows) { var type = new TypeVm(); type.Id = (int)row["Id"]; type.Name = (string)row["Name"]; types.Add(type); } return(types); }
private IEnumerable <PlaceType> GetAllPlaceTypes() { var db = PlaceTypeDb.GetAllPlaceTypes(); var types = new List <PlaceType>(); foreach (DataRow row in db.Rows) { var type = new PlaceType(); type.Id = (int)row["Id"]; type.Name = (string)row["Name"]; types.Add(type); } return(types); }