DataTable, ChoiceFilteredPropertyColumn, Choice renderer and values translated via M:1 association

2009-09-24 Thread Petr Fejfar
Hi all,

please, could somebody push me forward how to implement ChoiceRenderer
of ChoiceFilteredPropertyColumn? I seem to be lost among data
providers and models little bit...

I followed Wicket-stuff's phonebook example and I show list of
persistent entities in the DataTable. I'd like to have a choice
filtered column containing subcription names got from phone numbers
via @ManyToOne association. But I'm not able to create proper Choice
renderer to be returned to DataTable for filtering purposes. My code
looks like this (choice filtering is commented out):


private PropertyColumn createSenderColumn()
{
return new PropertyColumn(new
ResourceModel("columnPhone"), "phone", "phone") {
//return new ChoiceFilteredPropertyColumn(
//new ResourceModel("columnPhone"), "phone","phone",
//new LoadableDetachableModel() {
//private static final long serialVersionUID = 1L;
//@Override
//protected Object load() {
//List names =
TTraceWebSession.get().getUser().listSubscriptionNames();
//names.add(0,"");
//return names;
//}
//}) {
private static final long serialVersionUID = 1L;

public void populateItem(Item cellItem, String
componentId, IModel model) {
AttitudeHistory history = (AttitudeHistory) model.getObject();
Label label = new Label(componentId, createLabelModel(model));
label.add(new AttributeModifier("title", true, new
Model(history.getPhone(;
cellItem.add(label);
}

@Override
protected IModel createLabelModel(IModel rowModel) {
final AttitudeHistory history = (AttitudeHistory)
rowModel.getObject();
return new AbstractReadOnlyModel() {
private static final long serialVersionUID = 1L;

@Override
public String getObject() {
return history.getSubscription().getSubscriptionName();
}
};
}

//@Override
//protected IChoiceRenderer getChoiceRenderer() {
//return null;
//}


public String getCssClass() {
return "column-phone";
}
};

}


Thanks, Petr

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



Re: Palette Update Behaviour Problem

2009-09-24 Thread Fernando Wermus
On Thu, Sep 24, 2009 at 5:19 PM, Tim Hughes  wrote:

> Fernando:
>
> I thought that's what I was doing by overriding the newRecorderComponent
> method. Is that not correct?
>

I didn't mean to say that. According to your piece of code, I thought you
had created a new Recorder. You have the getter to ask for the Recorder.

>
> I made a change to the code (see below) and now it's storing Categories in
> Documents, but:
> 1) it's always the first Cat in the list of choices that gets set into a
> Doc no matter which Cat I choose
> 2) when reselecting a given Doc, it still has Cats but they don't reflect
> in the Palette choices
>
> @Override
> protected void onUpdate( AjaxRequestTarget ajaxRequestTarget)
> {
>
>  
> selectedDocumentModel.getObject().addCategory((Category)recorder.getSelectedChoices().next());
>
> }
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


-- 
Fernando Wermus.

www.linkedin.com/in/fernandowermus


Re: IComponentAssignedModel and ComponentModel

2009-09-24 Thread garz

ok, this is kind of embarassing. i subscribed to the list, but i didnt get
any feedback if it was successful. i post a message to the mailinglist, no
feedback again. i look in nabble, my mail isnt there. what am i supposed to
think? so i subscribed again and again with little differences and everytime
i sent a new email. nothing happened. i cant know that nabble takes 10 hours
to list a mail that was send to the list. why not just using a forum? its
the successor of mailinglists. :D

ok back to topic. why wrap the model if i just want to assign the component,
that the model is assigned to. why not just set a property on the model
itself? why wrap the model itself?
-- 
View this message in context: 
http://www.nabble.com/IComponentAssignedModel-and-ComponentModel-tp25593781p25605171.html
Sent from the Wicket - User 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



inmethod DataGrid javascript error (with fix?)

2009-09-24 Thread Russell Morrisey
I'm getting a javascript error using the inmethod DataGrid; it looks to me 
like a bug with the DataGrid's script code. I am hoping that the DataGrid 
script can be patched =)

When using the inmethod grid (com.inmethod.grid.datagrid.DataGrid), I get 
the error whenever I hover the mouse over a row in the grid. This seems to 
happen:
-Only in IE6
-Only when "window.update" is already defined. In my case, my page has: 
. (This button is just a 
stub, not wicket-enabled yet.) Debugging in Visual Studio, I see that 
there is a reference to the button ("update") already defined, which seems 
to be generated automatically by IE.

When I mouse over the grid I get: "Object does not support this property 
or method", in AbstractGrid/res/script.js, in the "updatePrelight" method, 
on this line:

update = function(e) {
 
var scrollLeft;
 
if (Wicket.Browser.isOpera()) {
// for some reason opera doesn't 
preserve the scroll offset when changing/removing style
bodyContainer1 = this.getElement(
"div", "imxt-body-container1"); 
scrollLeft = 
bodyContainer1.scrollLeft;
//e.style.visibility = "hidden";
} 
 
if (e.imxtPrelight == true) {
addClass(e, "imxt-prelight");
} else {
removeClass(e, "imxt-prelight");
}
 
if (Wicket.Browser.isOpera()) {
//e.style.visibility = "";
bodyContainer1 = this.getElement(
"div", "imxt-body-container1");
bodyContainer1.scrollLeft = 
scrollLeft;
}
 
}.bind(this);

We use the DataGrid on another page in our production app and it doesn't 
experience this problem. The other page does not have a DOM element with 
id="update", or a window.update property. I think the script needs to be 
changed to:

var update = function... 

So that the locally defined function isn't trying to overwrite the 
window.update property.

I'm using datagrid version: 1.0.0-SNAPSHOT according to our project's POM.

Thanks! 

Russell E. Morrisey
Application Designer Associate Professional
CSC 

NOTE: Regardless of content, this e-mail shall not operate to bind CSC to 
any order or other contract unless pursuant to explicit written agreement 
or government initiative expressly permitting the use of e-mail for such 
purpose.

Re: Best way to handle circular references

2009-09-24 Thread Christian Beil

Hi Giovanni,

I absolutely understand what you mean. I recently refactored some Swing 
GUI code and also tried to remove the circular references.
The menu bar of the app's main frame needed a reference to this frame in 
order to show a modal dialog on it.

The frame embeds the menu bar and therefore references it.
And the menu bar references the frame to show a dialog on it when an 
action is performed.
Fortunately, in Swing there is a method to find the frame which contains 
the menu bar (or any component).
So I could remove the menu bar's reference to the frame. Instead I call 
JOptionPane.getFrameForComponent(menuBar) to find the frame.


I also experienced some other circular dependencies which could not be 
resolved directly. I decoupled some components using an EventBus, but 
that is not always the right option.
Reagarding your case, if you had a menu panel and a content panel on the 
same page and the menu's actions are responsible for switching the 
content panel, the dependency cycle could be removed. But I don't think 
this is a good solution for a web application. I'd rather stay with what 
you have right now.
After doing some GUI refactorings, I went away with the opinion that 
some code tends to need circular dependencies, especially in GUI code 
this seems to be the case.

One should remove as much cycles as possible, but some are ok to keep.
That's my opinion, but I'm happy if someone can teach me better.

Regards,
Christian



Giovanni Cuccu schrieb:

Thanks for the response,
I try to clarify my point of view.
Before using wicket I don't remember that my classes were cross 
references, I always paid attention that if class A references Class B 
Class B can't reference Class A (even in imports).
After starting wicket development I've seen several cases of circular 
references in my code. Since these circular references sometimes seem 
natural (Page references MenuPanel and MenuPanel references Page) but 
at the same time I consider the a "bad practice" I'm asking to myself 
and to this list if someone had the same thoughts and what was the 
conclusion.

What is your advice?
Should I relax my "best practice" about class circular referencing? 
Should I code my Wicket app in a different manner?

Thanks,
Giovanni


It looks like you are looking for cohesion.
In the class menupanel.java I must reference Page
In the class Page.java I must reference MenuPanel

menupanel can to be an parameter to PageXXX; PageXXX can to be 
abstract and

have an abstract method :
abstract protected Page
getPageToSetOnReturnOnCase1Case2And3(PossibleParameter p);

noted that in the examples there is a circular reference between 
Checkout

page and Index page
on the example the objects has an reference to the other type class. 
And the

class object do not has an reference those objects. I don't see it as
circular reference.

Are circular references unavoidable with Wicket?
do they are unavoidable in java, in object oriented paradigm? Is this 
the

correct question?

Is there a best practive to avoid this situation?
When I avoid an circular reference, I make a choice between a several
possible solutions, the on I get depends on the class objectives


On Wed, Sep 23, 2009 at 7:21 AM, Giovanni Cuccu
wrote:


Hi all,
   I'm developing a wicket application and I'm facing a problem.
I built a menupanel that shows the menu to access the various 
aplication
pages; since the panel needs to show the pages it contains a list of 
links

that when clicked simply do the the following
   setResponsePage(new Page());
In the class menupanel.java I must reference Page
In the class Page.java I must reference MenuPanel
At the end I have a circular reference between manupanel and the 
various

Page and I don't like it.
While reading wicketInAction I noted that in the examples there is a
circular reference between Checkout page and Index page. Are circular
references unavoidable with Wicket? Is there a best practive to 
avoid this

situation?
Thanks,
   Giovanni


--
Giovanni Cuccu
Via del Borgo di S. Pietro, 90/c - 40126 Bologna
e-mail: giovanni.cuccu _at_ cup2000.it


-
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



Wizard help

2009-09-24 Thread Jeffrey Schneller
I have looked at the examples and the javadocs but can't figure out how
to do the following.  I am a wicket newbie.

 

I want to create a wizard with 2 steps implemented as panels.

 

Step 1:  Asks the user to enter some information.  Validates that the
information entered is in the database before moving to step 2.  [I have
this working]

Step 2:  Based on the information entered in step 1, look in the db for
the matching data and display the rest of the information.  [part I am
having trouble with]

 

This is to implement a forgot password functionality.  Based on the
username entered in step 1, look up a question in the db, then display
the question to the user in step 2 so they can answer it.  Then after
successfully answering the question perform some logic to reset the
password.

 

I am just having trouble with the move from Step 1 to Step 2.  I assume
the success logic would be implemented in the onFinish() method of my
ForgotPasswordWizard

 

The code  [just displaying the constructors]:

 

   public ForgotPasswordWizard(String id) {

  super(id);

  ForgotPasswordModel bean = new ForgotPasswordModel();

  setDefaultModel(new
CompoundPropertyModel(bean));

  WizardModel model = new WizardModel();

  model.add(new ForgotPasswordStep1());

  model.add(new ForgotPasswordStep2());

  init(model);

   }

   public ForgotPasswordStep1() {

  super(new Model("ForgotPasword"), new Model("Enter your
username [email]"));

  RequiredTextField username = new
RequiredTextField("username");

  username.add(EmailAddressValidator.getInstance());

  add(username);

  IFormValidator validator = new AccountValidator(username);

  this.add(validator);

   }

   public ForgotPasswordStep2() {

  super(new Model("ForgotPasword"), new Model("Answer your
Security Question"));

  

  // ??

  // find the question from the db for the user

  ForgotPasswordModel myModel = (ForgotPasswordModel)
this.getDefaultModelObject();

  // access the db to get the actual question

  myModel.setQuestion("[the question I shoud show]);

  // ???

  

  add(new Label("question"));

  add(new RequiredTextField("answer"));

   }

 

 

Thanks.

 

Jeff



IComponentAssignedModel and ComponentModel

2009-09-24 Thread garz

hi,

i have a question regarding implementation details of wicket. 
IComponentAssignedModel is used to make a model aware of the component 
its assigned to. ComponentModel is a quick implementation of this 
interface. why is it done with an inner class? why not just have an 
attribute on the "outer" class and assign the component to it in 
wrapOnAssignment(Component component)? why an inner class?


thanks in advance, garz (just want to learn)

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



wicketstuff-merged-resources: New (much simpler) Version

2009-09-24 Thread Stefan Fußenegger

Hi all,

I just wanted to let you know that I've posted an article on the new
version of wicketstuff-merged-resources:
http://techblog.molindo.at/2009/09/wicketstuff-merged-resources-new-much-simpler-version.html

For those that aren't aware of this small library:

wicketstuff-merged-resources is a set of simple helper classes to
improve Wicket interface loading performance. This is achieved with
improved caching configuration and merging of shared resources without
the need of touching any components (it's all done inside
Application.init()). The initial code base was the outcome of Stefan
Fussenegger's blog series called "Wicket Interface Speed-Up". (from
Wicket Stuff Wiki:
http://wicketstuff.org/confluence/display/STUFFWIKI/wicketstuff-merged-resources)

Btw, if you're interested in serving Wicket-mounted resources from
Amazon S3/CloudFront, it might be worth subscribing to my blog. I am
planning a write-up on how to use wicketstuff-merged-resources to upload
and mount resources to/from Amazon's CDN.

Cheers,

Stefan Fußenegger
http://techblog.molindo.at/


(Sorry if this message appears multiple time - but I feel that the 
previous attempts to post to this list with another address didn't work)


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



IComponentAssignedModel and ComponentModel

2009-09-24 Thread Garz
hi,

i have a question regarding implementation details of wicket. 
IComponentAssignedModel is used to make a model aware of the component its 
assigned to. ComponentModel is a quick implementation of this interface. why is 
it done with an inner class? why not just have an attribute on the "outer" 
class and assign the component to it in wrapOnAssignment(Component component)? 
why an inner class?

thanks in advance, garz (just want to learn)
-- 
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3.5 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser

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



Re: Palette Update Behaviour Problem

2009-09-24 Thread Tim Hughes

Fernando:

I thought that's what I was doing by overriding the  
newRecorderComponent method. Is that not correct?


I made a change to the code (see below) and now it's storing  
Categories in Documents, but:
1) it's always the first Cat in the list of choices that gets set into  
a Doc no matter which Cat I choose
2) when reselecting a given Doc, it still has Cats but they don't  
reflect in the Palette choices


@Override
protected void onUpdate( AjaxRequestTarget ajaxRequestTarget)
{
selectedDocumentModel.getObject().addCategory((Category) 
recorder.getSelectedChoices().next());

}

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



IComponentAssignedModel and ComponentModel

2009-09-24 Thread Garz
hi,

i have a question regarding implementation details of wicket. 
IComponentAssignedModel is used to make a model aware of the component its 
assigned to. ComponentModel is a quick implementation of this interface. why is 
it done with an inner class? why not just have an attribute on the "outer" 
class and assign the component to it in wrapOnAssignment(Component component)? 
why an inner class?

thanks in advance, garz (just want to learn)
-- 
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3.5 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser

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



IComponentAssignedModel and ComponentModel

2009-09-24 Thread Garz
hi,

i have a question regarding implementation details of wicket. 
IComponentAssignedModel is used to make a model aware of the component its 
assigned to. ComponentModel is a quick implementation of this interface. why is 
it done with an inner class? why not just have an attribute on the "outer" 
class and assign the component to it in wrapOnAssignment(Component component)? 
why an inner class? and how i'm supposed to use ComponentModel as a base class 
when i cant subclass the innerclass because its private and therefor not 
visible?

thanks in advance, garz
-- 
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3.5 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser

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



Re: wicket-phonebook

2009-09-24 Thread Johannes Schneider
I think 1.4.1 has been released. So I think the current version should
be either 1.4.1 or 1.4.2-SNAPSHOT

Johannes

Andreas Kaluza wrote:
> Hi @all,
> 
>  
> 
> I'm trying to install the wicket-phonebook with "mvn install". The error
> message is:
> 
>  
> 
> [INFO] Scanning for projects...
> 
> Downloading:
> http://download.java.net/maven/2//org/wicketstuff/wicketstuff-core/
> 
> 1.4-SNAPSHOT/wicketstuff-core-1.4-SNAPSHOT.pom
> 
> [INFO] Unable to find resource
> 'org.wicketstuff:wicketstuff-core:pom:1.4-SNAPSHO
> 
> T' in repository maven2-repository.dev.java.net
> (http://download.java.net/maven/
> 
> 2/)
> 
> [INFO]
> 
> 
> [ERROR] FATAL ERROR
> 
> [INFO]
> 
> 
> [INFO] Error building POM (may not be this project's POM).
> 
>  
> 
>  
> 
> Project ID: null:phonebook:war:null
> 
>  
> 
> Reason: Cannot find parent: org.wicketstuff:wicketstuff-core for project:
> null:p
> 
> honebook:war:null for project null:phonebook:war:null
> 
>  
> 
>  
> 
> [INFO]
> 
> 
> [INFO] Trace
> 
> org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
> org.wicket
> 
> stuff:wicketstuff-core for project: null:phonebook:war:null for project
> null:pho
> 
> nebook:war:null
> 
> at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:404)
> 
> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:272)
> 
> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
> 
> at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
> 
> at
> org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6
> 
> 0)
> 
>  
> 
> Is the pom.xml corrupted (I have the original one)?  It seems that the maven
> repository is incomplete. Anyone a solution?
> 
>  
> 
> Cheers,
> 
> Andy
> 
> 

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



Re: Wicket-auth-roles + EJB 3 (Authentication and Authorization)

2009-09-24 Thread jraanamo


m_e wrote:
> 
> Hi Barry,
> 
> I've running three webapps using wicket (1.3) wicket-security 
> (SWARM/WASP) together with JAAS.
> It's working great. Ok, the logout isn't very nice but it's doing it's
> job.
> 
> 

Hi,

Couple of  questions:
- what did you do to pass the login details to the ejb3 container (via jndi
context?) and which container were you using? 
- were you able to handle authorization via e.g. @RolesAllowed annotations?

-jukka-


-- 
View this message in context: 
http://www.nabble.com/Wicket-auth-roles-%2B-EJB-3-%28Authentication-and-Authorization%29-tp22649841p25578029.html
Sent from the Wicket - User 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: wicket-phonebook

2009-09-24 Thread Phil Grimm
Folks,

I just got it working by adding to the pom...


main-maven2-repo
The "main" maven2 repository
http://mirrors.ibiblio.org/pub/mirrors/maven2



commons-pool
commons-pool
1.5


The commons-dbcp requires commons-pool.

Phil

On Thu, Sep 24, 2009 at 6:19 AM, Andreas Kaluza wrote:

> There was a problem in the pom.xml. You have to include:
>
>
>wicket-snaps
>http://wicketstuff.org/maven/repository
>
>true
>
>
>true
>
>
>
> into the repositories-tag. With that the installation works.
>
> Cheers,
>
> Andy
>
> > -Ursprüngliche Nachricht-
> > Von: Pierre Goupil [mailto:goupilpie...@gmail.com]
> > Gesendet: Donnerstag, 24. September 2009 12:39
> > An: users@wicket.apache.org
> > Betreff: Re: wicket-phonebook
> >
> > I've used the phonebook without any problem. Are you sure you've got
> > the
> > latest version? Plus, you need the whole wickestuff-core project (found
> > in
> > wicketstuff/wicketstuff-core), AFAIK. And it looks like you haven't got
> > it
> > on your hard drive, since Maven tries and download it.
> >
> > Regards,
> >
> > Pierre
> >
> >
> > On Thu, Sep 24, 2009 at 12:33 PM, Andreas Kaluza  > kl.de>wrote:
> >
> > > Hi @all,
> > >
> > >
> > >
> > > I'm trying to install the wicket-phonebook with "mvn install". The
> > error
> > > message is:
> > >
> > >
> > >
> > > [INFO] Scanning for projects...
> > >
> > > Downloading:
> > > http://download.java.net/maven/2//org/wicketstuff/wicketstuff-core/
> > >
> > > 1.4-SNAPSHOT/wicketstuff-core-1.4-SNAPSHOT.pom
> > >
> > > [INFO] Unable to find resource
> > > 'org.wicketstuff:wicketstuff-core:pom:1.4-SNAPSHO
> > >
> > > T' in repository maven2-repository.dev.java.net
> > > (http://download.java.net/maven/
> > >
> > > 2/)
> > >
> > > [INFO]
> > > -
> > ---
> > >
> > > [ERROR] FATAL ERROR
> > >
> > > [INFO]
> > > -
> > ---
> > >
> > > [INFO] Error building POM (may not be this project's POM).
> > >
> > >
> > >
> > >
> > >
> > > Project ID: null:phonebook:war:null
> > >
> > >
> > >
> > > Reason: Cannot find parent: org.wicketstuff:wicketstuff-core for
> > project:
> > > null:p
> > >
> > > honebook:war:null for project null:phonebook:war:null
> > >
> > >
> > >
> > >
> > >
> > > [INFO]
> > > -
> > ---
> > >
> > > [INFO] Trace
> > >
> > > org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
> > > org.wicket
> > >
> > > stuff:wicketstuff-core for project: null:phonebook:war:null for
> > project
> > > null:pho
> > >
> > > nebook:war:null
> > >
> > >at
> > org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:404)
> > >
> > >at
> > org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:272)
> > >
> > >at
> > org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
> > >
> > >at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
> > >
> > >at
> > > org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6
> > >
> > > 0)
> > >
> > >
> > >
> > > Is the pom.xml corrupted (I have the original one)?  It seems that
> > the
> > > maven
> > > repository is incomplete. Anyone a solution?
> > >
> > >
> > >
> > > Cheers,
> > >
> > > Andy
> > >
> > >
> >
> >
> > --
> > Sans amis était le grand maître des mondes,
> > Eprouvait manque, ce pour quoi il créa les esprits,
> > Miroirs bienveillants de sa béatitude.
> > Mais au vrai, il ne trouva aucun égal,
> > Du calice du royaume total des âmes
> > Ecume jusqu'à lui l'infinité.
> >
> > (Schiller, "l'amitié")
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


-- 
Phil Grimm
Mobile: (858) 342-5987
Skype: philgrimm336


Re: WebSession issue - Netbeans & Glassfish

2009-09-24 Thread VGJ
I see.  So, if I follow you, I should be OK.  The http-to-https switch
happens after the user has chosen some items and added them to the SFSB,
which would have already been created and added to the session.  The user
doesn't return to http again until the order is completed and the session is
cleared.

Am I correct?

Thanks!

On Thu, Sep 24, 2009 at 11:44 AM, Igor Vaynberg wrote:

> not really sure what is happening, but one thing to keep inmind is:
>
> when accessing an application over https a cookie that holds the
> session id is marked as secure and is not available to following
> requests if they are over http.
>
> so if the user creates the session over an https request that session
> will essentially be invisible to users over http. this may or may not
> be what is happening to you. if your user enters your app over https
> there is not much you can do, unless you can override container
> environment and stop it from marking the session as secure - which is
> a potential security vulnerability. if your user enters your app over
> http then an easy fix is to create a session right away, that way
> https cookie will hold the same session id.
>
> -igor
>
> On Thu, Sep 24, 2009 at 10:39 AM, VGJ  wrote:
> > I've got a very strange problem with WebSession objects becoming null
> > (suddenly ending) while debugging in Netbeans, using Glassfish as an app
> > server.  I'm using Wicket 1.3.2 and do not have the option of upgrading
> to
> > the latest version on this project right now.
> >
> > I've got an e-commerce app that switches to https during the checkout
> > process.  If I'm not in debug mode in Netbeans, this works properly and
> the
> > session persists from one page to the next after using a redirect, like
> so:
> >
> >  getRequestCycle().setRedirect(false);
> >
>  getRequestCycle().setRequestTarget(EmptyRequestTarget.getInstance());
> >  getResponse().redirect("https://site/secure-page";);
> >
> > I pass a stateful session bean around the application, in the session,
> like
> > so:
> >
> > ShoppingCartLocal cart = ((UserSession)getSession()).getCart();
> >
> > My UserSession class looks like this:
> >
> > public class UserSession extends WebSession
> > {
> >private User user;
> >private ShoppingCartLocal  cart;
> >
> >public UserSession(WebApplication application, Request request)
> >{
> >super(application, request);
> >}
> >
> >public User getUser()
> >{
> >return this.user;
> >}
> >
> >public void setUser(User user)
> >{
> >this.user = user;
> >dirty();
> >}
> >
> >public boolean authenticated()
> >{
> >if (this.getUser() == null)
> >return false;
> >else
> >return true;
> >}
> >
> >public ShoppingCartLocal getCart()
> >{
> >return this.cart;
> >}
> >
> >public void setCart(ShoppingCartLocal cart)
> >{
> >this.cart = cart;
> >dirty();
> >}
> > }
> >
> > If I'm debugging, the session becomes null after the redirect and throws
> a
> > NPE when I try accessing it (of course).  I get the following message:
> >
> > 141750 [httpSSLWorkerThread-8080-4] ERROR org.apache.wicket.RequestCycle
> -
> > Can't instantiate page using constructor public com.myapp.UserAccount()
> > org.apache.wicket.WicketRuntimeException: Can't instantiate page using
> > constructor public com.myapp.UserAccount()
> >at
> >
> org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:168)
> >at
> >
> org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:58)
> >at
> >
> org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.newPage(BookmarkablePageRequestTarget.java:262)
> >at
> >
> org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.getPage(BookmarkablePageRequestTarget.java:283)
> >at
> >
> org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.processEvents(BookmarkablePageRequestTarget.java:210)
> >at
> >
> org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:91)
> >at
> >
> org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1166)
> >at org.apache.wicket.RequestCycle.step(RequestCycle.java:1243)
> >at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1330)
> >at org.apache.wicket.RequestCycle.request(RequestCycle.java:493)
> >at
> > org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:358)
> >at
> >
> org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194)
> >at
> >
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230)
> >at
> >
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198)
> >at
> >
> org.apache.catalina.core.StandardWrapperVal

