Raising priority as this was reverted once already.

I do see the three potential interpretations of the required property for multi-fields in general (i.e. multivalue, composite and switchable fields).

But I also think we may come up with a sensible interpretation for each of them, individually:

  • MultiField would require at least one entry.
  • SwitchableField would require exactly its switch property to be set, i.e. the radio was explicitly selected. Whether subfield should have a value depends upon its respective required property.
  • CompositeField is more arguable.
    • It's already possible to mark individual sub-fields as required, on their respective definition.
    • A. Either it means all fields are required
    • B. Either at least one subfield is required
      • the "all" option remains possible by marking all subfield definitions as required (parent probably missing the asterisk then).
      • is more consistent with other multi-fields.
    • C. I would dismiss the "exactly one field" proposal — use a switchable field instead.
    • D. Fourth option: simply ignore the required property explicitly for composite fields.

In any case, if the required property doesn't solve issues, we should make sure it is possible to set custom FieldValidators to implement these behaviors, and maybe provide some of them.

Change By: Mikaël Geljic (17/Feb/15 5:36 PM)
Priority: Neutral Major
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira



----------------------------------------------------------------
For list details, see: http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: <dev-list-unsubscr...@magnolia-cms.com>
----------------------------------------------------------------

Reply via email to