{extends file='documents/index.tpl'} {block name="document_index_head_bottom"}

{s name="DocumentIndexShippingNumber"}{/s} {$Document.id}

{s name="DocumentIndexPageCounter"}{/s} {/block} {block name="document_index_selectAdress"} {assign var="address" value="shipping"} {/block} {block name="document_index_head_right"} {$smarty.block.parent} {if $Document.bid}{s name="DocumentIndexInvoiceID"}{/s} {$Document.bid}
{/if} {/block} {block name="document_index_table_header"} {/block} {assign var="totWeight" value="0"} {assign var="cal_weight" value="0"} {assign var="totADR" value="0"} {block name="document_index_table_each"} {if ($position.modus == 0 || $position.modus == 1) && $position.name != 'Versandkosten'} {/if} {/block} {block name="document_index_amount"}
{s name="DocumentIndexHeadPosition"}{/s} {s name="DocumentIndexHeadArticleID"}{/s} {s name="DocumentIndexHeadName"}{/s} {s name="DocumentIndexHeadQuantity"}{/s} {s name="DocumentIndexHeadWeigt"}{/s} {s name="DocumentIndexHeadADR"}{/s}
{$number+1} {$position.articleordernumber|truncate:14:""} {s name="DocumentIndexPositionNameDefault"}{$position.name|nl2br|wordwrap:80:"
\n"}{/s} {if $position.attr5 != ""}
{$position.attr5|nl2br|wordwrap:80:"
\n"} {/if} {if $position.attr4 != ""}
{s name="DocumentIndexEachSupplier"}{/s} {$position.attr4|nl2br|wordwrap:65:"
\n"} {/if} {if $position.attr6 != ""}
{s name="DocumentIndexEachUN"}{/s} {$position.attr6|nl2br|wordwrap:70:"
\n"} {/if} {if $position.attr3 != ""}
{s name="DocumentIndexEachHint"}{/s} {$position.attr3|nl2br|wordwrap:70:"
\n"} {/if}
{$position.quantity} {$cal_weight = $position.attr1 * $position.quantity} {if $cal_weight < 1} {$cal_weight*1000} g {else} {($cal_weight)|string_format:"%.1f"} kg {/if} {$totWeight = $totWeight + $cal_weight} {$position.attr2 * $position.quantity} P. {$totADR = $totADR + ($position.attr2 * $position.quantity)}
{s name="DocumentIndexTotalWeight"}{/s}: {($totWeight)|string_format:"%.1f"} kg
{s name="DocumentIndexTotalADR"}{/s}: {$totADR} Punkte
{/block}