[Zope] My objectValues doesn't have the right permissions ... I guess

Jens Vagelpohl jens@digicool.com
Mon, 9 Jul 2001 21:34:10 +0200


i have seen this happen because the wrong objectValues (or objectItems =
or=20
objectIds) methods get called. what classes, and in what order, does =
your=20
class inherit from?

OFS.SimpleItem.SimpleItem has an objectValues method that always returns=20=

an empty list and if you have SimpleItem before ObjectManager in your=20
class inheritance list you will get the empty list.

jens

On Monday, July 9, 2001, at 05:26 , Max M=F8ller Rasmussen wrote:

> I am trying to make a minimal ObjectManager How-To. So far so good. I =
have
> made the product and it works ... allmost.
>
> I can add objects to my objectmanager class. But when I try to see =
then in
> the management interface they dont show up.
>
> When I try to list the objects through:
>
> <dtml-in objectValues>
>     <a href=3D"<dtml-var absolute_url>"><dtml-var title_or_id></a><br>
> </dtml-in>
>
> I get nothing too.
>
> I CAN see them directly through the url. So my guess is that there is
> something wrong with my permissions for "objectValues" or somesuch.
>
> These are my permissions:
>
>     __ac_permissions__ =3D ObjectManager.__ac_permissions__ + (
>         ('View', # label
>             ('index_html',), # methods
>             ('Anonymous', 'Manager'), # roles
>         ),
>         ('Change minimalOM',
>             ('manage_editAction', 'manage_editForm'),
>             ('Manager',)
>         ),
>         ('Add minimalOM',
>             ('manage_addminimalOMAction', 'manage_addminimalOMForm'),
>             ('Manager',)
>         ),
>     )
>
> If I print them out concatenated, they look like this:
>
> (
>     ('View management screens',
>         ('manage_main', 'manage_menu')),
>     ('Access contents information',
>         ('objectIds', 'objectValues', 'objectItems', ''),
>         ('Anonymous', 'Manager')),
>     ('Delete objects',
>         ('manage_delObjects',)),
>     ('FTP access',
>         ('manage_FTPstat', 'manage_FTPlist')),
>     ('Import/Export objects',
>         ('manage_importObject', 'manage_importExportForm',
> 'manage_exportObject')),
>     ('View',
>         ('index_html',), ('Anonymous', 'Manager')),
>     ('Change minimalOM',
>         ('manage_editAction', 'manage_editForm'),
>         ('Manager',)),
>     ('Add minimalOM',
>         ('manage_addminimalOMAction', 'manage_addminimalOMForm'),
>         ('Manager',))
> )
>
> I cannot see what is wrong here. "objectValues" has the usual =
settings,=20
> and
> the user im logged on as has manager role.
>
> Anybody has a clue?
>
> Regards Max M
>
>
>                          - N=F8rg=E5rd Mikkelsen a/s -
>              www.normik.dk - Vandv=E6rksvej 18 - DK 5000 Odense C
>                Tlf (+45) 66 14 14 80 - Fax (+45) 66 14 19 43
>                      Max M - Direkte (+45) 63 14 47 15
>
>
> _______________________________________________
> Zope maillist  -  Zope@zope.org
> http://lists.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
>  http://lists.zope.org/mailman/listinfo/zope-announce
>  http://lists.zope.org/mailman/listinfo/zope-dev )