Mercurial > getan > getan
annotate getan/templates/zeiterfassung-hierarchy1 @ 568:e7b36e596751 tip
Last week's year is not necessarily today's year
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Mon, 03 Jan 2022 11:37:31 +0100 |
parents | 1a179ed1c9d7 |
children |
rev | line source |
---|---|
553
1a179ed1c9d7
Improve getan-report templates
Bernhard Reiter <bernhard@intevation.de>
parents:
549
diff
changeset
|
1 {#- using project keys as zeiterfassung's workpackages |
540
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
2 -#} |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
3 {%- for day, day_entries |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
4 in entries|sort(attribute='startisoday')|groupby('startisoday') -%} |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
5 {%- for project in projects -%} |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
6 {%- for project_id, project_day_entries |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
7 in day_entries|sort(attribute='project_id')|groupby('project_id') %} |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
8 |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
9 {%- if project_id == project.id -%} |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
10 {%- for entry in project_day_entries -%} |
553
1a179ed1c9d7
Improve getan-report templates
Bernhard Reiter <bernhard@intevation.de>
parents:
549
diff
changeset
|
11 {{ entry.start|date_format }} {{ |
1a179ed1c9d7
Improve getan-report templates
Bernhard Reiter <bernhard@intevation.de>
parents:
549
diff
changeset
|
12 (entry.get_duration()|human_time).rjust(5) |
1a179ed1c9d7
Improve getan-report templates
Bernhard Reiter <bernhard@intevation.de>
parents:
549
diff
changeset
|
13 }}h a {{ user.ljust(3) }} [{{ project.key }}] {{ |
1a179ed1c9d7
Improve getan-report templates
Bernhard Reiter <bernhard@intevation.de>
parents:
549
diff
changeset
|
14 entry.get_comment() |
1a179ed1c9d7
Improve getan-report templates
Bernhard Reiter <bernhard@intevation.de>
parents:
549
diff
changeset
|
15 }}{{'\n'}} |
1a179ed1c9d7
Improve getan-report templates
Bernhard Reiter <bernhard@intevation.de>
parents:
549
diff
changeset
|
16 {%- endfor -%} |
540
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
17 {%- endif -%} |
553
1a179ed1c9d7
Improve getan-report templates
Bernhard Reiter <bernhard@intevation.de>
parents:
549
diff
changeset
|
18 |
540
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
19 {%- endfor -%} |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
20 {%- endfor -%} |
91aaf455c44e
Add new template zeiterfassung-hierarchy1
Bernhard Reiter <bernhard@intevation.de>
parents:
diff
changeset
|
21 {% endfor -%} |