Re: Pass page parameters

2008-01-13 Thread tsuresh
Ok I solved it. I changed the line User userSelected= (User) getModelObject(); to User userSelected= (User) getParent().getModelObject(); The problem must have been no model set for link. tsuresh wrote: Hello I have a list of users with links in class UserList. When I click the link I

Re: the flow of wicket

2008-01-13 Thread Dmitry Kandalov
On Sunday 13 January 2008 04:19:30 Igor Vaynberg wrote: Ok, so rarely you need to roll your own IRequestTargetUrlCodingStrategy, we do provide implementations to cover most common cases. And even if you do, you only need to know about IRequestTarget - which has good javadoc, and so does the

Any quickstart for wicket-terracotta

2008-01-13 Thread xdirewolfx
I am aware that there is such an integration between wicket and terracotta however, I have yet to see any example. Anyone can point me to that? -- View this message in context: http://www.nabble.com/Any-quickstart-for-wicket-terracotta-tp14783593p14783593.html Sent from the Wicket - User

PagingNavigator refactoring request

2008-01-13 Thread behlma
Hi guys, would it be possible to change PagingNavigator's constructor from public PagingNavigator(final String id, final IPageable pageable, final IPagingLabelProvider labelProvider) { super(id); // Get the navigation bar

Re: Resizable and reorderable grid components

2008-01-13 Thread Martijn Dashorst
On Jan 13, 2008 6:01 AM, Igor Vaynberg [EMAIL PROTECTED] wrote: so exactly what kinds of components would it be nice to see? a weather widget? I initially read that as a feather widget (a Wicket component that shows the Apache feather). Martijn -- Buy Wicket in Action:

Re: Pass page parameters

2008-01-13 Thread Martijn Dashorst
You could also do: add(new Link(foo, item.getModel()) { }); Martijn On Jan 13, 2008 9:29 AM, tsuresh [EMAIL PROTECTED] wrote: Ok I solved it. I changed the line User userSelected= (User) getModelObject(); to User userSelected= (User) getParent().getModelObject(); The problem must have

Re: How do you do this in wicket?

2008-01-13 Thread Martijn Dashorst
Have one session that knows when authentication has happened... public MySession extends WebSession { private String username; public void setUsername(){} public boolean isAuthenticated() { return username != null; } } Then in your web page you can do: if

Re: the flow of wicket

2008-01-13 Thread Dmitry Kandalov
On Sunday 13 January 2008 12:47:44 Dmitry Kandalov wrote: On Sunday 13 January 2008 04:19:30 Igor Vaynberg wrote: Ok, so rarely you need to roll your own IRequestTargetUrlCodingStrategy, we do provide implementations to cover most common cases. And even if you do, you only need to know

Raw urls using WicketTester 1.3.0

