[magnolia-dev] [JIRA] (MGNLUI-3098) Bulk oprtation MoveNodeAction: "Move After" is reverting the chosen Node order

2014-08-13 Thread JIRA (on behalf of Christian Ringele)














































Christian Ringele
 created  MGNLUI-3098


Bulk oprtation MoveNodeAction: "Move After" is reverting the chosen Node order















Issue Type:


Bug



Affects Versions:


5.3.2, 5.2.8



Assignee:


Unassigned


Attachments:


MoveNodeAction-M5.2.5.patch, MoveNodeAction-M5.3.1.patch



Components:


content app



Created:


13/Aug/14 1:39 PM



Description:


Summary:
When moving a selection of Nodes with the "Move After" operation, their order is reversed.
The reason is that for each Node the moveAfter() is called, which reverses implicit its order:
The last Node is placed as last element directly after the target node -> its then the first Node and not the last anymore.

Cause:
Super class of MoveNodeAction abstract class is


info.magnolia.ui.framework.action.AbstractMultiItemAction


It calls in the execute() for every item operating on the abstract method .executeOnItem(JcrItemAdapter).
The MoveNodeAction implementing the method executeOnItem is calling 


info.magnolia.ui.workbench.tree.MoveHandler.moveItem(Item, Item, MoveLocation)


 which in the end calles 

info.magnolia.jcr.util.NodeUtil.moveNodeAfter(Node, Node)

.


Solution general:
Override the method 

info.magnolia.ui.contentapp.movedialog.action.MoveNodeAction.getSortedItems(Comparator)

 of the super class and revert the list on the MoveLoction.after operation.


Solution patches:
As the code changed form 5.2 to 5.3 of this class, I needed to create two different patches basically containing the same code. Just the line numbers won't match.






Project:


Magnolia UI



Labels:


support




Priority:


Major




Reporter:


Christian Ringele




























This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira








For list details, see: http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: 





[magnolia-dev] [JIRA] (MGNLUI-3098) Bulk oprtation MoveNodeAction: "Move After" is reverting the chosen Node order

2014-08-13 Thread JIRA (on behalf of Christian Ringele)














































Christian Ringele
 updated  MGNLUI-3098


Bulk oprtation MoveNodeAction: "Move After" is reverting the chosen Node order
















Change By:


Christian Ringele
(13/Aug/14 1:57 PM)




Description:


Summary:When moving a selection of Nodes with the "Move After" operation, their order is reversed.The reason is that for each Node the moveAfter() is called, which reverses implicit its order:The last Node is placed as last element directly after the target node -> its then the first Node and not the last anymore.Cause:Super class of MoveNodeAction abstract class is{code}info.magnolia.ui.framework.action.AbstractMultiItemAction{code}It calls in the execute() for every item operating on the abstract method .executeOnItem(JcrItemAdapter).The MoveNodeAction implementing the method executeOnItem is calling {code}info.magnolia.ui.workbench.tree.MoveHandler.moveItem(Item, Item, MoveLocation){code} which in the end calles {code}info.magnolia.jcr.util.NodeUtil.moveNodeAfter(Node, Node){code}
.
Solution general:Override the method {code}info.magnolia.ui.contentapp.movedialog.action.MoveNodeAction.getSortedItems(Comparator){code} of the super class and revert the list on the MoveLoction.after operation.Solution patches:As the code changed form 5.2 to 5.3 of this class, I needed to create two different patches basically containing the same code. Just the line numbers won't match.



























This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira








For list details, see: http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: