diff options
16 files changed, 575 insertions, 1 deletions
diff --git a/Master/texmf-dist/doc/latex/bankstatement/201412.csv b/Master/texmf-dist/doc/latex/bankstatement/201412.csv new file mode 100644 index 00000000000..fe7b9485cf4 --- /dev/null +++ b/Master/texmf-dist/doc/latex/bankstatement/201412.csv @@ -0,0 +1,10 @@ +"Auftragskonto";"Buchungstag";"Valutadatum";"Buchungstext";"Verwendungszweck";"Glaeubiger ID";"Mandatsreferenz";"Kundenreferenz (End-to-End)";"Sammlerreferenz";"Lastschrift Ursprungsbetrag";"Auslagenersatz Ruecklastschrift";"Beguenstigter/Zahlungspflichtiger";"Kontonummer/IBAN";"BIC (SWIFT-Code)";"Betrag";"Waehrung";"Info" +"240408336";"30.12.14";"01.01.15";"ABSCHLUSS";"Abrechnung 30.12.2014 siehe Anlage ";"";"";"";"";"";"";"";"0240408336";"62841530";"0,00";"EUR";"Umsatz gebucht" +"240408336";"30.12.14";"01.01.15";"ENTGELTABSCHLUSS";"Entgeltabrechnung siehe Anlage ";"";"";"";"";"";"";"";"0000000000";"62841530";"-2,50";"EUR";"Umsatz gebucht" +"240408336";"18.12.14";"18.12.14";"FOLGELASTSCHRIFT";"302-4433811-1222731 Amazon.de 1045123487483681 ";"DE24ZZZ00000561652";"v:Bs73iT6BOB1wnSrLHmN7QpAe6c19";"1045684687483681";"";"";"";"AMAZON EU S.A.R.L. 5 RUE PLAETIS";"DE51300308801938072015";"TUBDDEDD";"-19,90";"EUR";"Umsatz gebucht" +"240408336";"16.12.14";"16.12.14";"GUTSCHRIFT";"ebayDDR2 Speicherriegel ";"";"";"ZV0100172628619600000002";"";"";"";"Hubert Schmidt";"DE90370100500236608109";"PBNKDEFFXXX";"7,54";"EUR";"Umsatz gebucht" +"240408336";"10.12.14";"10.12.14";"ERSTLASTSCHRIFT";"1000138169 Rechnung EDEKA mobil ";"DE26ZZZ00000006194";"EDEL01063189";"1000138169";"";"";"";"Vodafone GmbH";"DE91300400000174585007";"COBADEFF300";"-9,99";"EUR";"Umsatz gebucht" +"240408336";"08.12.14";"08.12.14";"ONLINE-UEBERWEISUNG";"Ebay 141671448786 klejo2011 Bahn Extra 06 2014 DATUM 08.12.2014, 15.55 UHR1.TAN 085028 ";"";"";"";"";"";"";"Reinhold Zwack";"DE02750905000024965237";"GENODEF1S05";"-9,58";"EUR";"Umsatz gebucht" +"240408336";"02.12.14";"02.12.14";"FOLGELASTSCHRIFT";"PP.6422.PP . elefantenbaby29, Ihr Einkauf bei elefantenbaby29, Artikel-321512375783 ";"LU96ZZZ0000000000000000058";"44X2224NAC48U";"YYIJ222223N6KX7N PP.6422.PP PAYPAL";"";"";"";"PayPal Europe S.a.r.l. et Cie S.C.A";"DE88500700100175526303";"DEUTDEFFXXX";"-18,60";"EUR";"Umsatz gebucht" +"240408336";"02.12.14";"02.12.14";"EINZAHLUNG";"SB-EINZAHLUNG ErdingW2 GA 2121 / 02.12.14 18.28.520240408336 / 1812 /0 / 0 ";"";"";"";"";"";"";"";"0240408336";"62841530";"150,00";"EUR";"Umsatz gebucht" +"240408336";"01.12.14";"29.11.14";"ENTGELTABSCHLUSS";"Entgeltabrechnung siehe Anlage ";"";"";"";"";"";"";"";"0000000000";"62841530";"-2,50";"EUR";"Umsatz gebucht" diff --git a/Master/texmf-dist/doc/latex/bankstatement/README b/Master/texmf-dist/doc/latex/bankstatement/README new file mode 100644 index 00000000000..2827552abcc --- /dev/null +++ b/Master/texmf-dist/doc/latex/bankstatement/README @@ -0,0 +1,14 @@ +More and more banks allow their customers to download posting +records in various formats. By using the bankstatement class, +you can create bank statements -- as long as a csv format is +available! At the moment, the csv-mt940 and csv-camt formats +- used by many german Sparkassen - are supported. You can +quite easily add support for other csv formats. Simply define +the order of the keys in the csv data file and how to use them. + +The terminology in this class like BIC (Business Identifier +Codes) or IBAN (International Bank Account Number) is based on +SEPA (Single Euro Payments Area). But you can adjust the +terminology to suit your needs. + +License: LPPL
\ No newline at end of file diff --git a/Master/texmf-dist/doc/latex/bankstatement/bankstatement-example.pdf b/Master/texmf-dist/doc/latex/bankstatement/bankstatement-example.pdf Binary files differnew file mode 100644 index 00000000000..60147e87541 --- /dev/null +++ b/Master/texmf-dist/doc/latex/bankstatement/bankstatement-example.pdf diff --git a/Master/texmf-dist/doc/latex/bankstatement/bankstatement-example.tex b/Master/texmf-dist/doc/latex/bankstatement/bankstatement-example.tex new file mode 100644 index 00000000000..661ed69d73a --- /dev/null +++ b/Master/texmf-dist/doc/latex/bankstatement/bankstatement-example.tex @@ -0,0 +1,18 @@ +\documentclass[a4paper,10pt,bic=BYLADEM1ERD, + iban=DE70753574230240408336, + holder={Josef Kleber}, + language=german,logo=stmlogo, + format=csv-camt, + logowidth=4cm,negativecolor=red] + {bankstatement} +\usepackage[german]{babel} +\usepackage[utf8]{inputenc} +\usepackage[T1]{fontenc} +\usepackage{textcomp} +\usepackage{bera} +\renewcommand\familydefault{\sfdefault} +\begin{document} +\bankstatement[title={Kontoauszug 12/2014}, + openingbalance={-12,34}, + closingbalance={82,13}]{201412.csv} +\end{document}
\ No newline at end of file diff --git a/Master/texmf-dist/doc/latex/bankstatement/bankstatement.pdf b/Master/texmf-dist/doc/latex/bankstatement/bankstatement.pdf Binary files differnew file mode 100644 index 00000000000..752c7c4260f --- /dev/null +++ b/Master/texmf-dist/doc/latex/bankstatement/bankstatement.pdf diff --git a/Master/texmf-dist/doc/latex/bankstatement/bankstatement.tex b/Master/texmf-dist/doc/latex/bankstatement/bankstatement.tex new file mode 100644 index 00000000000..0ad53c2ad90 --- /dev/null +++ b/Master/texmf-dist/doc/latex/bankstatement/bankstatement.tex @@ -0,0 +1,279 @@ +\documentclass[a4paper]{ltxdoc}% +\usepackage[english]{babel}% +\usepackage[latin1]{inputenc}% +\usepackage[T1]{fontenc}% +\usepackage{textcomp}% +\usepackage{lmodern}% +\usepackage{bera}% +\usepackage{microtype}% +\usepackage{ltxdocext}% +\usepackage{marginnote}% +\usepackage[svgnames,rgb]{xcolor}% +\usepackage{amsmath,array}% +\usepackage{tikz}% +\usepackage{listings}% +\usepackage{filecontents}% +\usetikzlibrary{calc}% +\usepackage{ragged2e}% +\usepackage{url}% +\usepackage[automark,nouppercase]{scrpage2} +\usepackage{hyperref} +% +\begin{filecontents}{bankstatement.bib} +@misc{bib:datatool, + author = {Talbot, {Nicola L.C.}}, + note = {\href{http://mirrors.ctan.org/macros/latex/contrib/datatool/datatool-user.pdf}{http://mirrors.ctan.org/macros/latex/contrib/datatool/datatool-user.pdf}}, + title = {{User Manual for datatool bundle version 2.22}}, + year = {2014}, + } + +@misc{bib:sepa, + author = {{wikipedia.org}}, + note = {\href{https://en.wikipedia.org/wiki/Single_Euro_Payments_Area}{https://en.wikipedia.org/wiki/Single\_Euro\_Payments\_Area}}, + title = {{Single Euro Payments Area}}, + year = {2014}, + } + +@misc{bib:bic, + author = {{wikipedia.org}}, + note = {\href{https://en.wikipedia.org/wiki/ISO_9362}{https://en.wikipedia.org/wiki/ISO\_9362}}, + title = {{ISO 9362}}, + year = {2014}, + } + +@misc{bib:iban, + author = {{wikipedia.org}}, + note = {\href{https://en.wikipedia.org/wiki/International_Bank_Account_Number}{https://en.wikipedia.org/wiki/International\_Bank\_Account\_Number}}, + title = {{International Bank Account Number}}, + year = {2014}, + } + +\end{filecontents} +\makeatletter +\setlength{\headheight}{1.1\baselineskip}% +% +\hypersetup{colorlinks=true,urlcolor=NavyBlue,linkcolor=NavyBlue,citecolor=CornflowerBlue,naturalnames=true,hypertexnames=false}% +\renewcommand{\maketitle}% +{% + \thispagestyle{empty}% + \pagecolor{Ivory}% + \begin{titlepage}% + \begin{tikzpicture}[remember picture,overlay]% + \node[yshift=-2cm] at (current page.north west)% + {% + \begin{tikzpicture}[remember picture, overlay]% + \draw[fill=CornflowerBlue,color=CornflowerBlue] (0,0) rectangle% + (\paperwidth,2cm);% + \draw[anchor=west,yshift=-4cm,xshift=3cm,color=NavyBlue] (0,0) node% + {\parbox{15cm}{\RaggedRight\Huge\sffamily\textbf{\@title}}};% + \draw[anchor=west,yshift=-6cm,xshift=3cm,color=NavyBlue] (0,0) node% + {\parbox{15cm}{\huge\sffamily\textbf{\@fileversion}}};% + \draw[anchor=west,yshift=-9cm,xshift=3cm,color=NavyBlue] (0,0) node% + {\parbox{15cm}{\RaggedRight\huge\sffamily\textbf{\@subtitle}}};% + \draw[anchor=west,yshift=-14cm,xshift=3cm,color=NavyBlue] (0,0) node% + {\parbox{15cm}{\huge\sffamily\textbf{\@date}}};% + \draw[anchor=west,yshift=-20cm,xshift=3cm,color=NavyBlue] (0,0) node% + {\parbox{15cm}{\Large\sffamily{\@authorline\\\textbf{\@author}}}};% + \end{tikzpicture}% + };% + \node[yshift=0cm] at (current page.south west)% + {% + \begin{tikzpicture}[remember picture, overlay]% + \draw[fill=NavyBlue,color=NavyBlue,yshift=6cm,xshift=2cm] (0,0) rectangle (0.2cm,19cm);% + \draw[fill=CornflowerBlue,color=CornflowerBlue] (0,0) rectangle (\paperwidth,2cm);% + \draw[anchor=west,yshift=1cm,xshift=3cm,color=NavyBlue] (0,0) node% + {\parbox{15cm}{\large\sffamily{\@refline}}};% + \end{tikzpicture}% + };% + \end{tikzpicture}% + \end{titlepage}% + \pagecolor{white}% +}% +% +\newcommand*{\@tikzhead}[1]% +{% + \begin{tikzpicture}[remember picture,overlay]% + \node[yshift=-2cm] at (current page.north west)% + {% + \begin{tikzpicture}[remember picture, overlay]% + \draw[fill=CornflowerBlue] (0,0) rectangle (\paperwidth,2cm);% + \draw[anchor=west,yshift=1cm,xshift=1.5cm,color=NavyBlue] (0,0) node% + {\parbox{15cm}{\LARGE\sffamily\textbf{\@title}}};% + \node[anchor=east,xshift=.9\paperwidth,rectangle,% + rounded corners=15pt,inner sep=11pt,fill=NavyBlue]% + {\color{white}\textsc{#1}};% + \end{tikzpicture}% + };% + \end{tikzpicture}% +}% +\clearscrheadings% +\ihead{\@tikzhead{\headmark}}% +\cfoot{\upshape\thepage}% +\pagestyle{scrheadings}% +% +%\newcommand*{\headline}[1]{\@mkboth{\MakeUppercase{#1}}{\MakeUppercase{#1}}}% +\newcommand*{\Headline}[1]{\@mkboth{#1}{#1}}% +% +\renewcommand{\headfont}{\normalfont\mdseries\scshape} +% +\gdef\@subtitle{}% +\providecommand*{\Subtitle}[1]{\gdef\@subtitle{#1}}% +\gdef\@fileversion{}% +\providecommand*{\Fileversion}[1]{\gdef\@fileversion{#1}}% +\gdef\@author{}% +\providecommand*{\Author}[1]{\gdef\@author{#1}}% +\gdef\@authorline{Package author:}% +\providecommand*{\Authorline}[1]{\gdef\@authorline{#1}}% +\gdef\@refline{}% +\providecommand*{\Refline}[1]{\gdef\@refline{#1}}% +\gdef\and{\unskip{}, }% +\newcommand\doubledash{-\kern0.5pt-} +\def\enoteformat{\rightskip\z@ \leftskip\z@ \parindent=1em\leavevmode\llap{\makeenmark}} +\makeatother +% +\def\filename{bankstatement.cls}% +\def\XeLaTeX{Xe\LaTeX}% +% +\makeatletter% +\renewcommand\tableofcontents% +{% + %\section*{\contentsname}% + \@mkboth{% + \MakeUppercase\contentsname}{\MakeUppercase\contentsname}% + \@starttoc{toc}% +}% +% +\newcommand\styleoption{\name@idx{style option}}% +\newcommand\stylename{\name@idx{document style}}% +\def\name@idx#1#2{% + {\ttfamily#2}% + \index{#2\space#1=\string\ttt{#2}\space#1}\index{#1>#2=\string\ttt{#2}}% +}% +\newcommand*\margcs[1]{\marginnote{\raggedleft\scriptsize #1}}% +\newcommand*\package[1]{\texttt{#1}\index{#1=\string\ttt{#1}}}% +\newcommand*\mco[1]{\mbox{\LANGLE\itshape#1\RANGLE}\index{#1, class option value}\index{class option value>#1}}% +% +\renewcommand\@biblabel[1]{\makebox[1.5cm][l]{[#1]}} +\renewcommand*\l@subsection{\@dottedtocline{2}{1.2em}{2.3em}} +\renewcommand*\l@subsubsection{\@dottedtocline{3}{2.4em}{3.7em}} +\makeatother +% +\setlength\parindent{0pt}% +\hypersetup{pdfauthor={Josef Kleber},pdftitle={A LaTeX class for bank statements based on csv data},pdfsubject={Documentation for LaTeX class \filename}}% +\lstset{language=[LaTeX]TeX,numbers=left,numberstyle=\tiny, basicstyle=\ttfamily, aboveskip=\baselineskip, frame=single, backgroundcolor=\color{LightGoldenrodYellow}, keywordstyle=\color{Blue}, +emph={bankstatement},emphstyle=\color{Tomato}, +emph={[2]logo,bic,iban,holder,title,language,10pt,a4paper,format,logowidth,negativecolor,openingbalance,closingbalance},emphstyle={[2]\color{OliveDrab}}, +morekeywords={bankstatement}} +\begin{document} +\bibliographystyle{alphadin} +\title{\filename}% +\Subtitle{A \LaTeX{} class for bank statements based on csv data}% +\author{Josef Kleber} +\Fileversion{v0.9.1} +\Refline{\href{mailto:josef.kleber@gmx.de}{\texttt{josef.kleber@gmx.de}}\\\href{https://bitbucket.org/kleberj/bankstatement/}{\texttt{https://bitbucket.org/kleberj/bankstatement/}}} +\date{07.01.2015} +\maketitle +\Headline{Abstract} +\begin{abstract} +More and more banks allow their customers to download posting records in various formats. +By using the \texttt{bankstatement} class, you can create bank statements -- as long as a csv format is available! +At the moment, the \texttt{csv-mt940} \texttt{and csv-camt} formats -- used by many german Sparkassen -- are supported. +You can quite easily add support for other csv formats. +Simply define the order of the keys in the csv data file and how to use them. + +The terminology in this class like BIC (Business Identifier Codes) or IBAN (International Bank Account Number) is based on SEPA (Single Euro Payments Area). +But you can adjust the terminology to suit your needs. +\end{abstract} +\clearpage +\tableofcontents +\clearpage +\section{Class options} + +\begin{description} +\item[format (\texttt{csv-mt940})] specifies the csv format of your data files +\item[language (\texttt{english})] specifies the language of your document +\item[left (\texttt{2cm})] specifies the left margin +\item[right (\texttt{2cm})] specifies the right margin +\item[top (\texttt{2cm})] specifies the top margin +\item[bottom (\texttt{2cm})] specifies the bottom margin +\end{description} + +\section{The \texttt{bankstatement} command} +The \cmd\bankstatement{}\marginnote{\cmd\bankstatement\\\oarg{options}\{\marg{csv file}\}} command reads in \marg{csv file} and outputs your bank statement. +It supports the following options, which can also be used as class options with global scope: + +\begin{description} +\item[title (\texttt{})] specifies the title of your bank statement +\item[logo (\texttt{})] specifies the logo used in the bank statement. It may be the logo of your bank or the sports club, whose treasurer you are. +\item[logowidth (\texttt{4cm})] defines the width of the logo +\item[holder (\texttt{})] specifies the account holder +\item[bic (\texttt{})] specisfies the BIC (Business Identifier Codes) +\item[iban (\texttt{})] specifies the IBAN (International Bank Account Number) +\item[referencewidth (\texttt{11cm})] specifies the width of the second table column used for the reference. Depending on page size, margins and font you may need to adjust the width. +\item[negativecolor (\texttt{red})] specifies the color used for negative amounts +\item[sort (\texttt{PostingDate})] defines the sort key of the csv data base +\item[openingbalance (\texttt{none})] specifies the opening balance. csv posting records do not contain an opening balance, only postings. +\item[closingbalance (\texttt{none})] specifies the closing balance +\end{description} + +Make sure to use the same encoding in your document than in the csv file(s)! + +\section{Customization} + +You can quite easily add support for other languages and formats. Please send a copy to the maintainer of \texttt{bankstatement}. + +\subsection{Languages} + +Supported languages: + +\begin{itemize} +\item \texttt{\bfseries english} +\item \texttt{german} +\end{itemize} + +To support other languages, simply copy \texttt{stmenglish.def} to your local \TeX{} tree, rename it and translate the definitions to your language! + +\subsection{Formats} + +Supported formats: + +\begin{itemize} +\item \texttt{\bfseries csv-mt940} +\item \texttt{csv-camt} +\end{itemize} + +To support other formats, simply copy \texttt{csv-mt940.def} to your local \TeX{} tree, rename it and adjust the definitions to your needs! +That is, define the order of keys in your format and specify how to use them. Furthermore, you should specify the separator of the csv file and whether the csv file has a header row or not. + +\section{Example} + +\begin{lstlisting} +\documentclass[a4paper,10pt,bic=BYLADEM1ERD, + iban=DE70753574230240408336, + holder={Josef Kleber}, + language=german,logo=stmlogo, + format=csv-camt, + logowidth=4cm,negativecolor=red] + {bankstatement} +\usepackage[german]{babel} +\usepackage[utf8]{inputenc} +\usepackage[T1]{fontenc} +\usepackage{textcomp} +\usepackage{bera} +\renewcommand\familydefault{\sfdefault} +\begin{document} +\bankstatement[title={Kontoauszug 12/2014}, + openingbalance={-12,34}, + closingbalance={82,13}]{201412.csv} +\end{document} +\end{lstlisting} + +{ +\clearpage +\raggedright +\nocite{*} +\bibliography{bankstatement} +\addcontentsline{toc}{section}{\refname} +} + +\end{document} diff --git a/Master/texmf-dist/doc/latex/bankstatement/makefile b/Master/texmf-dist/doc/latex/bankstatement/makefile new file mode 100644 index 00000000000..ea57673d5fd --- /dev/null +++ b/Master/texmf-dist/doc/latex/bankstatement/makefile @@ -0,0 +1,45 @@ +TEXMF = $(shell kpsewhich -var-value TEXMFLOCAL) +RM = rm -f +PKGNAME = bankstatement + +all: doc example + +doc: + pdflatex $(PKGNAME) + bibtex $(PKGNAME) + pdflatex $(PKGNAME) + pdflatex $(PKGNAME) + +example: + pdflatex $(PKGNAME)-example + pdflatex $(PKGNAME)-example + + +install: doc + mkdir -p ${TEXMF}/doc/latex/${PKGNAME} + cp README ${TEXMF}/doc/latex/${PKGNAME}/ + cp *.txt ${TEXMF}/doc/latex/${PKGNAME}/ + cp *.tex ${TEXMF}/doc/latex/${PKGNAME}/ + cp *.pdf ${TEXMF}/doc/latex/${PKGNAME}/ + mkdir -p ${TEXMF}/tex/latex/${PKGNAME} + cp *.cls ${TEXMF}/tex/latex/${PKGNAME}/ + cp *.def ${TEXMF}/tex/latex/${PKGNAME}/ + texhash + +uninstall: + rm -rf ${TEXMF}/doc/latex/${PKGNAME} + rm -rf ${TEXMF}/tex/latex/${PKGNAME} + texhash + +ctan: + ./copyCTAN + +clean: + $(RM) *.aux *.fdb_latexmk *.fls *.ind *.idx *.ilg *.glo *.gls \ + *.log *.lol *.m *.out *.tmp *.toc *.sh *.hd \ + *.bbl *.blg *.ins *.txt *.bib + +cleanall: clean + $(RM) $(PKGNAME).pdf $(PKGNAME)_example.pdf + +.PHONY: all doc install uninstall ctan clean cleanall diff --git a/Master/texmf-dist/doc/latex/bankstatement/stmlogo.jpg b/Master/texmf-dist/doc/latex/bankstatement/stmlogo.jpg Binary files differnew file mode 100644 index 00000000000..cbe110af3fd --- /dev/null +++ b/Master/texmf-dist/doc/latex/bankstatement/stmlogo.jpg diff --git a/Master/texmf-dist/tex/latex/bankstatement/bankstatement.cls b/Master/texmf-dist/tex/latex/bankstatement/bankstatement.cls new file mode 100644 index 00000000000..7eba22e1852 --- /dev/null +++ b/Master/texmf-dist/tex/latex/bankstatement/bankstatement.cls @@ -0,0 +1,122 @@ +\NeedsTeXFormat{LaTeX2e}% +\ProvidesClass{bankstatement}[2015/01/07 class for csv based bank statements v0.9.1]% +% +\RequirePackage{xkeyval}% +% needed to allow xxx={yyy} in class options +\RequirePackage{xkvltxp}% +% +\newcommand*\STM@JK@define@key[4]% +{% + \expandafter\gdef\csname#1@#3\endcsname{#4}% + \define@key{#2.cls}{#3}[#4]% + {% + \expandafter\gdef\csname#1@#3\endcsname{##1}% + }% + \define@key{#2}{#3}% + {% + \expandafter\def\csname#1@#3\endcsname{##1}% + }% +}% +% +\STM@JK@define@key{STM@JK}{bankstatement}{format}{csv-mt940}% +\STM@JK@define@key{STM@JK}{bankstatement}{language}{english}% +\STM@JK@define@key{STM@JK}{bankstatement}{title}{}% +\STM@JK@define@key{STM@JK}{bankstatement}{logo}{}% +\STM@JK@define@key{STM@JK}{bankstatement}{logowidth}{4cm}% +\STM@JK@define@key{STM@JK}{bankstatement}{holder}{}% +\STM@JK@define@key{STM@JK}{bankstatement}{bic}{}% +\STM@JK@define@key{STM@JK}{bankstatement}{iban}{}% +\STM@JK@define@key{STM@JK}{bankstatement}{referencewidth}{11cm}% +\STM@JK@define@key{STM@JK}{bankstatement}{negativecolor}{red}% +\STM@JK@define@key{STM@JK}{bankstatement}{sort}{PostingDate}% +\STM@JK@define@key{STM@JK}{bankstatement}{openingbalance}{none}% +\STM@JK@define@key{STM@JK}{bankstatement}{closingbalance}{none}% +\STM@JK@define@key{STM@JK}{bankstatement}{left}{2cm}% +\STM@JK@define@key{STM@JK}{bankstatement}{right}{2cm}% +\STM@JK@define@key{STM@JK}{bankstatement}{top}{2cm}% +\STM@JK@define@key{STM@JK}{bankstatement}{bottom}{2cm}% +% +\DeclareOptionX*{\PassOptionsToClass{\CurrentOption}{article}}% +\ExecuteOptionsX{format,language,title,logo,logowidth,holder,bic,iban,referencewidth,negativecolor,sort,openingbalance,closingbalance,left,right,top,bottom}% +\ProcessOptionsX*\relax% +\LoadClass{article}% +% +\RequirePackage[left=\STM@JK@left,right=\STM@JK@right,top=\STM@JK@top,bottom=\STM@JK@bottom]{geometry}% +\RequirePackage{longtable}% +\RequirePackage{tabularx}% +\RequirePackage{xcolor}% +\RequirePackage{graphicx}% +\RequirePackage{booktabs}% +\RequirePackage{datatool}% +\RequirePackage{calc}% +\RequirePackage{ifthen}% +% +\newcommand*\STM@JK@dbkeys{}% +\newcommand*\STM@JK@DTLforeach{}% +\newcommand*\STM@JK@holdername{}% +\newcommand*\STM@JK@bicname{}% +\newcommand*\STM@JK@ibanname{}% +\newcommand*\STM@JK@firstcolumnheading{}% +\newcommand*\STM@JK@secondcolumnheading{}% +\newcommand*\STM@JK@thirdcolumnheading{}% +\newcommand*\STM@JK@openingbalancenamename{}% +\newcommand*\STM@JK@closingbalancenamename{}% +% +\newcommand*\STM@JK@headingsep{0.5cm}% +\newcommand*\STM@JK@noheader{false}% +% +\newlength\STM@JK@parspace% +\AtBeginDocument{\setlength\STM@JK@parspace{\widthof{(}}}% +\newcounter{STM@JK@count}% +% +\input{\STM@JK@format.def}% +\input{stm\STM@JK@language.def}% +% +\newcommand*\STM@JK@includelogo% +{% + \ifthenelse{\equal{\STM@JK@logo}{}}% + {}% + {\hfill\includegraphics[width=\STM@JK@logowidth]{\STM@JK@logo}}% +}% +% +\newcommand*\STM@JK@header% +{% + \noindent% + \begin{tabularx}{\textwidth}{XXr}% + \multicolumn{3}{l}{\Huge{}\hspace{.22em}\STM@JK@title\STM@JK@includelogo}\\% + & &\\% + \begin{tabular}{l}\textbf{\STM@JK@holdername}\\\STM@JK@holder\end{tabular} &% + \begin{tabular}{l}\textbf{\STM@JK@bicname}\\\STM@JK@bic\end{tabular} &% + \begin{tabular}{l}\textbf{\STM@JK@ibanname}\\\STM@JK@iban\end{tabular}\\% + \end{tabularx}% + \vspace{\STM@JK@headingsep}% +}% +% +\newcommand\bankstatement[2][]% +{% + \begingroup% + \setkeys{bankstatement}{#1}% + \stepcounter{STM@JK@count}% + \xdef\STM@JK@dbname{stm\arabic{STM@JK@count}}% + \ifthenelse{\equal{\STM@JK@noheader}{false}}% + {\DTLloaddb[keys={\STM@JK@dbkeys},noheader=false]{\STM@JK@dbname}{#2}}% + {\DTLloaddb[keys={\STM@JK@dbkeys},noheader=true]{\STM@JK@dbname}{#2}}% + \DTLsort{\STM@JK@sort}{\STM@JK@dbname}% + \STM@JK@header% + \begin{longtable}{llr}% + \toprule% + \STM@JK@firstcolumnheading &% + \STM@JK@secondcolumnheading &% + \STM@JK@thirdcolumnheading% + \\\toprule% + \endhead% + \ifthenelse{\equal{\STM@JK@openingbalance}{none}}% + {}% + { & & \\ & \STM@JK@openingbalancenamename & \DTLifStartsWith{\STM@JK@openingbalance}{-}{\textcolor{\STM@JK@negativecolor}{\STM@JK@openingbalance}}{\STM@JK@openingbalance} \\\midrule}% + \STM@JK@DTLforeach% + \end{longtable}% + \endgroup% +}% +% +\AtBeginDocument{\disable@keys{bankstatement}{format,language,left,right,top,bottom}}% +%
\ No newline at end of file diff --git a/Master/texmf-dist/tex/latex/bankstatement/csv-camt.def b/Master/texmf-dist/tex/latex/bankstatement/csv-camt.def new file mode 100644 index 00000000000..801569bcf85 --- /dev/null +++ b/Master/texmf-dist/tex/latex/bankstatement/csv-camt.def @@ -0,0 +1,36 @@ +% +% definitions for the csv-mt940 format +% +% define the order of keys in your csv file +% simply use arbitrary keys for unused fields +\renewcommand*\STM@JK@dbkeys{Account,PostingDate,ValueDate,Type,Reference,CreditorIdentifier,MandateReference,EndToEndReference,AAA,BBB,CCC,Recipient,IBAN,BIC,Amount,Currency,Info}% +% define usage of key values inside the used longtable +% dates & mixed information & amount +\renewcommand*\STM@JK@DTLforeach% +{% + \DTLforeach{\STM@JK@dbname}% + {\postingdate=PostingDate,\valuedate=ValueDate,\type=Type,\reference=Reference,\credid=CreditorIdentifier,\mref=MandateReference,\eref=EndToEndReference,\recipient=Recipient,\iban=IBAN,\bic=BIC,\amount=Amount,\currency=Currency}% + {% + \parbox[t]{\widthof{ DD.MM.YYYY }}{\hspace{\STM@JK@parspace}\postingdate\\(\valuedate)} &% + \parbox[t]{\STM@JK@referencewidth}{\raggedright% + \DTLifstringeq{\type}{}{}{\type\\}% + \DTLifstringeq{\bic}{}{-}{\bic{}}\DTLifstringeq{\iban}{}{}{ / \iban}\\% + \DTLifstringeq{\recipient}{}{}{\recipient\\}% + \DTLifstringeq{\credid}{}{}{CRED: \credid\\}% + \DTLifstringeq{\mref}{}{}{MREF: \mref\\}% + \DTLifstringeq{\eref}{}{}{EREF: \eref\\}% + \reference} &% + \DTLifStartsWith{\amount}{-}{\textcolor{\STM@JK@negativecolor}{\amount}}{\amount}% + \DTLiflastrow{% + \ifthenelse{\equal{\STM@JK@closingbalance}{none}}% + {}% + {\\\midrule\\ & \STM@JK@closingbalancenamename & \DTLifStartsWith{\STM@JK@closingbalance}{-}{\textcolor{\STM@JK@negativecolor}{\STM@JK@closingbalance}}{\STM@JK@closingbalance}}% + \\\bottomrule% + }% + {\\ & & \\}% + }% +}% +% set separator of csv file +\DTLsetseparator{;}% +% does the csv file (not) have a header row? ;-) +\renewcommand*\STM@JK@noheader{false}%
\ No newline at end of file diff --git a/Master/texmf-dist/tex/latex/bankstatement/csv-mt940.def b/Master/texmf-dist/tex/latex/bankstatement/csv-mt940.def new file mode 100644 index 00000000000..ce17e4b6c10 --- /dev/null +++ b/Master/texmf-dist/tex/latex/bankstatement/csv-mt940.def @@ -0,0 +1,33 @@ +% +% definitions for the csv-mt940 format +% +% define the order of keys in your csv file +% simply use arbitrary keys for unused fields +\renewcommand*\STM@JK@dbkeys{Account,PostingDate,ValueDate,Type,Reference,Recipient,IBAN,BIC,Amount,Currency,Info}% +% define usage of key values inside the used longtable +% dates & mixed information & amount +\renewcommand*\STM@JK@DTLforeach% +{% + \DTLforeach{\STM@JK@dbname}% + {\postingdate=PostingDate,\valuedate=ValueDate,\type=Type,\reference=Reference,\recipient=Recipient,\iban=IBAN,\bic=BIC,\amount=Amount,\currency=Currency}% + {% + \parbox[t]{\widthof{ DD.MM.YYYY }}{\hspace{\STM@JK@parspace}\postingdate\\(\valuedate)} &% + \parbox[t]{\STM@JK@referencewidth}{\raggedright% + \DTLifstringeq{\type}{}{}{\type\\}% + \DTLifstringeq{\bic}{}{-}{\bic{}}\DTLifstringeq{\iban}{}{}{ / \iban}\\% + \DTLifstringeq{\recipient}{}{}{\recipient\\}% + \reference} &% + \DTLifStartsWith{\amount}{-}{\textcolor{\STM@JK@negativecolor}{\amount}}{\amount}% + \DTLiflastrow{% + \ifthenelse{\equal{\STM@JK@closingbalance}{none}}% + {}% + {\\\midrule\\ & \STM@JK@closingbalancenamename & \DTLifStartsWith{\STM@JK@closingbalance}{-}{\textcolor{\STM@JK@negativecolor}{\STM@JK@closingbalance}}{\STM@JK@closingbalance}}% + \\\bottomrule% + }% + {\\ & & \\}% + }% +}% +% set separator of csv file +\DTLsetseparator{;}% +% does the csv file (not) have a header row? ;-) +\renewcommand*\STM@JK@noheader{false}%
\ No newline at end of file diff --git a/Master/texmf-dist/tex/latex/bankstatement/stmenglish.def b/Master/texmf-dist/tex/latex/bankstatement/stmenglish.def new file mode 100644 index 00000000000..e24df2c04b8 --- /dev/null +++ b/Master/texmf-dist/tex/latex/bankstatement/stmenglish.def @@ -0,0 +1,8 @@ +\renewcommand*\STM@JK@holdername{Account holder}% +\renewcommand*\STM@JK@bicname{BIC}% +\renewcommand*\STM@JK@ibanname{IBAN}% +\renewcommand*\STM@JK@firstcolumnheading{\bfseries Date}% +\renewcommand*\STM@JK@secondcolumnheading{\bfseries Reference}% +\renewcommand*\STM@JK@thirdcolumnheading{\bfseries Amount (GBP)}% +\renewcommand*\STM@JK@openingbalancenamename{Opening balance}% +\renewcommand*\STM@JK@closingbalancenamename{Closing balance}%
\ No newline at end of file diff --git a/Master/texmf-dist/tex/latex/bankstatement/stmgerman.def b/Master/texmf-dist/tex/latex/bankstatement/stmgerman.def new file mode 100644 index 00000000000..80129f674cc --- /dev/null +++ b/Master/texmf-dist/tex/latex/bankstatement/stmgerman.def @@ -0,0 +1,8 @@ +\renewcommand*\STM@JK@holdername{Kontoinhaber}% +\renewcommand*\STM@JK@bicname{BIC}% +\renewcommand*\STM@JK@ibanname{IBAN}% +\renewcommand*\STM@JK@firstcolumnheading{\bfseries Datum}% +\renewcommand*\STM@JK@secondcolumnheading{\bfseries Verwendungszweck}% +\renewcommand*\STM@JK@thirdcolumnheading{\bfseries Betrag (EUR)}% +\renewcommand*\STM@JK@openingbalancenamename{Anfangssaldo}% +\renewcommand*\STM@JK@closingbalancenamename{Endsaldo}%
\ No newline at end of file diff --git a/Master/tlpkg/bin/tlpkg-ctan-check b/Master/tlpkg/bin/tlpkg-ctan-check index 565adb40550..309e32a4126 100755 --- a/Master/tlpkg/bin/tlpkg-ctan-check +++ b/Master/tlpkg/bin/tlpkg-ctan-check @@ -63,7 +63,7 @@ my @TLP_working = qw( babel-serbianc babel-slovak babel-slovenian babel-sorbian babel-spanish babel-swedish babel-thai babel-turkish babel-ukraineb babel-vietnamese babel-welsh - babelbib background backnaur bagpipe bangorcsthesis bangtex + babelbib background backnaur bagpipe bangorcsthesis bangtex bankstatement barcodes bardiag barr bartel-chess-fonts bashful basicarith baskervald baskervaldx basque-book basque-date diff --git a/Master/tlpkg/tlpsrc/bankstatement.tlpsrc b/Master/tlpkg/tlpsrc/bankstatement.tlpsrc new file mode 100644 index 00000000000..e69de29bb2d --- /dev/null +++ b/Master/tlpkg/tlpsrc/bankstatement.tlpsrc diff --git a/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc b/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc index eb66f25351a..bc14a7b4ec4 100644 --- a/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc +++ b/Master/tlpkg/tlpsrc/collection-latexextra.tlpsrc @@ -51,6 +51,7 @@ depend authorindex depend autonum depend avremu depend background +depend bankstatement depend bashful depend basicarith depend bchart |