Skip to content

Commit

Permalink
fix: Use session.order_in_meeting() in the agenda (#5222)
Browse files Browse the repository at this point in the history
  • Loading branch information
jennifer-richards committed Feb 27, 2023
1 parent 5c9a364 commit a2bdd31
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions ietf/meeting/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ def preprocess_assignments_for_agenda(assignments_queryset, meeting, extra_prefe
# check before blindly assigning to meeting just in case.
if a.session.meeting.pk == meeting.pk:
a.session.meeting = meeting
a.session.order_number = None
a.session.order_number = a.session.order_in_meeting() if a.session.group else None

if a.session.group and a.session.group not in groups:
groups.append(a.session.group)
Expand All @@ -134,12 +134,6 @@ def preprocess_assignments_for_agenda(assignments_queryset, meeting, extra_prefe
if a.session and a.session.group:
sessions_for_groups[(a.session.group, a.session.type_id)].append(a)

for a in assignments:
if a.session and a.session.group:

l = sessions_for_groups.get((a.session.group, a.session.type_id), [])
a.session.order_number = l.index(a) + 1 if a in l else 0

timeslot_by_session_pk = {a.session_id: a.timeslot for a in assignments}

for a in assignments:
Expand Down

0 comments on commit a2bdd31

Please sign in to comment.