[Zope-PTK] Building ZPatterns

Phillip J. Eby pje@telecommunity.com
Wed, 17 May 2000 21:21:52 -0500


At 01:42 AM 5/18/00 +0200, Alexander Limi wrote:
>
>I am running the official Zope 2.2.0alpha release on a wintendo box, for
>reference. The thing I don't get is: Where am I supposed to be able to add
>users?

LoginManager manages logins, not users.  :)  To add users, you have to have
a UserSource that supports adding users.  AFAIK (As Far As I Know) no such
UserSource currently exists except for the PersistentUserSource in the PTK
(which unfortunately is broken for use with the latest version of
LoginManager).

LoginManager was designed primarily with the intention of being able to
deal with non-Zope based users.  (There was already a good solution for
having Zope-based users!)  That is, ones that live in an SQL, LDAP, or
other sort of database.  That's why the prepackaged UserSource
(GenericUserSource) doesn't have any facility for adding users; you have to
write your own.

Of course, now that LoginManager offers the widest assortment of user
database access, customizable classes, and extensible data for Zope logins,
it just needs to deal with the rather simple need of inserting
run-of-the-mill Zope user objects.  :)

LoginManager will at some point have a simple UserSource that allows you to
directly add users, but we haven't got to it yet.  When we need to hack in
a few users manually on our own projects, we use GenericUserSource, with a
TinyTable added in and some DTML methods to make it all work.  This is a
pretty silly kludge, as it's primarily so we don't have to write all the
DTML screens for actually editing user information.  :)