Skip to content

Commit

Permalink
Contribution list: Filter speakers correctly (#4712)
Browse files Browse the repository at this point in the history
Do not attempt to match on all ContributionPersonLinks, only on
those marked as a speaker.

Otherwise a contribution with a second, non-speaker author that has
registered will not show up if searching for non-registered speakers.
  • Loading branch information
bpedersen2 authored and ThiefMaster committed Nov 18, 2020
1 parent 1d47989 commit ea5f384
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ Improvements
Bugfixes
^^^^^^^^

- None so far :)
- Only consider actual speakers in the "has registered speakers" contribution list filter
(:pr:`4712`, thanks :user:`bpedersen2`)

Version 2.3.1
-------------
Expand Down
1 change: 1 addition & 0 deletions indico/modules/events/contributions/lists.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ def _filter_list_entries(self, query, filters):
registration_join_criteria = db.and_(
Registration.event_id == Contribution.event_id,
Registration.is_active,
ContributionPersonLink.is_speaker,
(Registration.user_id == EventPerson.user_id) | (Registration.email == EventPerson.email)
)
contrib_query = (db.session.query(Contribution.id)
Expand Down

0 comments on commit ea5f384

Please sign in to comment.