Re: WebSession issue - Netbeans & Glassfish

2009-09-24 Thread Igor Vaynberg
not really sure what is happening, but one thing to keep inmind is:

when accessing an application over https a cookie that holds the
session id is marked as secure and is not available to following
requests if they are over http.

so if the user creates the session over an https request that session
will essentially be invisible to users over http. this may or may not
be what is happening to you. if your user enters your app over https
there is not much you can do, unless you can override container
environment and stop it from marking the session as secure - which is
a potential security vulnerability. if your user enters your app over
http then an easy fix is to create a session right away, that way
https cookie will hold the same session id.

-igor

On Thu, Sep 24, 2009 at 10:39 AM, VGJ  wrote:
> I've got a very strange problem with WebSession objects becoming null
> (suddenly ending) while debugging in Netbeans, using Glassfish as an app
> server.  I'm using Wicket 1.3.2 and do not have the option of upgrading to
> the latest version on this project right now.
>
> I've got an e-commerce app that switches to https during the checkout
> process.  If I'm not in debug mode in Netbeans, this works properly and the
> session persists from one page to the next after using a redirect, like so:
>
>      getRequestCycle().setRedirect(false);
>      getRequestCycle().setRequestTarget(EmptyRequestTarget.getInstance());
>      getResponse().redirect("https://site/secure-page";);
>
> I pass a stateful session bean around the application, in the session, like
> so:
>
> ShoppingCartLocal cart = ((UserSession)getSession()).getCart();
>
> My UserSession class looks like this:
>
> public class UserSession extends WebSession
> {
>    private User user;
>    private ShoppingCartLocal  cart;
>
>    public UserSession(WebApplication application, Request request)
>    {
>        super(application, request);
>    }
>
>    public User getUser()
>    {
>        return this.user;
>    }
>
>    public void setUser(User user)
>    {
>        this.user = user;
>        dirty();
>    }
>
>    public boolean authenticated()
>    {
>        if (this.getUser() == null)
>            return false;
>        else
>            return true;
>    }
>
>    public ShoppingCartLocal getCart()
>    {
>        return this.cart;
>    }
>
>    public void setCart(ShoppingCartLocal cart)
>    {
>        this.cart = cart;
>        dirty();
>    }
> }
>
> If I'm debugging, the session becomes null after the redirect and throws a
> NPE when I try accessing it (of course).  I get the following message:
>
> 141750 [httpSSLWorkerThread-8080-4] ERROR org.apache.wicket.RequestCycle -
> Can't instantiate page using constructor public com.myapp.UserAccount()
> org.apache.wicket.WicketRuntimeException: Can't instantiate page using
> constructor public com.myapp.UserAccount()
>        at
> org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:168)
>        at
> org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:58)
>        at
> org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.newPage(BookmarkablePageRequestTarget.java:262)
>        at
> org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.getPage(BookmarkablePageRequestTarget.java:283)
>        at
> org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.processEvents(BookmarkablePageRequestTarget.java:210)
>        at
> org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:91)
>        at
> org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1166)
>        at org.apache.wicket.RequestCycle.step(RequestCycle.java:1243)
>        at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1330)
>        at org.apache.wicket.RequestCycle.request(RequestCycle.java:493)
>        at
> org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:358)
>        at
> org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194)
>        at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230)
>        at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198)
>        at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:288)
>        at
> org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
>        at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
>        at
> org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
>        at
> org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
>        at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
>        at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
>        at
> org.apache.catalina.core.Stan

