Posted 21 October 2023, 5:56 pm EST - Updated 21 October 2023, 6:03 pm EST
Hi,
In the above image. I have nodes in the left hand side. I have multiple tabs in the right hand side. we have grid as response in every tab.
When we click on particular node I need to display the respective grid in the respective tab by calling API. I can able to get the grids in the tabs.
But when I click on any node. Everytime first tab is getting highlighted in the multiple tabs. I need to highlight the tab based on what I clicked in the left hand side.
In the below code I am getting index dynamically also (i.e., getting index as 0,1,2…) But that tab will not getting highlighted. Everytime first tab is getting highlighted. View is not getting updated
<wj-tab-panel #pTabPanel (initialized)="tabInit(pTabPanel)" [selectedIndex]="getting index dynamically">
<wj-tab *ngFor="let tab of tabsInfo">
<a>{{tab.header}}</a>
<wj-flex-grid #flexGrid [isReadOnly]="true" [itemsSource]="tab.data" (initialized)="flexGrid.autoSizeColumns(); flexInitialized(flexGrid)">
</wj-flex-grid>
</wj-tab>
</wj-tab-panel>