mirror of
https://github.com/nasa/openmct.git
synced 2024-12-22 06:27:48 +00:00
e04b9828ea
Use ng-model when communicating state to/from the tree in browse mode. This will simplify implementation of the Locator control, which also uses a tree, but which should not set navigation state. WTD-593.
27 lines
1.1 KiB
HTML
27 lines
1.1 KiB
HTML
<span ng-controller="ToggleController as toggle">
|
|
<span ng-controller="TreeNodeController as treeNode">
|
|
<span class="tree-item menus-to-left">
|
|
<span class='ui-symbol view-control'
|
|
ng-click="toggle.toggle(); treeNode.trackExpansion()"
|
|
ng-if="model.composition !== undefined">
|
|
{{toggle.isActive() ? "v" : ">"}}
|
|
</span>
|
|
<mct-representation key="'label'"
|
|
mct-object="domainObject"
|
|
ng-model="ngModel"
|
|
ng-click="ngModel.selectedObject = domainObject"
|
|
ng-class="{selected: treeNode.isSelected()}">
|
|
</mct-representation>
|
|
</span>
|
|
<span class="tree-item-subtree"
|
|
ng-show="toggle.isActive()"
|
|
ng-if="model.composition !== undefined">
|
|
|
|
<mct-representation key="'tree'"
|
|
ng-model="ngModel"
|
|
mct-object="treeNode.hasBeenExpanded() && domainObject">
|
|
</mct-representation>
|
|
|
|
</span>
|
|
</span>
|
|
</span> |