Currently, the @ViewEntries annotation just passes view columns on directly by programmatic name. This is okay in the normal case where the column is just the item name, or when the model object makes explicit affordances for view column names, but in practice things get hairier.
For example, in a client case, view columns are given programmatic names prefixed with “$” even when they contain a direct item - e.g. “$ProjectName”.
Additionally, this mapping may be different view to view.
It may end up making sense to have a repeatable annotation to provide entity field mappings to column names with an optional viewNames property.
Alternatively to mapping it on the entity level, it may make more sense to have a larger customization annotation set on the querying method, listing any field mappings needed.
Currently, the
@ViewEntries
annotation just passes view columns on directly by programmatic name. This is okay in the normal case where the column is just the item name, or when the model object makes explicit affordances for view column names, but in practice things get hairier.For example, in a client case, view columns are given programmatic names prefixed with “$” even when they contain a direct item - e.g. “$ProjectName”.
Additionally, this mapping may be different view to view.
It may end up making sense to have a repeatable annotation to provide entity field mappings to column names with an optional viewNames property.