Multipart issues in Wicket 1.4.15

2011-01-18 Thread exl
Encountering a show stopper for our project that involves being able to deal with a form containing a file upload that can be revealed depending on whether that particular workflow is desired. Please see attached quickstart project that shows this failing using Wicket version 1.4.15 (

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread Igor Vaynberg
file a jira issue. it will get lost here. -igor On Tue, Jan 18, 2011 at 2:43 AM, exl eric@uwa.edu.au wrote: Encountering a show stopper for our project that involves being able to deal with a form containing a file upload that can be revealed depending on whether that particular workflow

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread Pedro Santos
Set the root form as multipart in the onInitialize method, Wicket will fail in detect the form as multipart if the inner one with the upload field is not visible at the first render. On Tue, Jan 18, 2011 at 8:43 AM, exl eric@uwa.edu.au wrote: Encountering a show stopper for our project

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread Pedro Santos
I tested the quickstart with the HomeForm multipart property set to true and it is all ok. I'm 1+ to change Form#isMultipart implementation to don't test the form components visibility while visiting children. It is quite natural to have them set to true and sent back to browser in an AJAX

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread Igor Vaynberg
what about cases where users swap in an upload field later? in this case visibility isnt going to help. this is why we provide a way for the user to hard-set the value to true via form.setmultipart(true) - which is what i think exl should do. -igor On Tue, Jan 18, 2011 at 3:41 PM, Pedro Santos

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread exl
Ok. So Igor you're basically saying that as long as there is a possibility for a file upload, the root form should always be setMultiPart(true) as part of initialisation. I guess this means it is not a bug? (if so, then I won't add this to your bug tracking). I should mention that it will be

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread Jeremy Thomerson
Should we set the parent form to multipart somewhere around the post-configure / pre-render of a FileUpload? It could find its parent Form and do it automatically. I guess the question is really: is there anytime that we *wouldn't* want that to happen automatically? If we do it post-configure /

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread exl
Well as per Pedro and Igor's observation - if I setMultiPart(true) on the root form on initialisation, then I don't encounter exceptions any more using Wicket 1.4.15. I've applied this in our main development project and it seems to work fine. As a quick test, I switched back to Wicket version

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread exl
As an after thought, I'm leaning towards leaving 1.4.15 the way it is. I like the idea of having greater control over the multipart settings, assuming developers know when to enable it and when not to. For example, if I had another nested form that doesn't involve a file upload, then I'm

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread Arjun Dhar
Hi am not sure if a user vote is going on here. My 2 cents for my own insecurities: Leave it as is! Its good enough. I'm pretty much screwing around with FileUpload in many ways and overall its great. thanks - Don't take life too seriously, your'e not getting out it alive anyway! -- View

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread Jeremy Thomerson
On Tue, Jan 18, 2011 at 11:08 PM, Arjun Dhar dhar...@yahoo.com wrote: Hi am not sure if a user vote is going on here. Nah - a vote would have [VOTE] in the subject, and they are typically only on the dev@ list, not users@. But, we're *always* open to feedback here. My 2 cents for my own

Re: Multipart issues in Wicket 1.4.15

2011-01-18 Thread Igor Vaynberg
in 1.4.9 it worked because we did not take visibility of children into account. eg an invisible multipart component would make the form multipart as well. this was inconsistent so it was fixed. as far as automatic detection - i think in this case it happens during an ajax update and going from