Commit cbf3185c authored by Côme Bernigaud's avatar Côme Bernigaud Committed by Benoit Mortier
Browse files

Fixes #3554 Fixed user->group gidNumber foreign key

parent 49795f05
...@@ -1142,6 +1142,27 @@ class group extends plugin ...@@ -1142,6 +1142,27 @@ class group extends plugin
} }
} }
protected function attributeInitialValue($field)
{
if ($field == 'gidNumber') {
return $this->saved_gidNumber;
} else {
return parent::attributeInitialValue($field);
}
}
protected function attributeHaveChanged($field)
{
if ($field == 'gidNumber') {
if (!$this->initially_was_account) {
return TRUE;
}
return ($this->$field != $this->attributeInitialValue($field));
} else {
return parent::attributeHaveChanged($field);
}
}
/*! \brief Get a new SambaSID for a group */ /*! \brief Get a new SambaSID for a group */
function getSambaSID() function getSambaSID()
{ {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment