Open
Description
Motivation
When rendering a multiple choice elements in a strongly typed model, one must access the List<Option> value
property of the MultipleChoiceElement class, which might be tedious. There should be a more straightforward path to the names of options.
One potential way to handle this would be like the following:
@ContentItemMapping("product")
public class Product {
@ElementMapping("product_categories")
List<Option> productCategories;
//New feature
@ElementMappingOption(elementCodeName = "product_categories", optionCodeName = "footwear")
Boolean isFootwear;
}
Original description
If an Option is mapped to a field, the name from the option should be used.