cbrain
cbrain copied to clipboard
Admin can't re-assign the owner of a task
As admin user X, tried to reassign a task (belonging to X) to normal user Y.
I get "this object doesn't belong to you" and the task stays with the same owner X.
I was not able to reproduce this issue.
Here is what I have done to test it:
Cannot reproduce either. Just assigned to Natacha two my tasks (@natacha-beck beck, sorry for any inconveniecne feel free to delete, that's old tasks https://portal.cbrain.mcgill.ca/tasks/1844183 https://portal.cbrain.mcgill.ca/tasks/1844183 )
I'm sure I got it in the past, and looking at the code I think it's because the controller code depends on the current view scope to find() the task to modify. So Probably, to reproduce, we would need:
- two browser tabs
- the first one shows some tasks with an old scope
- the second one shows some other tasks with a newer different scope and doesn't include the tasks shown in the first tab
Then we try to perform an operation on tasks shown in the first tab.
@prioux and @MontrealSergiy Retested on my end following your instruction. I am still able to re-assign owner of the task without any issues. @MontrealSergiy can you give it a try too.
@natacha-beck I did not understand the exact steps. Also I think the scope is the same within one browser.