Fix silent crasher when reordering table rows
This commit is contained in:
parent
d169f131a2
commit
4fe3829b98
2 changed files with 7 additions and 7 deletions
|
@ -260,10 +260,10 @@ def reorder_tasks(request) -> HttpResponse:
|
|||
|
||||
# Re-prioritize each task in list
|
||||
i = 1
|
||||
for t in newtasklist:
|
||||
newtask = Task.objects.get(pk=t)
|
||||
newtask.priority = i
|
||||
newtask.save()
|
||||
for id in newtasklist:
|
||||
task = Task.objects.get(pk=id)
|
||||
task.priority = i
|
||||
task.save()
|
||||
i += 1
|
||||
|
||||
# All views must return an httpresponse of some kind ... without this we get
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue