Stripes

The "field-metadata" tag should provide the "on" property value

Details

  • Type: Improvement Improvement
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: Release 1.5
  • Fix Version/s: Release 1.5.1, Release 1.6
  • Component/s: Tag Library
  • Labels:
    None

Description

The clever and useful "field-metadata" tag would be even better if it were to include the "on" property from field validation metadata. The "on" property value would make it possible for client-side code to figure out whether fields marked "required" really are required in the actual context of the form.

A variation on this would be to provide a way to tell the tag what event should be considered as the one for which validation will be performed. With that change, the tag would internally determine whether the "required" property is true or not. Thus my page would say something like

<s:field-metadata var='meta' event='save'>/* whatever */</s:field-metadata>

and the resulting block of metadata would only mark those fields "required" which are so marked for the "save" event.

Activity

Hide
Ben Gunter added a comment - 03/Mar/09 10:34 AM

Fixed. The "on" events are provided as an array of strings under the key "on".

Show
Ben Gunter added a comment - 03/Mar/09 10:34 AM Fixed. The "on" events are provided as an array of strings under the key "on".

People

Vote (0)
Watch (0)

Dates

  • Created:
    13/Dec/08 12:50 PM
    Updated:
    04/Jan/11 2:59 PM
    Resolved:
    03/Mar/09 10:34 AM