Dynamic UI Layout
Hi guys; I am trying to create a dynamic layout for bean fields. The fields could have the labels on top or on the side, The layout could be single column or multiple columns. Any idea on how to do this? I am thinking of using a table and use column span for multiple column. Any suggestions will be welcome. kind regards. Josh
Re: Catching maxSize of fileUpload error
See: org.apache.wicket.markup.html.form.Form.onFileUploadException(FileUploadException, MapString, Object) Regards Žilvinas Vilutis Mobile: (+370) 652 38353 E-mail: cika...@gmail.com On Fri, Oct 8, 2010 at 11:09 AM, meduolis meduol...@gmail.com wrote: Hello, is it possible to handle validation of maxSize of file upload (FileUploadField)? I need something like this onFileMaxSizeError() { someOtherField.error(someValidationMessage); } I hope someone understand what I want :D, if not, please let me know, i will try to describe more accuretly. Thanks in advance -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Catching-maxSize-of-fileUpload-error-tp2968831p2968831.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Catching maxSize of fileUpload error
It's working, thanks a lot ;) -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Catching-validation-error-of-fileUpload-maxSize-failing-tp2968831p2970111.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Dynamic UI Layout
You can use ListView's: https://cwiki.apache.org/WICKET/forms-with-dynamic-elements.html https://cwiki.apache.org/WICKET/page-with-dynamic-components.html https://cwiki.apache.org/WICKET/create-dynamic-markup-hierarchies-using-panels.html -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Dynamic-UI-Layout-tp2970085p2970123.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Nice URL for non-bookmarkable page
Ok, but what to do with the payment object? As far as I know bookmarkable page can't have a constructor with Payment object as an argument - it can have only constuctor without arguments or with PageParameters argument. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Nice-URL-for-non-bookmarkable-page-tp2967886p2970170.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
The proxy server received an invalid response from an upstream server.
Hi! I have this problem Error reading from remote server with Wicket-Jetty-Apache mod_proxy integration. It occurs only for page requests that take long time (couple of minutes) to process. Did anybody find a solution for it? http://serverfault.com/questions/185894/proxy-error-502-reason-error-reading-from-remote-server-with-apache-2-2-3-deb ** Martin - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: RadioChoice - what's wrong?
So maybe someone could just show me working RadioChoice code with OnSubmit part? Just how to properly display it and grab data from it :) That should solve the problem, as I would compare and see what I'm doing wrong. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/RadioChoice-what-s-wrong-tp2967576p2970217.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Nice URL for non-bookmarkable page
Can't you just pass a parameter (e.g. an id) and from there retrieve your payment object? Enretso On Sun, Oct 10, 2010 at 1:05 PM, fadeyev fade...@yandex.ru wrote: Ok, but what to do with the payment object? As far as I know bookmarkable page can't have a constructor with Payment object as an argument - it can have only constuctor without arguments or with PageParameters argument. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Nice-URL-for-non-bookmarkable-page-tp2967886p2970170.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Nice URL for non-bookmarkable page
Can't spell correctly my own name:-) Ernesto On Sun, Oct 10, 2010 at 5:36 PM, Ernesto Reinaldo Barreiro reier...@gmail.com wrote: Can't you just pass a parameter (e.g. an id) and from there retrieve your payment object? Enretso On Sun, Oct 10, 2010 at 1:05 PM, fadeyev fade...@yandex.ru wrote: Ok, but what to do with the payment object? As far as I know bookmarkable page can't have a constructor with Payment object as an argument - it can have only constuctor without arguments or with PageParameters argument. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Nice-URL-for-non-bookmarkable-page-tp2967886p2970170.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: RadioChoice - what's wrong?
Hello Zeldor, I've red your code and it seems that you define variable rc two times: the first time as form private field and the second time just below between braces. When onSubmit method calls rc.getModelObject() it uses private field rc which was not initialized and so triggers a NullPointerException. Try to remove the second type definition RadioChoiceString and it should work. public class Registration extends WebPage { public Registration() { add(new FeedbackPanel(errorMsg)); //New user registration form FormString regForm = new FormString(registrationForm,new ModelString()) { static final ListString NUMBERS = Arrays.asList(new String[] { 1, 2, 3 }); private RadioChoiceString rc; { RadioChoiceString rc = new RadioChoiceString(numberRadioChoice, new ModelString(),NUMBERS).setSuffix(); add(rc.setRequired(true)); } @Override public void onSubmit() { String _numbers = rc.getModelObject(); System.out.println(_numbers); } }; add(regForm); } } - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: RadioChoice - what's wrong?
It does! Thanks a lot! I knew it was something stupid and trivial. Huh, but it should not cause that still - I was defining TextFields in same way and then again to add parameters and it went fine. On Sun, Oct 10, 2010 at 7:11 PM, Andrea Del Bene [via Apache Wicket] ml-node+2970427-965616561-152...@n4.nabble.comml-node%2b2970427-965616561-152...@n4.nabble.com wrote: Hello Zeldor, I've red your code and it seems that you define variable rc two times: the first time as form private field and the second time just below between braces. When onSubmit method calls rc.getModelObject() it uses private field rc which was not initialized and so triggers a NullPointerException. Try to remove the second type definition RadioChoiceString and it should work. public class Registration extends WebPage { public Registration() { add(new FeedbackPanel(errorMsg)); //New user registration form FormString regForm = new FormString(registrationForm,new ModelString()) { static final ListString NUMBERS = Arrays.asList(new String[] { 1, 2, 3 }); private RadioChoiceString rc; { RadioChoiceString rc = new RadioChoiceString(numberRadioChoice, new ModelString(),NUMBERS).setSuffix(); add(rc.setRequired(true)); } @Override public void onSubmit() { String _numbers = rc.getModelObject(); System.out.println(_numbers); } }; add(regForm); } } - To unsubscribe, e-mail: [hidden email]http://user/SendEmail.jtp?type=nodenode=2970427i=0 For additional commands, e-mail: [hidden email]http://user/SendEmail.jtp?type=nodenode=2970427i=1 -- View message @ http://apache-wicket.1842946.n4.nabble.com/RadioChoice-what-s-wrong-tp2967576p2970427.html To unsubscribe from RadioChoice - what's wrong?, click herehttp://apache-wicket.1842946.n4.nabble.com/template/TplServlet.jtp?tpl=unsubscribe_by_codenode=2967576code=cGdyb25raWV3aWN6QGdtYWlsLmNvbXwyOTY3NTc2fC0xMTUwMjA4NDM=. -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/RadioChoice-what-s-wrong-tp2967576p2970465.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: wicket 1.5, css resourcereference from string?
I actually just made a youtube video how to add css/js to a page. See it here: http://www.youtube.com/watch?v=9toRTCFJf3Y Though I did not cover textemplateresourcereference. It is just as Igor described but now you can see the complete code if necessary. On Fri, Oct 8, 2010 at 12:50 PM, nino martinez wael nino.martinez.w...@gmail.com wrote: hmm right, could I just embed it in the html page then, I guess the answer is yes? I guess the reason I took this path was because of the texttemplateresourcereference which seems to do something much like this. regards Nino 2010/10/8 Igor Vaynberg igor.vaynb...@gmail.com what you are trying to do doesnt make sense, think about it. how is wicket supposed to build a url to your anonymous reference instance? you have two options, use renderCssReference(String url) to output the url to your custom css or if you need to stream it from somewhere inaccessible by the browser you can create a shared resource or a servlet -igor On Fri, Oct 8, 2010 at 2:44 AM, nino martinez wael nino.martinez.w...@gmail.com wrote: Has someone an idea? I am just trying to read a custom css from a string and render it as a reference on the page. Do I need to register the reference somewhere or sormething? 2010/10/7 nino martinez wael nino.martinez.w...@gmail.com Hi I cant get below working: public void renderHead(IHeaderResponse response) { super.renderHead(response); if (wallboardConfigurationModel.getObject().hasCustomCss()) { final StringResourceStream stringResourceStream = new StringResourceStream( wallboardConfigurationModel.getObject().getCustomCss(), text/css); ResourceReference resourceReference = new ResourceReference( wallboardConfigurationModel.getObject().getId()) { @Override public IResource getResource() { return new ResourceStreamResource(stringResourceStream); } }; response.renderCSSReference(resourceReference); } } I get this out put in the log: 010-10-07 15:33:57,555 WARN [org.apache.wicket.request.resource.ResourceReferenceRegistry] - Asked to auto-create a ResourceReference, but ResourceReferenceRegistry.createDefaultResourceReference() return null. [scope: org.apache.wicket.Application; name: test1; locale: null; style: null; variation: null] 2010-10-07 15:33:57,555 ERROR [org.apache.wicket.request.cycle.RequestCycle] - Unable to execute request. No suitable RequestHandler found. URL=wicket/resource/org.apache.wicket.Application/test1 - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Page Expired page with PatternDateConverter
I am new to the Wicket framework and I hope I can get some help with a problem I am facing. I am using version 1.4.12. I am overriding the AjaxEditableLabel class and its overridden getConverter method is at follows: @Override public IConverter getConverter(Class type) { return new PatternDateConverter(MM/dd/, true); } However, the first time in a session the component is updated, I get the Page Expired message. The error results only when the getConverter method is called. Note that this happens only the first time I access it in a session. If I go to the home page and from there back to the page which contains the component, it works without any problems. I am not sure how to overcome this problem. I hope you guys can help. Thanks. - Hemant
Re: Page Expired page with PatternDateConverter
Did you look at Wicket's logs ? Be sure serialization is done correctly. 2010/10/10 Hemant Shah prot...@gmail.com I am new to the Wicket framework and I hope I can get some help with a problem I am facing. I am using version 1.4.12. I am overriding the AjaxEditableLabel class and its overridden getConverter method is at follows: @Override public IConverter. getConverter(Class type) { return new PatternDateConverter(MM/dd/, true); } However, the first time in a session the component is updated, I get the Page Expired message. The error results only when the getConverter method is called. Note that this happens only the first time I access it in a session. If I go to the home page and from there back to the page which contains the component, it works without any problems. I am not sure how to overcome this problem. I hope you guys can help. Thanks. - Hemant
Dunamic neted List Views
Hi, I just developed a Menu; that is nested many levels. At the point of rendering in my code I'm slightly confused. ok, Let the code talk: (The following code assumes a domain model with MenuItemState which is hiararchial has children. And each child node is a MenuItemState. The child can either have null or further children. The renderMenu() is called by a Panel.) @Override public void renderMenu() { IModelMenuItemState modelState = getState(); MenuItemState state = modelState.getObject(); //Add all menu state objects as Ordered List / sub lists. add(new ListViewMenuItemState(menuItems, state.getChildren()) { @Override public void populateItem(final ListItemMenuItemState wrappedChildComponent) { final MenuItemState childItemState = wrappedChildComponent.getModelObject(); wrappedChildComponent.add(new Label(name, childItemState.getMenuItem().getName())); wrappedChildComponent.add(new StaticImage(img, new Model(childItemState.getMenuItem().getImg())) ); wrappedChildComponent.add(new StaticImage(rollOverImg, new Model(childItemState.getMenuItem().getRollOverImg())) ); wrappedChildComponent.add(new Label(selected, Boolean.toString(childItemState.isSelected(; } }); .. now I can add the children like: wrappedChildComponent.add(new ListView(nestedItemsFor_+childItemState.getMenuItem().getName(), childItemState.getChildren() {...} ); Code: Current markup code:: table tr wicket:id=menuItems td/td td /td td /td td /td /tr /table ..but how will the above markup code generate the name for the nestedItem Component know if the item has children. Should I just inject markup mylsef or using ListView can achieve this cleanly? I want to introduce nesting from my Model into the markup using ListView! Ideas?! (I dont wanna keep posting answers to my own questions so quick replies would help :) ) heh -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Dunamic-neted-List-Views-tp2970644p2970644.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Dunamic neted List Views
!...@#$ The subject was meant to be Dynamic Nested List Views! Apologies -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Dunamic-neted-List-Views-tp2970644p2970646.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: Page Expired page with PatternDateConverter
Altuğ, thanks for responding. There are no errors reported in the log. All the classes in the project are serializable. Could this be a bug? Regards, Hemant On 10/10/2010 5:03 PM, Altuğ Bilgin Altıntaş wrote: Did you look at Wicket's logs ? Be sure serialization is done correctly. 2010/10/10 Hemant Shahprot...@gmail.com I am new to the Wicket framework and I hope I can get some help with a problem I am facing. I am using version 1.4.12. I am overriding the AjaxEditableLabel class and its overridden getConverter method is at follows: @Override public IConverter. getConverter(Class type) { return new PatternDateConverter(MM/dd/, true); } However, the first time in a session the component is updated, I get the Page Expired message. The error results only when the getConverter method is called. Note that this happens only the first time I access it in a session. If I go to the home page and from there back to the page which contains the component, it works without any problems. I am not sure how to overcome this problem. I hope you guys can help. Thanks. - Hemant