From 3861e90336031873d7f6dc2f7476b5502af7d69f Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Wed, 31 Aug 2016 21:04:22 -0400 Subject: Fix wrong project date format (shown as 01/01/1970) --- app/Model/ProjectModel.php | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'app/Model/ProjectModel.php') diff --git a/app/Model/ProjectModel.php b/app/Model/ProjectModel.php index d2019b72..aba5eee2 100644 --- a/app/Model/ProjectModel.php +++ b/app/Model/ProjectModel.php @@ -419,6 +419,14 @@ class ProjectModel extends Base $values['identifier'] = strtoupper($values['identifier']); } + if (! empty($values['start_date'])) { + $values['start_date'] = $this->dateParser->getIsoDate($values['start_date']); + } + + if (! empty($values['end_date'])) { + $values['end_date'] = $this->dateParser->getIsoDate($values['end_date']); + } + $this->helper->model->convertIntegerFields($values, array('priority_default', 'priority_start', 'priority_end')); return $this->exists($values['id']) && -- cgit v1.2.3