From 2fe16959c1572aff59745ce3e7616166cb34c1c2 Mon Sep 17 00:00:00 2001 From: Dominik George <dominik.george@teckids.org> Date: Thu, 30 Nov 2017 15:46:49 +0100 Subject: [PATCH] Add attendance list. --- .../templates/ticdesk_org/list_attendance.tex | 23 +++++++++++++++++++ .../ticdesk_org/list_participants.tex | 2 +- .../templates/ticdesk_org/persons.html | 2 ++ 3 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 ticdesk_org/templates/ticdesk_org/list_attendance.tex diff --git a/ticdesk_org/templates/ticdesk_org/list_attendance.tex b/ticdesk_org/templates/ticdesk_org/list_attendance.tex new file mode 100644 index 0000000..34c609d --- /dev/null +++ b/ticdesk_org/templates/ticdesk_org/list_attendance.tex @@ -0,0 +1,23 @@ +{% load i18n latex_helpers %} +{% autoescape off %} +\documentclass{teckidsproto} + +\usepackage{tabu} +\usepackage{longtable} +\geometry{landscape} + +\usepackage[export]{adjustbox} + +\keineseitenzahlenbeginn +\begin{document} + \teckidshead{ {{ group.display_name }} \dash {% blocktrans %}Anwesenheitsliste{% endblocktrans %} } + + \begin{longtabu} to \linewidth {|l|l|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|X|} +\hline\rowfont\bfseries Nachname & Vorname & & & & & & & & & & & & & & & & & & & & & & & & & & & & & & \\[1cm]\hline +\endhead +{% for person in persons|dictsort:"sn" %} +\nohyphens{ {{ person.sn }} } & \nohyphens{ {{ person.given_name }} } & & & & & & & & & & & & & & & & & & & & & & & & & & & & & & \\\hline +{% endfor %} + \end{longtabu} +\end{document} +{% endautoescape %} diff --git a/ticdesk_org/templates/ticdesk_org/list_participants.tex b/ticdesk_org/templates/ticdesk_org/list_participants.tex index f8654be..e35709d 100644 --- a/ticdesk_org/templates/ticdesk_org/list_participants.tex +++ b/ticdesk_org/templates/ticdesk_org/list_participants.tex @@ -16,7 +16,7 @@ \hline\rowfont\bfseries Foto & Nachname & Vorname & Geburts\-datum & Benutzer & Schule & Klasse \\\hline \endhead {% for person in persons|dictsort:"sn" %} -\parbox[c][3cm]{2.25cm}{\includegraphics[width=2.24cm,height=2.99cm,keepaspectratio=true,valign=c]{{ person.jpeg_photo__rel|embrace }}} & \nohyphens{ {{ person.sn }} } & \nohyphens{ {{ person.given_name }} } & \nohyphens{ {{ person.date_of_birth }} } & \texttt{ {{ person.uid }} } & \nohyphens{ {{ person.o }}, {{ person.l}} & {{ person.ou }} } \\\hline +\parbox[c][3cm]{2.25cm}{\includegraphics[width=2.24cm,height=2.99cm,keepaspectratio=true,valign=c]{{ person.jpeg_photo__rel|embrace }}} & \nohyphens{ {{ person.sn }} } & \nohyphens{ {{ person.given_name }} } & \nohyphens{ {{ person.date_of_birth }} } & \texttt{ {{ person.uid }} } & \nohyphens{ {{ person.o }} }, \nohyphens{ {{ person.l}} } & \nohyphens{ {{ person.ou }} } \\\hline {% endfor %} \end{longtabu} \end{document} diff --git a/ticdesk_org/templates/ticdesk_org/persons.html b/ticdesk_org/templates/ticdesk_org/persons.html index 1dcd8c7..8654741 100644 --- a/ticdesk_org/templates/ticdesk_org/persons.html +++ b/ticdesk_org/templates/ticdesk_org/persons.html @@ -20,6 +20,8 @@ · PDF ( <a href="{% url 'persons_by_group' group.cn %}?format=pdf&template=list_participants">{% blocktrans %}Teilnehmerliste{% endblocktrans %}</a> + · + <a href="{% url 'persons_by_group' group.cn %}?format=pdf&template=list_attendance">{% blocktrans %}Anwesenheitsliste{% endblocktrans %}</a> ) </p> -- GitLab