WebSession issue - Netbeans & Glassfish

2009-09-24 Thread VGJ
I've got a very strange problem with WebSession objects becoming null
(suddenly ending) while debugging in Netbeans, using Glassfish as an app
server.  I'm using Wicket 1.3.2 and do not have the option of upgrading to
the latest version on this project right now.

I've got an e-commerce app that switches to https during the checkout
process.  If I'm not in debug mode in Netbeans, this works properly and the
session persists from one page to the next after using a redirect, like so:

  getRequestCycle().setRedirect(false);
  getRequestCycle().setRequestTarget(EmptyRequestTarget.getInstance());
  getResponse().redirect("https://site/secure-page";);

I pass a stateful session bean around the application, in the session, like
so:

ShoppingCartLocal cart = ((UserSession)getSession()).getCart();

My UserSession class looks like this:

public class UserSession extends WebSession
{
private User user;
private ShoppingCartLocal  cart;

public UserSession(WebApplication application, Request request)
{
super(application, request);
}

public User getUser()
{
return this.user;
}

public void setUser(User user)
{
this.user = user;
dirty();
}

public boolean authenticated()
{
if (this.getUser() == null)
return false;
else
return true;
}

public ShoppingCartLocal getCart()
{
return this.cart;
}

public void setCart(ShoppingCartLocal cart)
{
this.cart = cart;
dirty();
}
}

