I need to replace a text value in a table column with an image. Here is the use case:
- I have a screen that shows search criteria fields (of type a. lookups, b. texts, c. dates).
- On clicking the Search button on the screen, the results are displayed in a table at the bottom section of the same screen. The results data is extracted from the database as a “Collection”.
I get the following error as soon as the JVM tries to executes the following in screen controller:
i wish to replace the text values in the “status” column with three images.
registrationsTable.addGeneratedColumn(“status”, entity -> {
if (entity.getStatus() == null) {
return null;
}
String[] statuses = entity.getStatus().split(";");
HBoxLayout hBoxLayout = componentsFactory.createComponent(HBoxLayout.class);
hBoxLayout.add(getLinkButtonForDocumentStatus(statuses[0]));
hBoxLayout.add(getLinkButtonForVerificationStatus(statuses[1]));
hBoxLayout.add(getLinkButtonForKYCStatus(statuses[2]));
return hBoxLayout;
});