diff options
author | Frederic Guillot <fred@kanboard.net> | 2016-02-06 18:08:41 -0500 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2016-02-06 18:08:41 -0500 |
commit | 58cef289674717027b6b470044504a661f3bd9ad (patch) | |
tree | bf3be866b414009b60b1e1f16480a84c91da03de /app/Helper/Task.php | |
parent | fc785bbbf6cc7db01964ae1d99cd02e85afeedc2 (diff) |
The date time format can be chosen in application settings
Diffstat (limited to 'app/Helper/Task.php')
-rw-r--r-- | app/Helper/Task.php | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/app/Helper/Task.php b/app/Helper/Task.php index 0ef3da2c..e85d6e30 100644 --- a/app/Helper/Task.php +++ b/app/Helper/Task.php @@ -142,7 +142,7 @@ class Task extends Base public function selectStartDate(array $values, array $errors = array(), array $attributes = array()) { - $placeholder = $this->helper->text->in($this->config->get('application_date_format'), $this->dateParser->getAvailableFormats()); + $placeholder = date($this->config->get('application_date_format', 'm/d/Y H:i')); $attributes = array_merge(array('tabindex="11"', 'placeholder="'.$placeholder.'"'), $attributes); $html = $this->helper->form->label(t('Start Date'), 'date_started'); @@ -153,12 +153,11 @@ class Task extends Base public function selectDueDate(array $values, array $errors = array(), array $attributes = array()) { - $placeholder = $this->helper->text->in($this->config->get('application_date_format'), $this->dateParser->getAvailableFormats()); + $placeholder = date($this->config->get('application_date_format', 'm/d/Y')); $attributes = array_merge(array('tabindex="12"', 'placeholder="'.$placeholder.'"'), $attributes); $html = $this->helper->form->label(t('Due Date'), 'date_due'); $html .= $this->helper->form->text('date_due', $values, $errors, $attributes, 'form-date'); - $html .= '<div class="form-help">'.t('Others formats accepted: %s and %s', date('Y-m-d'), date('Y_m_d')).'</div>'; return $html; } |