public PlacesInsideOutsideBdViewModel FilterPlacsBy_Inside_OutSIde_Bd() { var destinationsGroupedByOrigin = _destinationRepository.FilterPlacsBy_Inside_OutSIde_Bd(); var placesInsideOutsideBdList = new PlacesInsideOutsideBdViewModel(); foreach (var destinations in destinationsGroupedByOrigin) { if (destinations.Key) { placesInsideOutsideBdList.Places_InsideBd = destinations.ToList(); } else { placesInsideOutsideBdList.Places_OutsideBd = destinations.ToList(); } } return(placesInsideOutsideBdList); }