If I'm debugging, the session becomes null after the redirect and throws a
NPE when I try accessing it (of course).  I get the following message:

141750 [httpSSLWorkerThread-8080-4] ERROR org.apache.wicket.RequestCycle -
Can't instantiate page using constructor public com.myapp.UserAccount()
org.apache.wicket.WicketRuntimeException: Can't instantiate page using
constructor public com.myapp.UserAccount()
at
org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:168)
at
org.apache.wicket.session.DefaultPageFactory.newPage(DefaultPageFactory.java:58)
at
org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.newPage(BookmarkablePageRequestTarget.java:262)
at
org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.getPage(BookmarkablePageRequestTarget.java:283)
at
org.apache.wicket.request.target.component.BookmarkablePageRequestTarget.processEvents(BookmarkablePageRequestTarget.java:210)
at
org.apache.wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:91)
at
org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1166)
at org.apache.wicket.RequestCycle.step(RequestCycle.java:1243)
at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1330)
at org.apache.wicket.RequestCycle.request(RequestCycle.java:493)
at
org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:358)
at
org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:288)
at
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
at
org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
at
org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
at
org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
at
org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
at
org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
at
org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
at
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:272)
at
com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
   

Palette Behaviour Problems

2009-09-24 Thread Tim Hughes
I'm using a Palette to set "Category" objects to a "Document". The  
Palette operates correctly on-screen,  but:


1) in debug, selected choice  is ALWAYS the 1st item in the list
2) the Category does not  get assigned to the Document object

I'm overriding newRecorderComponent in my Palette (code below).

 final Palette...
 {
 @Override
 protected Recorder newRecorderComponent()
 {
 final Recorder recorder = new Recorder("recorder", this);
 recorder.setOutputMarkupId( true );
 recorder.add(new AjaxFormComponentUpdatingBehavior 
("onchange")

 {
 @Override
 protected void onUpdate( AjaxRequestTarget  
ajaxRequestTarget)

 {
 selectedCategory.addCategory((Category) 
recorder.getSelectedChoices().next());

 }
 });
 return recorder;
 }

 };


Thanks!


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



Palette Behaviour Problems

2009-09-24 Thread Tim Hughes
I'm using a Palette to assign multiple "Category" objects to a  
"Document". When I select a Category, the Palette operates correctly  
on-screen,  but:


1) in debug, the selected choice  is ALWAYS the first item in the  
"allCategories" list

2) the Category does not seem to get assigned to the Document object

