Also fix hour()

This commit is contained in:
Mark Scherer 2015-04-20 22:04:33 +02:00
parent 3ba4308356
commit 8cdf222cc0

View file

@ -2315,6 +2315,11 @@ class FormHelper extends AppHelper {
* @link http://book.cakephp.org/2.0/en/core-libraries/helpers/form.html#FormHelper::hour
*/
public function hour($fieldName, $format24Hours = false, $attributes = array()) {
if (is_array($format24Hours)) {
$attributes = $format24Hours;
$format24Hours = null;
}
$attributes += array('empty' => true, 'value' => null);
$attributes = $this->_dateTimeSelected('hour', $fieldName, $attributes);