summaryrefslogtreecommitdiff
path: root/app/Template
diff options
context:
space:
mode:
Diffstat (limited to 'app/Template')
-rw-r--r--app/Template/app/notifications.php2
-rw-r--r--app/Template/app/tasks.php2
-rw-r--r--app/Template/board/task_footer.php2
-rw-r--r--app/Template/board/tooltip_comments.php2
-rw-r--r--app/Template/comment/show.php2
-rw-r--r--app/Template/config/application.php6
-rw-r--r--app/Template/event/events.php2
-rw-r--r--app/Template/file/show.php4
-rw-r--r--app/Template/listing/show.php2
-rw-r--r--app/Template/notification/task_create.php4
-rw-r--r--app/Template/notification/task_overdue.php2
-rw-r--r--app/Template/project/index.php4
-rw-r--r--app/Template/project/show.php6
-rw-r--r--app/Template/project_user/tasks.php4
-rw-r--r--app/Template/search/results.php2
-rw-r--r--app/Template/task/changes.php4
-rw-r--r--app/Template/task/details.php12
-rw-r--r--app/Template/task/time_tracking_details.php4
-rw-r--r--app/Template/task/transitions.php2
-rw-r--r--app/Template/task_external_link/show.php2
-rw-r--r--app/Template/user/last.php2
-rw-r--r--app/Template/user/password_reset.php4
-rw-r--r--app/Template/user/sessions.php4
-rw-r--r--app/Template/user/timesheet.php4
24 files changed, 45 insertions, 39 deletions
diff --git a/app/Template/app/notifications.php b/app/Template/app/notifications.php
index 511f377b..4cb3c571 100644
--- a/app/Template/app/notifications.php
+++ b/app/Template/app/notifications.php
@@ -49,7 +49,7 @@
<?php endif ?>
</td>
<td>
- <?= dt('%B %e, %Y at %k:%M %p', $notification['date_creation']) ?>
+ <?= $this->dt->datetime($notification['date_creation']) ?>
</td>
<td>
<i class="fa fa-check fa-fw"></i>
diff --git a/app/Template/app/tasks.php b/app/Template/app/tasks.php
index f4f9b2ad..786d7159 100644
--- a/app/Template/app/tasks.php
+++ b/app/Template/app/tasks.php
@@ -33,7 +33,7 @@
<?php endif ?>
</td>
<td>
- <?= dt('%B %e, %Y', $task['date_due']) ?>
+ <?= $this->dt->date($task['date_due']) ?>
</td>
</tr>
<?php endforeach ?>
diff --git a/app/Template/board/task_footer.php b/app/Template/board/task_footer.php
index 1912dd83..73e68602 100644
--- a/app/Template/board/task_footer.php
+++ b/app/Template/board/task_footer.php
@@ -22,7 +22,7 @@
<?php if (! empty($task['date_due'])): ?>
<span class="task-board-date <?= time() > $task['date_due'] ? 'task-board-date-overdue' : '' ?>">
<i class="fa fa-calendar"></i>
- <?= (date('Y') === date('Y', $task['date_due']) ? dt('%b %e', $task['date_due']) : dt('%b %e %Y', $task['date_due'])) ?>
+ <?= $this->dt->date($task['date_due']) ?>
</span>
<?php endif ?>
diff --git a/app/Template/board/tooltip_comments.php b/app/Template/board/tooltip_comments.php
index 2e2c0c1e..ca91e13f 100644
--- a/app/Template/board/tooltip_comments.php
+++ b/app/Template/board/tooltip_comments.php
@@ -4,7 +4,7 @@
<?php if (! empty($comment['username'])): ?>
<span class="comment-username"><?= $this->e($comment['name'] ?: $comment['username']) ?></span> @
<?php endif ?>
- <span class="comment-date"><?= dt('%b %e, %Y, %k:%M %p', $comment['date_creation']) ?></span>
+ <span class="comment-date"><?= $this->dt->datetime($comment['date_creation']) ?></span>
</p>
<div class="comment-inner">
diff --git a/app/Template/comment/show.php b/app/Template/comment/show.php
index 26b300e8..2c9b426f 100644
--- a/app/Template/comment/show.php
+++ b/app/Template/comment/show.php
@@ -9,7 +9,7 @@
<span class="comment-username"><?= $this->e($comment['name'] ?: $comment['username']) ?></span> @
<?php endif ?>
- <span class="comment-date"><?= dt('%B %e, %Y at %k:%M %p', $comment['date_creation']) ?></span>
+ <span class="comment-date"><?= $this->dt->datetime($comment['date_creation']) ?></span>
</p>
<div class="comment-inner">
diff --git a/app/Template/config/application.php b/app/Template/config/application.php
index 35d85dd8..48b04cf9 100644
--- a/app/Template/config/application.php
+++ b/app/Template/config/application.php
@@ -19,6 +19,12 @@
<?= $this->form->select('application_date_format', $date_formats, $values, $errors) ?>
<p class="form-help"><?= t('ISO format is always accepted, example: "%s" and "%s"', date('Y-m-d'), date('Y_m_d')) ?></p>
+ <?= $this->form->label(t('Date and time format'), 'application_datetime_format') ?>
+ <?= $this->form->select('application_datetime_format', $datetime_formats, $values, $errors) ?>
+
+ <?= $this->form->label(t('Time format'), 'application_time_format') ?>
+ <?= $this->form->select('application_time_format', $time_formats, $values, $errors) ?>
+
<?= $this->form->checkbox('password_reset', t('Enable "Forget Password"'), 1, $values['password_reset'] == 1) ?>
<?= $this->form->label(t('Custom Stylesheet'), 'application_stylesheet') ?>
diff --git a/app/Template/event/events.php b/app/Template/event/events.php
index aec0b29e..bbb01be4 100644
--- a/app/Template/event/events.php
+++ b/app/Template/event/events.php
@@ -14,7 +14,7 @@
<?php elseif ($this->text->contains($event['event_name'], 'comment')): ?>
<i class="fa fa-comments-o"></i>
<?php endif ?>
- &nbsp;<?= dt('%B %e, %Y at %k:%M %p', $event['date_creation']) ?>
+ &nbsp;<?= $this->dt->datetime($event['date_creation']) ?>
</p>
<div class="activity-content"><?= $event['event_content'] ?></div>
</div>
diff --git a/app/Template/file/show.php b/app/Template/file/show.php
index b87739a8..7a4d38b4 100644
--- a/app/Template/file/show.php
+++ b/app/Template/file/show.php
@@ -14,7 +14,7 @@
</div>
<p>
<?= $this->e($file['name']) ?>
- <span class="tooltip" title='<?= t('uploaded by: %s', $file['user_name'] ?: $file['username']).'<br>'.t('uploaded on: %s', dt('%B %e, %Y at %k:%M %p', $file['date'])).'<br>'.t('size: %s', $this->text->bytes($file['size'])) ?>'>
+ <span class="tooltip" title='<?= t('uploaded by: %s', $file['user_name'] ?: $file['username']).'<br>'.t('uploaded on: %s', $this->dt->datetime($file['date'])).'<br>'.t('size: %s', $this->text->bytes($file['size'])) ?>'>
<i class="fa fa-info-circle"></i>
</span>
</p>
@@ -38,7 +38,7 @@
<td><i class="fa <?= $this->file->icon($file['name']) ?> fa-fw"></i></td>
<td>
<?= $this->e($file['name']) ?>
- <span class="tooltip" title='<?= t('uploaded by: %s', $file['user_name'] ?: $file['username']).'<br>'.t('uploaded on: %s', dt('%B %e, %Y at %k:%M %p', $file['date'])).'<br>'.t('size: %s', $this->text->bytes($file['size'])) ?>'>
+ <span class="tooltip" title='<?= t('uploaded by: %s', $file['user_name'] ?: $file['username']).'<br>'.t('uploaded on: %s', $this->dt->datetime($file['date'])).'<br>'.t('size: %s', $this->text->bytes($file['size'])) ?>'>
<i class="fa fa-info-circle"></i>
</span>
</td>
diff --git a/app/Template/listing/show.php b/app/Template/listing/show.php
index c24110f4..e7aa5947 100644
--- a/app/Template/listing/show.php
+++ b/app/Template/listing/show.php
@@ -43,7 +43,7 @@
<?php endif ?>
</td>
<td>
- <?= dt('%B %e, %Y', $task['date_due']) ?>
+ <?= $this->dt->date($task['date_due']) ?>
</td>
<td>
<?php if ($task['is_active'] == \Kanboard\Model\Task::STATUS_OPEN): ?>
diff --git a/app/Template/notification/task_create.php b/app/Template/notification/task_create.php
index 1d834d44..fb7898fc 100644
--- a/app/Template/notification/task_create.php
+++ b/app/Template/notification/task_create.php
@@ -2,11 +2,11 @@
<ul>
<li>
- <?= dt('Created on %B %e, %Y at %k:%M %p', $task['date_creation']) ?>
+ <?= t('Created:').' '.$this->dt->datetime($task['date_creation']) ?>
</li>
<?php if ($task['date_due']): ?>
<li>
- <strong><?= dt('Must be done before %B %e, %Y', $task['date_due']) ?></strong>
+ <strong><?= t('Due date:').' '.$this->dt->date($task['date_due']) ?></strong>
</li>
<?php endif ?>
<?php if (! empty($task['creator_username'])): ?>
diff --git a/app/Template/notification/task_overdue.php b/app/Template/notification/task_overdue.php
index a231937b..d7e6ff5a 100644
--- a/app/Template/notification/task_overdue.php
+++ b/app/Template/notification/task_overdue.php
@@ -9,7 +9,7 @@
<?php else: ?>
<?= $this->e($task['title']) ?>
<?php endif ?>
- (<?= dt('%B %e, %Y', $task['date_due']) ?>)
+ (<?= $this->dt->date($task['date_due']) ?>)
<?php if ($task['assignee_username']): ?>
(<strong><?= t('Assigned to %s', $task['assignee_name'] ?: $task['assignee_username']) ?></strong>)
<?php endif ?>
diff --git a/app/Template/project/index.php b/app/Template/project/index.php
index c5dd267c..8d384e58 100644
--- a/app/Template/project/index.php
+++ b/app/Template/project/index.php
@@ -57,10 +57,10 @@
<?= $this->url->link($this->e($project['name']), 'project', 'show', array('project_id' => $project['id'])) ?>
</td>
<td>
- <?= $project['start_date'] ?>
+ <?= $this->dt->date($project['start_date']) ?>
</td>
<td>
- <?= $project['end_date'] ?>
+ <?= $this->dt->date($project['end_date']) ?>
</td>
<td>
<?php if ($project['owner_id'] > 0): ?>
diff --git a/app/Template/project/show.php b/app/Template/project/show.php
index 5f1aefc1..166b8902 100644
--- a/app/Template/project/show.php
+++ b/app/Template/project/show.php
@@ -21,15 +21,15 @@
<?php endif ?>
<?php if ($project['last_modified']): ?>
- <li><?= dt('Last modified on %B %e, %Y at %k:%M %p', $project['last_modified']) ?></li>
+ <li><?= t('Modified:').' '.$this->dt->datetime($project['last_modified']) ?></li>
<?php endif ?>
<?php if ($project['start_date']): ?>
- <li><?= t('Start date: %s', $project['start_date']) ?></li>
+ <li><?= t('Start date: ').$this->dt->date($project['start_date']) ?></li>
<?php endif ?>
<?php if ($project['end_date']): ?>
- <li><?= t('End date: %s', $project['end_date']) ?></li>
+ <li><?= t('End date: ').$this->dt->date($project['end_date']) ?></li>
<?php endif ?>
<?php if ($stats['nb_tasks'] > 0): ?>
diff --git a/app/Template/project_user/tasks.php b/app/Template/project_user/tasks.php
index f4fc2723..8d1cbd96 100644
--- a/app/Template/project_user/tasks.php
+++ b/app/Template/project_user/tasks.php
@@ -33,10 +33,10 @@
<?php endif ?>
</td>
<td>
- <?= dt('%B %e, %Y', $task['date_started']) ?>
+ <?= $this->dt->date($task['date_started']) ?>
</td>
<td>
- <?= dt('%B %e, %Y', $task['date_due']) ?>
+ <?= $this->dt->date($task['date_due']) ?>
</td>
</tr>
<?php endforeach ?>
diff --git a/app/Template/search/results.php b/app/Template/search/results.php
index 88eed87c..3bb0e603 100644
--- a/app/Template/search/results.php
+++ b/app/Template/search/results.php
@@ -38,7 +38,7 @@
<?php endif ?>
</td>
<td>
- <?= dt('%B %e, %Y', $task['date_due']) ?>
+ <?= $this->dt->date($task['date_due']) ?>
</td>
<td>
<?php if ($task['is_active'] == \Kanboard\Model\Task::STATUS_OPEN): ?>
diff --git a/app/Template/task/changes.php b/app/Template/task/changes.php
index f288a8f4..db844857 100644
--- a/app/Template/task/changes.php
+++ b/app/Template/task/changes.php
@@ -31,7 +31,7 @@
if (empty($task['date_due'])) {
echo '<li>'.t('The due date have been removed').'</li>';
} else {
- echo '<li>'.dt('New due date: %B %e, %Y', $task['date_due']).'</li>';
+ echo '<li>'.t('New due date: ').$this->dt->date($task['date_due']).'</li>';
}
break;
case 'description':
@@ -56,7 +56,7 @@
break;
case 'date_started':
if ($value != 0) {
- echo '<li>'.dt('Start date changed: %B %e, %Y', $task['date_started']).'</li>';
+ echo '<li>'.t('Start date changed: ').$this->dt->datetime($task['date_started']).'</li>';
}
break;
default:
diff --git a/app/Template/task/details.php b/app/Template/task/details.php
index 838eb260..5c2e3cff 100644
--- a/app/Template/task/details.php
+++ b/app/Template/task/details.php
@@ -79,7 +79,7 @@
<?php if ($task['date_due']): ?>
<li>
<strong><?= t('Due date:') ?></strong>
- <span><?= dt('%B %e, %Y', $task['date_due']) ?></span>
+ <span><?= $this->dt->date($task['date_due']) ?></span>
</li>
<?php endif ?>
<?php if ($task['time_estimated']): ?>
@@ -100,28 +100,28 @@
<ul class="no-bullet">
<li>
<strong><?= t('Created:') ?></strong>
- <span><?= dt('%B %e, %Y at %k:%M %p', $task['date_creation']) ?></span>
+ <span><?= $this->dt->datetime($task['date_creation']) ?></span>
</li>
<li>
<strong><?= t('Modified:') ?></strong>
- <span><?= dt('%B %e, %Y at %k:%M %p', $task['date_modification']) ?></span>
+ <span><?= $this->dt->datetime($task['date_modification']) ?></span>
</li>
<?php if ($task['date_completed']): ?>
<li>
<strong><?= t('Completed:') ?></strong>
- <span><?= dt('%B %e, %Y at %k:%M %p', $task['date_completed']) ?></span>
+ <span><?= $this->dt->datetime($task['date_completed']) ?></span>
</li>
<?php endif ?>
<?php if ($task['date_started']): ?>
<li>
<strong><?= t('Started:') ?></strong>
- <span><?= dt('%B %e, %Y at %k:%M %p', $task['date_started']) ?></span>
+ <span><?= $this->dt->datetime($task['date_started']) ?></span>
</li>
<?php endif ?>
<?php if ($task['date_moved']): ?>
<li>
<strong><?= t('Moved:') ?></strong>
- <span><?= dt('%B %e, %Y at %k:%M %p', $task['date_moved']) ?></span>
+ <span><?= $this->dt->datetime($task['date_moved']) ?></span>
</li>
<?php endif ?>
</ul>
diff --git a/app/Template/task/time_tracking_details.php b/app/Template/task/time_tracking_details.php
index 85ad5567..147c5109 100644
--- a/app/Template/task/time_tracking_details.php
+++ b/app/Template/task/time_tracking_details.php
@@ -16,8 +16,8 @@
<tr>
<td><?= $this->url->link($this->e($record['user_fullname'] ?: $record['username']), 'user', 'show', array('user_id' => $record['user_id'])) ?></td>
<td><?= t($record['subtask_title']) ?></td>
- <td><?= dt('%B %e, %Y at %k:%M %p', $record['start']) ?></td>
- <td><?= dt('%B %e, %Y at %k:%M %p', $record['end']) ?></td>
+ <td><?= $this->dt->datetime($record['start']) ?></td>
+ <td><?= $this->dt->datetime($record['end']) ?></td>
<td><?= n($record['time_spent']).' '.t('hours') ?></td>
</tr>
<?php endforeach ?>
diff --git a/app/Template/task/transitions.php b/app/Template/task/transitions.php
index 2ca2387f..d79c2fd9 100644
--- a/app/Template/task/transitions.php
+++ b/app/Template/task/transitions.php
@@ -15,7 +15,7 @@
</tr>
<?php foreach ($transitions as $transition): ?>
<tr>
- <td><?= dt('%B %e, %Y at %k:%M %p', $transition['date']) ?></td>
+ <td><?= $this->dt->datetime($transition['date']) ?></td>
<td><?= $this->e($transition['src_column']) ?></td>
<td><?= $this->e($transition['dst_column']) ?></td>
<td><?= $this->url->link($this->e($transition['name'] ?: $transition['username']), 'user', 'show', array('user_id' => $transition['user_id'])) ?></td>
diff --git a/app/Template/task_external_link/show.php b/app/Template/task_external_link/show.php
index 2dc3d1dd..12d8e4f6 100644
--- a/app/Template/task_external_link/show.php
+++ b/app/Template/task_external_link/show.php
@@ -31,7 +31,7 @@
<?= $this->e($link['creator_name'] ?: $link['creator_username']) ?>
</td>
<td>
- <?= dt('%B %e, %Y', $link['date_creation']) ?>
+ <?= $this->dt->date($link['date_creation']) ?>
</td>
<?php if ($this->user->hasProjectAccess('TaskExternalLink', 'edit', $task['project_id'])): ?>
<td>
diff --git a/app/Template/user/last.php b/app/Template/user/last.php
index 8879466e..d6c86391 100644
--- a/app/Template/user/last.php
+++ b/app/Template/user/last.php
@@ -14,7 +14,7 @@
</tr>
<?php foreach ($last_logins as $login): ?>
<tr>
- <td><?= dt('%B %e, %Y at %k:%M %p', $login['date_creation']) ?></td>
+ <td><?= $this->dt->datetime($login['date_creation']) ?></td>
<td><?= $this->e($login['auth_type']) ?></td>
<td><?= $this->e($login['ip']) ?></td>
<td><?= $this->e($login['user_agent']) ?></td>
diff --git a/app/Template/user/password_reset.php b/app/Template/user/password_reset.php
index b4c9a0c4..4e9063ef 100644
--- a/app/Template/user/password_reset.php
+++ b/app/Template/user/password_reset.php
@@ -15,8 +15,8 @@
</tr>
<?php foreach ($tokens as $token): ?>
<tr>
- <td><?= dt('%B %e, %Y at %k:%M %p', $token['date_creation']) ?></td>
- <td><?= dt('%B %e, %Y at %k:%M %p', $token['date_expiration']) ?></td>
+ <td><?= $this->dt->datetime($token['date_creation']) ?></td>
+ <td><?= $this->dt->datetime($token['date_expiration']) ?></td>
<td><?= $token['is_active'] == 0 ? t('No') : t('Yes') ?></td>
<td><?= $this->e($token['ip']) ?></td>
<td><?= $this->e($token['user_agent']) ?></td>
diff --git a/app/Template/user/sessions.php b/app/Template/user/sessions.php
index 7a66c5ad..8db02430 100644
--- a/app/Template/user/sessions.php
+++ b/app/Template/user/sessions.php
@@ -15,8 +15,8 @@
</tr>
<?php foreach ($sessions as $session): ?>
<tr>
- <td><?= dt('%B %e, %Y at %k:%M %p', $session['date_creation']) ?></td>
- <td><?= dt('%B %e, %Y at %k:%M %p', $session['expiration']) ?></td>
+ <td><?= $this->dt->datetime($session['date_creation']) ?></td>
+ <td><?= $this->dt->datetime($session['expiration']) ?></td>
<td><?= $this->e($session['ip']) ?></td>
<td><?= $this->e($session['user_agent']) ?></td>
<td><?= $this->url->link(t('Remove'), 'User', 'removeSession', array('user_id' => $user['id'], 'id' => $session['id']), true) ?></td>
diff --git a/app/Template/user/timesheet.php b/app/Template/user/timesheet.php
index 5c0d3af8..4a6e42c5 100644
--- a/app/Template/user/timesheet.php
+++ b/app/Template/user/timesheet.php
@@ -18,8 +18,8 @@
<tr>
<td><?= $this->url->link($this->e($record['task_title']), 'task', 'show', array('project_id' => $record['project_id'], 'task_id' => $record['task_id'])) ?></td>
<td><?= $this->url->link($this->e($record['subtask_title']), 'task', 'show', array('project_id' => $record['project_id'], 'task_id' => $record['task_id'])) ?></td>
- <td><?= dt('%B %e, %Y at %k:%M %p', $record['start']) ?></td>
- <td><?= dt('%B %e, %Y at %k:%M %p', $record['end']) ?></td>
+ <td><?= $this->dt->datetime($record['start']) ?></td>
+ <td><?= $this->dt->datetime($record['end']) ?></td>
<td><?= n($record['time_spent']).' '.t('hours') ?></td>
</tr>
<?php endforeach ?>