Skip to content

Use source models for select and multiselect configuration fields #5

Open
@avstudnitz

Description

@avstudnitz

When retrieving a value of a select or multiselect field, the ID(s) are returned. For example: the country configuration general/country/default will return "DE".
I'd like to return "Germany" or "Deutschland", depending on the locale setting. Ideally, it'd return "Germany (DE)" or something like that. I could also think of making it configurable or providing an extra column with the "speaking" value. What do you think?

The same goes for multiselect fields like general/country/allow which return comma seperated lists like "DE,AT,CH".

For retrieving the speaking value, you can use the source model which is assigned to a config field.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions