Dynamically Changing User Groups

Author Message

Frey Staso

Thursday 14 April 2005 2:22:35 pm

On my site, there are several different departments (say, mailroom, finance, administration for example) now each department has their own section and can only see/upload files there. I need to be able to let the department heads create new users on their own (without my support) for their own department.

Using user/register is a big step, but the problem is that I can only set ONCE where a user is "created" this is a problem because I need the Finance head to make new accounts that are automatically in the "finance" group and the administration head to make new accounts that are automatically in the "administration" group.

I know you can set where a new user is sent in the site.ini file, but my question is: how can I change that dynamically so that when they fill out the register form there is a drop down ezselector to let them pick their department in order to make a new user in that user group.

I SUPPOSE I could just make a new class for EACH department (all 15 of them) and then set the starting user group node ID number for each, but lets hope there is an easier way.

Thanks

Frey Staso

Tuesday 19 April 2005 8:26:57 am

Since I've seen my question asked before, I'm going to post how I got around this problem in case anyone needs it in the future.

Users and User Groups work just like any other content object (like an article) you don't need to make them using user/register. If you set up a button that sends the class id & node id it will create a new user in that node. This will, however, disable the email checking (which is okay for me, I was trying to disable it anyway)

Ekkehard Dörre

Tuesday 19 April 2005 8:58:21 am

You can use the content create toolbar in administration.
http://ez.no/ez_publish/documentation/customization/components/toolbars/how_to_customise_toolbar

But I don't know, if anybody can make a subtree limitation in this user group when creating this new user automatically.
Target is: One Folder, one user.

Greetings ekke

http://www.coolscreen.de - Over 40 years of certified eZ Publish know-how: http://www.cjw-network.com
CJW Newsletter: http://projects.ez.no/cjw_newsletter - http://cjw-network.com/en/ez-publ...w-newsletter-multi-channel-marketing

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.