You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by grazia <Gr...@gmail.com> on 2012/09/20 22:11:13 UTC

how to use the palette component for multiple updates ?

I am trying to work on a screen that should allow users to:
a. Associate elements from two different lists
b. Visualize the associations before saving. 

So, for instance, I could have two palettes, Instructor and Course.
I would liek to associate an Instructor to a Course repeatedly, and at the
bottom of the page to have a third palette-like that allows users to see the
selections before saving. 

I would really appreciate if you could send me a pointer in the right
direction. 

<http://apache-wicket.1842946.n4.nabble.com/file/n4652201/palettes.jpg> 



--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/how-to-use-the-palette-component-for-multiple-updates-tp4652201.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: how to use the palette component for multiple updates ?

Posted by Sven Meier <sv...@meiers.net>.
Sure, just one additional DropDownChoice for each ListView. The 
ListView's model takes into consideration what's in the DropDownChoice's 
model.

Sven

On 09/21/2012 03:24 PM, grazia wrote:
> This is very helpful ! Thank you very much.
> I am still learning on Wicket, I had not used ListChoice.
>
> You were asking about the dropdowns.
> The dropdown contains soem search criteria (and I am not sure this is the
> best UI, but my user is accustomed to this functionality). For instance, the
> drop down would allow them to choose available instructors by lastname or by
> country of origin or whatever, just to give an idea.
> In my case, the ListChoices would be populated based upon the selections in
> teh drop downs. It should be possible.
>
>
>
>
> --
> View this message in context: http://apache-wicket.1842946.n4.nabble.com/how-to-use-the-palette-component-for-multiple-updates-tp4652201p4652228.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: how to use the palette component for multiple updates ?

Posted by grazia <Gr...@gmail.com>.
This is very helpful ! Thank you very much. 
I am still learning on Wicket, I had not used ListChoice. 

You were asking about the dropdowns. 
The dropdown contains soem search criteria (and I am not sure this is the
best UI, but my user is accustomed to this functionality). For instance, the
drop down would allow them to choose available instructors by lastname or by
country of origin or whatever, just to give an idea.
In my case, the ListChoices would be populated based upon the selections in
teh drop downs. It should be possible. 




--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/how-to-use-the-palette-component-for-multiple-updates-tp4652201p4652228.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: how to use the palette component for multiple updates ?

Posted by Sven Meier <sv...@meiers.net>.
Hi,

I'm not sure what you're up to with the drop down selects at the top, 
but I'd suggest:

form = new Form("form");
form.add(new ListChoice("instructor", instructor, instructors));
form.add(new ListChoice("course", course, courses));
form.add(new Button("assign") {
   onSubmit() {
     assignments.getObject().add(new Assignment(instructor.getObject(), 
course.getObject()));
   }
});
form.add(new ListView("assigments", assignments) {
   populateItem(ListItem item) {
     item.add(new Label("instructor", new PropertyModel(item.getModel(), 
"instructor.name")));
     item.add(new Label("course", new PropertyModel(item.getModel(), 
"course.name")));
   }
});
form.add(new Button("save") {
   onSubmit() {
     save(assignments.getObject());
   }
});

Hope this helps
Sven

On 09/20/2012 11:38 PM, grazia wrote:
> What wicket components would you recommend I use ?
>
>
>
> --
> View this message in context: http://apache-wicket.1842946.n4.nabble.com/how-to-use-the-palette-component-for-multiple-updates-tp4652201p4652203.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: how to use the palette component for multiple updates ?

Posted by grazia <Gr...@gmail.com>.
What wicket components would you recommend I use ? 



--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/how-to-use-the-palette-component-for-multiple-updates-tp4652201p4652203.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org