{if $viewSelected eq 'documents'}

{if $documentSelected eq 'EcmStockDocOuts'}
{/if}

Lp.

Numer dokumentu

Data

{if $documentSelected eq 'EcmStockDocInsideOuts' or $documentSelected eq 'EcmStockDocInsideIns' or $documentSelected eq 'EcmStockDocCorrects'} Kartoteka materiałowa {elseif $documentSelected eq 'EcmStockDocMoves'} Magazyn docelowy {elseif $documentSelected eq 'EcmStockDocIns'} Dostawca {elseif $documentSelected eq 'EcmStockDocOuts'} Odbiorca {elseif $documentSelected eq 'EcmInvoiceOuts'} Kontrahent {/if}

Opis dokumentu

Wartość

Magazyn

Kategoria

{foreach from=$DATA.doc key="key" item="item" name=loop}
{if $documentSelected eq 'EcmStockDocOuts'}
{/if}

{assign var=pozycja value=$pozycja+1}{$pozycja}

{$item.numer}

{$item.data}

{if $documentSelected eq 'EcmStockDocInsideOuts' or $documentSelected eq 'EcmStockDocInsideIns' or $documentSelected eq 'EcmStockDocCorrects'} {$item.kartoteka} {elseif $documentSelected eq 'EcmStockDocMoves'} {$item.magazynIn} {elseif $documentSelected eq 'EcmStockDocIns' or $documentSelected eq 'EcmStockDocOuts' or $documentSelected eq 'EcmInvoiceOuts' } {$item.accountNazwa} {/if}

{if $item.typ=='KS'} {if $item.otyp==0} Przychód {/if} {if $item.otyp==1} Rozchód {/if} {else} {$item.nazwa} {/if}

{assign var=suma value=$suma+$item.wartosc} {$item.wartosc|number_format:2:",":"."}

{$item.magazyn}

{$item.doccategory}

{/foreach}
{if $documentSelected eq 'EcmStockDocOuts'}
{/if}
Suma: | {$suma|number_format:2:",":"." } |  |

{elseif $viewSelected eq 'positions'}

Lp. | Indeks | Nazwa | Jm | Ilość | Wartość
--- | --- | --- | --- | --- | ---
{foreach from=$DATA.prod key="key" item="item" name=loop}
{assign var=pozycja value=$pozycja+1}{$pozycja} | {$item.kod} | {$item.nazwa} | {$item.jm} | {assign var=sumaIlosci value=$sumaIlosci+$item.ilosc} {$item.ilosc|number_format:2:",":"."} | {assign var=suma value=$suma+$item.wartosc} {$item.wartosc|number_format:2:",":"."}
{/foreach}
Suma: | {$sumaIlosci|number_format:2:",":"." } | {$suma|number_format:2:",":"." }

{/if}