diff --git a/plugins/baser-core/src/View/Helper/BcAdminFormHelper.php b/plugins/baser-core/src/View/Helper/BcAdminFormHelper.php index d9fdd8f599..197f4d07ca 100644 --- a/plugins/baser-core/src/View/Helper/BcAdminFormHelper.php +++ b/plugins/baser-core/src/View/Helper/BcAdminFormHelper.php @@ -99,6 +99,7 @@ public function control(string $fieldName, array $options = []): string case 'password': case 'date': case 'datePicker': + case 'time': case 'tel': case 'email': case 'number': diff --git a/plugins/baser-core/tests/TestCase/View/Helper/BcAdminFormHelperTest.php b/plugins/baser-core/tests/TestCase/View/Helper/BcAdminFormHelperTest.php index f9abb63257..6bbbf47ec2 100644 --- a/plugins/baser-core/tests/TestCase/View/Helper/BcAdminFormHelperTest.php +++ b/plugins/baser-core/tests/TestCase/View/Helper/BcAdminFormHelperTest.php @@ -184,6 +184,19 @@ public function testControl() $controlDatePicker = $this->BcAdminForm->control($name, $optionsDatePicker); $this->assertEquals($controlDatePicker, $this->BcAdminForm->control($name, ['type' => 'datePicker'])); + $optionsTime = array_replace_recursive($options, [ + 'type' => 'time', + 'class' => 'bca-textbox__input', + 'templateVars' => [ + 'class' => 'bca-textbox' + ], + 'labelOptions' => [ + 'class' => 'bca-textbox__label' + ] + ]); + $controlTime = $this->BcAdminForm->control($name, $optionsTime); + $this->assertEquals($controlTime, $this->BcAdminForm->control($name, ['type' => 'time'])); + $optionsTextarea = array_replace_recursive($options, [ 'type' => 'textarea', 'class' => 'bca-textarea__textarea',