add

adds a new item to the grouplist

string add(object obj, [number index,string parentId] );
objobjectthe item object
indexnumberoptional, the position that the item will be added to (zero-based numbering)
parentIdstringoptional, the parent id
stringID of the newly added item

Example

//inserts a new item into the parent with id='root'
grouplist.data.add({
    id:"item10", value:"NewItem"
}, 0, "root" );

Related samples

    Details

    Grouplist items are added in the same way as Tree items. Read more in Tree Nodes Manipulations

    See also
  • Articles
    • Back to top
      Join Our Forum
      We've retired comments here. Visit our forum for faster technical support, connect with other developers, and share your feedback there.
      If you have not checked yet, be sure to visit site of our main product Webix javascript ui components library and page of object list javascript product.