Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Click but no response #58

Open
kentlee87 opened this issue May 23, 2016 · 1 comment
Open

Click but no response #58

kentlee87 opened this issue May 23, 2016 · 1 comment

Comments

@kentlee87
Copy link

I setup the tree using the example given. A simple tree structure:
$scope.folderTreeList = [{ name: "folder_1", label: "Folder 1", collapsed: true, child: [{ name: "file_1", label: "Superman.txt" }] }, { name: "folder_2", label: "Folder 2" }];

The tree able to render correctly. But when I clicked on the folder icon, it won't expand. No error thrown in my firebug. Is a simple setup. But not working. The demo in jsfiddle working fine.

@tulior
Copy link

tulior commented Oct 21, 2016

I had the same problem.
Looking at the source, we have this line:
<i class="collapsed" data-ng-show="node.' + nodeChildren + '.length && node.collapsed" data-ng-click="' + treeId + '.selectNodeHead(node)"></i>
You can see that it registers the ng-click under "treeId".selectNodeHead(node). In my case, I had the treeId as "modulos-grupo" (with a dash), which is an invalid name for a property or variable. Changing the id from "modulos-grupo" to "modulosgrupo" fixed the problem.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants