1

I am working to include support for filtering in a cell table. I have been looking for options on how to do this on SO,elsewhere, but I am yet to come up with a solution that would enable me to do dynamic filtering on a column. It would be difficult for me to change the base table ( its a basic cell table ) to one of the more advanced ones (like the ones i saw here GWT Table that supports dynamic filtering ). I am using a list data provider and all the operations will be done on the client side. Could someone give me some advice about how to proceed ?

Thanks in advance.

4

1 回答 1

1

如果一切都是客户端(例如,您使用简单的ListDataProvider),那么一切都与您渲染的内容有关。鉴于每个CellWidget都由 a 支持DataProvider以检索要显示的数据,那么我会说根据一些用户输入在支持的列表上应用过滤器。视图会自动更新。

如果你想做一些其他花哨的事情,比如文本突出显示,或者数据的视图操作,那么你需要进入render()你的列的单元格方法。就像当时的旧费用样本所做的那样。

旁注:CellTable您使用的实际上是您在帖子中链接的小部件的继承者。所以你比你想象的要更新。那篇文章已经很老了,因为孵化器项目在几年前就被弃用了,几乎所有的小部件都在 GWT 本身中找到了位置,在其他性质上。

于 2013-09-06T18:43:26.270 回答