Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Ian Marshall
Hello Bertrand, Where is your Page2 code fragment called? Is in the page constructor, in a page component onSubmit() method, or somewhere else? My guess is that your code fragment is called in the page constructor. If this is so, then: · I might expect the differences in behaviour you

Re: Twitter Bootstrap Navigation and JQuery Impromptu demo / tutorial

2012-06-29 Thread Decebal Suiu
Thanks. I like Twitter Bootstrap -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Twitter-Bootstrap-Navigation-and-JQuery-Impromptu-demo-tutorial-tp4650273p4650279.html Sent from the Users forum mailing list archive at Nabble.com.

Re: Wicket 1.5.7: Links not working in WebSphere 6.1? Wrong redirection?

2012-06-29 Thread Jörn Gersdorf
Hi Andrew, thanks for your suggestion. I tried using the Wicket-Servlet instead of the Filter but unfortunately WebSphere's behaviour stays the same. It's only working if I override newWebResponse() in my application class additionally to . Just wanted to share the solution I found right now in

Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Bertrand Guay-Paquet
Hi Ian, Thanks for your reply. By the way, I forgot to mention I'm using Wicket 1.5.7. The (pseudo) code I wrote in my previous email is in Page2's constructor. I tried both approaches and here are the results: setResponsePage in page constructor: -Cookie not set === Cookie SET with patch

Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Martin Grigorov
Hi Bertrand, I'll write a more detailed answer to your mail later. Until then you can try to workaround it by calling 'setResponsePage()' in #onBeforeRender() instead. On Fri, Jun 29, 2012 at 4:21 PM, Bertrand Guay-Paquet ber...@step.polymtl.ca wrote: Hi Ian, Thanks for your reply. By the

Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Ian Marshall
Hi Bertrand, If you use and then one of in your Page2 constructor you should be able to pass (your cookie?) data to your Page1, and you will see by trial and error whether your flash message makes it to Page1 or not. Regards, Ian Bertrand Guay-Paquet wrote Hi Ian, Thanks for your

Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Bertrand Guay-Paquet
Hi Ian, I'm sorry, I don't understand. Perhaps some parts of your message didn't make it to the mailing list? (see If you use and and then one of). On 29/06/2012 9:39 AM, Ian Marshall wrote: Hi Bertrand, If you use and then one of in your Page2 constructor you should be able to pass (your

Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Bertrand Guay-Paquet
Hi Martin, This doesn't seem to fix the issue. The flash messages are not carried over to Page1 and the cookie is not set in the 302 to Page1. I did it like this: private boolean doRedirect; Page2(Parameters) { if( whatever ) { doRedirect = true; } } @Override protected

Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Ian Marshall
Sorry, raw HTML tag content did not make it to the E-mail I meant: If you use Session.get().info(blah); and then one of throw new RestartResponseException(Page1.class, PageParameters params); throw new RestartResponseException(new Page1(...)); in your Page2 constructor you should

Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Bertrand Guay-Paquet
Ok now I understand! What you suggest is more or less what I mentioned in the first email. RestartResponseException does indeed halt rendering of Page2 which causes the flash message to be displayed on Page1. I guess I could find a way to pass as page parameters of Page1 the cookie and set it

Re: setResponsePage swallows my session feedback messages

2012-06-29 Thread Martin Grigorov
Another way to solve this is to use: setCookie(); PageB pageb = new PageB(); pageB.info(something); setResponsePage(pageb) On Fri, Jun 29, 2012 at 5:25 PM, Bertrand Guay-Paquet ber...@step.polymtl.ca wrote: Ok now I understand! What you suggest is more or less what I mentioned in the first

Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
Hi, In my wicket application, each page carries many panels. *Now every panel is rendered when the page is loaded but when it is refreshed, nothing happens. * No panel is getting rendered again, not even sysouts are printing anything. *Now this is a good thing for performance but I want them to

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread Scott Swank
How do you construct your panels? This sounds like a model issue... Scott On Fri, Jun 29, 2012 at 9:02 AM, kshitiz k.agarw...@gmail.com wrote: Hi, In my wicket application, each page carries many panels. *Now every panel is rendered when the page is loaded but when it is refreshed, nothing

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
Hi, Like this is one page: public UserHome(final PageParameters pageParameters, UserDomain userDomain) { super(pageParameters, userDomain); if (userDomain == null) userDomain = getUserById(this.userId); add(new SearchPanel(searchPanel));

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread Dan Retzlaff
That's how Wicket manages stateful pages: it constructs it once, and subsequent actions (including re-rendering all or part) are handled by the same instance. If you want a label's content to be recomputed with each rendering, give it an IModelString at construction instead of the actual string.

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
Hi, Thanks for the reply. Just to clarify, like if I am adding a panel: *add(new PostPanel(postPanel, pageParameters, userTypeDomain, userDomain));* So, how do I make it render at every page refresh...? -- View this message in context:

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread Scott Swank
It is rendered, but the existing page is reused so you do not see the constructor called again. That's what Dan meant when he said, That's how Wicket manages stateful pages: it constructs it once, and subsequent actions (including re-rendering all or part) are handled by the same instance. You

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread Dan Retzlaff
Instead of using entities and strings in your constructors, use IModels such as LoadableDetachableModel. When re-rendering (AJAX or reload), your constructors aren't called again, but IModel#getObject() are called. On Fri, Jun 29, 2012 at 12:09 PM, kshitiz k.agarw...@gmail.com wrote: Hi,

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread Dan Retzlaff
Are you giving your ListView an IModelListT or a ListT? It needs to be the former to be redetermined on refresh. On Fri, Jun 29, 2012 at 12:48 PM, kshitiz k.agarw...@gmail.com wrote: Actually in that post panel, I am taking data from the database and displaying it as listview. Now, when I

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread kshitiz
I am using list only like this: PageableListViewPostDomain postDomainListView = new PageableListViewPostDomain( postList, *postDomainList*, postsPerPage) { // . } How am I suppose to use IModel for list? It is giving errors over here... -- View this

Re: Components do not re-render when page is refreshed...

2012-06-29 Thread Dan Retzlaff
I can't guess what your errors are, but for pageable lists you should probably be using DataView. There are examples here: http://www.wicket-library.com/wicket-examples/repeater/ On Fri, Jun 29, 2012 at 1:08 PM, kshitiz k.agarw...@gmail.com wrote: I am using list only like this: