Skip to content

Commit

Permalink
sort with second criteria to handle case where two profil have the same
Browse files Browse the repository at this point in the history
level
  • Loading branch information
digitalfox committed Sep 11, 2024
1 parent bdc4cfb commit 58c7992
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion staffing/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,7 @@ def pdc_review(request, year=None, month=None):
if groupby == "manager":
data.sort(key=lambda x: str(x[0].staffing_manager)) # Sort by staffing manager
else:
data.sort(key=lambda x: x[0].profil.level) # Sort by level
data.sort(key=lambda x: (x[0].profil.level, x[0].profil.id)) # Sort by level

scopes, team_current_filter, team_current_url_filter = get_team_scopes(subsidiary, team)
if team:
Expand Down

0 comments on commit 58c7992

Please sign in to comment.