angular-ui/ui-grid

rowIndex changes

Open

#6.577 geöffnet am 17. Feb. 2018

Auf GitHub ansehen
 (0 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)JavaScript (2.496 Forks)batch import
difficulty: hardhelp wanted

Repository-Metriken

Stars
 (5.395 Stars)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

Hello,

I have a custom row select function, as in following plunker: http://plnkr.co/edit/dyof0UiGKtvn0gAWcWuu?p=preview

for the first ~10-15 entries, it works awesome (try rightclicking the entries), but after scrolling, the rowIndex kinda changes. I tried changing cellTemplate to have gridApi.grid.renderContainers.body.visibleRowsCache.indexOf(row) instead of rowIndex, but same error afterwards unfortunately. You guys know some fix for that?

I even gave them an id: ... ui-grid-one-bind-id-grid="rowRenderIndex + '-' + row.entity.id + '-' + col.uid + '-cell'" ...

but even this one changes because scrolling kinda changes only the visible data but not the actual one, or the other way round.

Thank you very much for your help.

Contributor Guide