Project

General

Profile

Actions

Idea #3821

closed

[Workbench] Delete and rename files in collections

Added by Peter Amstutz over 9 years ago. Updated about 7 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Radhika Chippada
Category:
Workbench
Target version:
Start date:
12/10/2014
Due date:
Story points:
2.0

Description

The "show collection" page (for a collection that is writable by the current user) should have the following features:

  • Copy files from another collection see #3177
  • Delete files
  • Rename files
  • Move files to a different collection (maybe?)

Implemented in workbench using the existing Ruby SDK support. Trash can icons for delete & pencil icons for rename.


Subtasks 3 (0 open3 closed)

Task #4774: Removing files from a collectionClosed12/10/2014Actions
Task #4773: Renaming files in collectionsClosed12/10/2014Actions
Task #11265: Review branch 3821-collection-file-manageResolvedRadhika Chippada12/10/2014Actions

Related issues

Related to Arvados - Feature #4808: [Workbench] "Add data from another project" modal supports regex filteringClosedActions
Has duplicate Arvados - Idea #4594: [Workbench] In the collections page, provide the ability to select individual files from different collections and combine them into a new collection. ResolvedActions
Blocked by Arvados - Feature #5104: [SDKs] Add Ruby SDK methods for manipulating collection contents (rename, delete, copy file from another collection)ResolvedBrett Smith03/08/2015Actions
Blocked by Arvados - Idea #5781: [API] [DRAFT] Provide API methods for manipulating and combining collectionsResolved04/21/2015Actions
Actions #1

Updated by Peter Amstutz over 9 years ago

  • Description updated (diff)
  • Category set to Workbench
Actions #2

Updated by Peter Amstutz over 9 years ago

  • Target version set to Arvados Future Sprints
Actions #3

Updated by Peter Amstutz over 9 years ago

  • Story points set to 2.0
Actions #4

Updated by Tom Clegg over 9 years ago

  • Subject changed from [Workbench] Editing collections to [Workbench] Edit collections
Actions #5

Updated by Tom Clegg over 9 years ago

  • Description updated (diff)
Actions #6

Updated by Tom Clegg over 9 years ago

  • Target version changed from Arvados Future Sprints to 2015-02-18 sprint
Actions #7

Updated by Radhika Chippada over 9 years ago

  • Assigned To set to Radhika Chippada
Actions #8

Updated by Tom Clegg about 9 years ago

  • Target version changed from 2015-02-18 sprint to Arvados Future Sprints
Actions #9

Updated by Tom Clegg about 9 years ago

  • Description updated (diff)
Actions #10

Updated by Tom Clegg about 9 years ago

  • Subject changed from [Workbench] Edit collections to [Workbench] Delete and rename files in collections
  • Description updated (diff)
Actions #11

Updated by Tom Clegg about 9 years ago

  • Assigned To deleted (Radhika Chippada)
Actions #12

Updated by Tom Morris about 7 years ago

  • Target version changed from Arvados Future Sprints to 2017-04-12 sprint
Actions #13

Updated by Tom Morris about 7 years ago

  • Description updated (diff)
Actions #14

Updated by Tom Morris about 7 years ago

  • Target version changed from 2017-04-12 sprint to 2017-03-29 sprint
Actions #15

Updated by Radhika Chippada about 7 years ago

  • Assigned To set to Radhika Chippada
Actions #16

Updated by Radhika Chippada about 7 years ago

  • Status changed from New to In Progress
Actions #17

Updated by Radhika Chippada about 7 years ago

Branch 3821-collection-file-manage @ 07e060d

  • Added a "Remove selected files" option to the Selection dropdown collection#show page. This allows multiple files to be selected and removed from a collection per request
  • Added trash icon(s) to collection file row(s) in collection#show page. This allows removal of that particular file (row) from collection
  • Added pencil icon(s) to collection file row(s) in collection#show page. This allows renaming of that particular file in the collection. This is implemented using the current "render_editable_attribute" with appropriate enhancements made to this method. The editable input box displays the full path of the file. The user is allowed to: just change the file name or move it to a different existing subdirectory or even to an entirely new subdirectory
  • Added controller tests as well as (minimal required) integration tests

Test run @ https://ci.curoverse.com/job/developer-run-tests/215/

Actions #18

Updated by Lucas Di Pentima about 7 years ago

Some comments:

  • File apps/workbench/config/routes.rb:
    • Related detail: Could you update the rest of the routes so that instead of using the “:on => :member” style, use the newer “on: :member” for consistency?
  • File apps/workbench/test/controllers/collections_controller_test.rb:
    • Lines 644, 669, 693: Instead of asserting against a previously created string variable, wouldn’t be better to prove that the newly created collection’s manifest includes 0:0:file1?
    • Line 683: I think that assert_match is proving that ./file1 & ./file2 exist, but doesn’t prove that ./dir1/ is missing, maybe a $ is missing at the end of the regexp?
  • The pencil icon’s tooltip says “edit”, do you think it would be better to say “rename”?
  • Renaming a file the same as another file, makes that other file to be deleted. Is that on purpose? If so, maybe we can ask the user for confirmation.
Actions #19

Updated by Radhika Chippada about 7 years ago

Could you update the rest of the routes so that instead of using the “:on => :member” style, use the newer “on: :member” for consistency?

It would be desirable that "all" references are updated and thoroughly tested. So, didn't want to go there at this time. Will note it for next time around.

File apps/workbench/test/controllers/collections_controller_test.rb: Lines 644, 669, 693: Instead of asserting against a previously created string variable, wouldn’t be better to prove that the newly created collection’s manifest includes 0:0:file1?

Good catch. Updated the assertions

Line 683: I think that assert_match is proving that ./file1 & ./file2 exist, but doesn’t prove that ./dir1/ is missing, maybe a $ is missing at the end of the regexp?

Added the missing $ and also added another assertion fir "dir1".

The pencil icon’s tooltip says “edit”, do you think it would be better to say “rename”?
Renaming a file the same as another file, makes that other file to be deleted. Is that on purpose? If so, maybe we can ask the user for confirmation.

I improved the tooltip on the pencil icon in detailed now. It now says the user can change the file path (name or dir or both) and may not use duplicate names.

Thanks.

Actions #20

Updated by Lucas Di Pentima about 7 years ago

LGTM, please merge.

Actions #21

Updated by Radhika Chippada about 7 years ago

  • Status changed from In Progress to Resolved
  • % Done changed from 33 to 100

Applied in changeset arvados|commit:2b27132d13fd72f29dbab2297f0d2dc1c110eed1.

Actions

Also available in: Atom PDF