I do have ListGrid with datasource.xml file created by builder.
Pretty much straight forward.
Also I've added this:
....
for (int i = 0; i < dsf.length - 1; i++) {
DataSourceField ff = dsf[i];
if (ff.getAttribute("foreignKey") != null) {
ff.setEditorType(new ComboBoxItem());
}
}
.....
listGrid.setShowFilterEditor(true);
to set editor for current column and have ability to choose appropriate value from table linked by foreign key, and it works!
What doesn't work - that same list of values from lookup table aren't get populated in Filter columns which are displayed like Comboboxes as well.
How to solve the problem?
Pretty much straight forward.
Also I've added this:
....
for (int i = 0; i < dsf.length - 1; i++) {
DataSourceField ff = dsf[i];
if (ff.getAttribute("foreignKey") != null) {
ff.setEditorType(new ComboBoxItem());
}
}
.....
listGrid.setShowFilterEditor(true);
to set editor for current column and have ability to choose appropriate value from table linked by foreign key, and it works!
What doesn't work - that same list of values from lookup table aren't get populated in Filter columns which are displayed like Comboboxes as well.
How to solve the problem?
Comment