You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-user@portals.apache.org by Greg Buchanan <gm...@cfl.rr.com> on 2005/08/07 14:42:59 UTC

RE: "Create New Account" doesn't work

David, 

I saw this entry from the mailing list. 

I appreciate how busy you are with J2 and other stuff, so any help or
pointers you can provide me are greatly appreciated. 

Can you send me the source code to the module(s) you changed so that I can
replicate them ? The 1.6 distribution also has a similar problem with the
"last login" date that I need to fix. 

Once again, thank you for all the hard work on the Jetspeed project. 

-----Original Message-----
From: David Sean Taylor [mailto:david@bluesunrise.com] 
Sent: Tuesday, May 24, 2005 9:14 AM
To: Jetspeed Users List
Subject: Re: "Create New Account" doesn't work


Stefano Bianchi wrote:
> Dear Sven,
> I don't know if it is similar, but we experience a problem with J1.5 
> CreateNewAccount functionality. We had to modify the relative class 
> since it did not write correctly the Creation Date in the DB (always 
> '0000-00-00'). The user was created, but could not be retrieved 
> immediately afterwards. Sorry if this does not apply to your case...
> Cheers
> Stefano
I added a patch yesterday to 1.6 to fix this problem with the creation 
date and password changed during creation of a new user.
Tested on Hypersonic and MySQL only.

   +        if (user.isNew())
   +        {
   +            Date created = user.getCreateDate();
   +            if (created == null)
   +            {
   +                created = new Date();
   +            }
   +            criteria.add( "TURBINE_USER.CREATED", created);
   +            criteria.add( "TURBINE_USER.PASSWORD_CHANGED", created);
   +         }

-- 
David Sean Taylor
Bluesunrise Software
david@bluesunrise.com
[office] +01 707 773-4646
[mobile] +01 707 529 9194

---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-user-help@portals.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-user-help@portals.apache.org


Re: "Create New Account" doesn't work

Posted by David Sean Taylor <da...@bluesunrise.com>.
Greg Buchanan wrote:
> David, 
> 
> I saw this entry from the mailing list. 
> 
> I appreciate how busy you are with J2 and other stuff, so any help or
> pointers you can provide me are greatly appreciated. 
> 
> Can you send me the source code to the module(s) you changed so that I can
> replicate them ? The 1.6 distribution also has a similar problem with the
> "last login" date that I need to fix. 
> 
With which database?
The code below is IN the final 1.6 release.
Often, I see this problem when the wrong database bindings jar is used.
See instructions here for selecting another database:

http://portals.apache.org/jetspeed-1/database.html

    +        if (user.isNew())
    +        {
    +            Date created = user.getCreateDate();
    +            if (created == null)
    +            {
    +                created = new Date();
    +            }
    +            criteria.add( "TURBINE_USER.CREATED", created);
    +            criteria.add( "TURBINE_USER.PASSWORD_CHANGED", created);
    +         }

---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-user-help@portals.apache.org