Merge branch '5.0' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
9648f20a2e
@ -58,6 +58,8 @@ class Events // extends CommonObject
|
||||
array('id'=>'USER_NEW_PASSWORD', 'test'=>1),
|
||||
array('id'=>'USER_ENABLEDISABLE', 'test'=>1),
|
||||
array('id'=>'USER_DELETE', 'test'=>1),
|
||||
/* array('id'=>'USER_SETINGROUP', 'test'=>1), deprecated. Replace with USER_MODIFY
|
||||
array('id'=>'USER_REMOVEFROMGROUP', 'test'=>1), deprecated. Replace with USER_MODIFY */
|
||||
array('id'=>'GROUP_CREATE', 'test'=>1),
|
||||
array('id'=>'GROUP_MODIFY', 'test'=>1),
|
||||
array('id'=>'GROUP_DELETE', 'test'=>1),
|
||||
|
||||
@ -1855,8 +1855,9 @@ class User extends CommonObject
|
||||
{
|
||||
if (! $error && ! $notrigger)
|
||||
{
|
||||
$this->newgroupid=$group;
|
||||
|
||||
$this->newgroupid=$group; // deprecated. Remove this.
|
||||
$this->context = array('audit'=>$langs->trans("UserSetInGroup"), 'newgroupid'=>$group);
|
||||
|
||||
// Call trigger
|
||||
$result=$this->call_trigger('USER_SETINGROUP',$user);
|
||||
if ($result < 0) { $error++; }
|
||||
@ -1909,8 +1910,9 @@ class User extends CommonObject
|
||||
{
|
||||
if (! $error && ! $notrigger)
|
||||
{
|
||||
$this->oldgroupid=$group;
|
||||
|
||||
$this->oldgroupid=$group; // deprecated. Remove this.
|
||||
$this->context = array('audit'=>$langs->trans("UserRemovedFromGroup"), 'oldgroupid'=>$group);
|
||||
|
||||
// Call trigger
|
||||
$result=$this->call_trigger('USER_REMOVEFROMGROUP',$user);
|
||||
if ($result < 0) { $error++; }
|
||||
|
||||
@ -140,7 +140,7 @@ if ($action == 'adduser' || $action =='removeuser')
|
||||
{
|
||||
if ($caneditperms)
|
||||
{
|
||||
if ($userid)
|
||||
if ($userid > 0)
|
||||
{
|
||||
$object->fetch($id);
|
||||
$object->oldcopy = clone $object;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user