334 lines
17 KiB
Smarty
Executable File
334 lines
17 KiB
Smarty
Executable File
|
|
|
|
<link rel="stylesheet" type="text/css" href="modules/EcmReports/TableSorter/css/theme.blue.css"/>
|
|
<link rel="stylesheet" type="text/css" href="modules/EcmReports/TableSorter/css/theme.blue2.css"/>
|
|
<!-- Tablesorter -->
|
|
<script type="text/javascript" src="modules/EcmReports/TableSorter/js/jquery.tablesorter.min.js"></script>
|
|
<script type="text/javascript" src="modules/EcmReports/TableSorter/js/jquery.tablesorter.staticrow.min.js"></script>
|
|
{*<script type="text/javascript" src="modules/EcmReports/TableSorter/js/jquery.tablesorter.widgets.js"></script> *}
|
|
|
|
<script type="text/javascript" src="modules/EcmReports/javascript/ReportStockDocMoves.js"></script>
|
|
|
|
<style type="text/css">
|
|
{literal}
|
|
|
|
thead, tfoot {font-weight: bold;}
|
|
|
|
.additionalColumn {
|
|
background-color: #87CCED;
|
|
border-top: 1px solid black;
|
|
}
|
|
.line {
|
|
border-top: 1px solid black !important;;
|
|
}
|
|
.groupActive {
|
|
border-top: 1px solid black;
|
|
border-bottom: 1px solid black;
|
|
border-left: 1px solid black;
|
|
background-color: #87CCED;
|
|
}
|
|
|
|
.sumRow {
|
|
background-color: #BDC7B5;
|
|
}
|
|
|
|
.sumAll td{
|
|
background-color: #BDC7B5;
|
|
}
|
|
|
|
table.tablesorter tbody tr:hover td {
|
|
background: #E8E8E8;
|
|
color: #343432;
|
|
}
|
|
|
|
/* Extra selectors needed to override the default styling */
|
|
table.tablesorter tbody tr.normal-row td {
|
|
background: #EFEFF1;
|
|
color: #343432;
|
|
|
|
}
|
|
table.tablesorter tbody tr.alt-row td {
|
|
background: #FFF;
|
|
color: #343432;
|
|
|
|
}
|
|
|
|
/* Extra selectors needed to override the default styling */
|
|
table.tablesorter tbody tr.normal-row:hover td {
|
|
background: #B8E8E8;
|
|
color: #343432;
|
|
font-weight: bold;
|
|
}
|
|
table.tablesorter tbody tr.alt-row:hover td {
|
|
background: #B8E8E8;
|
|
color: #343432;
|
|
font-weight: bold;
|
|
}
|
|
table.tablesorter tbody tr.sumAll td {
|
|
background: #EBEBED;
|
|
color: black;
|
|
}
|
|
table.tablesorter tbody tr.sumAll:hover td {
|
|
background: #E0E0E2;
|
|
color: black;
|
|
font-weight: bold;
|
|
}
|
|
|
|
table.tablesorter .sumRow, .oddListRowS1 {
|
|
text-align: right;
|
|
}
|
|
|
|
table.tablesorter .alignLeft {
|
|
text-align: left;
|
|
}
|
|
|
|
table.tablesorter .subcategory .alignLeft {
|
|
padding-left: 20px;
|
|
}
|
|
|
|
table.tablesorter .contractor .alignLeft {
|
|
padding-left: 40px;
|
|
}
|
|
|
|
.plusStyle {
|
|
color: #abc3d7;
|
|
text-decoration: none;
|
|
cursor: pointer;
|
|
}
|
|
|
|
{/literal}
|
|
</style>
|
|
|
|
|
|
<table id="tableMenu" cellspacing="0" cellpadding="0" border="0">
|
|
<tbody>
|
|
<tr>
|
|
<td>
|
|
<img src="themes/Sugar/images/EcmProducts.gif" style="margin-top: 3px; margin-right: 3px;" alt="EcmProducts" width="16" border="0" height="16">
|
|
</td>
|
|
<td>
|
|
<h2>Obroty wg dokumentów</h2>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<br>
|
|
<ul class="tablist" style="width:100%;">
|
|
<li>
|
|
<a class="current" href="#">Wyszukiwanie</a>
|
|
</li>
|
|
</ul>
|
|
<form action="index.php" method="get" name="ReportStockDocMoves">
|
|
<input type="hidden" name="module" value="EcmReports" />
|
|
<input type="hidden" name="action" value="ReportStockDocMoves" />
|
|
<table style="border-top: 0px none; margin-bottom: 4px;width:100%" class="tabForm" border="0" cellpadding="0" cellspacing="0">
|
|
<tbody>
|
|
<tr>
|
|
<td class="dataField" width="10%" nowrap="nowrap">
|
|
<span id="stockSelectedspan">{$MOD.LBL_STOCK}</span>
|
|
<select multiple="multiple" name="stockSelected[]">
|
|
{foreach from=$stocksList key="key" item="item"}
|
|
<option value="{$key}" {if @in_array($key, $stockSelected) } selected="true" {/if}>{$item}</option>
|
|
{/foreach}
|
|
</select>
|
|
|
|
</td>
|
|
<td class="dataField" width="10%" nowrap="nowrap">
|
|
Dokument
|
|
{html_options name=documentsSelected options=$documentList selected=$documentSelected}
|
|
</td>
|
|
<td class="dataField" width="10%" nowrap="nowrap">
|
|
Widok:
|
|
{html_options name=viewSelected options=$viewList selected=$viewSelected}
|
|
</td>
|
|
<td class="dataField" width="10%" nowrap="nowrap">
|
|
<span class="changebox kartotekamaterialowa">
|
|
Kartoteka materiałowa
|
|
<select multiple name="stockIndexSelected[]">
|
|
<option value="NULL" {if @in_array('NULL', $stockIndexSelected) } selected="true" {/if}></option>
|
|
{foreach from=$stockIndexList key="key" item="item"}
|
|
<option value="{$key}" {if @in_array($key, $stockIndexSelected) } selected="true" {/if}>{$item}</option>
|
|
{/foreach}
|
|
</select>
|
|
</span>
|
|
<span class="changebox magazyndocelowy">
|
|
Do magazynu
|
|
<select multiple="multiple" name="mmSelected[]">
|
|
{foreach from=$stocksList key="key" item="item"}
|
|
<option value="{$key}" {if @in_array($key, $mmSelected) } selected="true" {/if}>{$item}</option>
|
|
{/foreach}
|
|
</select>
|
|
</span>
|
|
<span class="changebox kontrahent">
|
|
{$MOD.LBL_CONTRACTOR}
|
|
<input type="text" id="accountName" name="accountName" value="{$accountName}">
|
|
<input type="hidden" id="accountId" name="accountId" value="{$accountId}">
|
|
<button
|
|
type="button"
|
|
id="selectAccount"
|
|
value="{$APP.LBL_ADD_BUTTON}"
|
|
title="Wybierz kontrahenta">
|
|
<img src="{sugar_getimagepath file="id-ff-select.png"}">
|
|
</button>
|
|
<button
|
|
type="button"
|
|
id="clear"
|
|
value="Wyczyść"
|
|
title="Wyczyść">
|
|
<img src="{sugar_getimagepath file="id-ff-clear.png"}">
|
|
</button>
|
|
</span>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="dataLabel" width="10%" nowrap="nowrap">
|
|
Data od
|
|
<input id="date_from" name="date_from" type="text" maxlength="10" size="11" tabindex="" title="Data od" value="{$date_from}" autocomplete="off">
|
|
<img id="date_from_trigger" border="0" align="absmiddle" alt="Enter Date" src="themes/default/images/jscalendar.gif">
|
|
<script language="JavaScript" type="text/javascript">
|
|
Calendar.setup({ldelim}
|
|
inputField: "date_from",
|
|
daFormat: "%d.%m.%Y",
|
|
button: "date_from_trigger",
|
|
singleClick: true,
|
|
dateStr: "",
|
|
step: 1
|
|
{rdelim}
|
|
);
|
|
</script>
|
|
</td>
|
|
<td class="dataLabel" width="10%" nowrap="nowrap">
|
|
Data do
|
|
<input autocomplete="off" name="date_to" id="date_to" value="{$date_to}" title="Data do" tabindex="" size="11" maxlength="10" type="text">
|
|
<img src="themes/default/images/jscalendar.gif" alt="Enter Date" id="date_to_trigger" align="absmiddle" border="0">
|
|
<script language="JavaScript" type="text/javascript">
|
|
Calendar.setup({ldelim}
|
|
inputField: "date_to",
|
|
daFormat: "%d.%m.%Y",
|
|
button: "date_to_trigger",
|
|
singleClick: true,
|
|
dateStr: "",
|
|
step: 1
|
|
{rdelim}
|
|
);
|
|
</script>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
<input type="submit" value="{$MOD.LBL_EXECUTE}">
|
|
<input class="button" name="clear" value="{$MOD.LBL_CLEAR}" type="button" onclick="location.href = 'index.php?module=EcmReports&action=ReportStockDocMoves';">
|
|
<input id="pdf" class="button" name="pdf" value="PDF" onClick="pdfExport();" type="button">
|
|
</form>
|
|
<br>
|
|
<div class="content" style="text-align:center">
|
|
{if $viewSelected eq 'documents'}
|
|
<table id="myTable">
|
|
<thead>
|
|
<tr class="tablesorter-headerRow" role="row">
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="0" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:left; width:6%" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Numer dokumentu</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="1" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:left; width:6%" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Data</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="2" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:left;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">
|
|
{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}
|
|
</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="0" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:left;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Opis dokumentu</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="3" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:right;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Wartość</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="3" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:left; width:18%" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Magazyn</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody aria-live="polite" aria-relevant="all">
|
|
{foreach from=$DATA.doc key="key" item="item" name=loop}
|
|
<tr>
|
|
<td>
|
|
<a href="index.php?module={$documentSelected}&action=DetailView&record={$item.id}">{$item.typ} {$item.numer}</a>
|
|
</td>
|
|
<td>
|
|
{$item.data}
|
|
</td>
|
|
<td>
|
|
{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' }
|
|
<a href="index.php?module=Accounts&action=DetailView&record={$item.accountId}">{$item.accountNazwa}</a>
|
|
{/if}
|
|
|
|
</td>
|
|
<td>
|
|
{$item.nazwa}
|
|
</td>
|
|
|
|
<td style="text-align: right">
|
|
{assign var=suma value=$suma+$item.wartosc}
|
|
{$item.wartosc|number_format:2:",":"."}
|
|
</td>
|
|
<td style="text-align: left">
|
|
{$item.magazyn}
|
|
</td>
|
|
</tr>
|
|
{/foreach}
|
|
</tbody>
|
|
<tfoot>
|
|
<tr>
|
|
<th colspan='4' style="text-align:left;">Suma:</th>
|
|
<th style="text-align:right;">{$suma|number_format:2:",":"." }</th>
|
|
<th ></th>
|
|
</tr>
|
|
</tfoot>
|
|
</table>
|
|
{elseif $viewSelected eq 'positions'}
|
|
<table id="myTable">
|
|
<thead>
|
|
<tr>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="0" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:left;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Indeks</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="1" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:left;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Nazwa</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="1" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:left;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Jm</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="2" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:right;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Ilość</th>
|
|
<th class="sorter-text tablesorter-header tablesorter-headerUnSorted" data-column="3" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;text-align:right;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Wartość</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody aria-live="polite" aria-relevant="all">
|
|
{foreach from=$DATA.prod key="key" item="item" name=loop}
|
|
<tr>
|
|
<td>
|
|
<a href="index.php?module=EcmProducts&action=DetailView&record={$item.id}">{$item.kod} </a>
|
|
</td>
|
|
<td>
|
|
<a href="index.php?module=EcmProducts&action=DetailView&record={$item.id}">{$item.nazwa} </a>
|
|
</td>
|
|
<td>
|
|
{$item.jm}
|
|
</td>
|
|
<td style="text-align: right">
|
|
{assign var=sumaIlosci value=$sumaIlosci+$item.ilosc}
|
|
{$item.ilosc|number_format:2:",":"."}
|
|
</td>
|
|
<td style="text-align: right">
|
|
{assign var=suma value=$suma+$item.wartosc}
|
|
{$item.wartosc|number_format:2:",":"."}
|
|
</td>
|
|
</tr>
|
|
{/foreach}
|
|
</tbody>
|
|
<tfoot>
|
|
<tr>
|
|
<th colspan='3' style="text-align:left;">Suma:</th>
|
|
<th colspan='1' style="text-align:right;">{$sumaIlosci|number_format:2:",":"." }</th>
|
|
<th colspan='1' style="text-align:right;">{$suma|number_format:2:",":"." }</th>
|
|
</tr>
|
|
</tfoot>
|
|
</table>
|
|
{/if}
|
|
<span id="info">Strona w budowie :)</span>
|
|
</div>
|