use of com.haulmont.cuba.gui.components.filter.dateinterval.predefined.PredefinedDateInterval in project cuba by cuba-platform.
the class DateIntervalEditor method fillPredefinedIntervalsLookup.
protected void fillPredefinedIntervalsLookup() {
Map<String, PredefinedDateInterval> optionsMap = new LinkedHashMap<>();
for (PredefinedDateInterval interval : getPredefinedDateIntervals()) {
optionsMap.put(interval.getLocalizedCaption(), interval);
}
predefinedIntervalsLookup.setOptionsMap(optionsMap);
}
use of com.haulmont.cuba.gui.components.filter.dateinterval.predefined.PredefinedDateInterval in project cuba by cuba-platform.
the class DateIntervalEditor method getPredefinedDateIntervals.
protected Collection<PredefinedDateInterval> getPredefinedDateIntervals() {
List<PredefinedDateInterval> intervals = new ArrayList<>(AppBeans.getAll(PredefinedDateInterval.class).values());
intervals.sort(new AnnotationAwareOrderComparator());
return intervals;
}
Aggregations