Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Won't Fix
-
Affects Version/s: EE-4.0.0.GA
-
Fix Version/s: EE-4.1.0.GA
-
Component/s: ACE-Components
-
Labels:None
-
Environment:Tomcat 8, Myfaces libs, all browsers
-
Assignee Priority:P2
-
Workaround Description:
Description
When using myfaces libs and the ace:fileEntry Add row to top or bottom of table apps there is a js console error when using the Add button. This error occurs whether or not the multipart-config is added to the web.xml.
Screen shot of console error is included as there is no description.
To reproduce:
Build ace:fileEntry with myfaces libs.
Use the /fileEntryTableTop.jsf application found at:
http://dev.icesoft.com/svn/repo/qa/trunk/Regression-Icefaces4/Sparkle/Nightly/fileEntry
Open the browser console and press the Add button.
Screen shot of console error is included as there is no description.
To reproduce:
Build ace:fileEntry with myfaces libs.
Use the /fileEntryTableTop.jsf application found at:
http://dev.icesoft.com/svn/repo/qa/trunk/Regression-Icefaces4/Sparkle/Nightly/fileEntry
Open the browser console and press the Add button.
Activity
Liana Munroe
created issue -
Liana Munroe
made changes -
Field | Original Value | New Value |
---|---|---|
Attachment | 4.PNG [ 22041 ] |
Ken Fyten
made changes -
Assignee | Arturo Zambrano [ artzambrano ] | |
Fix Version/s | EE-4.1.0.GA [ 12171 ] | |
Assignee Priority | P2 [ 10011 ] |
Arturo Zambrano
made changes -
Status | Open [ 1 ] | Resolved [ 5 ] |
Resolution | Fixed [ 1 ] |
Arturo Zambrano
made changes -
Resolution | Fixed [ 1 ] | |
Status | Resolved [ 5 ] | Reopened [ 4 ] |
Arturo Zambrano
made changes -
Status | Reopened [ 4 ] | Resolved [ 5 ] |
Resolution | Won't Fix [ 2 ] |
Arturo Zambrano
made changes -
Workaround Description |
There are two possible workarounds:
1) Keep the upload form exclusively for uploading. All other actions should be done in a separate form or forms. 2) Add the enctype="multipart/form-data" attribute-value to the form. |
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
r44589: modified test app: moved 'add' button to a separate form
Regardless of which operation was being done, MyFaces was complaining for every request done inside a form that contained <input type="file"/> elements for not being a multipart form. The message I got was "Uncaught clientError: The form with the id frm has an input file element, but is not a multipart form". Even a plain h:commandButton with ajax and no actionListener was causing this issue. The operation done by the listener (i.e. adding a new row) was being performed normally however.
The way ace:fileEntry works is to hijack the request and makes it a multipart request dynamically. Of course, MyFaces doesn't know this and will complain about it. This is just MyFaces behaviour and nothing much can be done about it except for having the ace:fileEntry component(s) in an exclusive form where no other kinds of requests take place. We have already been recommending this practice.
Another option would be to simply specify the enctype="multipart/form-data" attribute in the form to prevent MyFaces from complaining.