export/latex: Update template.
parent
f432c5424a
commit
1361108a9e
|
@ -34,12 +34,13 @@ var exportTemplate = template.Must(template.
|
||||||
|
|
||||||
\documentclass[11pt,a4paper,oneside]{article}
|
\documentclass[11pt,a4paper,oneside]{article}
|
||||||
|
|
||||||
\usepackage{fancyhdr}
|
|
||||||
\usepackage{tabularx}
|
|
||||||
\usepackage[left=2cm,right=2cm,top=2cm,bottom=6cm,includeheadfoot]{geometry}
|
\usepackage[left=2cm,right=2cm,top=2cm,bottom=6cm,includeheadfoot]{geometry}
|
||||||
\usepackage{csquotes}
|
\usepackage{csquotes}
|
||||||
|
\usepackage{fancyhdr}
|
||||||
\usepackage{fontspec}
|
\usepackage{fontspec}
|
||||||
\usepackage{ifluatex}
|
\usepackage{ifluatex}
|
||||||
|
\usepackage{tabularx}
|
||||||
|
\usepackage{titling}
|
||||||
\ifluatex
|
\ifluatex
|
||||||
\else
|
\else
|
||||||
\usepackage[utf8]{inputenc}
|
\usepackage[utf8]{inputenc}
|
||||||
|
@ -49,8 +50,13 @@ var exportTemplate = template.Must(template.
|
||||||
\fancyhf{}
|
\fancyhf{}
|
||||||
\setlength{\headheight}{2cm}
|
\setlength{\headheight}{2cm}
|
||||||
|
|
||||||
\newcommand{\Name}{<.Project.Name>}
|
\newcommand{\department}[1]{\global\def\wrDepartment{#1}}
|
||||||
\newcommand{\Department}{<.Project.Department>}
|
\newcommand{\workreportNumber}[1]{\global\def\wrNumber{#1}}
|
||||||
|
\newcommand{\workreportDateFrom}[1]{\global\def\wrDateFrom{#1}}
|
||||||
|
\newcommand{\workreportDateTo}[1]{\global\def\wrDateTo{#1}}
|
||||||
|
|
||||||
|
\author{<.Project.Name>}
|
||||||
|
\department{<.Project.Department>}
|
||||||
|
|
||||||
\newcommand{\wrSigningField}[0]{
|
\newcommand{\wrSigningField}[0]{
|
||||||
\begin{tabularx}{\textwidth}{| X | X | X |}
|
\begin{tabularx}{\textwidth}{| X | X | X |}
|
||||||
|
@ -62,35 +68,42 @@ var exportTemplate = template.Must(template.
|
||||||
\end{tabularx}
|
\end{tabularx}
|
||||||
}
|
}
|
||||||
|
|
||||||
\newenvironment{weeklyreport}{
|
\fancypagestyle{weeklyreport} {
|
||||||
}{
|
|
||||||
\fancyfoot[C]{\wrSigningField}
|
\fancyfoot[C]{\wrSigningField}
|
||||||
}
|
}
|
||||||
|
|
||||||
\newcommand{\preweeklyreporthead}[3]{}
|
\newenvironment{weeklyreport}[3]{
|
||||||
|
\newpage
|
||||||
\newcommand{\weeklyreporthead}[3]{
|
\thispagestyle{weeklyreport}
|
||||||
\preweeklyreporthead{#1}{#2}{#3}
|
|
||||||
\fancyhead[R]{
|
\fancyhead[R]{
|
||||||
\begin{tabularx}{8cm}{rl}
|
\begin{tabularx}{8cm}{rl}
|
||||||
\textbf{<T "name">}: & \Name \\
|
\textbf{<T "name">}: & \theauthor \\
|
||||||
\textbf{<T "department">}: & \Department \\
|
\textbf{<T "department">}: & \wrDepartment \\
|
||||||
\textbf{<T "time_period">}: & #2 - #3 \\
|
\textbf{<T "time_period">}: & \wrDateFrom~-~\wrDateTo \\
|
||||||
\end{tabularx}
|
\end{tabularx}
|
||||||
}
|
}
|
||||||
\fancyfoot{}
|
|
||||||
\newpage
|
\workreportNumber{#1}
|
||||||
\setcounter{section}{#1}
|
\workreportDateFrom{#2}
|
||||||
|
\workreportDateTo{#3}
|
||||||
|
|
||||||
|
\setcounter{section}{\wrNumber}
|
||||||
\setcounter{subsection}{0}
|
\setcounter{subsection}{0}
|
||||||
\section*{<T "proof_of_education" "#1">}
|
\section*{Ausbildungsnachweis Nr. \wrNumber}
|
||||||
\addcontentsline{toc}{section}{<T "proof_of_education" "#1">}
|
\addcontentsline{toc}{section}{Ausbildungsnachweis Nr. \wrNumber}
|
||||||
|
}{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
\newcommand{\weeklyreporthead}[3]{}
|
||||||
|
|
||||||
\newcommand{\weeklyreportsection}[1]{
|
\newcommand{\weeklyreportsection}[1]{
|
||||||
\subsection*{#1}
|
\subsection*{#1}
|
||||||
}
|
}
|
||||||
|
|
||||||
<with .TexInputs>
|
<with .TexInputs>
|
||||||
|
|
||||||
|
% Includes
|
||||||
|
|
||||||
<range .>
|
<range .>
|
||||||
\input{<.>}
|
\input{<.>}
|
||||||
<end>
|
<end>
|
||||||
|
@ -100,8 +113,7 @@ var exportTemplate = template.Must(template.
|
||||||
\tableofcontents
|
\tableofcontents
|
||||||
|
|
||||||
<range $index, $week := .Project.Weeks>
|
<range $index, $week := .Project.Weeks>
|
||||||
\begin{weeklyreport}
|
\begin{weeklyreport}{<add $index 1>}{<beginofweek $week.Date>}{<endofweek $week.Date>}
|
||||||
\weeklyreporthead{<add $index 1>}{<beginofweek $week.Date>}{<endofweek $week.Date>}
|
|
||||||
|
|
||||||
\weeklyreportsection{<T "operational_activities">}
|
\weeklyreportsection{<T "operational_activities">}
|
||||||
<with $week.WorkActivities>
|
<with $week.WorkActivities>
|
||||||
|
|
Loading…
Reference in New Issue