Changeset 7734


Ignore:
Timestamp:
Aug 8, 2019, 9:21:14 AM (2 years ago)
Author:
Nicklas Nordborg
Message:

Fixes #2188: Enumerated annotation types should sort the possible values

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.15-stable/src/core/net/sf/basedb/core/AnnotationType.java

    r7615 r7734  
    12331233    if (!isEnumeration()) return null;
    12341234    ParameterValueData<?> pv = getData().getEnumerationValues();
    1235     return pv == null ? null : Collections.unmodifiableList(Values.getItemValues(getDbControl(), pv.getValues()));
     1235    if (pv == null) return null;
     1236   
     1237    List<T> values = Values.getItemValues(getDbControl(), pv.getValues());
     1238    if (values.size() > 1) values.sort(null);
     1239    return Collections.unmodifiableList(values);
    12361240  }
    12371241 
Note: See TracChangeset for help on using the changeset viewer.