I'm overriding newRecorderComponent in my Palette (code below). What  
am I doing wrong here?


  final Palette...
  {
  @Override
  protected Recorder newRecorderComponent()
  {
  final Recorder recorder = new Recorder("recorder", this);
  recorder.setOutputMarkupId( true );
  recorder.add(new AjaxFormComponentUpdatingBehavior 
("onchange")

  {
  @Override
  protected void onUpdate( AjaxRequestTarget  
ajaxRequestTarget)

  {
  selectedCategory.addCategory((Category) 
recorder.getSelectedChoices().next());

  }
  });
  return recorder;
  }

  };


Thanks!

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



Hiring a full-time telecommuting wicket engineer

2009-09-24 Thread Clint Popetz
Hi everyone,

Quick note, I'm hiring another full-time wicket engineer in the next
week or so.  The job posting is similar to the last one I put on the
list a few months ago:

http://www.42lines.net/employment/full_time_java_engineer

It's a telecommuting position, but you have to be within a few hours
of my time zone (GMT -0500) for my sanity when training you on the
source base.

Thanks!
-Clint

-- 
Clint Popetz
http://42lines.net
Scalable Web Application Development

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



RE: image html element's (img) src attribute processing

2009-09-24 Thread Bernhard Michal
Great! Thank you very much.

I get new url through
IRequestCodingStrategy#rewriteStaticRelativeUrl(String url):

String newUrl =
RequestCycle.get().getProcessor().getRequestCodingStrategy().rewriteStat
icRelativeUrl(urlToChange);

MB

-Original Message-
From: Pedro Santos [mailto:pedros...@gmail.com] 
Sent: Thursday, September 24, 2009 1:33 PM
To: users@wicket.apache.org
Subject: Re: image html element's (img) src attribute processing

1) Where exactly is the code which doing this?
http://wicket.apache.org/docs/1.4/org/apache/wicket/request/IRequestCodi
ngStrategy.html
2) How can I obtain this changed url for static resources?
You can create an resource reference to your image resource.
http://wicket.apache.org/docs/wicket-1.3.2/wicket/apidocs/org/apache/wic
ket/ResourceReference.html


On Thu, Sep 24, 2009 at 6:13 AM, Bernhard Michal
wrote:

>
> Hello everyone.
>
> I noticed that wicket automatically translate url in img's src 
> attribute in html to the right url regarding to changed url context.
> I mean when I've got eg. link  and that 
> page is rendered in some context for example "/appContext/" the src 
> attribute is automatically changed to something like this:  src="/../img/someimage.png"> (notice two dots) to reflect changed 
> context (and link still the same resource)
>
> 1) Where exactly is the code which doing this?
> 2) How can I obtain this changed url for static resources?
>
> I am asking this because I've got some static resources (javascripts) 
> and I need to know their relative url regarding to changed context.
>
> Thank you for your response.
>
> Best wishes
>
> MB
>
>
>
>
>
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


--
Pedro Henrique Oliveira dos Santos

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



Form Processing problem on pages with Border - Wicket 1.4.1

2009-09-24 Thread Flavius
I am migrating a project from 1.3.6 to 1.4.1.  I've run into a problem and
I'm not sure if this is a bug or not.

Most of the pages have a border and the border has a DropDownChoice in it
(as well as other components).  Technically it's in a panel in the border.

The Form objects are typically children of the border, like

add(border);
border.add(inputForm);

When the form is submitted, the DropDownChoice's value is being reset.  I've
traced through the code and it looks like the root of the cause is in
Form#internalUpdateFormComponentModels.

This is checking if there is a border and, if yes, then visiting all the
components of the border.

The internalUpdateFormComponentModels method in 1.3.6 didn't look for the
border and visit it's components.  It's not obvious to me why this needs to
be done now in 1.4.

So ultimately FormComponent#visitComponentsPostOrderHelper is being called
for all components whether they are inside the form or not.

It's returning visitor.component(component), which calls Form#component and
that calls ((IFormModelUpdateListener)component).updateModel();

I looked through the nabble logs and noticed this entry here:
http://www.nabble.com/Form-processing-issues-and-questions-%28particularly-r
elated-to-Border-and-ListMultipleChoice%29-td25251849.html#a25251849


Is there something I need to do here?  I'm not seeing any way of telling the
Form not to visit the Border's controls, and again, I'm not sure why it's
doing this.

I'd greatly appreciate any insight that can be offered.


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



Re: [wicket-stuff] project sitemap-xml - empty jar' files

2009-09-24 Thread Jeremy Thomerson
Can you submit a patch or even just commit the fix yourself?  The brutal
truth is that most wicket stuff projects are abandoned toys that their
owners once created.  But the nice thing is that you are free to change it
if you want.

--
Jeremy Thomerson
http://www.wickettraining.com



On Thu, Sep 24, 2009 at 2:36 AM, Jens Zastrow  wrote:

> Hi all,
>
> I already created a jira but without any feedback
> http://wicketstuff.org/jira/browse/ACTIVEWIDGETS-3
>
> We want to use the sitemap-xml project but the jars in the maven-repository
> are empty.
>
> I checked out 1.4.1 sitemap-xml source-code from the svn...
> The problem exists because the directory structure (main/java) doesnt
> follow the default-maven-layout (src/main/java)
> and the pom.xml isnt reconfigured  to match the (main/java) structure.
>
> I hope sombody of the sitemap-xml-source commiters will read this.
>
> Thanks
> Jens
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: Wicket in Italy

2009-09-24 Thread Paolo Di Tommaso
Roma (~)


On Thu, Sep 24, 2009 at 8:46 AM, francesco dicarlo
wrote:

> Hi, i've just worked on a project with wicket for a software house in Bari.
>
> But now i'm in Rome.
>
> Hope to see you in an event XD
>
> 2009/9/24 Luca Provenzani 
>
>


Re: Problem configuring RequestLogger with Jetty

2009-09-24 Thread Rens Verhage
But you are using Tomcat, not Jetty, right?
Oh, and by the way, my log file is already based upon yours :) I checked it
out from svn yesterday.

Rens


On Thu, Sep 24, 2009 at 1:39 PM, Martijn Dashorst <
martijn.dasho...@gmail.com> wrote:

> This is our file that works like a charm:
>
> 
> 
> 
>
>  class="nl.topicus.cobra.logging.log4j.ContextAwareDatedFileAppender">
>
>
>
> 
>  value="[%d{ISO8601}] [%p] [%t]
> %C{1} | %m%n" />
>
>
> 
> 
>
>
>
> 
>  class="nl.topicus.cobra.logging.log4j.ContextAwareDatedFileAppender">
>
>
>
> 
>
>
>
>
>
>
>
>
>
> 
>
>
>
>
>
>
>
>
>
>
>
> 
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> 
>
>
>
>
>
>
>
>
>
>
> 
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: IComponentAssignedModel and ComponentModel

2009-09-24 Thread Pedro Santos
ComponentModel is an public class:

public class ComponentModel implements IModel,
IComponentAssignedModel

why not just have an attribute on the "outer" class and assign the component
to it in wrapOnAssignment(Component component)?
could you draw?

On Thu, Sep 24, 2009 at 8:49 AM,  wrote:

> hi,
>
> i have a question regarding implementation details of wicket.
> IComponentAssignedModel is used to make a model aware of the component its
> assigned to. ComponentModel is a quick implementation of this interface. why
> is it done with an inner class? why not just have an attribute on the
> "outer" class and assign the component to it in wrapOnAssignment(Component
> component)? why an inner class? and how i'm supposed to use ComponentModel
> as a base class when i cant subclass the innerclass because its private and
> therefor not visible?
>
> thanks in advance, garz
> --
> Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3 -
> sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser
>
> --
> GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
> Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


-- 
Pedro Henrique Oliveira dos Santos


IComponentAssignedModel and ComponentModel

2009-09-24 Thread Garz
hi,

i have a question regarding implementation details of wicket. 
IComponentAssignedModel is used to make a model aware of the component its 
assigned to. ComponentModel is a quick implementation of this interface. why is 
it done with an inner class? why not just have an attribute on the "outer" 
class and assign the component to it in wrapOnAssignment(Component component)? 
why an inner class? and how i'm supposed to use ComponentModel as a base class 
when i cant subclass the innerclass because its private and therefor not 
visible?

thanks in advance, garz
-- 
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser

-- 
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01

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



Re: Problem configuring RequestLogger with Jetty

