Re: Using interfaces as param type for Page constructor?

2012-09-17 Thread Martin Grigorov
Hi, Default impl of IPageFactory interface in Wicket knows how to instantiate only pages with default (empty) constructor and with PageParameters as only parameter. If your page has your own parameters (like IHasTraits) then you need either to instantiate the page yourself (e.g.

Re: Wicket+Spring+JUnit testing

2012-09-17 Thread Martin Grigorov
Hi, From the code below I don't see what exactly doesn't work. It looks fine for me. For simpler cases/pages I'd recommend to use Wicket's ApplicationContextMock instead of using the whole Spring context because this will slow down your tests. Just do: ctx= new ApplicationContextMock();

Re: AjaxEditableLabel causes exceptions after session timeout

2012-09-17 Thread Martin Grigorov
Hi, Usage of Wicket's Ajax behaviors make the page stateful, so there is no easy way to make it stateless. The easiest solution is to use org.apache.wicket.settings.IPageSettings#setRecreateMountedPagesAfterExpiry(false). This way you'll see the configured

Re: JavaScript execution on Ajax response in Wicket

2012-09-17 Thread seba.wag...@gmail.com
Thanks Sebastian, I was able to resolve it based on your examples! Sebastian 2012/9/16 Sebastien seb...@gmail.com: Hi Sebastian The issue is that $(document).ready( function() is not called (or only the first time) a Panel is loaded via Ajax. IMHO, the main thing to understand while working

Re: Wicket+Spring+JUnit testing

2012-09-17 Thread Sandor Feher
Hi, An unitializes session variable caused my problem. First I thought it was injecting problem. Thank you for advices now I'm green :). -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-Spring-JUnit-testing-tp4652021p4652030.html Sent from the Users forum

bookmarkable page being processed twice, second time, extra parameters passed

2012-09-17 Thread lucast
Dear Forum, I have a bookmarkable page which can take two parameters: uniqueName=[uniqueName] and unique_id_key=[] For some reason, the page is being instantiated twice. The first time, the right parameters are being passed. The second time, a lot of parameters are being passed and one of the

Re: Using and creating URLs to Bookmarkable Pages without Wicket Application

2012-09-17 Thread Sven Meier
Hi Dirk, IEmailUrlProviderI have used a similar approach in a project. You just have to make sure Wicket's ThreadContext is properly set before you access Wicket functionality. Take a look at BaseWicketTester's constructor. Hope this helps Sven On 09/17/2012 07:10 AM, Dirk Forchel wrote:

Re: Using and creating URLs to Bookmarkable Pages without Wicket Application

2012-09-17 Thread Dirk Forchel
Thank you for the hint. I just thought about using the WicketTester to mock the behavior (RequestCycle) of getting the url for a mounted page. -- View this message in context:

Re: Wicket 6 - drupal markup is rendered totally wrong

2012-09-17 Thread Marieke Vandamme
Hi, underneath the first part where it goes wrong. Al the -tag is printed before the *html wicket makes from it:* style type=text/css media=all /**/ /**/ /**/ */-- /**/ style type=text/css media=print /*![CDATA[*/ @import

Catch the doGet/doPost on every request and override it

2012-09-17 Thread eugenebalt
In Wicket, is there an easy way to override the doGet/doPost on every request in order to add some common code that should fire on every request? I used to know but forgot. The idea is to add some common code e.g. database transaction start/end for the request scope. -- View this message in

Re: Catch the doGet/doPost on every request and override it

2012-09-17 Thread Martijn Dashorst
A plain old servlet filter will do the trick afaik. If you want Wicket (=1.5) specific code, RequestCycleListener's are your best bet. Martijn On Mon, Sep 17, 2012 at 3:59 PM, eugenebalt eugeneb...@yahoo.com wrote: In Wicket, is there an easy way to override the doGet/doPost on every request

Re: Catch the doGet/doPost on every request and override it

2012-09-17 Thread vineet semwal
add your requestcyclelistener and do it in onbeginrequest On Mon, Sep 17, 2012 at 7:29 PM, eugenebalt eugeneb...@yahoo.com wrote: In Wicket, is there an easy way to override the doGet/doPost on every request in order to add some common code that should fire on every request? I used to know but

Re: disabling ajax submit button

2012-09-17 Thread Anna Simbirtsev
div class=submitareaa href=# wicket:id = submitButton1 class=button submitareaSUBMIT/a/div Sorry, you are right, it is an ajax link, not a button. On Thu, Sep 13, 2012 at 4:26 PM, Paul Bors p...@bors.ws wrote: I'm confused, the title is talking about an Ajax submit button yet your code

Re: Catch the doGet/doPost on every request and override it

2012-09-17 Thread vineet semwal
i didn't see last part of your mail see IRequestCycleListener onbeginrequest/onendrequest On Mon, Sep 17, 2012 at 7:29 PM, eugenebalt eugeneb...@yahoo.com wrote: In Wicket, is there an easy way to override the doGet/doPost on every request in order to add some common code that should fire on

Re: Catch the doGet/doPost on every request and override it

2012-09-17 Thread eugenebalt
What I'm looking for is some kind of an overridable onRequest() or a Request Listener that would apply to all requests within the Wicket app. (This must be done on the Request level, not on the Page level.) -- View this message in context:

Re: Catch the doGet/doPost on every request and override it

2012-09-17 Thread eugenebalt
Thanks, I found an example here: http://wicket.apache.org/apidocs/1.5/org/apache/wicket/request/cycle/IRequestCycleListener.html -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Catch-the-doGet-doPost-on-every-request-and-override-it-tp4652038p4652044.html Sent from

Re: Catch the doGet/doPost on every request and override it

2012-09-17 Thread eugenebalt
Sorry, one more question. Is it possible to know which active Page I'm currently on during this request interception? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Catch-the-doGet-doPost-on-every-request-and-override-it-tp4652038p4652045.html Sent from the Users

Re: Catch the doGet/doPost on every request and override it

2012-09-17 Thread vineet semwal
see PageRequestHandlerTracker ,you can get first and last page of your request On Mon, Sep 17, 2012 at 7:55 PM, eugenebalt eugeneb...@yahoo.com wrote: Sorry, one more question. Is it possible to know which active Page I'm currently on during this request interception? -- View this message

Re: Catch the doGet/doPost on every request and override it

2012-09-17 Thread eugenebalt
Thanks so much!! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Catch-the-doGet-doPost-on-every-request-and-override-it-tp4652038p4652047.html Sent from the Users forum mailing list archive at Nabble.com.

Re: AjaxEditableLabel causes exceptions after session timeout

2012-09-17 Thread Ondrej Zizka
Ok, thanks. I set this.getPageSettings().setRecreateMountedPagesAfterExpiry(false); in the app class. But, to my previous point: The page is mounted and reached with all the necessary data (to get the entity). But on AjaxEditableLabel interaction, the page is created with empty PageParameters.

Re: AjaxEditableLabel causes exceptions after session timeout

2012-09-17 Thread Martin Grigorov
On Mon, Sep 17, 2012 at 5:59 PM, Ondrej Zizka ozi...@redhat.com wrote: Ok, thanks. I set this.getPageSettings().setRecreateMountedPagesAfterExpiry(false); in the app class. But, to my previous point: The page is mounted and reached with all the necessary data (to get the entity). But on

ClassNotFoundException I'm out of ideas.

2012-09-17 Thread zarathustra
If I start it with eclipse-jetty it's works. If i start it with a tomcat 6 follow exeption shows up. I tried to fix it. but I dont have really a clou what's wrong. /Sep 17, 2012 4:58:56 PM org.apache.catalina.core.StandardContext filterStart Schwerwiegend: Exception starting filter

Re: ClassNotFoundException I'm out of ideas.

2012-09-17 Thread Martin Grigorov
What did you check already ? On Mon, Sep 17, 2012 at 6:09 PM, zarathustra wicketfo...@noxin.ch wrote: If I start it with eclipse-jetty it's works. If i start it with a tomcat 6 follow exeption shows up. I tried to fix it. but I dont have really a clou what's wrong. /Sep 17, 2012 4:58:56 PM

Re: bookmarkable page being processed twice, second time, extra parameters passed

2012-09-17 Thread Fergal Keating
The only similar issues i have come across are with plugins to my browser (firebug etc) causing second requests without any parameters. But this may be something similar. On 17 September 2012 11:18, lucast lucastol...@hotmail.com wrote: Dear Forum, I have a bookmarkable page which can take two

Wicket 6.0.0: RenderStrategy.REDIRECT_TO_RENDER and missing FeedbackMessages in ComponentFeedbackPanel.

2012-09-17 Thread Dan Haywood
We're using RenderStrategy.REDIRECT_TO_RENDER (ie redirect after post strategy; in 1.4.x this was working fine and our FeedbackMessage's were rendered correctly against their reporter using ComponentFeedbackPanel. Having upgraded to 6.0.0, the messages no longer appear. Investigating, it seems

Re: ClassNotFoundException I'm out of ideas.

2012-09-17 Thread S B
Hello zarathustra, Sorry if this is stating the obvious, but it looks like a classpath issue, are you sure that the wicket jar is being included in your servlet's lib directory? One way to find out what's in your classpath is to simply print it out with a jsp: Try saving the following as a

Is dataview/table with multiple rows possible?

2012-09-17 Thread Delange
Hi, I need a dataview/table with multipe rows One row is no problem, so who can help me with an example with 2 rows? # -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Is-dataview-table-with-multiple-rows-possible-tp4652055.html Sent from the Users

Re: Is dataview/table with multiple rows possible?

2012-09-17 Thread Thomas Götz
Please have a look at http://www.wicket-library.com/wicket-examples/repeater -Tom On 17.09.2012, at 20:37, Delange delan...@telfort.nl wrote: Hi, I need a dataview/table with multipe rows One row is no problem, so who can help me with an example with 2 rows?

Re: Is dataview/table with multiple rows possible?

2012-09-17 Thread Delange
I did, none of them have multiple rows What I mean is for example: How to do that? -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Is-dataview-table-with-multiple-rows-possible-tp4652055p4652057.html Sent from the Users

Re: Is dataview/table with multiple rows possible?

2012-09-17 Thread Martin Grigorov
http://www.wicket-library.com/wicket-examples-6.0.x/tree/wicket/bookmarkable/org.apache.wicket.examples.tree.TableTreePage On Mon, Sep 17, 2012 at 9:57 PM, Delange delan...@telfort.nl wrote: I did, none of them have multiple rows What I mean is for example: How to do that? --

Wicket 6 Websocket Example

2012-09-17 Thread sfwicket
Is there a working Wicket 6.0.0 Websocket example written in Java? The only demo provided here on the wiki page is written in Scala. https://cwiki.apache.org/WICKET/wicket-native-websockets.html The other demo I found has outdated dependencies on Wicket 6.0-SNAPSHOT and

Re: Wicket 6 Websocket Example

2012-09-17 Thread Martin Grigorov
Hi, http://wicketinaction.com/2012/07/wicket-6-native-websockets/ This is the Java example. What is the problem with compiling it ? On Mon, Sep 17, 2012 at 11:13 PM, sfwicket li...@bgb.net wrote: Is there a working Wicket 6.0.0 Websocket example written in Java? The only demo provided here

Re: Wicket 6 Websocket Example

2012-09-17 Thread sfwicket
ChartsResourceReference.java will not compile with a missing import on: import org.apache.wicket.request.resource.ExternalUrlResourceReference; This is with the Wicket version set in the pom.xml as either 6.0-SNAPSHOT (as it currently is) or changing it to 6.0.0. also, the pom.xml will

Re: Wicket 6 Websocket Example

2012-09-17 Thread Martin Grigorov
This class has been renamed to UrlResourceReference. Remove 'External' and it should work. On Mon, Sep 17, 2012 at 11:41 PM, sfwicket li...@bgb.net wrote: ChartsResourceReference.java will not compile with a missing import on: import

Re: Wicket 6 Websocket Example

2012-09-17 Thread sfwicket
got it - thanks! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-6-Websocket-Example-tp4652059p4652064.html Sent from the Users forum mailing list archive at Nabble.com. - To unsubscribe,

Re: Wicket 6 Websocket Example

2012-09-17 Thread Martin Grigorov
Good! I've updated the code of the demo apps in my repository. On Mon, Sep 17, 2012 at 11:57 PM, sfwicket li...@bgb.net wrote: got it - thanks! -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Wicket-6-Websocket-Example-tp4652059p4652064.html Sent from the

Wicket 6 / Modal Dialogs and Safari

2012-09-17 Thread Geoff Hayman
In Wicket 6 using Safari, a modal dialog will not allow interactions with form components. The whole dialog always seems to be in drag mode. Click anyw here on the panel and the dialog will drag. Interaction works fine with all other browsers. Safari interaction works fine with previous Wicket

Re: Wicket 6 Websocket Example

2012-09-17 Thread sfwicket
Thanks... the Tomcat artifact could be switched to 0.2 as well - I know its commented out but would make it easier switching from Jetty to Tomcat. Curious though in the example, ChartsResourceReference.java: JavaScriptHeaderItem.forReference(WicketWebSocketJQueryResourceReference.get())

Re: Wicket 6 / Modal Dialogs and Safari

2012-09-17 Thread Geoff Hayman
This issue can also be seen here: http://www.wicket-library.com/wicket-examples-6.0.x/ajax/modal-window Using Safari, the dialog appears to resize rather that select input fields -- View this message in context:

PageReference as page parameter?

2012-09-17 Thread Nelson Segura
Hello, I have a very common pattern in which from a list, I can to detail of an element in the list. In the detail page I have a reference back to the page list. The page list can be different, several list might point to the same detail. Until now I have been using page reference to return to the

Re: PageReference as page parameter?

2012-09-17 Thread Igor Vaynberg
you can pass in the page id obtained from page#getpageid() as a bookmarkable url, then to navigate back to the original page you can do setResponsePage(new PageReference(pageid).getPage()) this will, however, leave you on a nonbookmarkable url when you come back. if you want bookmarkable urls

Re: PageReference as page parameter?

2012-09-17 Thread Nelson Segura
That is what I thought, but PageReference constructor is not public, so I cannot do that, unless I am missing something? But I could do (Page)Session.get().getPageManager().getPage(pageId) As PageReference does internally, correct? - Nelson On Mon, Sep 17, 2012 at 3:11 PM, Igor Vaynberg

Re: PageReference as page parameter?

2012-09-17 Thread Igor Vaynberg
its public in 6. but yeah, you can do that yourself. -igor On Mon, Sep 17, 2012 at 3:20 PM, Nelson Segura nsegu...@gmail.com wrote: That is what I thought, but PageReference constructor is not public, so I cannot do that, unless I am missing something? But I could do

Wicket 6 + WebSocket + Apache + mod_jk

2012-09-17 Thread sfwicket
I have realized my WebSocket connection was closing briefly after opening because I have Apache httpd on port 80 with mod_jk running in front of my Tomcat instance on port 8080. When I connect directly on 8080 to Tomcat the Wicket WebSocket demo app works. What is the recommended configuration

Re: Wicket 6 / Modal Dialogs and Safari

2012-09-17 Thread Geoff Hayman
I have a proposed fix - please let me know if I've analyzed the problem correctly. The modal dialog tries to set event.ignore=true if the browser is Safari. This Wicket event data structure used to be passed through to Wicket.Drag.mouseDownHandler as the argument e. However, in the switch over

Re: Wicket 6 / Modal Dialogs and Safari

2012-09-17 Thread Geoff Hayman
My apologies... the patch file was incomplete. This one supersedes the previous one http://apache-wicket.1842946.n4.nabble.com/file/n4652075/Fix_to_Wicket_6___Safari_modal_window_drag_issue1.patch Fix_to_Wicket_6___Safari_modal_window_drag_issue1.patch -- View this message in context:

Re: AjaxEditableLabel causes exceptions after session timeout

2012-09-17 Thread Ondrej Zizka
Is there a mechanism to let the page be re-created with the original PageParameters? Maybe they could be kept within JS of the page and sent with the AJAX request? That would probably need a change in Wicket's AJAX code. (Wicket 1.5) That was the case until recently but there was

Auto PageParameters from a POJO?

2012-09-17 Thread Ondrej Zizka
Hi, I found myself repeatedly creating a PageParameters object from some domain object for BookmarkablePageLink just to have it then parsed back to that same domain object. Example: Release rel { product: AS; version: 7.1.2 } = add( new BookmarkablePageLink ( link, ReleasePage.class,

Re: [announce] Wicket-CDI for Wicket 6.0.0 released

2012-09-17 Thread Bruno Borges
Jeremy, the archetype is already on the Gamboa project repository: http://github.com/brunoborges/gamboa-project :-) It's just not up to date *Bruno Borges* (11) 99564-9058 *www.brunoborges.com* On Thu, Sep 13, 2012 at 11:39 AM, Jeremy Thomerson jer...@wickettraining.com wrote: On Wed, Sep