add missing CLI utilities to FS.pm too
[freeside.git] / sql-ledger / templates / Default-sales_order.tex
1 \documentclass[twoside]{scrartcl}
2 \usepackage[frame]{xy}
3 \usepackage{tabularx}
4 \usepackage{graphicx}
5 \setlength{\voffset}{0.5cm}
6 \setlength{\hoffset}{-1.9cm}
7 \setlength{\topmargin}{0cm}
8 \setlength{\headheight}{0.5cm}
9 \setlength{\headsep}{1cm}
10 \setlength{\topskip}{0pt}
11 \setlength{\oddsidemargin}{1.0cm}
12 \setlength{\evensidemargin}{1.0cm}
13 \setlength{\textwidth}{19.2cm}
14 \setlength{\textheight}{24.7cm}
15 \setlength{\footskip}{1cm}
16 \setlength{\parindent}{0pt}
17 \renewcommand{\baselinestretch}{1}
18 \begin{document}
19
20 \newlength{\descrwidth}\setlength{\descrwidth}{10cm}
21 \fontfamily{cmss}\fontsize{10pt}{12pt}\selectfont
22
23 \pagestyle{myheadings}
24 \thispagestyle{empty}
25
26 \vspace*{-1.3cm}
27
28 \parbox{\textwidth}{%
29   \parbox[b]{.42\textwidth}{%
30     <%company%>
31      
32     <%address%>
33   }
34   \parbox[b]{.2\textwidth}{
35     \includegraphics[scale=0.3]{sql-ledger}
36   }\hfill 
37   \begin{tabular}[b]{rr@{}}
38   Telephone & <%tel%>\\
39   Facsimile & <%fax%>
40   \end{tabular}
41
42   \rule[1.5em]{\textwidth}{0.5pt}
43 }
44
45
46 <%pagebreak 90 27 48%>
47 \end{tabularx}
48
49   \rule{\textwidth}{2pt}
50   
51   \hfill
52   \begin{tabularx}{7cm}{Xr@{}}
53   \textbf{Subtotal} & \textbf{<%sumcarriedforward%>} \\
54   \end{tabularx}
55
56 \newpage
57
58 \markboth{<%company%>\hfill <%ordnumber%>}{<%company%>\hfill <%ordnumber%>}
59
60 \vspace*{-12pt}
61
62 \begin{tabularx}{\textwidth}{@{}rlXrlrrr@{}}
63   \textbf{Pos} & \textbf{Number} & \textbf{Description} & \textbf{Qt'y} &
64   \textbf{Unit} & \textbf{Price} & \textbf{Disc \%} & \textbf{Amount} \\
65   & carried forward from <%lastpage%> & & & & & <%sumcarriedforward%> \\
66 <%end pagebreak%>
67
68
69 \vspace*{0.5cm}
70
71 \parbox[t]{1cm}{\hfill}
72 \parbox[t]{.45\textwidth}{
73 \textbf{To}
74 \vspace{0.7cm}
75   
76 <%name%>
77
78 <%address1%>
79
80 <%address2%>
81
82 <%city%> <%state%> <%zipcode%>
83
84 <%country%>
85
86 \vspace{0.3cm}
87
88 <%if contact%>
89 <%contact%>
90 \vspace{0.2cm}
91 <%end contact%>
92
93 <%if customerphone%>
94 Tel: <%customerphone%>
95 <%end customerphone%>
96
97 <%if customerfax%>
98 Fax: <%customerfax%>
99 <%end customerfax%>
100
101 <%email%>
102 }
103 \parbox[t]{.45\textwidth}{
104 \textbf{Ship To}
105 \vspace{0.7cm}
106
107 <%shiptoname%>
108
109 <%shiptoaddress1%>
110
111 <%shiptoaddress2%>
112
113 <%shiptocity%> <%shiptostate%> <%shiptozipcode%>
114
115 <%shiptocountry%>
116
117 \vspace{0.3cm}
118
119 <%if shiptocontact%>
120 <%shiptocontact%>
121 \vspace{0.2cm}
122 <%end shiptocontact%>
123
124 <%if shiptophone%>
125 Tel: <%shiptophone%>
126 <%end shiptophone%>
127
128 <%if shiptofax%>
129 Fax: <%shiptofax%>
130 <%end shiptofax%>
131
132 <%shiptoemail%>
133 }
134 \hfill
135
136 \vspace{1cm}
137
138 \textbf{S A L E S} \parbox{0.3cm}{\hfill} \textbf{O R D E R}
139 \hfill
140
141 \vspace{1cm}
142
143 \begin{tabularx}{\textwidth}{*{6}{|X}|} \hline
144   \textbf{Order \#} & \textbf{Order Date} & \textbf{Required by} & \textbf{Salesperson} & \textbf{Shipping Point} & \textbf{Ship Via} \\ [0.5em]
145   \hline
146   <%ordnumber%> & <%orddate%> & <%reqdate%> & <%employee%> & <%shippingpoint%> & <%shipvia%> \\
147   \hline
148 \end{tabularx}
149   
150 \vspace{1cm}
151
152 \begin{tabularx}{\textwidth}{@{}rlXrlrrr@{}}
153   \textbf{Pos} & \textbf{Number} & \textbf{Description} & \textbf{Qt'y} &
154   \textbf{Unit} & \textbf{Price} & \textbf{Disc \%} & \textbf{Amount} \\
155 <%foreach number%>
156   <%runningnumber%> & <%number%> & <%description%> & <%qty%> &
157   <%unit%> & <%sellprice%> & <%discountrate%> & <%linetotal%> \\
158 <%end number%>
159 \end{tabularx}
160
161
162 \parbox{\textwidth}{
163 \rule{\textwidth}{2pt}
164
165 \vspace{0.2cm}
166
167 \hfill
168 \begin{tabularx}{7cm}{Xr@{}}
169   Subtotal & <%subtotal%> \\
170 <%foreach tax%>
171   <%taxdescription%> on <%taxbase%> & <%tax%>\\
172 <%end tax%>
173   \hline
174   Total & <%ordtotal%>\\
175 \end{tabularx}
176
177 \vspace{0.3cm}
178
179 <%text_amount%> ***** <%decimal%>/100
180 \hfill
181 All prices in \textbf{<%currency%>}.
182
183 <%if terms%>
184 Terms: <%terms%> days
185 <%end terms%>
186
187 \vspace{12pt}
188
189 <%notes%>
190
191 }
192
193 \vfill
194
195 \vspace{1cm}
196
197 \centerline{\textbf{Thank You for your valued business!}}
198
199 \rule{\textwidth}{0.5pt}
200
201 \end{document}
202
203
204
205
206
207