Posted 15 September 2022, 4:14 pm EST
Hi Team,
I have a wjFlexGridDetail grid as below. <wj-flex-grid #flexGrid class=“bento-flex-grid has-row-hover mt-4” [(itemsSource)]=“gridDataSource” [isReadOnly]=“true” [stickyHeaders]=“true” [showSort]=“true” [selectionMode]=“‘Row’” (initialized)=“gridInitialized(flexGrid)” [itemFormatter]=“itemFormatter” [headersVisibility]=“‘Column’” [ngStyle]=“{‘height’: CalculateHeight()}” [bentoBusyLoader]=“gridLoader”>
<ng-template wjFlexGridDetail #dp="wjFlexGridDetail" [detailVisibilityMode]="'Code'" let-row="row" let-item="item"> </ng-template>
I have a dropdown above the grid and on chnage od the dropdown value, the grid data updates.
the grid breaks with the below error in console for angular an error occurred here broo TypeError: Cannot read properties of undefined (reading ‘dataItem’) at FlexGridDetailProvider.getDetailRow (es5-esm.js:14:5821) at FlexGridDetailProvider.isDetailVisible (es5-esm.js:14:6013) at AccrualsComponent_div_3_div_16_ng_template_7_Template (accruals.component.html:526:33) at executeTemplate (core.js:9614:9) at refreshView (core.js:9480:13) at refreshEmbeddedViews (core.js:10605:17) at refreshView (core.js:9504:9) at refreshEmbeddedViews (core.js:10605:17) at refreshView (core.js:9504:9) at refreshEmbeddedViews (core.js:10605:17)
It is breaking at the html: <wj-flex-grid-column is-read-only=“true” [width]=“40”> <ng-template wjFlexGridCellTemplate [cellType]=“‘Cell’” let- row=“row” let-item=“item”> <i class=“grid-action-icon” [ngClass]=“{‘bento-icon-expand’:!dp.isDetailVisible(row),‘bento- icon-collapse’:dp.isDetailVisible(row)}” (click)=“toggleDetail(row, dp, item)”>