Setting Droppable: false to TreeNode doesn't disable its DropPoints
[x ] bug report
Current behavior When droppableNodes="true", Nodes can be dropped on all DropPoints, even when the 'droppable' property of the DropPoints' parent Nodes is set to 'false'.
- PrimeNG version: 4.0.3
I feel like it is expected, it is not dropping onto the node, droppoints are still useful to change order within tree. If more users demand it, we'll reopen, thank you.
To clarify, the problem is that ALL droppoints are enabled, which means a node may be dropped into droppoints of different levels, hence changing their parent, and not just their order.
@cagataycivici, I have the same issue. For an example, If 'node A' contains two children 'node A1' and 'node A2' and 'node A's droppable property is set false, then I need to disable all the drop points belong to 'node A' not 'node A1' and 'nodeA2'. Is there anyway I can achieve this?
I use PrimeNG 5.0.2 and am trying to limit where nodes can be dropped. I use a custom template to enable dropping (droppable=true) using the onDragStart method, and disabling dropping (droppable=false) on onDragEnd.
The onDragStart contains the logic to determine what allowed nodes (and 'reorder' locations) are.
Due to the droppoint behaviour I cannot make it work. Even when I set droppable=false on a node, the dragged node can still be dropped on a droppoint below that node, hence 'bypassing' my logic.
I have not found a way to influence to enable/disable 'droppable' on droppoints.
So 2 questions:
- is there a way to influence droppoint droppable behaviour and
- can you reconsider reopening this bug
PS: Thanks for the great set of components )