{include file="clearheader.html"}
<!--// $Id$ //-->
<TABLE WIDTH="100%" CELLPADDING="3" ALIGN="CENTER">
	<TR>
		<TD WIDTH="535" VALIGN="TOP">
			<H1>{$layout.pagetitle}</H1>
		</TD>
		<TD WIDTH="180" ALIGN="RIGHT" NOWRAP>
			LMS {$layout.lmsv} @ {$layout.hostname}<BR>
			{t a=trans($smarty.now|date_format:"l") b=$smarty.now|date_format:"Y-m-d"}<!date-format>$a, $b{/t}
			<br>
			{t a=$layout.logname}Prepared by: $a{/t}
		</TD>
	</TR>
</TABLE>
<BR>
<TABLE WIDTH="100%" CELLPADDING="3" BORDER="1" ALIGN="CENTER">
	<TR>
		<TD WIDTH="15" CLASS="HEAD" ALIGN="CENTER">
			{trans("No.")}
		</TD>
		<TD WIDTH="45" CLASS="HEAD" ALIGN="CENTER">
			{trans("Date")}
		</TD>
		<TD WIDTH="45" CLASS="HEAD" ALIGN="CENTER">
			{trans("Invoice No.")}
		</TD>
		<TD WIDTH="60" CLASS="HEAD" ALIGN="CENTER">
			{trans("Liability")}
		</TD>
		<TD WIDTH="50" CLASS="HEAD" ALIGN="CENTER">
			{trans("Income")}
		</TD>
		<TD WIDTH="50" CLASS="HEAD" ALIGN="CENTER">
			{trans("Expense")}
		</TD>
		<TD WIDTH="50" CLASS="HEAD" ALIGN="CENTER">
			{trans("After")}
		</TD>
		<TD WIDTH="280" CLASS="HEAD" ALIGN="CENTER">
			{trans("Description")}
		</TD>
	</TR>
	{cycle values="white,grey" print=false}
	{section name=balancelist loop=$balancelist.id}
	<TR class="{cycle}">
		<TD ALIGN="CENTER">
			{counter}.
		</TD>
		<TD ALIGN="CENTER" NOWRAP>
			{$balancelist.date[balancelist]}
		</TD>
		<TD ALIGN="CENTER" NOWRAP>
			{$balancelist.fullnumber[balancelist]}
		</TD>
		<TD ALIGN="RIGHT" NOWRAP>
			{if !$balancelist.type[balancelist]}{moneyf($balancelist.value[balancelist]*-1, $balancelist.currency[balancelist])}{else}-{/if}
		</TD>
		<TD ALIGN="RIGHT" NOWRAP>
			{if $balancelist.type[balancelist] && $balancelist.value[balancelist] > 0}{moneyf($balancelist.value[balancelist], $balancelist.currency[balancelist])}{else}-{/if}
		</TD>
		<TD ALIGN="RIGHT" NOWRAP>
			{if $balancelist.type[balancelist] && $balancelist.value[balancelist] < 0}{moneyf($balancelist.value[balancelist]*-1, $balancelist.currency[balancelist])}{else}-{/if}
		</TD>
		<TD ALIGN="RIGHT" NOWRAP>
			{$balancelist.after[balancelist]|money_format}
		</TD>
		<TD ALIGN="LEFT">
			{$balancelist.comment[balancelist]|wordwrap:60:"<br />\n"}
		</TD>
	</TR>
	{sectionelse}
	<tr>
		<td colspan="8" class="empty-table">
			{trans("No such transactions")}
		</td>
	</tr>
	{/section}
	<TR>
		<TD CLASS="HEADGREY" ALIGN="right" COLSPAN="3">
			<B>{trans("Total:")}</B>
		</TD>
		<TD CLASS="HEADGREY" ALIGN="right" nowrap>
			<B>{$balancelist.liability|money_format}</B>
		</TD>
		<TD CLASS="HEADGREY" ALIGN="right" nowrap>
			<B>{$balancelist.income|money_format}</B>
		</TD>
		<TD CLASS="HEADGREY" ALIGN="right" nowrap>
			<B>{$balancelist.expense|money_format}</B>
		</TD>
		<TD CLASS="HEADGREY" COLSPAN="2" ALIGN="right">
			<B>{trans("Balance:")} {$balancelist.summary|money_format}</B>
		</TD>
	</TR>
</TABLE>
{include file="clearfooter.html"}
