[ 
https://jira.nuxeo.org/browse/NXP-4934?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Stéfane Fermigier updated NXP-4934:
-----------------------------------

    Component/s: Layouts / Widgets

> Add a generic way to declare validators on builtin widget types
> ---------------------------------------------------------------
>
>                 Key: NXP-4934
>                 URL: https://jira.nuxeo.org/browse/NXP-4934
>             Project: Nuxeo Enterprise Platform
>          Issue Type: Sub-task
>          Components: Layouts / Widgets
>            Reporter: Anahide Tchertchian
>
> Most of standard widget types are using standard JSF components, that accept
> standard validators. There are two ways to declare a validator on a JSF 
> component:
> - use the "validator" property to declare a method binding that will perform 
> the
>   check and throw a ValidatorException error if validation fails. This is 
> already
>   available.
> - add a tag inside the component to declare another validator. For instance:
>        <h:inputText value="#{field_0}">
>           <f:validateLongRange minimum="1"/>
>        </h:inputText>
> The "f:validateLongRange" is a standard validator. The "f:validator" tag also 
> makes
> it possible to declare a validator by id.
> Custom validators can also be added to the framework. For instance, ui-web 
> defines
> validators "nxu:validateFileSize" and "nxu:validateFileMimetype" that can be 
> used
> inside the "nxu:inputFile" tag.
> As these tags all accept specific attributes, maybe a generic way to declare 
> them on
> the resulting component would be needed.
> Another idea would consist in defining validation rules on the layout, so 
> that condi-
> tions can be easily expressed in a el-like language, with some variables 
> exposed (to
> define.
> Syntax is still to discuss.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
https://jira.nuxeo.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
_______________________________________________
ECM-tickets mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/ecm-tickets

Reply via email to