Great! Thanks Fran.

On Jun 18, 12:58 am, mdipierro <[email protected]> wrote:
> Thanks for the patch. I will commit it within a few hours.
>
> massimo
>
> On Jun 17, 1:37 am, Fran <[email protected]> wrote:
>
> > On Jun 17, 7:17 am, mdipierro <[email protected]> wrote:
>
> > > no
>
> > Shame.
>
> > I patch this manually in my extended Auth class, but it's extra work
> > to keep updating my extension to keep in-line with main.
>
> > Here is a patch to tools.py (also sent by mail):
>
> > --- gluon\tools.py.928  Sat Jun 13 20:47:24 2009
> > +++ gluon\tools.py      Wed Jun 17 07:35:54 2009
> > @@ -825,6 +825,19 @@
> >              else:
> >                  user[form.vars.id] = dict(registration_key='')
> >                  session.flash = self.messages.registration_successful
> > +                table_user = self.settings.table_user
> > +                if 'username' in table_user.fields:
> > +                    username = 'username'
> > +                else:
> > +                    username = 'email'
> > +                users = self.db(table_user[username] == form.vars
> > [username])\
> > +                    .select()
> > +                user = users[0]
> > +                user = Storage(table_user._filter_fields(user,
> > id=True))
> > +                session.auth = Storage(user=user,
> > last_visit=request.now,
> > +
> > expiration=self.settings.expiration)
> > +                self.user = user
> > +                session.flash = self.messages.logged_in
> >              if log:
> >                  self.log_event(log % form.vars)
> >              if onaccept:
>
> > F
>
> > > On Jun 16, 10:10 pm, Richard <[email protected]> wrote:
>
> > > > hello,
>
> > > > I came across an old T2 thread (http://groups.google.com/group/web2py/
> > > > browse_thread/thread/a4af19f213f5040e/df86352747060125) where Massimo
> > > > said he would add automatic login after registration to T2.
>
> > > > This is useful for simple registration forms with no email
> > > > authentication. Has this feature been implemented in the Auth tool?
>
> > > > thanks,
> > > > Richard
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to