2008-01-13 Thread Martin Makundi
Hi! My main question is: how to process multiple consecutive raw requests using WicketTester, during the same user session. By raw I mean page requests that do not result from clicking links on pages, but instead, they would be equivalent to the user simply typing them into the browser (like the

Re: How to display as is

2008-01-13 Thread Matej Knopp
What do you mean that browser displays as amp;? Is it in source code? Because that is right. The needs to be escaped, but unless your browser is broken the user should never see amp; unless he looks to source code. Anyway, label.setEscapeModelStrings(false) prevents wicket from escaping it.

Re: Adding breadcrumbs

2008-01-13 Thread WickedMan
I gave it a try but I really cannot figure it out how to do it with pages instead of panels. Any help would be appreciated. Eelco Hillenius wrote: Could you give me code examples how to do that? Not without having to spend a couple of hours on it, and I'm afraid I don't have time for

Re: How to display as is

2008-01-13 Thread dvd
Thanks for the quick response. That solves the problem. What do you mean that browser displays as amp;? Is it in source code? Because that is right. The needs to be escaped, but unless your browser is broken the user should never see amp; unless he looks to source code. Anyway,

How to display as is

2008-01-13 Thread dvd
Hello: I use Label(id, A B)    and the is supposed to be kept as is since it is what the title would read.  but the browser displays  A amp; B What should I do to avoid this? Thanks  

Re: London Wicket Event - Schedule/Bigger Room

2008-01-13 Thread jweekend
Ian has sent me the project and I will be reviewing it soon. In case he doesn't see this thread I'll ask him to send us a one paragraph summary that does it justice. Regards - Cemal http://jWeekend.co.uk http://jWeekend.co.uk Johan Compagner wrote: Whats that new wicket security

Re: How do you do this in wicket?

2008-01-13 Thread xdirewolfx
Thank you Martijin. Ken Martijn Dashorst wrote: Have one session that knows when authentication has happened... public MySession extends WebSession { private String username; public void setUsername(){} public boolean isAuthenticated() { return username !=

Re: How do you do this in wicket?

2008-01-13 Thread Martijn Dashorst
Another option is too look at wicket-auth-roles. It is really simple (basically an example) but for a lot of applications it is in the sweet spot. Two default roles: user and admin. The wicket examples have the auth roles examples in them. Martijn On Jan 13, 2008 3:31 PM, xdirewolfx [EMAIL

Re: How do you do this in wicket?

2008-01-13 Thread xdirewolfx
The reason we went for such an approach was because user will design the lookfeel, content and whether it is public or private(authentication needed) on runtime using view metadata. We used proprietary technology earlier on and decided to give a short in wicket as it fits better and much more

Re: Problem with Wicket and Guice

2008-01-13 Thread Martijn Dashorst
iirc objects that aren't components are not injected as they are not under Wicket's control. In the spring integration you need to do: Cart() { InjectionHolder.inject(this); } I imagine this is similar to the Wicket guice integration. Martijn On 1/13/08, t.weitzel [EMAIL PROTECTED] wrote:

Re: How do you do this in wicket?

2008-01-13 Thread Anders Peterson
I have a related question. What should I do when the user logs out. Currently I just set username to null and redirect to the original login page. I feel I also should invalidate the session but that doesn't work. Then I always end up with a Page Expired page. I'd like to still end up with

Re: How do you do this in wicket?

2008-01-13 Thread Martijn Dashorst
iirc: setResponsePage(LoginPage.class); setRedirect(true); getSession().invalidate(); Martijn On 1/13/08, Anders Peterson [EMAIL PROTECTED] wrote: I have a related question. What should I do when the user logs out. Currently I just set username to null and redirect to the original login

Re: How do you do this in wicket?

2008-01-13 Thread Anders Peterson
Doesn't work for me... I have a PageLink class with a onClick() method that looks like this: public void onClick() { super.onClick(); this.setRedirect(true); this.getSession().invalidate(); } super.onClick(); sets the response page. I do not end up with the desired

Re: How do you do this in wicket?

2008-01-13 Thread Martijn Dashorst
You *MUST* redirect to a bookmarkable page, not a page instance. A page instance is always relative to your current session, which you just conveniently invalidated. Martijn On 1/13/08, Anders Peterson [EMAIL PROTECTED] wrote: Doesn't work for me... I have a PageLink class with a onClick()

Re: Problem with Wicket and Guice

2008-01-13 Thread t.weitzel
Martijn Dashorst wrote: iirc objects that aren't components are not injected as they are not under Wicket's control. Ah. Ok, when I setup a second module for all other objects and inject them the Guice way, it works indeed. Thanks! I'm not sure about your other suggestion:

InjectorHolder has not been assigned an injector error

2008-01-13 Thread Karen Schaper
Hello Again, I am upgrading to the latest and greatest release of wicket 1.3. I made the change to register my converters by overriding the newConverterLocator method. In my customer converter class, in the constructor, I am calling InjectorHolder.getInjector().inject( this ); The converter

Re: Problem with Wicket and Guice

2008-01-13 Thread Eelco Hillenius
I'm not sure about your other suggestion: InjectionHolder.inject(this), mainly because I somehow need to get hold of the Injector to pass it to the InjectionHolder first, and I don't know how (it's not set by Wicket). InjectorHolder.getInjector().inject(this); It is set by Wicket if you

Re: Adding breadcrumbs

2008-01-13 Thread Igor Vaynberg
class abstract basepage extends page { private listbasepage history=new arraylist(); public basepage() { add(new listview(history, new PropertyModel(this, history)) { protected void onpopulateitem(listitem item) { link link=new link(link, item.getmodel()) {

Re: InjectorHolder has not been assigned an injector error

2008-01-13 Thread Eelco Hillenius
I'm guessing that the call to newConverterLocater happens before Spring injection. Yeah. Too bad, maybe in hind sight it would have been better to create it lazily. Any ideas on how to fix this? I think just creating the SpringComponentInjector in your webapp's constructor instead of in the

RE: InjectorHolder has not been assigned an injector error

2008-01-13 Thread Karen Schaper
-Original Message- From: Eelco Hillenius [mailto:[EMAIL PROTECTED] Sent: Sunday, January 13, 2008 12:11 PM To: users@wicket.apache.org Subject: Re: InjectorHolder has not been assigned an injector error I'm guessing that the call to newConverterLocater happens before Spring

Re: Any quickstart for wicket-terracotta

2008-01-13 Thread Orion Letizi
Wicket support is provided as a Terracotta configuration module. Once you have Terracotta set up for sessions, you just need to add the wicket configuration module to your terracotta config. Here's a link to using the Terracotta sessions configurator:

Re: InjectorHolder has not been assigned an injector error

2008-01-13 Thread Eelco Hillenius
Tried putting addComponentInstantiationListener( new SpringComponentInjector(this ); into the constructor of Application which extends AuthentationWebApplication... but I now get the following error. java.lang.IllegalStateException: servletContext is not set yet. Any code in your

Re: AjaxEditableLabel onClick

2008-01-13 Thread Eelco Hillenius
Is there a way for me to go into Edit Mode on an AjaxEditableLabel without clicking on the actual label? I would like to have an Edit link or button somewhere that will put the field in edit mode when clicked by the user. The best thing to do for you is to dig into how the component is

Re: Resizable and reorderable grid components

2008-01-13 Thread Evan Chooly
well, for example, while DefaultDataTable does the bulk of what we needed, it's not the easiest to extend when you start looking at toolbars and ordering and the like. Some of what we needed was more chrome, but some of it is alterations of some of the functionaly. None of it was hard to do by

Re: Resizable and reorderable grid components

2008-01-13 Thread Igor Vaynberg
DefaultDataTable is just that, a default. It isnt meant to be extended, just a convinient implementation of what most people would like. You should extend DataTable and add the toolbars yourself in any order you want... -igor On Jan 13, 2008 10:08 AM, Evan Chooly [EMAIL PROTECTED] wrote: well,

RE: InjectorHolder has not been assigned an injector error

2008-01-13 Thread Karen Schaper
Tried putting addComponentInstantiationListener( new SpringComponentInjector(this ); into the constructor of Application which extends AuthentationWebApplication... but I now get the following error. java.lang.IllegalStateException: servletContext is not set yet. Any code in

Re: Problem with Wicket and Guice

2008-01-13 Thread t.weitzel
Eelco Hillenius wrote: InjectorHolder.getInjector().inject(this); It is set by Wicket if you initialize it properly (by creating SpringComponentInjector). The applications is set up via GuiceWebApplicationFactory and web.xml. When I try to get the Injector (that Wicket has somewhere)

Re: How do you do this in wicket?

2008-01-13 Thread Anders Peterson
Then where do I call that invalidation code? It's not possible to override onClick() with BookmarkablePageLink. /Anders Martijn Dashorst wrote: You *MUST* redirect to a bookmarkable page, not a page instance. A page instance is always relative to your current session, which you just

Re: How do you do this in wicket?

2008-01-13 Thread Anders Peterson
I have never done new LoginPage(), and I never said I did - that's something you assumed. It has always been LoginPage.class. In my original code the LoginPage.class was passed as an argument to the PageLink constructor and then I had an onClick method like this: public void onClick() {

Re: How do you do this in wicket?

2008-01-13 Thread Martijn Dashorst
For the record: I can't smell or magically see what you do in your call to super(). I tried it in an application here, and I haven't reproduced your problem. It works here. As long as you don't share the whole code, I have to assume that what I can validate on my side is your problem.

Re: Javascript call to wicket

2008-01-13 Thread Erik van Oosten
I did not find the results of this thread on the Wiki yet, so I created the following page: http://cwiki.apache.org/confluence/display/WICKET/Calling+Wicket+from+Javascript Comments and edits are appreciated. There is a TODO on the page for providing an example that adds Javascript to the

Re: How do you do this in wicket?

2008-01-13 Thread Maurice Marrink
Try using a normal Link instead of PageLink and do the setResponsePage stuff in the onClick. Maurice On Jan 13, 2008 9:41 PM, Martijn Dashorst [EMAIL PROTECTED] wrote: For the record: I can't smell or magically see what you do in your call to super(). I tried it in an application here, and I

Cannot create Spring Bean via Proxy in Wicket

2008-01-13 Thread Sergey Podatelev
Hello, My WebApplication extends SpringWebApplication and I use proxy-based approach for bean instantiation. I'm using JDK1.4, so I'm unable to just annotate the beans, but have to do it in the following way: MyWebApplication { private UserDao userDao; ... public UserDao getUserDao() {

Re: Cannot create Spring Bean via Proxy in Wicket

2008-01-13 Thread Igor Vaynberg
if you could provide a quickstart maybe someone can look into it -igor On Jan 13, 2008 1:34 PM, Sergey Podatelev [EMAIL PROTECTED] wrote: Hello, My WebApplication extends SpringWebApplication and I use proxy-based approach for bean instantiation. I'm using JDK1.4, so I'm unable to just

Re: Cannot create Spring Bean via Proxy in Wicket

2008-01-13 Thread Konstantin Ignatyev
You have to use interface and cast to the interface unless Spring is forced to use cglib for proxy creation. If your UserDao is interface then just cast to it, not to the JdbcUserDao and it should be fine. - Original Message From: Sergey Podatelev [EMAIL PROTECTED] To:

Re: Cannot create Spring Bean via Proxy in Wicket

2008-01-13 Thread Sergey Podatelev
Thanks for your fast responses. On Jan 14, 2008 1:13 AM, Konstantin Ignatyev [EMAIL PROTECTED] wrote: If your UserDao is interface then just cast to it, not to the JdbcUserDao and it should be fine. Actually, that was just a typo in the code I've pasted here. It supposed to be JdbcUserDao

Re: Autocomplete Textfield gets submitted twice on mouse click

2008-01-13 Thread ckuehne
Just in case anybody is interested: the problem was, that clicking with the mouse fired the onchange event of the auto complete field. The javascript responsible for handling the autocomplete fired it again after finishing it's work. Since I am using a hidden field to store and communicate the

Re: Autocomplete Textfield gets submitted twice on mouse click

2008-01-13 Thread Igor Vaynberg
file a bug report please -igor On Jan 13, 2008 2:44 PM, ckuehne [EMAIL PROTECTED] wrote: Just in case anybody is interested: the problem was, that clicking with the mouse fired the onchange event of the auto complete field. The javascript responsible for handling the autocomplete fired it

Re: the flow of wicket

2008-01-13 Thread Fabio Fioretti
On Jan 12, 2008 8:56 PM, Dmitry Kandalov [EMAIL PROTECTED] wrote: On the whole I think it's the matter of knowing the big picture and not using framework as a black box. Exactly. For knowledge's sake. Documenting Wicket's inner implementations and strategies, beyond its API, is desirable and a

Re: the flow of wicket

2008-01-13 Thread Igor Vaynberg
On Jan 13, 2008 3:28 PM, Fabio Fioretti [EMAIL PROTECTED] wrote: Documenting Wicket's inner implementations and strategies, beyond its API, is desirable and a huge plus for hardcore developers. i wouldnt think hardcore developers would be afraid of setting a breakpoint and walking the code.

Re: the flow of wicket

2008-01-13 Thread Eelco Hillenius
Documenting Wicket's inner implementations and strategies, beyond its API, is desirable and a huge plus for hardcore developers. i wouldnt think hardcore developers would be afraid of setting a breakpoint and walking the code. maybe one of them could even create a wiki page - open source

lang.merge is not a function error

2008-01-13 Thread Karen Schaper
Hello Again, I am experience a strange issue when using the new date picker in conjunction with the YUI menu. I can use them each alone but when then are together I get this error in firebug. The error is lang.merge is not a function which is located in the yuiloader-beta-min.js. This js is

Re: lang.merge is not a function error

2008-01-13 Thread Gerolf Seitz
is the YUI menu from the wicketstuff project? if so, what YUI version does it use? i suspect this only happens if the YUI menu js files (yahoo, dom, event, menu, ...) are loaded before the datepickers yuiloader-beta-min.js. yuiloader checks if YAHOO.lang is already available (which it would be if

Re: Cannot create Spring Bean via Proxy in Wicket

2008-01-13 Thread Sergey Podatelev
On Jan 14, 2008 1:13 AM, Konstantin Ignatyev [EMAIL PROTECTED] wrote: You have to use interface and cast to the interface Too bad I've forgotten about the whole injection idea of using interfaces instead of their specific implementations. Surely, your suggestion did the trick. Thanks a bunch.

AutoCompleBehavior is an abstract class.

2008-01-13 Thread Fernando Wermus
Dear all, I just want to share with the list that AutoCompleBehavior is abstract, but the http://wicketstuff.org/confluence/display/STUFFWIKI/Script.aculo.us+AutoCompleteBehaviorshows an example using it as a concrete class. Bye! -- Fernando Wermus.

Re: Adding breadcrumbs

2008-01-13 Thread WickedMan
Thanks igor. I'll give it a try. igor.vaynberg wrote: class abstract basepage extends page { private listbasepage history=new arraylist(); public basepage() { add(new listview(history, new PropertyModel(this, history)) { protected void onpopulateitem(listitem item) {