moves an item to a new position
sid | id | the id of the source item |
tindex | number | a new item index |
tobj | object | the target view |
details | object | extra parameters for moving |
string|number | the id of a moved item (a new id, if it was changed) |
The details object can contain the following properties:
details = {};
details.newId = "123"; // a new id for the moved item
details.parent = "a2"; // the id of a new parent element
If the parent is defined, tindex will be the child index inside the target branch.
If the parent is not defined, the value will be set to 0 (will be added to the tree root).
In case newId is not defined, the new ID will be the same as the ID of the source item (sid), which is not desirable while moving takes place within one and the same component.
Back to top