PDA

View Full Version : Problem creating checkbox column in grid



ssinai
7 Apr 2011, 11:57 AM
I'm having a problem getting checkboxes to show up in a grid column. I need the checkboxes to show up in both the header and all the cells of that column, but the header and cells in the column show up empty.

I'm following the example code from the GridPlugins example in the Ext GWT 2.2.3 Explorer Demo.

When I do the following in my code:




CheckBoxSelectionModel<Patient> sm = new CheckBoxSelectionModel<Patient>();
columns.add(sm.getColumn());
System.out.println("checkBox class="+sm.getColumn().getClass());


I get

checkBox class=class com.extjs.gxt.ui.client.widget.grid.ColumnConfig

I do call


grid.setSelectionModel(sm);
grid.addPlugin(sm);

after the grid has been created.

Shouldn't I be get getting a CheckColumnConfig rather than just a plain, old ColumnConfig?