allow tables in pdf name list to span multiple pages
authorpaul <paul@plutz.net>
Tue, 3 Feb 2015 14:01:05 +0000 (14:01 +0000)
committerpaul <paul@plutz.net>
Tue, 3 Feb 2015 14:01:05 +0000 (14:01 +0000)
svn path=/trunk/; revision=53

templates/course_print.sh

index 6eb7501..3ee01fe 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2014 Paul Hänsch
+# Copyright 2014 - 2015 Paul Hänsch
 #
 # This file is part of Confetti.
 # 
 # You should have received a copy of the GNU Affero General Public License
 # along with Confetti.  If not, see <http://www.gnu.org/licenses/>. 
 
+. ${_EXEC}/templates/text_attendee.sh
+
 echo -E '
 \documentclass[landscape,10pt]{article}
 \usepackage[utf8]{inputenc}
 \usepackage{ngerman}
 \usepackage[landscape]{geometry}
+\usepackage{longtable}
 
 \begin{document}
 
 \section*{Teilnehmende}
-\begin{tabular}{|l|l|p{50mm}|p{80mm}|}
+\begin{longtable}{|l|l|p{50mm}|p{80mm}|}
 \hline
-  \textbf{Name} &
-  \textbf{Geburtstag} &
-  \textbf{Telefon} &
-  \textbf{Notiz} \\
+  \textbf{'"$(l10n N)"'} &
+  \textbf{'"$(l10n BDAY)"'} &
+  \textbf{'"$(l10n TEL)"'} &
+  \textbf{'"$(l10n NOTE)"'} \\
 \hline
 \hline
+\endhead
 '"$(
 list_attendance "$course" |sort -k 2 |while read line; do
   cardfile="$(echo "$line" |cut -d\  -f1)"
   list_attendee "$cardfile" |sed -r 's:$:\\\\[3ex] \\hline:'
 done
 )"'
-\end{tabular}
+\end{longtable}
 
 \newpage
 
 \section*{Termine}
-\begin{tabular}{|l|c|c|c|c|c|c|c|c|c|c|}
+\begin{longtable}{|l|c|c|c|c|c|c|c|c|c|c|}
 \hline
  '"$(get_dates)"' \\
 \hline
 \hline
+\endhead
 '"$(
 list_attendance "$course" |sort -k 2 | debug |sed -r 's:^[0-9a-z\.]+ (.+) \(\*[0-9]{4}\)$:\1:;s:$: \& \& \& \& \& \& \& \& \& \& \\\\[3ex] \\hline:'
 )"'
-\end{tabular}
+\end{longtable}
 
 \end{document}
 '