Bug #17098
closedCollection "restore from previous version" button
Added by Peter Amstutz about 4 years ago. Updated almost 4 years ago.
Related issues
Updated by Peter Amstutz about 4 years ago
- Status changed from New to In Progress
Updated by Lucas Di Pentima about 4 years ago
- Related to Idea #13494: Browse previous versions of a collection added
Updated by Lucas Di Pentima about 4 years ago
- Target version set to 2020-11-18
- Assigned To set to Lucas Di Pentima
Updated by Lucas Di Pentima about 4 years ago
- Target version changed from 2020-11-18 to 2020-12-02 Sprint
Updated by Lucas Di Pentima almost 4 years ago
As commented on https://dev.arvados.org/issues/13494#note-59, We'll be avoiding offering the "add to favorites" action on past versions as it isn't supported by the API server.
Updated by Lucas Di Pentima almost 4 years ago
Updates at arvados-workbench2|673bf2ac - branch 17098-old-version-as-head
Test run: developer-tests-workbench2: #193
- Refactored a function that is used to decide which kind of context menu to show. Its was being called differently from several places, sometimes returning inconsistent values.
- Added 'Recover version' action for old collection versions.
- Avoid offering the 'Add to favorites' action on old collection versions.
- Updated tests.
Updated by Lucas Di Pentima almost 4 years ago
Updates at arvados-workbench2|adc0008e
Test run: developer-tests-workbench2: #196
- Merged latest master
- Adjusted latest's master code on the refactored function.
Updated by Peter Amstutz almost 4 years ago
How hard would it be to add a confirmation dialog? Someone might select the action not knowing what it does. The confirmation dialog could also explain that this command makes it the new "head" version, but if they want a copy to work on without modifying "head", they should use "make a copy".
Updated by Peter Amstutz almost 4 years ago
Also, I don't want to get sidetracked on this, but the menu item ordering is odd.
I know that Danny changed it so the menu items are sorted alphabetically. This isn't optimal but at least it is consistent. However, the actions on the "current" version "Advanced"..."Share" sorted and then starts over with "Add to favorites"..."View details".
The whole thing should be sorted together.
Although, a better way to do this would be to create a master ordered list of actions (with similar actions grouped together intentionally) and adjust the ordering the items in each specific action menu from the position in the master list. Then we would get both consistent ordering and the ability to manually specify ordering to reflect categories or frequency of use.
Updated by Lucas Di Pentima almost 4 years ago
Peter Amstutz wrote:
How hard would it be to add a confirmation dialog? Someone might select the action not knowing what it does. The confirmation dialog could also explain that this command makes it the new "head" version, but if they want a copy to work on without modifying "head", they should use "make a copy".
Confirmation dialog added at arvados-workbench2|b115fc74
Test run: developer-tests-workbench2: #198
Updated by Lucas Di Pentima almost 4 years ago
Peter Amstutz wrote:
Also, I don't want to get sidetracked on this, but the menu item ordering is odd.
I know that Danny changed it so the menu items are sorted alphabetically. This isn't optimal but at least it is consistent. However, the actions on the "current" version "Advanced"..."Share" sorted and then starts over with "Add to favorites"..."View details".
The whole thing should be sorted together.
Although, a better way to do this would be to create a master ordered list of actions (with similar actions grouped together intentionally) and adjust the ordering the items in each specific action menu from the position in the master list. Then we would get both consistent ordering and the ability to manually specify ordering to reflect categories or frequency of use.
I've checked the code that does the sorting and it's correct in the sense that the sorting is done by action's names. Usually action's names are the same as the text being displayed on the context menu, but sometimes (on "toggle" type actions) the displayed text changes (example: Add/Remove to/from favorites) so in those cases the action's name is usually "ToggleActionType" and gets ordered by that.
Updated by Peter Amstutz almost 4 years ago
Lucas Di Pentima wrote:
Peter Amstutz wrote:
How hard would it be to add a confirmation dialog? Someone might select the action not knowing what it does. The confirmation dialog could also explain that this command makes it the new "head" version, but if they want a copy to work on without modifying "head", they should use "make a copy".
Confirmation dialog added at arvados-workbench2|b115fc74
Test run: developer-tests-workbench2: #198
- I prefer the word "Restore" (which means to put something back) instead of "Recover" (which means to get something that was lost). So the menu item would be "Restore version".
- Change the dialog text a little bit:
"This will copy the content of the selected version to the head. To make a new collection with the content of the selected version, use 'Make a copy' instead."
Updated by Lucas Di Pentima almost 4 years ago
Updates at arvados-workbench2|936570fa
Test run: developer-tests-workbench2: #199
- Renamed "recover version" to "restore version".
- Changed the dialog's text.
- Updated the integration test.
Updated by Peter Amstutz almost 4 years ago
Lucas Di Pentima wrote:
Updates at arvados-workbench2|936570fa
Test run: developer-tests-workbench2: #199
- Renamed "recover version" to "restore version".
- Changed the dialog's text.
- Updated the integration test.
Seem to be having a tough run of failing tests on jenkins, but otherwise this LGTM.
Updated by Lucas Di Pentima almost 4 years ago
Successful test re-run: developer-tests-workbench2: #205
Merging, thanks!
Updated by Anonymous almost 4 years ago
- % Done changed from 0 to 100
- Status changed from In Progress to Resolved
Applied in changeset arvados-workbench2|ebaede5aff01400db400a3e69bb3bec2b636db3a.