wuyuedefeng / vue-sortable-tree

vue tree draggable, drag item sort
90 stars 21 forks source link

how to limit children ? #17

Open webafra opened 6 years ago

webafra commented 6 years ago

hello .

i need help to limit children tree

i want to add 1 children tree level in parent . for example :

this is Ok :

-parent 1 
  --child 1-1
  -- child 1-2

this is not ok :

-parent 1 
  --child 1-1
    ---- child 1-1-1

limit user to not add child 1-1-1

please help me .

wuyuedefeng commented 6 years ago

when insert a object as child, you can write A logical judge whether it can mounted. if not, don't assign the child data.

webafra commented 6 years ago

@wuyuedefeng i'm sorry , i'm not understand your idea !