From bede875a99e900025a7ffcd0963dc9cc20c368c2 Mon Sep 17 00:00:00 2001 From: Dino Turopoli Date: Fri, 29 Mar 2024 12:52:50 +0100 Subject: [PATCH] [Bug]: Fix moving objects in alphabetical tree (#469) --- public/js/pimcore/object/tree.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/public/js/pimcore/object/tree.js b/public/js/pimcore/object/tree.js index 1504983fb0..aaaf7c8e35 100644 --- a/public/js/pimcore/object/tree.js +++ b/public/js/pimcore/object/tree.js @@ -267,14 +267,16 @@ pimcore.registerNS("pimcore.object.tree"); onTreeNodesDrop: function (node, data, overModel, dropPosition, eOpts) { if (typeof this.treeNodeMoveParameter.oldParent.getOwnerTree !== "function") { + if (dropPosition == "before" || dropPosition == "after") { + return; + } + Ext.Array.each(data.records, function (record) { if (this.onTreeNodeBeforeMove(record, record.parentNode, overModel)) { this.onTreeNodeMove(record, record.parentNode, overModel, 0); } }.bind(this)); - } - if (typeof this.treeNodeMoveParameter.oldParent.getOwnerTree !== "function") { return; }