?
avatar intukas
intukas
18 Feb 2016

Steps to reproduce the issue

Create a form field of type calendar and set date format for example format="%Y-%m-%d"

Expected result

Should be same date format when creating or editing a records.

Actual result

When trying create new record and select date, show correctly date format, but when edit a record show date in format Y-m-d H:i:s

System information (as much as possible)

joomla 3.4.8

Additional comments

libraries\joomla\form\fields\calendar.php always date value formated by default format Y-m-d H:i:s
screen shot 2016-02-18 at 01 05 57
change
line 144 $format = preg_replace('/[\\%]/', '', $this->format);
line 168 $this->value = JFactory::getDate()->format($format);
line 187 $this->value = $date->format($format, true, false);
line 202 $this->value = $date->format($format, true, false);
line 212 return JHtml::
('calendar', $this->value, $this->name, $this->id, $this->format, $attributes);
_

avatar intukas intukas - open - 18 Feb 2016
avatar intukas intukas - change - 18 Feb 2016
Status New Closed
Closed_Date 0000-00-00 00:00:00 2016-02-18 11:19:37
Closed_By intukas
avatar intukas intukas - close - 18 Feb 2016

Add a Comment

Login with GitHub to post a comment