Annotation of RT/Invoicing/invoice.tex.tt, Revision 1.6
1.1 andrew 1: [% USE Latex -%]
2: [% FILTER latex("pdf") -%]
1.4 andrew 3: % $AFresh1: invoice.tex.tt,v 1.3 2011/03/20 05:20:11 andrew Exp $
1.1 andrew 4: \documentclass[oneside]{report}
5: \usepackage[top=1in, bottom=1in, left=.75in, right=.75in]{geometry}
6: \usepackage{multicol}
7: \usepackage{fancyhdr}
8: \usepackage{invoice}
9:
10: \pagestyle{fancy}
11:
1.2 andrew 12: \lhead{[% from.name | latex_encode %]}
13: \chead{Invoice \#\textbf{[% id | format('%06d') | latex_encode %]}}
1.1 andrew 14: \rhead{Page {\thepage}}
15:
1.4 andrew 16: \lfoot{[% info.0 | latex_encode %]}
1.1 andrew 17: \cfoot{}
1.4 andrew 18: \rfoot{[% info.1 | latex_encode %]}
1.1 andrew 19:
20: \begin{document}
21: \thispagestyle{empty}
1.6 ! andrew 22: \vspace*{-.75in}
1.1 andrew 23: \begin{multicols}{2}
1.5 andrew 24: \parbox[t][1.625in]{\linewidth}{\large
1.2 andrew 25: [% from.name | latex_encode %]
1.1 andrew 26:
27: [% IF from.attn -%]
1.2 andrew 28: [% from.attn | latex_encode %]
1.1 andrew 29:
30: [% END -%]
1.2 andrew 31: [% from.addr1 | latex_encode %]
1.1 andrew 32:
33: [% IF from.addr2 -%]
1.2 andrew 34: [% from.addr2 | latex_encode %]
1.1 andrew 35:
36: [% END -%]
1.5 andrew 37: [% from.city | latex_encode %],
38: [% from.state | latex_encode %] \ [% from.zip | latex_encode %]
39:
40: [% IF from.email -%]
41: [% from.email| latex_encode %]
42:
43: [% END -%]
1.1 andrew 44: }
45:
1.5 andrew 46: \parbox[t][1.5in]{\linewidth}{\Large
1.2 andrew 47: [% to.name | latex_encode %]
1.1 andrew 48:
49: [% IF to.attn -%]
1.2 andrew 50: [% to.attn | latex_encode %]
1.1 andrew 51:
52: [% END -%]
1.2 andrew 53: [% to.addr1 | latex_encode %]
1.1 andrew 54:
55: [% IF to.addr2 -%]
1.2 andrew 56: [% to.addr2 | latex_encode %]
1.1 andrew 57:
58: [% END -%]
1.6 ! andrew 59: [% to.city | latex_encode %],
! 60: [% to.state | latex_encode %] \ [% to.zip | latex_encode %]
1.1 andrew 61: }
62:
63: \columnbreak
64:
65: \begin{flushright}
66:
67: \begin{tabular}{ | p{3in} | }
68: \hline
69: LOGO \\
70: \hline
71: \end{tabular}
72:
73: \hfill
74: \vfill
75:
76: \begin{tabular}{ | r l | }
77: \hline
1.3 andrew 78: Invoice No. & \textbf{[% id | format('%06d') | latex_encode %]} \\
1.4 andrew 79: %Page & {\thepage} \\
1.3 andrew 80: Invoice Date & \today \\
1.4 andrew 81: [%- IF start %]
82: Start & [% start | latex_encode %] \\
83: [%- END %]
84: [%- IF end- %]
85: End & [% end | latex_encode %] \\
86: [%- END %]
1.3 andrew 87: Invoice Total & [% total | format('%.2f') | latex_encode %] \\
88: [% IF past_due -%]
89: Past Due & [% past_due | format('%.2f') | latex_encode %] \\
90: [%- END %]
91: [%- IF total_due -%]
92: Total Due & [% total_due | format('%.2f') | latex_encode %] \\
93: [%- END %]
1.1 andrew 94: \hline
1.4 andrew 95: \multicolumn{2}{|c|}{[% info.0 | latex_encode %]} \\
96: \multicolumn{2}{|c|}{[% info.1 | latex_encode %]} \\
1.1 andrew 97: \hline
98: \end{tabular}
99:
100: \end{flushright}
101:
102: \end{multicols}
103:
104: \begin{invoice}{USD}{0}
105: [%- FOR p IN projects %]
1.2 andrew 106: \ProjectTitle{[% p.title | latex_encode %]}%
107: [%- IF p.detail %]
1.3 andrew 108: \\\multicolumn{5}{l}{[% p.detail | latex_encode %]}\\%
1.2 andrew 109: [% END -%]
110:
1.1 andrew 111: [%- FOR f IN p.fees %]
1.2 andrew 112: \Fee{[% f.contents | latex_encode %]}{[% f.rate | latex_encode %]}{[% f.count | latex_encode %]}
113: [%- IF f.detail %]
1.3 andrew 114: \multicolumn{5}{l}{\small \textbullet \ [% f.detail | latex_encode %]}\\%
1.2 andrew 115: [% END -%]
1.1 andrew 116: [%- END -%]
117: [%- FOR e IN p.expenses %]
1.2 andrew 118: \EBC{[% e.contents | latex_encode %]}{[% e.amount | latex_encode %]}
119: [%- IF e.detail %]
1.3 andrew 120: \multicolumn{5}{l}{\small \textbullet \ [% e.detail | latex_encode %]}\\%
1.2 andrew 121: [% END -%]
1.1 andrew 122: [%- END -%]
1.3 andrew 123: [%- END %]
124: [%- IF discount %]
125: \\\Discount{[% discount.contents | latex_encode %]}{[% discount.amount | latex_encode %]}%
1.1 andrew 126: [%- END %]
127: \end{invoice}
128:
129: \end{document}
130: [% END -%]
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>