angular-ui/ui-grid

cellClass function not called when cell data changes

已关闭

#5,816 创建于 2016年11月16日

 (5 条评论) (1 个反应) (1 位负责人)JavaScript (2,496 个派生)batch import
help wantedseverity: performance

仓库指标

星标
 (5,395 个星标)
PR 合并指标
 (PR 指标待抓取)

描述

If the data in a cell changes, the cellClass function is not called to update the class of the cell. The cell styling doesn't change until something forces the call such as sorting the table.

I am attempting to update cell data as it is updated from a message coming in over a websocket. The data in the table is updated and displayed. However, the cellClass function isn't called for the updated cell so the styling doesn't change.

I have recreated an example in the below plunker. If you click on the Change Velity button, the company text for the 3rd entry is changed to Aaaaaa but the text remains blue. Clicking on the column heading to sort the collumn displays the text as normal. Clicking the button again returns the company name to Velity. The text doesn't change back to blue. You have to sort the table to get the text to change back to blue. Plunker demonstrating problem

贡献者指南