有谁知道我如何在可编辑表中跟踪修改后的项目值?
该表有一个 BeanContainer 数据源,我想在每次编辑或添加到表格中时更新它。
看起来很简单,但我到处都在搜索,但没有任何帮助,谢谢!
以下代码显示了我的BeanContainer:
`public BeanItemContainer createContainer() {
BeanItemContainer<PS_SECTION> beans = new BeanItemContainer<PS_SECTION>(PS_SECTION.class);
beans.addNestedContainerProperty("PS_SECTION");
beans.addNestedContainerProperty("NAME");
beans.addNestedContainerProperty("VORDER");
for (int i = 0; i < list.size(); i++) {
PS_SECTION section = list.get(i);
Long ps = section.getPS_SECTION();
String na = section.getNAME();
Long is = section.getISACTIVE();
Long isg = section.getISGLOBAL();
Long or = section.getVORDER();
Object itemId = beans.addItem(new PS_SECTION(ps, na, is, isg, or));
}
return beans;
}`