2009-09-24 Thread Martijn Dashorst
This is our file that works like a charm:




























































































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



Re: image html element's (img) src attribute processing

2009-09-24 Thread Pedro Santos
1) Where exactly is the code which doing this?
http://wicket.apache.org/docs/1.4/org/apache/wicket/request/IRequestCodingStrategy.html
2) How can I obtain this changed url for static resources?
You can create an resource reference to your image resource.
http://wicket.apache.org/docs/wicket-1.3.2/wicket/apidocs/org/apache/wicket/ResourceReference.html


On Thu, Sep 24, 2009 at 6:13 AM, Bernhard Michal
wrote:

>
> Hello everyone.
>
> I noticed that wicket automatically translate url in img's src attribute
> in html to the right url regarding to changed url context.
> I mean when I've got eg. link  and that
> page is rendered in some context for example "/appContext/" the src
> attribute is automatically changed to something like this:  src="/../img/someimage.png"> (notice two dots) to reflect changed
> context (and link
> still the same resource)
>
> 1) Where exactly is the code which doing this?
> 2) How can I obtain this changed url for static resources?
>
> I am asking this because I've got some static resources (javascripts)
> and I need to know their relative url regarding to changed context.
>
> Thank you for your response.
>
> Best wishes
>
> MB
>
>
>
>
>
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


-- 
Pedro Henrique Oliveira dos Santos


AW: wicket-phonebook

2009-09-24 Thread Andreas Kaluza
There was a problem in the pom.xml. You have to include:


wicket-snaps
http://wicketstuff.org/maven/repository

true


true

 

into the repositories-tag. With that the installation works.

Cheers,

Andy

> -Ursprüngliche Nachricht-
> Von: Pierre Goupil [mailto:goupilpie...@gmail.com]
> Gesendet: Donnerstag, 24. September 2009 12:39
> An: users@wicket.apache.org
> Betreff: Re: wicket-phonebook
> 
> I've used the phonebook without any problem. Are you sure you've got
> the
> latest version? Plus, you need the whole wickestuff-core project (found
> in
> wicketstuff/wicketstuff-core), AFAIK. And it looks like you haven't got
> it
> on your hard drive, since Maven tries and download it.
> 
> Regards,
> 
> Pierre
> 
> 
> On Thu, Sep 24, 2009 at 12:33 PM, Andreas Kaluza  kl.de>wrote:
> 
> > Hi @all,
> >
> >
> >
> > I'm trying to install the wicket-phonebook with "mvn install". The
> error
> > message is:
> >
> >
> >
> > [INFO] Scanning for projects...
> >
> > Downloading:
> > http://download.java.net/maven/2//org/wicketstuff/wicketstuff-core/
> >
> > 1.4-SNAPSHOT/wicketstuff-core-1.4-SNAPSHOT.pom
> >
> > [INFO] Unable to find resource
> > 'org.wicketstuff:wicketstuff-core:pom:1.4-SNAPSHO
> >
> > T' in repository maven2-repository.dev.java.net
> > (http://download.java.net/maven/
> >
> > 2/)
> >
> > [INFO]
> > -
> ---
> >
> > [ERROR] FATAL ERROR
> >
> > [INFO]
> > -
> ---
> >
> > [INFO] Error building POM (may not be this project's POM).
> >
> >
> >
> >
> >
> > Project ID: null:phonebook:war:null
> >
> >
> >
> > Reason: Cannot find parent: org.wicketstuff:wicketstuff-core for
> project:
> > null:p
> >
> > honebook:war:null for project null:phonebook:war:null
> >
> >
> >
> >
> >
> > [INFO]
> > -
> ---
> >
> > [INFO] Trace
> >
> > org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
> > org.wicket
> >
> > stuff:wicketstuff-core for project: null:phonebook:war:null for
> project
> > null:pho
> >
> > nebook:war:null
> >
> >at
> org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:404)
> >
> >at
> org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:272)
> >
> >at
> org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
> >
> >at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
> >
> >at
> > org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6
> >
> > 0)
> >
> >
> >
> > Is the pom.xml corrupted (I have the original one)?  It seems that
> the
> > maven
> > repository is incomplete. Anyone a solution?
> >
> >
> >
> > Cheers,
> >
> > Andy
> >
> >
> 
> 
> --
> Sans amis était le grand maître des mondes,
> Eprouvait manque, ce pour quoi il créa les esprits,
> Miroirs bienveillants de sa béatitude.
> Mais au vrai, il ne trouva aucun égal,
> Du calice du royaume total des âmes
> Ecume jusqu'à lui l'infinité.
> 
> (Schiller, "l'amitié")


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



Problem configuring RequestLogger with Jetty

2009-09-24 Thread Rens Verhage
I'm having some problems configuring wicket's RequestLogger with Jetty.
What I have done is:

I put log4j-1.2.14.jar, slf4j-api-1.5.6.jar and slf4j-log4j12-1.5.6.jar in
the ${jetty-home}/lib/ext/ directory. Then, I put the log4j.xml file in the
${jetty-home}/resources/ directory.

Relevant snippet from log4j.xml:

 





























When I start my application, all application log messages are correctly
displayed in the application.log file. However, the requests.log file
remains empty. The request logger doesn't seem to log anything at all,
anywhere.

I tried logging the requests to the application.log file as well, but still
nothing.

Am I missing something?


Rens


Re: wicket-phonebook

2009-09-24 Thread Pierre Goupil
I've used the phonebook without any problem. Are you sure you've got the
latest version? Plus, you need the whole wickestuff-core project (found in
wicketstuff/wicketstuff-core), AFAIK. And it looks like you haven't got it
on your hard drive, since Maven tries and download it.

Regards,

Pierre


On Thu, Sep 24, 2009 at 12:33 PM, Andreas Kaluza wrote:

> Hi @all,
>
>
>
> I'm trying to install the wicket-phonebook with "mvn install". The error
> message is:
>
>
>
> [INFO] Scanning for projects...
>
> Downloading:
> http://download.java.net/maven/2//org/wicketstuff/wicketstuff-core/
>
> 1.4-SNAPSHOT/wicketstuff-core-1.4-SNAPSHOT.pom
>
> [INFO] Unable to find resource
> 'org.wicketstuff:wicketstuff-core:pom:1.4-SNAPSHO
>
> T' in repository maven2-repository.dev.java.net
> (http://download.java.net/maven/
>
> 2/)
>
> [INFO]
> 
>
> [ERROR] FATAL ERROR
>
> [INFO]
> 
>
> [INFO] Error building POM (may not be this project's POM).
>
>
>
>
>
> Project ID: null:phonebook:war:null
>
>
>
> Reason: Cannot find parent: org.wicketstuff:wicketstuff-core for project:
> null:p
>
> honebook:war:null for project null:phonebook:war:null
>
>
>
>
>
> [INFO]
> 
>
> [INFO] Trace
>
> org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
> org.wicket
>
> stuff:wicketstuff-core for project: null:phonebook:war:null for project
> null:pho
>
> nebook:war:null
>
>at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:404)
>
>at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:272)
>
>at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
>
>at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
>
>at
> org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6
>
> 0)
>
>
>
> Is the pom.xml corrupted (I have the original one)?  It seems that the
> maven
> repository is incomplete. Anyone a solution?
>
>
>
> Cheers,
>
> Andy
>
>


-- 
Sans amis était le grand maître des mondes,
Eprouvait manque, ce pour quoi il créa les esprits,
Miroirs bienveillants de sa béatitude.
Mais au vrai, il ne trouva aucun égal,
Du calice du royaume total des âmes
Ecume jusqu'à lui l'infinité.

(Schiller, "l'amitié")


IComponentAssignedModel and ComponentModel

2009-09-24 Thread Kurt Zitze
hi,

i have a question regarding implementation details of wicket. 
IComponentAssignedModel is used to make a model aware of the component its 
assigned to. ComponentModel is a quick implementation of this interface. why is 
it done with an inner class? why not just have an attribute on the "outer" 
class and assign the component to it in wrapOnAssignment(Component component)? 
why an inner class? and how i'm supposed to use ComponentModel as a base class 
when i cant subclass the innerclass because its private and therefor not 
visible?

thanks in advance, garz
-- 
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/chbrowser

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



wicket-phonebook

2009-09-24 Thread Andreas Kaluza
Hi @all,

 

I'm trying to install the wicket-phonebook with "mvn install". The error
message is:

 

