9314: Allow place selection both individually and by filter

Add the places selected individually to the list generated by
the filter.
This commit is contained in:
Nick Hall 2016-05-22 18:26:34 +01:00 committed by prculley
parent 75d4f05185
commit 3ea4b0d109

View File

@ -107,13 +107,15 @@ class PlaceReport(Report):
self.sort = Sort(self.database)
self.place_handles = []
if self.filter.get_name() != '':
# Use the selected filter to provide a list of place handles
plist = self.database.iter_place_handles()
self.place_handles = self.filter.apply(self.database, plist)
else:
# Use the place handles selected without a filter
self.place_handles = self.__get_place_handles(places)
if places:
# Add places selected individually
self.place_handles += self.__get_place_handles(places)
if not self.place_handles:
raise ReportError(_('Place Report'),