我是 Vaadin 的新手,我创建了一个表,我可以通过 BeanItemCONtainer 填充其中的数据,下面是代码。
public Component getMainContent(ViewChangeListener.ViewChangeEvent event) {
List<ExecutionPlanVO> executionPlanVOs = executionPlanDelegate.getExecutionPlans(getSearchVO());
Table table = new Table();
BeanItemContainer<ExecutionPlanVO> container = new BeanItemContainer<ExecutionPlanVO>(ExecutionPlanVO.class, executionPlanVOs);
container.addBean(new ExecutionPlanVO());
table.setContainerDataSource(container);
table.setVisibleColumns(
new Object[] {"billOfladingNo" , "containerNo" , "houseBill" , "carrier" , "customer" , "origin" , "pol" , "transshipment" ,
"pod" , "destination" , "start" , "completion" , "status"});
table.setColumnHeaders(
new String[] {"Bill Of Lading" , "Container No." , "House Bill" , "Carrier" , "Customer" , "Origin" , "POL" , "Transshipment" ,
"POD" , "Destination" , "Start (LT)" , "Completion (LT)" , "Status"});
table.setStyleName("ep-list-table");
return table;
}
我在这里有两个问题,1.我想将 billOfladingNo 列更改为链接,当我单击时会执行一些操作?2. 我想再添加一列带有几个链接图标?
你能帮我如何添加列吗?
在此先感谢基兰。