From 5138bcda38c8439a4d1c7c51e9bba6d1396e284b Mon Sep 17 00:00:00 2001 From: gwoo Date: Tue, 29 Jan 2008 16:52:15 +0000 Subject: [PATCH] updating form helper field map, if var $map is defined it will use that, closes #3976 git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6418 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/libs/view/helpers/form.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cake/libs/view/helpers/form.php b/cake/libs/view/helpers/form.php index e6bae3fc3..768964a1b 100644 --- a/cake/libs/view/helpers/form.php +++ b/cake/libs/view/helpers/form.php @@ -523,10 +523,12 @@ class FormHelper extends AppHelper { 'string' => 'text', 'datetime' => 'datetime', 'boolean' => 'checkbox', 'timestamp' => 'datetime', 'text' => 'textarea', 'time' => 'time', - 'date' => 'date' + 'date' => 'date', 'float' => 'text' ); - if (isset($map[$type])) { + if (isset($this->map[$type])) { + $options['type'] = $this->map[$type]; + } elseif (isset($map[$type])) { $options['type'] = $map[$type]; } if ($this->field() == $primaryKey) {