[INFO] Scanning for projects...

Downloading:
http://download.java.net/maven/2//org/wicketstuff/wicketstuff-core/

1.4-SNAPSHOT/wicketstuff-core-1.4-SNAPSHOT.pom

[INFO] Unable to find resource
'org.wicketstuff:wicketstuff-core:pom:1.4-SNAPSHO

T' in repository maven2-repository.dev.java.net
(http://download.java.net/maven/

2/)

[INFO]


[ERROR] FATAL ERROR

[INFO]


[INFO] Error building POM (may not be this project's POM).

 

 

Project ID: null:phonebook:war:null

 

Reason: Cannot find parent: org.wicketstuff:wicketstuff-core for project:
null:p

honebook:war:null for project null:phonebook:war:null

 

 

[INFO]


[INFO] Trace

org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
org.wicket

stuff:wicketstuff-core for project: null:phonebook:war:null for project
null:pho

nebook:war:null

at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:404)

at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:272)

at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)

at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)

at
org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6

0)

 

Is the pom.xml corrupted (I have the original one)?  It seems that the maven
repository is incomplete. Anyone a solution?

 

Cheers,

Andy



Re: Starting with Wicket, Spring, Maven and JDBC

2009-09-24 Thread Pedro Sena
Wow,

Exactly what I was looking for!!!

Thanks a lot !!

On Thu, Sep 24, 2009 at 7:10 AM, Muro Copenhagen wrote:

> Hi Pedro
>
> Try Appfuse-light with the desired combination:
>
> https://appfuse-light.dev.java.net/servlets/ProjectDocumentList?folderID=8006&expandFolder=8006&folderID=0
>
> It should be at the bottom.
>
> Best Regards
> Muro
>
> On Thu, Sep 24, 2009 at 12:04 PM, Pedro Sena  wrote:
>
> > I'll check them
> >
> > Thanks Eric,
> >
> > On Wed, Sep 23, 2009 at 8:08 PM, Erik Post  wrote:
> >
> > > Well, besides iolite, you could take a look at wicket-phonebook and
> > > wicketopia. They're not JDBC but they both come with Spring
> > > preconfigured. The phonebook has a couple of example DAO's and iBatis
> > > (among others) set up. You could take those as a starting point and
> > > 'add' JDBC.
> > >
> > > Cheers,
> > > Erik
> > >
> > >
> > > On Wed, Sep 23, 2009 at 11:33 PM, Pedro Sena 
> > wrote:
> > > > Hi Guys,
> > > >
> > > > I'm new to Wicket with Spring(I never used Spring before, just Seam).
> > I'm
> > > > using lolite but it comes with JPA instead of JDBC.
> > > >
> > > > I would like to know if there is some archetype for the setup that I
> > > > described in the title. I already checked wicket stuff if no luck.
> > > >
> > > > Thanks in advance,
> > > > --
> > > > /**
> > > > * Pedro Sena
> > > > * Systems Architect
> > > > * Sun Certified Java Programmer
> > > > * Sun Certified Web Component Developer
> > > > */
> > > >
> > >
> > > -
> > > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> > > For additional commands, e-mail: users-h...@wicket.apache.org
> > >
> > >
> >
> >
> > --
> > /**
> > * Pedro Sena
> > * Systems Architect
> > * Sun Certified Java Programmer
> > * Sun Certified Web Component Developer
> > */
> >
>



-- 
/**
* Pedro Sena
* Systems Architect
* Sun Certified Java Programmer
* Sun Certified Web Component Developer
*/


Re: Starting with Wicket, Spring, Maven and JDBC

2009-09-24 Thread Muro Copenhagen
Hi Pedro

Try Appfuse-light with the desired combination:
https://appfuse-light.dev.java.net/servlets/ProjectDocumentList?folderID=8006&expandFolder=8006&folderID=0

It should be at the bottom.

Best Regards
Muro

On Thu, Sep 24, 2009 at 12:04 PM, Pedro Sena  wrote:

> I'll check them
>
> Thanks Eric,
>
> On Wed, Sep 23, 2009 at 8:08 PM, Erik Post  wrote:
>
> > Well, besides iolite, you could take a look at wicket-phonebook and
> > wicketopia. They're not JDBC but they both come with Spring
> > preconfigured. The phonebook has a couple of example DAO's and iBatis
> > (among others) set up. You could take those as a starting point and
> > 'add' JDBC.
> >
> > Cheers,
> > Erik
> >
> >
> > On Wed, Sep 23, 2009 at 11:33 PM, Pedro Sena 
> wrote:
> > > Hi Guys,
> > >
> > > I'm new to Wicket with Spring(I never used Spring before, just Seam).
> I'm
> > > using lolite but it comes with JPA instead of JDBC.
> > >
> > > I would like to know if there is some archetype for the setup that I
> > > described in the title. I already checked wicket stuff if no luck.
> > >
> > > Thanks in advance,
> > > --
> > > /**
> > > * Pedro Sena
> > > * Systems Architect
> > > * Sun Certified Java Programmer
> > > * Sun Certified Web Component Developer
> > > */
> > >
> >
> > -
> > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> > For additional commands, e-mail: users-h...@wicket.apache.org
> >
> >
>
>
> --
> /**
> * Pedro Sena
> * Systems Architect
> * Sun Certified Java Programmer
> * Sun Certified Web Component Developer
> */
>


Re: Starting with Wicket, Spring, Maven and JDBC

2009-09-24 Thread Pedro Sena
I'll check them

Thanks Eric,

On Wed, Sep 23, 2009 at 8:08 PM, Erik Post  wrote:

> Well, besides iolite, you could take a look at wicket-phonebook and
> wicketopia. They're not JDBC but they both come with Spring
> preconfigured. The phonebook has a couple of example DAO's and iBatis
> (among others) set up. You could take those as a starting point and
> 'add' JDBC.
>
> Cheers,
> Erik
>
>
> On Wed, Sep 23, 2009 at 11:33 PM, Pedro Sena  wrote:
> > Hi Guys,
> >
> > I'm new to Wicket with Spring(I never used Spring before, just Seam). I'm
> > using lolite but it comes with JPA instead of JDBC.
> >
> > I would like to know if there is some archetype for the setup that I
> > described in the title. I already checked wicket stuff if no luck.
> >
> > Thanks in advance,
> > --
> > /**
> > * Pedro Sena
> > * Systems Architect
> > * Sun Certified Java Programmer
> > * Sun Certified Web Component Developer
> > */
> >
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


-- 
/**
* Pedro Sena
* Systems Architect
* Sun Certified Java Programmer
* Sun Certified Web Component Developer
*/


image html element's (img) src attribute processing

2009-09-24 Thread Bernhard Michal

Hello everyone.

I noticed that wicket automatically translate url in img's src attribute
in html to the right url regarding to changed url context. 
I mean when I've got eg. link  and that
page is rendered in some context for example "/appContext/" the src
attribute is automatically changed to something like this:  (notice two dots) to reflect changed
context (and link 
still the same resource)

1) Where exactly is the code which doing this?
2) How can I obtain this changed url for static resources?

I am asking this because I've got some static resources (javascripts)
and I need to know their relative url regarding to changed context.

Thank you for your response.

Best wishes

MB





 

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



Re: Date validation in a form

2009-09-24 Thread Reinout van Schouwen
Hi,

Op woensdag 23-09-2009 om 10:38 uur [tijdzone -0700], schreef Igor
Vaynberg:
> see DateTextField in extensions
> 
> > e.g : The SimpleDateformat to be used to create a java Date is : dd/MM/
> > So I would like to check that the user has well introduced its date
> > using this format

I happened to be looking for the same thing yesterday (more specifically
about how to do client side validation) and found these two interesting
links:

http://www.jroller.com/wireframe/entry/wicket_client_side_validation
http://cwiki.apache.org/WICKET/fancy-validation-using-ajax-alternatives-to-feedbackpanel.html

regards,

-- 
Reinout van Schouwen


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



Re: Re: + key as alternative for tab key

2009-09-24 Thread nino martinez wael
thanks :)

2009/9/24 Boydens Joeri (OZ) 

