Hello
On dragging items inside a KendoUI treeview I need to know (while dragging) what the parent is of the dropTarget. Depending on that I will set the statusClass (whether its allowed to drop the dragged item or not).
The problem I run into is the fact, that e.dropTarget can return 2 different elements on statusClass insert-middle, insert-up and insert-down.
The first return element looks ok to me:
<span class=
"k-in"
>Entry 2</span>
The second one returns a DIV with no relation to where the dragged element will be dropped:
<div class=
"k-i-drag-and-drop"
style=
"visibility: visible; top: 81px; left: 16px;"
>
::before
</div>
With this DIV element I have no relation to where the dragged element will be dropped and therefore I can't set the statusClass properly.
The attached file shows a simple example of a treeview with 3 items. Drag the third element between the first and second item. The console output will show you the above described output elements while smoothly drag the third element between the first and second item. Same problem on dragging to insert-up and insert-down areas.
Is there a way to ensure I always get a tree item element back?
Regards