mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-01-11 01:38:41 +00:00
fix missing default bug
This commit is contained in:
parent
5d5796b8fb
commit
fc56af4ff1
|
|
@ -74,7 +74,7 @@ final class FormElementGenerator
|
|||
$element .= ' ' . $attribute . '="' . $val . '"';
|
||||
}
|
||||
|
||||
$value ??= $json['default']['value'];
|
||||
$value ??= $json['default']['value'] ?? '';
|
||||
|
||||
$element .= (isset($json['default']) || $value !== null ? ' value="' . ($json['subtype'] === 'datetime' ? (new SmartDateTime($value))->format($json['default']['format']) : $value) . '"' : '');
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user