Fix sql error
This commit is contained in:
parent
2b3599dba5
commit
0008e916ac
@ -604,7 +604,7 @@ class User extends CommonObject
|
||||
}
|
||||
|
||||
/**
|
||||
* Load default value in property ->default_values
|
||||
* Load default values from database table into property ->default_values
|
||||
*
|
||||
* @return int > 0 if OK, < 0 if KO
|
||||
*/
|
||||
@ -616,7 +616,7 @@ class User extends CommonObject
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/defaultvalues.class.php';
|
||||
|
||||
$defaultValues = new DefaultValues($this->db);
|
||||
$result = $defaultValues->fetchAll('', '', 0, 0, array('t.user_id'=>array(0, $this->id), 'entity'=>array($this->entity, $conf->entity))); // User 0 (all) + me (if defined)
|
||||
$result = $defaultValues->fetchAll('', '', 0, 0, array('t.user_id'=>array(0, $this->id), 'entity'=>array((isset($this->entity) ? $this->entity : $conf->entity), $conf->entity))); // User 0 (all) + me (if defined)
|
||||
|
||||
if (!is_array($result) && $result < 0) {
|
||||
setEventMessages($defaultValues->error, $defaultValues->errors, 'errors');
|
||||
|
||||
Loading…
Reference in New Issue
Block a user