[jbossseam-issues] [JBoss JIRA] Commented: (JBSEAM-1981) enable validation on file upload component

Bruno Bieth (JIRA) jira-events at lists.jboss.org
Thu Sep 27 08:46:41 EDT 2007

    [ http://jira.jboss.com/jira/browse/JBSEAM-1981?page=comments#action_12379037 ] 
Bruno Bieth commented on JBSEAM-1981:

Well I haven't been working with the CVS version and I haven't found patch function with the local history ...
This is a very minor change on a very simple file. If you need to have the differences pointed out, just use the compare function in your editor. To format the code I guess you should have format rules (which I don't have) and it takes 2sec to apply it (well at least with eclipse).

> enable validation on file upload component
> ------------------------------------------
>                 Key: JBSEAM-1981
>                 URL: http://jira.jboss.com/jira/browse/JBSEAM-1981
>             Project: JBoss Seam
>          Issue Type: Patch
>            Reporter: Bruno Bieth
>         Attachments: UIFileUpload.java
> Currently file upload can't be validated. 
> The attached patch allow to use the hibernate validation framework with byte[] attribute.
> You may have, for instance, to check if an uploaded file is an Image.
> About the patch :
> First the submittedValue is not set so the validation phase is skipped, second file upload doesn't use the standard "value" attribute (needed by the ModelValidator) but "data".
> To work you have to use a value attribute to your fileupload component. At the moment this work only with Facelets. For backward compatibility the data attribute is kept (but validation won't work).

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


More information about the seam-issues mailing list