new structure to statement.tex
authorMarei Peischl <marei@peitex.de>
Sun, 12 Jan 2020 22:07:53 +0000 (23:07 +0100)
committerJan Büren <jan@kivitendo.de>
Mon, 3 Feb 2020 11:21:39 +0000 (12:21 +0100)
statement.tex

index c895fe8..eb50804 100644 (file)
 
 \begin{document}
 
-\begin{minipage}[t]{8cm}
-  \vspace*{1.0cm}
-
-  <%name%>
-
-  <%street%>
-
-  ~
-
-  <%zipcode%> <%city%>
-
-  <%country%>
-\end{minipage}
-\hfill
-\begin{minipage}[t]{6cm}
-  \hfill{\LARGE\textbf{\sammelrechnung}}
-
-  \vspace*{0.2cm}
-
-  \ansprechpartner:\hfill <%employee_name%>
-\end{minipage}
-
-\vspace*{1.5cm}
-
-\hfill
+\setkomavar{title}{
+       \sammelrechnung~
+       \nr~<%quonumber%>
+}
+\setkomavar{transaction}{<%transaction_description%>}
+\setkomavar{customer}{<%customernumber%>}
+\setkomavar{fromname}{<%employee_name%>}
+\setkomavar{fromphone}{<%employee_tel%>}
+\setkomavar{fromemail}{<%employee_email%>}
+
+
+\begin{letter}{
+               <%name%>\strut\\
+               <%if department_1%><%department_1%>\\<%end if%>
+               <%if department_2%><%department_2%>\\<%end if%>
+               <%cp_givenname%> <%cp_name%>\strut\\
+               <%street%>\strut\\
+               <%zipcode%> <%city%>\strut\\
+               <%country%> \strut
+       }
 
 % Anrede nach Geschlecht unterscheiden
-\ifthenelse{\equal{<%cp_name%>}{}}{\anrede}{
-  \ifthenelse{\equal{<%cp_gender%>}{f}}
-    {\anredefrau}{\anredeherr} <%cp_title%> <%cp_name%>,}\\
-
-\sammelrechnungsformel\\
-
-\vspace{0.5cm}
-
+\opening{
+       \ifstr{<%cp_name%>}{}
+               {\anrede}
+               {
+                       \ifstr{<%cp_gender%>}{f}
+                               {\anredefrau}
+                               {\anredeherr}
+                               <%cp_title%> <%cp_name%>,
+               }
+}
+\thispagestyle{kivitendo.letter.first}
+
+\sammelrechnungsformel
 
 %
 % - longtable kann innerhalb der Tabelle umbrechen
 \end{longtable}
 
 
-\vspace{0.2cm}
+\closing{\gruesse}
 
-\gruesse \\ \\ \\
-  <%employee_name%>
+\end{letter}
 
 \end{document}