You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In your advanced example with DownlineTreeviewItem selection by order not work if we load items from unordered items (it will always sorted by value and product category in onSelectedChange(downlineItems: DownlineTreeviewItem[]) event).
as a sample I modify product.service.ts
getProducts(): TreeviewItem[]{const fruitCategory =newTreeviewItem({text: 'Fruit',value: 1,children: [{text: 'Apple',value: 11,checked: false},{text: 'Mango',value: 12,checked: false},{text: 'Banana',value: 13,checked: false},{text: 'Tomato',value: 14,checked: false},{text: 'Orange',value: 15,checked: false}]});constvegetableCategory=newTreeviewItem({text: 'Vegetable',value: 2,children: [{text: 'Salad',value: 21,checked: false},{text: 'Potato',value: 22,checked: false},{text: 'Spinach',value: 23,checked: false},{text: 'Cabbage',value: 24,checked: false},{text: 'Carrot',value: 25,checked: false}]});vegetableCategory.children.push(newTreeviewItem({text: 'Mushroom',value: 26,checked: false}));// vegetableCategory.correctChecked(); // need this to make 'Vegetable' node to change checked value from true to falsereturn[vegetableCategory,fruitCategory];}
and on product.component.ts I have selected member then set checked to true:
The text was updated successfully, but these errors were encountered:
dmaf87
changed the title
load from data DownlineTreeviewItem selection by order not work
load items from data, DownlineTreeviewItem selection by order not work
Feb 16, 2023
Hi @leovo2708,
In your advanced example with
DownlineTreeviewItem
selection by order not work if we load items from unordered items (it will always sorted by value and product category inonSelectedChange(downlineItems: DownlineTreeviewItem[])
event).as a sample I modify
product.service.ts
and on
product.component.ts
I have selected member then set checked to true:current result
expected result
Any solution for this or anyone can help?
Thanks.
The text was updated successfully, but these errors were encountered: