I setup my selection in tree as checkbox.
In the slection property I have my model. I want the data behind the node.
So how can I get the data of the node in the selection and not the node?
I tried to do it with select or unselectnode but no chances.
Can you help?
Thanks,
My code is:
Code: Select all
<p-tree [value]="treeSpes"
selectionMode="checkbox"
dataKey="SpecialityId"
[(selection)]="criteria.specialities"
(onNodeSelect)="selectNode($event)"
(onNodeUnselect)="unselectNode($event)"
>
<ng-template let-node pTemplate="default">
<div>
<span style="font-size: 18px;">
{{node.label}}
</span>
</div>
</ng-template>
</p-tree>