I have an entity definition which I build into a package so I can load it into a TAureliusDataset and create the fields. The important part of the entity definition is
[Enumeration(TEnumMappingType.emString, 'None,Text,Graph,Table')]
TDashboardDisplayType = (None, Text, Graph, Table);
[Entity]
[AutoMapping]
[DiscriminatorValue('DASHBOARD')]
TDashboardReport = class(TBaseReport)
private
FDashboardDisplay: Nullable<TDashboardDisplayType>;
public
property DashboardDisplay: Nullable<TDashboardDisplayType> read FDashboardDisplay write FDashboardDisplay;
end;
However, when I load from the package and create the field this gives me an Integer field and not a string field.
When I use a TXDataWebDataset in a WebCore app, then this maps as a stringfield.
While it is easy enough to work with both in an isolated app, it would be useful if this was consistent to allow for shared units.
Is there a way to enforce the handling of enumerated types in either dataset?