Re: Palette - AJAX functionality

2016-04-27 Thread PDiefent
Hi Sven,
thanks for your help - looks promising now!
Now I only have to improve the CSS ...
Peter

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Palette-AJAX-functionality-tp4674433p4674460.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: Palette - AJAX functionality

2016-04-27 Thread Sven Meier

Hi,

there are multiple things going wrong here:

- you didn't read Palette's javadoc:
 * Ajaxifying the palette: If you want to update a 
Palette with an
 * {@link AjaxFormComponentUpdatingBehavior}, you have to attach it to 
the contained
 * {@link Recorder} by overriding {@link #newRecorderComponent()} and 
calling

 * {@link #processInput()}:

- the following example code was bogus (my bad) and should read:

Palette palette=new Palette(...) {
protected Recorder newRecorderComponent()
{
 Recorder recorder=super.newRecorderComponent();
 recorder.add(new AjaxFormComponentUpdatingBehavior("change") {
protected void onUpdate(AjaxRequestTarget target) {
processInput(); // let Palette process input too
...
}
});
 return recorder;
}
}

- as written in the Javadoc too, you have to use unique ids, so your 
example has to be changed to use an id for the choices:


IChoiceRenderer renderer = new 
ChoiceRenderer("newAccName", "newAccIntAcc");


I'll improved the Javadoc, please let us know whether this fixes your issue.

Have fun
Sven




On 27.04.2016 08:32, PDiefent wrote:

Hi Sven,
thanks for your reply. Please find a QickStart attached.
Peter
palette.7z


--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Palette-AJAX-functionality-tp4674433p4674453.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: Palette - AJAX functionality

2016-04-27 Thread PDiefent
Hi Sven, 
thanks for your reply. Please find a QickStart attached.
Peter
palette.7z
  

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Palette-AJAX-functionality-tp4674433p4674453.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: Palette - AJAX functionality

2016-04-26 Thread Sven Meier

Hi,

have you checked whether an Ajax is triggered, possibly losing the 
current selection?


A quickstart would help :)

Sven

On 26.04.2016 15:19, PDiefent wrote:

Hello,
I've migrated my Wicket 6 application to Wicket 7 and I got some problems
with a modal window containing a palette component.
In Wicket 7 no updates are visible between the two lists
(available/selected). If I try to move one entry to the opposite list there
is only a short flicker but no entry will be moved.
Unfortunaletly there is no AJAX related example available for Wicket 7 ...
Thanks for any hints
Peter

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Palette-AJAX-functionality-tp4674433.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