{extends file="layout.html"} {block name=title}::: LMS :{$layout.pagetitle|striphtml} :::{/block} {block name=module_content}

{$layout.pagetitle}

{$default_printpage = ConfigHelper::getConfig('receipts.default_printpage')}
{trans("Main Information:")}
{trans("Cash Registry:")}
{trans("Receipt number:")} {if $receipt.extnumber || $receipt.extended} {trans("Additional number:")} {/if}
{trans("Settlement date:")} {if $receipt.cdatewarning} {/if}
{trans("Target:")}
{if isset($customer.id)} {customerlist form="setcustomer" customers=$customerlist selected=$customer.id selectname="customer" inputname="customerid" customOnChange="document.getElementById('radio_customer').checked=true;"} {else} {customerlist form="setcustomer" customers=$customerlist selected=$receipt.customerid selectname="customer" inputname="customerid" customOnChange="document.getElementById('radio_customer').checked=true;"} {/if}
{trans("Submit")}
{if $error.nocash}

{$error.nocash}

{/if} {if $receipt.selected && $customer}

{trans("Customer:")} {$customer.customername}  »  {$customer.address}   {$customer.zip} {$customer.city}  »  {if $customer.balance < 0}{/if}{$customer.balance|money_format}{if $customer.balance < 0}{/if} {if $customer.groups} ({foreach from=$customer.groups item=item name=groups}{$item.name}{if $smarty.foreach.groups.iteration < sizeof($customer.groups)}, {/if}{/foreach}) {/if}
{if $customer.notes}
{trans("Notes:")} {$customer.notes|replace:"\n":"
"}
{/if} {if $customer.docwarning}
{trans("Documents:")} {$customer.docwarning}
{/if} {if $customer.nodeswarning}
{trans("Nodes:")} {$customer.nodeswarning}
{/if} {if $customer.nodegroupswarning}
{trans("Groups:")} {$customer.nodegroupswarning}
{/if}

{/if}

{cycle values="light,lucid" print=false name="items"} {foreach from=$contents item=item} {foreachelse} {/foreach} {if $contents} {/if}
{trans("No.")} {trans("Name of product, commodity or service:")} {trans("Value:")}
{counter}. {$item.description} {$item.value|money_format}

{trans("Receipt have no items. Use form below for items addition.")}

{trans("Total:")} {sum array=$contents column=value string_format=$LANGDEFS.$_language.money_format}
{counter}.
{trans("Cancel")}   {if !$customer && $receipt.o_type != "other" && $receipt.o_type != "advance"} {elseif !$contents} {else} {/if} {trans("Save")}   {if !$customer && $receipt.o_type != "other" && $receipt.o_type != "advance"} {elseif !$contents} {else} {/if} {trans("Save & Print")}

{/block}