U put the finger on it !

In fact, when i look in the database table 'persons', I have 2 'admin'
usernames, one in SG0 and one in SG4.

When I log in using 'admin*', I am in SG0, which is indicated in the main
admin page. All users i tried to add are in SG0, so it should have worked
but the function terminated in error. For exemple i was unable to add
midgard administrator of SG0 in the new group. The new group was in SG0. Is
it possible the check on SG and username be confused by the same username ?

In a second part, I insist on something that seems important to me, that
functions indicate a more detailed status in the return code. On the same
way, the default admin site is too silent about errors...  know it takes
time to setup all this and this is programmer's nightmare :) but it saves
lots of time during use and debug ;p

Pascal




> > I put a print in the code init for the admin/group location to see what
is
> > done :  mdg_create_member(2,5,'');  which are
>
> Yes i was logged as admin*

That probably explains it.

_Every_ record in the midgard database is in one specific sitegroup and
the functions do checks to keep you from creating resources that cross
sitegroup boundaries.

A newly created resource gets the current sitegroup. You were logged in as
'admin*' so you were in SG0 while trying to create the member record. My
guess is that at least one of user '2' or group '5' wasn't SG0.

In general, you will want to log in as admin!sitegroupname to do
maintenance on a sitegroup. 'admin*' should probably only be used to
maintain SG0 content like the admin site itself and the root user group.

Emile



--
This is The Midgard Project's mailing list. For more information,
please visit the project's web site at http://www.midgard-project.org

To unsubscribe the list, send an empty email message to address
[EMAIL PROTECTED]

Reply via email to