> Daniel,
>
> Great library!
>
> Thanks for the information
>
>  Joeri Boydens
>  OZ Onafhankelijk Ziekenfonds
>  Informatica
>  050 40 53 09
>
>
> -Oorspronkelijk bericht-
> Van: news [mailto:n...@ger.gmane.org] Namens Daniel Toffetti
> Verzonden: woensdag 23 september 2009 20:43
> Aan: users@wicket.apache.org
> Onderwerp: Re: + key as alternative for tab key
>
> Boydens Joeri (OZ  oz.be> writes:
> > How would you do this in an elegant and generic way ?
> >
> > Joeri
> >
>
>Also, take a look at wicketstuff-input-events
>
> Daniel
>
>
>
> -
> 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: Wicket in France

2009-09-24 Thread Pierre Goupil
Excellent, men!

Nicolas: I love your blog. Keep it up!



On Thu, Sep 24, 2009 at 10:27 AM, Olivier Bourgeois  wrote:

> I'm located in Paris. We are just missing somebody from Lille and Nice for
> a
> perfect dispatch :)
>



-- 
Sans amis était le grand maître des mondes,
Eprouvait manque, ce pour quoi il créa les esprits,
Miroirs bienveillants de sa béatitude.
Mais au vrai, il ne trouva aucun égal,
Du calice du royaume total des âmes
Ecume jusqu'à lui l'infinité.

(Schiller, "l'amitié")


Re: Wicket in France

2009-09-24 Thread Olivier Bourgeois
I'm located in Paris. We are just missing somebody from Lille and Nice for a
perfect dispatch :)


Re: Date validation in a form

2009-09-24 Thread Per Lundholm
Hi!

Don't forget to setLenient false.

Hope snippet below is enough.

/Per

public final class LocalDateFormatValidator extends StringValidator {
private static final long serialVersionUID = 1L;
private final SimpleDateFormat dateFormat;

public LocalDateFormatValidator(Locale locale) {
this.dateFormat = (SimpleDateFormat) new
DateConverter().getDateFormat(locale);
this.dateFormat.setLenient(false);
}

(...)

@Override
protected void onValidate(IValidatable validatable) {
String dateString = validatable.getValue();
try {
dateFormat.parse(dateString);
} catch (ParseException e) {
error(validatable);
}
}
}

On Thu, Sep 24, 2009 at 10:10 AM, Charles Moulliard wrote:

> I would like to know How I can validate the string date inputted by a
> user in a textfield of my form ?
>
> e.g : The SimpleDateformat to be used to create a java Date is : dd/MM/
> So I would like to check that the user has well introduced its date
> using this format
>
> Regards,
>
> Charles Moulliard
> Senior Enterprise Architect
> Apache Camel Committer
>
> *
> blog : http://cmoulliard.blogspot.com
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


AW: Date validation in a form

2009-09-24 Thread Giambalvo, Christian
What about org.apache.wicket.validation.validator.PatternValidator

Mit freundlichen Grüßen
Christian Giambalvo
--
Fachinformatiker für Anwendungsentwicklung

EXCELSIS Informationssysteme GmbH
Wilhelmsplatz 8 - 70182 Stuttgart
Mobile +49 176 196 32 406
Office +49 711 6 20 30 406
christian.giamba...@excelsisnet.com
www.excelsisnet.com
 
Sitz Stuttgart
Amtsgericht Stuttgart, HRB 21104
Geschäftsführer: Christian Sauter, Dr. Nils Herda, Frank Wolf

-Ursprüngliche Nachricht-
Von: Charles Moulliard [mailto:cmoulli...@gmail.com] 
Gesendet: Donnerstag, 24. September 2009 10:10
An: users@wicket.apache.org
Betreff: Date validation in a form

I would like to know How I can validate the string date inputted by a
user in a textfield of my form ?

e.g : The SimpleDateformat to be used to create a java Date is : dd/MM/
So I would like to check that the user has well introduced its date
using this format

Regards,

Charles Moulliard
Senior Enterprise Architect
Apache Camel Committer

*
blog : http://cmoulliard.blogspot.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



Date validation in a form

2009-09-24 Thread Charles Moulliard
I would like to know How I can validate the string date inputted by a
user in a textfield of my form ?

e.g : The SimpleDateformat to be used to create a java Date is : dd/MM/
So I would like to check that the user has well introduced its date
using this format

Regards,

Charles Moulliard
Senior Enterprise Architect
Apache Camel Committer

*
blog : http://cmoulliard.blogspot.com

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



Re: adding ajaxindicator to dropdownchoice

2009-09-24 Thread Jason Novotny


   Thanks! That got me in the right direction-- I basically copied 
IndicatingAjaxLink and made a IndicatingDropDownChoice below... seems 
like it would be good to have as part of the default widget set...


public class IndicatingDropDownChoice extends DropDownChoice 
implements IAjaxIndicatorAware {


   private final AjaxIndicatorAppender indicatorAppender = new 
AjaxIndicatorAppender();
  
   public IndicatingDropDownChoice(final String id) {

   super(id);
   add(indicatorAppender);
   }

   /**
* @see 
org.apache.wicket.markup.html.form.AbstractChoice#AbstractChoice(String, 
java.util.List)

*/
   public IndicatingDropDownChoice(final String id, final Listextends T> choices)

   {
   super(id, choices);
   add(indicatorAppender);
   }

   /**
* @see 
org.apache.wicket.ajax.IAjaxIndicatorAware#getAjaxIndicatorMarkupId()

*/
   public String getAjaxIndicatorMarkupId()
   {
   return indicatorAppender.getMarkupId();
   }
}


Peter Thomas wrote:

On Thu, Sep 24, 2009 at 11:40 AM, Jason Novotny wrote:

  

Hi,

  I have a DropDownChoice that triggers an ajax event to occur using the
 AjaxFormComponentUpdatingBehavior. Since the event takes a little while to
complete, I'd like to display  an ajaxindicator similar to an
IndicatingAjaxButton next to it... how can this be done?




Have a look at this code, line #137 and #159

http://code.google.com/p/perfbench/source/browse/trunk/perfbench/wicket-jpa/src/main/java/wicketjpa/wicket/MainPage.java#137

In the HTML, use something like:



You can also use an Image component and get the markupId generated by wicket
instead of hardcoding "spinner" etc.  Hope this helps.

- Peter.



  

  Thanks, Jason

-
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



[wicket-stuff] project sitemap-xml - empty jar' files

2009-09-24 Thread Jens Zastrow

Hi all,

I already created a jira but without any feedback 
http://wicketstuff.org/jira/browse/ACTIVEWIDGETS-3


We want to use the sitemap-xml project but the jars in the 
maven-repository are empty.


I checked out 1.4.1 sitemap-xml source-code from the svn...
The problem exists because the directory structure (main/java) doesnt 
follow the default-maven-layout (src/main/java)

and the pom.xml isnt reconfigured  to match the (main/java) structure.

I hope sombody of the sitemap-xml-source commiters will read this.

Thanks
Jens

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



RE: Re: + key as alternative for tab key

2009-09-24 Thread Boydens Joeri (OZ)
Daniel,

Great library! 

Thanks for the information

 Joeri Boydens
 OZ Onafhankelijk Ziekenfonds
 Informatica
 050 40 53 09


-Oorspronkelijk bericht-
Van: news [mailto:n...@ger.gmane.org] Namens Daniel Toffetti
Verzonden: woensdag 23 september 2009 20:43
Aan: users@wicket.apache.org
Onderwerp: Re: + key as alternative for tab key

Boydens Joeri (OZ  oz.be> writes:
> How would you do this in an elegant and generic way ?
> 
> Joeri  
> 

Also, take a look at wicketstuff-input-events

Daniel



-
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: adding ajaxindicator to dropdownchoice

2009-09-24 Thread Peter Thomas
On Thu, Sep 24, 2009 at 11:40 AM, Jason Novotny wrote:

>
> Hi,
>
>   I have a DropDownChoice that triggers an ajax event to occur using the
>  AjaxFormComponentUpdatingBehavior. Since the event takes a little while to
> complete, I'd like to display  an ajaxindicator similar to an
> IndicatingAjaxButton next to it... how can this be done?
>

Have a look at this code, line #137 and #159

http://code.google.com/p/perfbench/source/browse/trunk/perfbench/wicket-jpa/src/main/java/wicketjpa/wicket/MainPage.java#137

In the HTML, use something like:



You can also use an Image component and get the markupId generated by wicket
instead of hardcoding "spinner" etc.  Hope this helps.

- Peter.



>
>   Thanks, Jason
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>