Uploaded image for project: 'RichFaces'
  1. RichFaces
  2. RF-9508

UIValidatorScript component test and implementation

    Details

    • Estimated Difficulty:
      High

      Description

      1. UIValidatorScript
      • Holds Set of per-field validator functions ( ScriptObject instances ).
      • encodeAll method:
        o encode html <script> element for all libraries used by validators/converters.
        o encode all ScriptObject as <script> element with validator function definition.
        o Encode form-wide function for ActionSource components. That function should call all per-field validation functions.
        o Encode MessageDispatcher JavaScript object used to delivery messages from validators.
      1. ScriptObject creates JavaScript function definition that performs per-field validation. Attributes:
      • functionName.
      • description for converter function call, with parameters and message.
      • Collection of description for validator functions, with actual parameters and message.
      • AJAX callback code.
      • implements equals() method so all validators with same functionality would use single function.
      1. ScriptBuilder takes ScriptObject collection and builds client-side JavaScript code.

      This component should be added to viewResource by code ( with "form" or "body" target ), so it should be implemented similar to Queue script.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  alexsmirnov Alexander Smirnov
                  Reporter:
                  alexsmirnov Alexander Smirnov
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  0 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: