cbrain
cbrain copied to clipboard
[ADD] launching task arrays by selecting multiple files in New Boutiques
Closed #1201
Double check all his, I really am not sure it works.
It was tested and seems to work properly when I did the PR.
I renamed some variable and remove the next
. I do not see the point of the next
neither.
I tested with multiple files selected (3 files selected as inputs --> Produce 3 tasks), I also verify that using a CbrainFileList work ok too.
Oups still have to cache the value. Will do.
The original 'next nil' statement was meant to replace in-situ a bad userfile ID in a File input.
Your code no longer does that.
Also, instead of looking up each and every file with a find_accessible_by_user
, why don't you get them all in one shot? That way if you have 1000 file entries you're not going top make 1000 requests to the database.
I will need to review this carefully, just a read of the code is not enough for me to approve it. The changes are too complex and subtle.