fix empty date customfield caused by not set app-name, defaulting to currentapp now

This commit is contained in:
ralf 2022-05-03 09:12:20 +02:00
parent 215dc21ec5
commit 9b6e6ad819

View File

@ -391,7 +391,7 @@ class Customfields extends Transformer
{ {
$form_name = self::form_name($cname, $this->id, $expand); $form_name = self::form_name($cname, $this->id, $expand);
$value =& $this->get_array($data, $form_name, true); $value =& $this->get_array($data, $form_name, true);
$customfields = Api\Storage\Customfields::get($this->attrs['app']); $customfields = Api\Storage\Customfields::get($this->attrs['app'] ?? $GLOBALS['egw_info']['flags']['currentapp']);
foreach($customfields as $field_name => $field) foreach($customfields as $field_name => $field)
{ {
@ -490,4 +490,4 @@ class Customfields extends Transformer
//error_log(__METHOD__."() $form_name $field: ".array2string($value).' --> '.array2string($value)); //error_log(__METHOD__."() $form_name $field: ".array2string($value).' --> '.array2string($value));
} }
} }
} }