summaryrefslogtreecommitdiff
path: root/app/Template/task/details.php
blob: 838eb2608348e61a70dc3e060fe5a58685f8ec79 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
<section id="task-summary">
    <h2><?= $this->e($task['title']) ?></h2>
    <div class="task-summary-container color-<?= $task['color_id'] ?>">
        <div class="task-summary-column">
            <ul class="no-bullet">
                <li>
                    <strong><?= t('Status:') ?></strong>
                    <span>
                    <?php if ($task['is_active'] == 1): ?>
                        <?= t('open') ?>
                    <?php else: ?>
                        <?= t('closed') ?>
                    <?php endif ?>
                    </span>
                </li>
                <li>
                    <strong><?= t('Priority:') ?></strong> <span><?= $task['priority'] ?></span>
                </li>
                <?php if (! empty($task['reference'])): ?>
                    <li>
                        <strong><?= t('Reference:') ?></strong> <span><?= $this->e($task['reference']) ?></span>
                    </li>
                <?php endif ?>
                <?php if (! empty($task['score'])): ?>
                    <li>
                        <strong><?= t('Complexity:') ?></strong> <span><?= $this->e($task['score']) ?></span>
                    </li>
                <?php endif ?>
                <?php if ($project['is_public']): ?>
                <li class="smaller">
                    <i class="fa fa-external-link fa-fw"></i>
                    <?= $this->url->link(t('Public link'), 'task', 'readonly', array('task_id' => $task['id'], 'token' => $project['token']), false, '', '', true) ?>
                </li>
                <?php endif ?>
            </ul>
        </div>
        <div class="task-summary-column">
            <ul class="no-bullet">
                <?php if (! empty($task['category_name'])): ?>
                    <li>
                        <strong><?= t('Category:') ?></strong>
                        <span><?= $this->e($task['category_name']) ?></span>
                    </li>
                <?php endif ?>
                <?php if (! empty($task['swimlane_name'])): ?>
                    <li>
                        <strong><?= t('Swimlane:') ?></strong>
                        <span><?= $this->e($task['swimlane_name']) ?></span>
                    </li>
                <?php endif ?>
                <li>
                    <strong><?= t('Column:') ?></strong>
                    <span><?= $this->e($task['column_title']) ?></span>
                </li>
                <li>
                    <strong><?= t('Position:') ?></strong>
                    <span><?= $task['position'] ?></span>
                </li>
            </ul>
        </div>
        <div class="task-summary-column">
            <ul class="no-bullet">
                <li>
                    <strong><?= t('Assignee:') ?></strong>
                    <span>
                    <?php if ($task['assignee_username']): ?>
                        <?= $this->e($task['assignee_name'] ?: $task['assignee_username']) ?>
                    <?php else: ?>
                        <?= t('not assigned') ?>
                    <?php endif ?>
                    </span>
                </li>
                <?php if ($task['creator_username']): ?>
                    <li>
                        <strong><?= t('Creator:') ?></strong>
                        <span><?= $this->e($task['creator_name'] ?: $task['creator_username']) ?></span>
                    </li>
                <?php endif ?>
                <?php if ($task['date_due']): ?>
                <li>
                    <strong><?= t('Due date:') ?></strong>
                    <span><?= dt('%B %e, %Y', $task['date_due']) ?></span>
                </li>
                <?php endif ?>
                <?php if ($task['time_estimated']): ?>
                <li>
                    <strong><?= t('Time estimated:') ?></strong>
                    <span><?= t('%s hours', $task['time_estimated']) ?></span>
                </li>
                <?php endif ?>
                <?php if ($task['time_spent']): ?>
                <li>
                    <strong><?= t('Time spent:') ?></strong>
                    <span><?= t('%s hours', $task['time_spent']) ?></span>
                </li>
                <?php endif ?>
            </ul>
        </div>
        <div class="task-summary-column">
            <ul class="no-bullet">
                <li>
                    <strong><?= t('Created:') ?></strong>
                    <span><?= dt('%B %e, %Y at %k:%M %p', $task['date_creation']) ?></span>
                </li>
                <li>
                    <strong><?= t('Modified:') ?></strong>
                    <span><?= dt('%B %e, %Y at %k:%M %p', $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>
                </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>
                </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>
                </li>
                <?php endif ?>
            </ul>
        </div>
    </div>
</section>