Multiple DropDownChoice inside Loop
I have to repeat two dropdownchoice, I do that but I could not get their data. I used IModel for their model but when I select them and click on the submit button, their model is empty. Where I am wrong? I am getting crazy with that. Please help. - Wicket-Java -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Multiple-DropDownChoice-inside-Loop-tp3607850p3607850.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: Multiple DropDownChoice inside Loop
I mean i could not get data of multiple dropdownchoices. Any idea? With my best regards. - Wicket-Java -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Multiple-DropDownChoice-inside-Loop-tp3607850p3607965.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: Multiple DropDownChoice inside Loop
I have solved my problem. Thank you for your support! Regards - Wicket-Java -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Multiple-DropDownChoice-inside-Loop-tp3607850p3608111.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
multiple DropDownChoice
is example available for multiple DropDownChoice where one menu changes value in other? i look at http://wicketstuff.org/wicket13/ but see no example
Re: multiple DropDownChoice
Am Sonntag, 20. April 2008 18:19:33 schrieb i ii: is example available for multiple DropDownChoice where one menu changes value in other? i look at http://wicketstuff.org/wicket13/ but see no example You could do this in your model. Both ddcs could point to same business model. If a selection changes the model could switch the other attribute. After you reloaded the ddcs - the value should be updated. MyModel extends MyBusinessModel { List? values1 = null; Object selectedValue1 = null; List? values2 = null; Object selectedValue2 = null; List? getValues1() {return values1;} MyModel setValues1(List? a) {values1=a;} Object getSelectedValue1() { return selectedValue1;} MyModel setSelectedValue1(Object a) { selectedValue1 = a; if (a.equals(aObject)) { setSelectedValue2(getValues2().get(0)); } } List? getValues2() {return values2;} MyModel setValues2(List? a) {values2=a;} Object getSelectedValue2() { return selectedValue2;} MyModel setSelectedValue2(Object a) { selectedValue2 = a; if (a.equals(aObject)) { setSelectedValue1(getValues1().get(0)); } } } MyPanel extends Panel { MyPanel(String id, IModel m) { super(id, m); Form f = new Form(theForm); add(f); f.add(new DDC(val1, new PropertyModel(m, selectedValue1), new PropertyModel(m, values1); f.add(new DDC(val2, new PropertyModel(m, selectedValue2), new PropertyModel(m, values2); // ... ajax update behavior - examples in wiki } } MyPage extends WebPage { MyPage() { MyModel m = createMyModelWithSomeValues(); CompoundPropertyModel c = new CompoundPropertyModel(m); add(new MyPanel(myPanel, c); } } Something like that. HTH Per - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multiple DropDownChoice
what about that one: http://wicketstuff.org/wicket13/ajax/choice.1 ;-) regards, Michael i ii wrote: is example available for multiple DropDownChoice where one menu changes value in other? i look at http://wicketstuff.org/wicket13/ but see no example - Michael Sparer http://talk-on-tech.blogspot.com -- View this message in context: http://www.nabble.com/multiple-DropDownChoice-tp16795432p16795639.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: multiple DropDownChoice
http://wicketstuff.org/wicket13/ajax/choice On Sun, Apr 20, 2008 at 6:19 PM, i ii [EMAIL PROTECTED] wrote: is example available for multiple DropDownChoice where one menu changes value in other? i look at http://wicketstuff.org/wicket13/ but see no example - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: multiple DropDownChoice
thank you Date: Sun, 20 Apr 2008 21:32:48 +0200 From: [EMAIL PROTECTED] To: users@wicket.apache.org Subject: Re: multiple DropDownChoice http://wicketstuff.org/wicket13/ajax/choice On Sun, Apr 20, 2008 at 6:19 PM, i ii [EMAIL PROTECTED] wrote: is example available for multiple DropDownChoice where one menu changes value in other? i look at http://wicketstuff.org/wicket13/ but see no example - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]