Skip to content

Commit

Permalink
don't put in first place current value when... not value is defined for
Browse files Browse the repository at this point in the history
billing mode
  • Loading branch information
digitalfox committed Nov 25, 2024
1 parent 3f770e0 commit 308c01b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion staffing/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -1816,7 +1816,8 @@ def mission_update(request):
mission = Mission.objects.get(id=mission_id) # If no mission found, it fails, that's what we want
if attribute == "billing_mode":
values = dict(Mission.BILLING_MODES)
values = {mission.billing_mode: values.pop(mission.billing_mode), **values}
if mission.billing_mode:
values = {mission.billing_mode: values.pop(mission.billing_mode), **values}
if mission.management_mode == "ELASTIC":
del values["FIXED_PRICE"]
elif attribute == "management_mode":
Expand Down

0 comments on commit 308c01b

Please sign in to comment.