[Seaside] Re: How to do a "login required" type of filter
pat.maddox at gmail.com
Thu May 28 02:21:01 UTC 2009
I changed the LoginForm component to set the account in the session
instead of using answer. Now my LoginDecoration renders the LoginForm
when there's no user in the session.
Now I'm running into a problem with children. The LoginForm isn't in
my main component's children list...which, there's really no way it
could be - the main component doesn't know anything about the
LoginForm, it only gets created as a result of my Decoration. I
verified that this is the problem by moving all the code from my
LoginForm into my LoginDecoration, and it works fine.
So again I think I'm doing something stupid here. I'm somewhat close
in that I can get the decoration to render my LoginForm component, but
now that component has to go into the decorated component's children
(apparently). That feels ugly so I would think there's a better way
to do this.
More information about the seaside