Bug #4026

[Workbench] "Move to project..." button should be displayed to an admin user even if the sub-project is in another user's Home project.

Added by Radhika Chippada almost 5 years ago. Updated almost 5 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Radhika Chippada
Category:
-
Target version:
Start date:
10/20/2014
Due date:
% Done:

100%

Estimated time:
(Total: 0.00 h)
Story points:
0.5

Subtasks

Task #4261: Review branch: 4026-project-move-adminResolvedRadhika Chippada

Associated revisions

Revision c6056f6f
Added by Radhika Chippada almost 5 years ago

closes #4026
Merge branch '4026-project-move-admin'

History

#1 Updated by Radhika Chippada almost 5 years ago

apps/workbench/app/views/application/_title_and_buttons.html.erb might need revisiting.

#2 Updated by Radhika Chippada almost 5 years ago

  • Subject changed from "Move to project..." button is not displayed to an admin user if the project is not owned by the admin user. It should be displayed to admin users. to "Move to project..." button is not displayed to an admin user if the sub-project is in another user's Home project.

#3 Updated by Ward Vandewege almost 5 years ago

  • Subject changed from "Move to project..." button is not displayed to an admin user if the sub-project is in another user's Home project. to [Workbench] "Move to project..." button is not displayed to an admin user if the sub-project is in another user's Home project.

#4 Updated by Ward Vandewege almost 5 years ago

  • Target version changed from Bug Triage to Arvados Future Sprints

#5 Updated by Tom Clegg almost 5 years ago

Possible fix in 4026-admin-move-project c64623a

#6 Updated by Ward Vandewege almost 5 years ago

  • Target version changed from Arvados Future Sprints to 2014-10-29 sprint

#7 Updated by Ward Vandewege almost 5 years ago

  • Story points set to 0.5

#8 Updated by Tom Clegg almost 5 years ago

  • Subject changed from [Workbench] "Move to project..." button is not displayed to an admin user if the sub-project is in another user's Home project. to [Workbench] "Move to project..." button should be displayed to an admin user even if the sub-project is in another user's Home project.

#9 Updated by Radhika Chippada almost 5 years ago

  • Assigned To set to Radhika Chippada

#10 Updated by Brett Smith almost 5 years ago

Reviewing 2556bf9

It's possible to simplify this condition by saying if (ArvadosBase.find(@object.owner_uuid).writable_by.include?(current_user.uuid) rescue nil). We just added this last week, but it's great for simplifying permission checks like this: both User and Group return writable_by, and it always includes the requesting user's own UUID if they're an admin. So it's one line that covers all the same cases as this condition.

I'm happy for this branch to be merged with that change, or without if there's some reason it's not appropriate. Thanks.

#11 Updated by Radhika Chippada almost 5 years ago

  • Status changed from New to In Progress

#12 Updated by Radhika Chippada almost 5 years ago

  • Status changed from In Progress to Resolved

Applied in changeset arvados|commit:c6056f6f1bb99fa10bc2046266accc4a85f66aad.

Also available in: Atom PDF