Thanks a lot Eelco and Igor.
add(new Label("username", new PropertyModel(this,
"customSession.user.firstName"))) works very well.
Eelco Hillenius a écrit :
> LOL. Of course.
>
> Eelco
>
> On 1/21/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
>
>> pfft
>>
>> add(new Label("username", new Prop
LOL. Of course.
Eelco
On 1/21/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
> pfft
>
> add(new Label("username", new PropertyModel(this,
> "customSession.user.firstName")));
>
> -igor
>
>
>
> On 1/21/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
> >
> > > or even:
> > >
> > >public SignInSucc
pfft
add(new Label("username", new PropertyModel(this, "
customSession.user.firstName")));
-igor
On 1/21/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
> or even:
>
>public SignInSuccess(String id) {
>super(id);
>add(new Label("username", new PropertyModel(new
> PropertyM
> or even:
>
>public SignInSuccess(String id) {
>super(id);
>add(new Label("username", new PropertyModel(new
> PropertyModel("customSession.user"), "firstName")));
>SignOutForm signOut = new SignOutForm("signOutForm");
>add(signOut);
>}
Erm, I mean:
publ
Oh, right. Best thing you can do here is wrap the user request in a
model: PropertyModel doesn't allow a null model, but a model that
produces null is fine. So this should work:
public SignInSuccess(String id) {
super(id);
IModel m = new AbstractReadOnlyModel() {
public
Sure. But it's a design problem i have here: my signin and signout
panels share the same place on the same page, and i'm just set them
visible/invisible when required, so they're created at the same time.
Yet getCustomSession().setUser(foo) is called after submit on signin...
How can i make sig
It looks like getCustomSession().getUser() returns null.
Eelco
On 1/21/07, Landry Soules <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I want to make work a signin component i have included in a page. When a
> user signs in, i retrieve the corresponding user record from DB, and put
> it a session prop
Hello,
I want to make work a signin component i have included in a page. When a
user signs in, i retrieve the corresponding user record from DB, and put
it a session property.
Then i hide the signin component, and make visible a new panel,
presenting a signout button, and a welcome message : "w