mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-26 01:43:47 +01:00
Custom fields are not allowed to have a null value, since NULL is skipped by backend
Fixes bug where it was impossible to clear date cfs
This commit is contained in:
parent
c99f0ee32d
commit
33594b565d
@ -323,6 +323,9 @@ class etemplate_widget_customfields extends etemplate_widget_transformer
|
|||||||
$valid =& self::get_array($validated, $this->id ? $form_name : $field, true);
|
$valid =& self::get_array($validated, $this->id ? $form_name : $field, true);
|
||||||
|
|
||||||
if (is_array($valid)) $valid = implode(',', $valid);
|
if (is_array($valid)) $valid = implode(',', $valid);
|
||||||
|
// NULL is valid for most fields, but not custom fields due to backend handling
|
||||||
|
// See so_sql_cf->save()
|
||||||
|
if (is_null($valid)) $valid = false;
|
||||||
//error_log(__METHOD__."() $form_name $field: ".array2string($value).' --> '.array2string($valid));
|
//error_log(__METHOD__."() $form_name $field: ".array2string($value).' --> '.array2string($valid));
|
||||||
}
|
}
|
||||||
} elseif ($this->type == 'customfields-types') {
|
} elseif ($this->type == 'customfields-types') {
|
||||||
|
Loading…
Reference in New Issue
Block a user