The date time format can be chosen in application settings
This commit is contained in:
@@ -31,7 +31,7 @@ class Analytic extends Base
|
||||
'average' => $this->averageLeadCycleTimeAnalytic->build($project['id']),
|
||||
'metrics' => $this->projectDailyStats->getRawMetrics($project['id'], $from, $to),
|
||||
'date_format' => $this->config->get('application_date_format'),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats(),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats($this->dateParser->getDateFormats()),
|
||||
'title' => t('Lead and Cycle time for "%s"', $project['name']),
|
||||
)));
|
||||
}
|
||||
@@ -154,7 +154,7 @@ class Analytic extends Base
|
||||
'metrics' => $display_graph ? $this->projectDailyColumnStats->getAggregatedMetrics($project['id'], $from, $to, $column) : array(),
|
||||
'project' => $project,
|
||||
'date_format' => $this->config->get('application_date_format'),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats(),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats($this->dateParser->getDateFormats()),
|
||||
'title' => t($title, $project['name']),
|
||||
)));
|
||||
}
|
||||
|
||||
@@ -85,7 +85,9 @@ class Config extends Base
|
||||
$this->response->html($this->helper->layout->config('config/application', array(
|
||||
'languages' => $this->config->getLanguages(),
|
||||
'timezones' => $this->config->getTimezones(),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats(),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats($this->dateParser->getDateFormats()),
|
||||
'datetime_formats' => $this->dateParser->getAvailableFormats($this->dateParser->getDateTimeFormats()),
|
||||
'time_formats' => $this->dateParser->getAvailableFormats($this->dateParser->getTimeFormats()),
|
||||
'title' => t('Settings').' > '.t('Application settings'),
|
||||
)));
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ class Export extends Base
|
||||
),
|
||||
'errors' => array(),
|
||||
'date_format' => $this->config->get('application_date_format'),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats(),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats($this->dateParser->getDateFormats()),
|
||||
'project' => $project,
|
||||
'title' => $page_title,
|
||||
), 'export/sidebar'));
|
||||
|
||||
@@ -62,7 +62,7 @@ class Task extends Base
|
||||
'time_spent' => $task['time_spent'] ?: '',
|
||||
);
|
||||
|
||||
$this->dateParser->format($values, array('date_started'), 'Y-m-d H:i');
|
||||
$values = $this->dateParser->format($values, array('date_started'), $this->config->get('application_datetime_format', 'm/d/Y H:i'));
|
||||
|
||||
$this->response->html($this->helper->layout->task('task/show', array(
|
||||
'project' => $this->project->getById($task['project_id']),
|
||||
@@ -77,8 +77,6 @@ class Task extends Base
|
||||
'columns_list' => $this->board->getColumnsList($task['project_id']),
|
||||
'colors_list' => $this->color->getList(),
|
||||
'users_list' => $this->projectUserRole->getAssignableUsersList($task['project_id'], true, false, false),
|
||||
'date_format' => $this->config->get('application_date_format'),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats(),
|
||||
'title' => $task['project_name'].' > '.$task['title'],
|
||||
'recurrence_trigger_list' => $this->task->getRecurrenceTriggerList(),
|
||||
'recurrence_timeframe_list' => $this->task->getRecurrenceTimeframeList(),
|
||||
|
||||
@@ -82,8 +82,8 @@ class Taskmodification extends Base
|
||||
$values = $this->hook->merge('controller:task:form:default', $values, array('default_values' => $values));
|
||||
}
|
||||
|
||||
$this->dateParser->format($values, array('date_due'));
|
||||
$this->dateParser->format($values, array('date_started'), 'Y-m-d H:i');
|
||||
$values = $this->dateParser->format($values, array('date_due'), $this->config->get('application_date_format', 'm/d/Y'));
|
||||
$values = $this->dateParser->format($values, array('date_started'), $this->config->get('application_datetime_format', 'm/d/Y H:i'));
|
||||
|
||||
$this->response->html($this->helper->layout->task('task_modification/edit_task', array(
|
||||
'project' => $project,
|
||||
@@ -93,8 +93,6 @@ class Taskmodification extends Base
|
||||
'users_list' => $this->projectUserRole->getAssignableUsersList($task['project_id']),
|
||||
'colors_list' => $this->color->getList(),
|
||||
'categories_list' => $this->category->getList($task['project_id']),
|
||||
'date_format' => $this->config->get('application_date_format'),
|
||||
'date_formats' => $this->dateParser->getAvailableFormats(),
|
||||
)));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user