mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-11-22 18:09:06 +01:00
LSldapObject: fix triggering after_modify event on create
This commit is contained in:
parent
59d6d0865d
commit
4b634e408d
1 changed files with 8 additions and 5 deletions
|
@ -372,15 +372,18 @@ class LSldapObject extends LSlog_staticLoggerClass {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$new = $this -> isNew();
|
||||||
if ($this -> submitChange($idForm)) {
|
if ($this -> submitChange($idForm)) {
|
||||||
self :: log_debug($this."->_updateData(): changes are submited");
|
self :: log_debug($this."->_updateData(): changes are submited");
|
||||||
// Event After Modify
|
// Event After Modify
|
||||||
$this -> fireEvent('after_modify');
|
if (!$new && $idForm != 'create') {
|
||||||
|
$this -> fireEvent('after_modify');
|
||||||
|
|
||||||
// $this -> attrs[*] => After Modify
|
// $this -> attrs[*] => After Modify
|
||||||
foreach($new_data as $attr_name => $attr_val) {
|
foreach($new_data as $attr_name => $attr_val) {
|
||||||
if ($this -> attrs[$attr_name] -> isUpdate()) {
|
if ($this -> attrs[$attr_name] -> isUpdate()) {
|
||||||
$this -> attrs[$attr_name] -> fireEvent('after_modify');
|
$this -> attrs[$attr_name] -> fireEvent('after_modify');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$this -> reloadData();
|
$this -> reloadData();
|
||||||
|
|
Loading…
Reference in a new issue