优化Form表单生成类

pull/515/head
Karson 2025-06-09 10:31:25 +08:00
parent 1909bb4e6f
commit c6a3251840
1 changed files with 2 additions and 0 deletions

View File

@ -579,7 +579,9 @@ EOD;
{
$defaults = [
'data-date-format' => "YYYY-MM-DD HH:mm:ss",
// 兼容旧的用法
'data-use-current' => "true",
'data-date-use-current' => "true",
];
$value = is_numeric($value) ? date("Y-m-d H:i:s", $value) : $value;
$options = array_merge($defaults, $options);