How to style individual CalendarEvents for a data-bound calendar? Similar as the red event here:
http://www.smartclient.com/smartgwt/showcase/#databound_calendar_category
Since I have a data-bound calendar, I don't create the CalendarEvents explicitely. So how to access them to set their style, e.g. with calendar.setEventStyle() ?
I would like to do something like this:
Using smartgwt 4.1p power.
http://www.smartclient.com/smartgwt/showcase/#databound_calendar_category
Since I have a data-bound calendar, I don't create the CalendarEvents explicitely. So how to access them to set their style, e.g. with calendar.setEventStyle() ?
I would like to do something like this:
Code:
calendar.fetchData(c, new DSCallback() {
@Override
public void execute(DSResponse dsResponse, Object data,
DSRequest dsRequest) {
for (Record rec : dsResponse.getData()) {
if (rec.getAttributeAsBoolean("condition")) {
// how to do this?
CalendarEvent event = calendar.getEvent(rec);
calendar.setEventStyle(event, "myStyle");
}
}
}
});