-
Type:
Hot Fix Request
-
Status: Closed
-
Resolution: Fixed
-
Affects Version/s: 5.0.3
-
Fix Version/s: 5.0.3.1
-
Component/s: Share Application
-
Labels:None
-
Bug Priority:
-
Hot Fix Version:5.0.3.1
-
ACT Numbers:
00612777 Premier
SVN and MVN please.
Jiras to be included in hotfix: MNT-15757, MNT-15760, MNT-15746, MNT-15662, MNT-15823
Customer respects PM's decision in MNT-13653 to have Copy/Move dialog defaults destination to "Recent Site".
They found an error handling issue on 5.0.3 when users hide the "Recent Site" view mode. The Copy/Move dialog would still render the view instead of choosing to another view to render.
[Steps to reproduce]
1. In share-config-custom.xml, add the following under section <config evaluator="string-compare" condition="DocumentLibrary" replace="true"> to hide these views:
<!-- Document Library config section --> <config evaluator="string-compare" condition="DocumentLibrary" replace="true"> <hidden-picker-view-modes> <mode>VIEW_MODE_SITE</mode> <mode>VIEW_MODE_USERHOME</mode> <mode>VIEW_MODE_RECENT_SITES</mode> <mode>VIEW_MODE_FAVOURITE_SITES</mode> <mode>VIEW_MODE_SHARED</mode> </hidden-picker-view-modes> ... </config>
2. Start Alfresco and log into Share
3. Click on either Copy or Move action of any file
[Actual result]
The Copy/Move dialog still try to show the "Recent Site" view but not expanding its path, i.e. rendering empty panels, see image "Copy and Move with Recent Site hidden.png" attached.
[Expected result]
The Copy/Move dialog triggers path expansion of the first visible view when the "Recent Site" view mode is hidden. It shouldn't try to render the "Recent Site" view.
[Investigation]
I noticed that the global-folder.js is trying to handle this but doesn't trigger the path expansion once the default selection has been changed:
Original code
for (var i = 0, ii = modeButtons.length; i < ii; i++) { modeButton = modeButtons[i]; viewMode = parseInt(modeButton.get("name"), 10); modeButton.set("disabled", !(viewMode in allowedViewModes)); modeButton.setStyle("display", viewMode in allowedViewModes ? "block" : "none"); if (viewMode == this.options.viewMode) { if (modeButton.get("checked")) { // Will trigger the path expansion this.setViewMode(viewMode); } else { modeButton.set("checked", true); } } }
The following change by bringing "this.setViewMode(viewMode);" out of the if statement seemed to have fixed the issue:
for (var i = 0, ii = modeButtons.length; i < ii; i++) { modeButton = modeButtons[i]; viewMode = parseInt(modeButton.get("name"), 10); modeButton.set("disabled", !(viewMode in allowedViewModes)); modeButton.setStyle("display", viewMode in allowedViewModes ? "block" : "none"); if (viewMode == this.options.viewMode) { if (modeButton.get("checked")) { } else { modeButton.set("checked", true); } // Will trigger the path expansion this.setViewMode(viewMode); } }
See image "Copy and Move after proposed fix.png" after the proposed fix is in place.
SVN and MVN please.
Jiras to be included in hotfix: MNT-15757, MNT-15760, MNT-15746, MNT-15662, MNT-15777, MNT-15823
- is cloned by
-
MNT-15990 CLONE - Copy/Move dialog's default selection should fall back to a non-hidden view mode
- Closed
-
MNT-16725 CLONE - Copy/Move dialog's default selection should fall back to a non-hidden view mode
- Closed
- requires
-
MNT-15662 Move / Copy dialog's Repository folder tree shows everything instead of specified default root folder
- Closed
-
MNT-15746 FTP/CIFS initial upload no longer fires onContentPropertyUpdate Policy
- Closed
-
MNT-15760 Inconsistent behavior on upload of zero byte files between REST v0 API and FTP
- Closed