Follow-up Comment #3, bug #13964 (project web-cyradm):
i guess it would be cleaner to have an asterisk-entry in the domaintable as
the the database-creation-script does. here my patch-suggestion:
--- editadminuser.php.orig 2005-12-13 21:07:39.939586562 +0100
+++ editadminuser.php 2005-12-13 21:08:33.197176731 +0100
@@ -282,11 +282,15 @@
if ($newtype==0){
# If the new type of admin will be
superuser, we also need to delete the domain
- # Responsibilities, because a
superuser is always responsible for all domains
+ # Responsibilities, because a
superuser is always responsible for all domains...
$query = "DELETE FROM domainadmin
WHERE adminuser='$username'";
$result = $handle1->query($query);
- # And update the type of this admin
+ # ...and update it's permission to
administrate all domains
+ $query = "INSERT INTO domainadmin
VALUES('*', '$username')";
+ $result = $handle1->query($query);
+
+ # as well as update the type of this
admin
$query="UPDATE adminuser SET
type='$newtype' WHERE username='$username'";
$result=$handle1->query($query);
}
cheers
romanDOThochuliATnexellentDOTch
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/bugs/?func=detailitem&item_id=13964>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
_______________________________________________
This mailing list is hosted and supported
by bit-heads GmbH | http://www.bit-heads.ch
_______________________________________________
Web-cyradm mailing list
[email protected]
http://www.web-cyradm.org/mailman/listinfo/web-cyradm