Javascript treeview task.