Thanks to all!

2011/8/28 Alan Etkin <[email protected]>

> If the user must start his session based on some condition,  then
> access can be recorded in the session object.
> If the user must not start to use the application with a condition,
> then i would store access in the database so
> your access control code can check the access data in case the user
> logs out having entered a required action
> and starts another session.
>
> On 28 ago, 06:20, Martin Weissenboeck <[email protected]> wrote:
> > Hi,
> >
> > lets say I have 3 functions
> >
> > def a():
> >     # some code
> >     if form.accepts(request.vars, session):
> >         redirect(URL('b'))
> >     return dict(form=form)
> >
> > def b():
> >     # some code
> >     if form.accepts(request.vars, session):
> >         redirect(URL('c'))
> >     return dict(form=form)
> >
> > def c():
> >     return "**** c *****"
> >
> > a, b and c have their own views. I do not want to allow any user to start
> at
> > function b or c. Everybody has to start at a.
> > I think, this problem could be solved using a decorator, but I could not
> > find how.
> >
> > Regards, Martin
>

Reply via email to