init
This commit is contained in:
405
modules/EcmReports/tpls/RaportZamowien2.html
Normal file
405
modules/EcmReports/tpls/RaportZamowien2.html
Normal file
@@ -0,0 +1,405 @@
|
||||
<!-- Tablesorter -->
|
||||
<script type="text/javascript" src="https://mottie.github.io/tablesorter/docs/js/jquery-latest.min.js"></script>
|
||||
<link class="theme" rel="stylesheet" href="https://mottie.github.io/tablesorter/docs/css/jquery-ui.min.css">
|
||||
<script type="text/javascript" src="https://mottie.github.io/tablesorter/docs/js/jquery-ui.min.js"></script>
|
||||
|
||||
<script src="https://mottie.github.io/tablesorter/js/jquery.tablesorter.js"></script>
|
||||
<script src="https://mottie.github.io/tablesorter/js/jquery.tablesorter.widgets.js"></script>
|
||||
<script src="https://mottie.github.io/tablesorter/js/widgets/widget-scroller.js"></script>
|
||||
|
||||
<link class="theme" rel="stylesheet" href="modules/EcmReports/TableSorterNew/css/theme.blue.css">
|
||||
|
||||
<script type="text/javascript" src="modules/EcmReports/javascript/RaportZamowien.js"></script>
|
||||
|
||||
|
||||
<style type="text/css">
|
||||
{literal}
|
||||
|
||||
thead, tfoot {font-weight: bold;}
|
||||
|
||||
.additionalColumn {
|
||||
background-color: #87CCED;
|
||||
border-top: 1px solid black;
|
||||
}
|
||||
|
||||
.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: #E8E8E8;
|
||||
color: #343432;
|
||||
}
|
||||
table.tablesorter tbody tr.alt-row:hover td {
|
||||
background: #E8E8E8;
|
||||
color: #343432;
|
||||
}
|
||||
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;
|
||||
}
|
||||
/*
|
||||
table#myTable-sticky th:first-child {
|
||||
display:none;
|
||||
}
|
||||
|
||||
*/
|
||||
.plusStyle {
|
||||
color: #abc3d7;
|
||||
text-decoration: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.green-text{
|
||||
color:#2E8B57;
|
||||
}
|
||||
.fix {
|
||||
position: absolute;
|
||||
margin-left: -50px;
|
||||
width: 100px;
|
||||
}
|
||||
|
||||
.outer {
|
||||
position: relative;
|
||||
}
|
||||
.inner {
|
||||
overflow-x: scroll;
|
||||
overflow-y: visible;
|
||||
width: auto;
|
||||
}
|
||||
|
||||
.ui-widget-content{
|
||||
opacity: 0.9 !important;
|
||||
}
|
||||
#back2Top {
|
||||
width: 40px;
|
||||
line-height: 40px;
|
||||
overflow: hidden;
|
||||
z-index: 999;
|
||||
display: block;
|
||||
cursor: pointer;
|
||||
position: fixed;
|
||||
bottom: 50px;
|
||||
right: 0;
|
||||
background-color: #DDD;
|
||||
color: #555;
|
||||
text-align: center;
|
||||
font-size: 30px;
|
||||
text-decoration: none;
|
||||
}
|
||||
#back2Top:hover {
|
||||
background-color: #DDF;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
{/literal}
|
||||
</style>
|
||||
|
||||
<script>
|
||||
// call the tablesorter plugin
|
||||
{literal}
|
||||
$(document).ready(function(){
|
||||
var startFixedColumns=1;
|
||||
$("table").tablesorter({
|
||||
|
||||
showProcessing: true,
|
||||
headerTemplate : '{content} {icon}',
|
||||
widgets: [ 'zebra', 'scroller','stickyHeaders' ],
|
||||
widgetOptions : {
|
||||
|
||||
|
||||
scroller_height : '100%',
|
||||
// set number of columns to fix
|
||||
scroller_fixedColumns : startFixedColumns,
|
||||
// add a fixed column overlay for styling
|
||||
scroller_addFixedOverlay : false,
|
||||
// add hover highlighting to the fixed column (disable if it causes slowing)
|
||||
scroller_rowHighlight : 'hover',
|
||||
|
||||
// bar width is now calculated; set a value to override
|
||||
scroller_barWidth : null,
|
||||
|
||||
stickyHeaders : '',
|
||||
stickyHeaders_appendTo: $(".outer"),
|
||||
// number or jquery selector targeting the position:fixed element
|
||||
stickyHeaders_offset : 0,
|
||||
// added to table ID, if it exists
|
||||
stickyHeaders_cloneId : '-sticky',
|
||||
// trigger "resize" event on headers
|
||||
stickyHeaders_addResizeEvent : true,
|
||||
// if false and a caption exist, it won't be included in the sticky header
|
||||
stickyHeaders_includeCaption : true,
|
||||
// The zIndex of the stickyHeaders, allows the user to adjust this to their needs
|
||||
stickyHeaders_zIndex : 2,
|
||||
// jQuery selector or object to attach sticky header to
|
||||
stickyHeaders_attachTo : null
|
||||
},
|
||||
|
||||
|
||||
});
|
||||
|
||||
$($('.tablesorter-headerRow')[0]).children().click();
|
||||
|
||||
// update column value display
|
||||
$( '.fixed-columns' ).text( startFixedColumns )
|
||||
});
|
||||
|
||||
|
||||
{/literal}
|
||||
</script>
|
||||
<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>Raport zamówień sprzedaży</h2>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br />
|
||||
|
||||
<ul class="tablist" style="width:100%;">
|
||||
<li>
|
||||
<a class="current" href="#">Podstawowe wyszukiwanie</a>
|
||||
</li>
|
||||
</ul>
|
||||
<form action="index.php" method="get" name="searchReportSales" id='searchReportSales'>
|
||||
<input type="hidden" name="module" value="EcmReports" />
|
||||
<input type="hidden" name="action" value="RaportZamowien" />
|
||||
<input type="hidden" name="to_pdf" id="to_pdf" value="" />
|
||||
<table style="border-top: 0px none; margin-bottom: 4px;width:100%" class="tabForm" border="0" cellpadding="0" cellspacing="0">
|
||||
|
||||
<tr>
|
||||
|
||||
{* Search by date_from *}
|
||||
<td class="dataLabel" width="5%" nowrap="nowrap"> Data od </td>
|
||||
<td class="dataField" width="10%" nowrap="nowrap">
|
||||
<input id="date_from" name="date_from" type="text" maxlength="10" size="11" tabindex="" value="{$date_from}" autocomplete="off">
|
||||
<img id="date_from_trigger" border="0" align="absmiddle" src="themes/default/images/jscalendar.gif">
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
Calendar.setup ({ldelim}
|
||||
inputField : "date_from",
|
||||
daFormat : "{$dateFormat}",
|
||||
button : "date_from_trigger",
|
||||
singleClick : true,
|
||||
dateStr : "",
|
||||
step : 1
|
||||
{rdelim}
|
||||
);
|
||||
</script>
|
||||
</td>
|
||||
</td>
|
||||
|
||||
{* Search by date_to *}
|
||||
<td class="dataLabel" width="5%" nowrap="nowrap">Data do</td>
|
||||
<td class="dataField" width="10%" nowrap="nowrap">
|
||||
<input autocomplete="off" name="date_to" id="date_to" value="{$date_to}" tabindex="" size="11" maxlength="10" type="text">
|
||||
<img src="themes/default/images/jscalendar.gif" id="date_to_trigger" align="absmiddle" border="0">
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
Calendar.setup ({ldelim}
|
||||
inputField : "date_to",
|
||||
daFormat : "{$dateFormat}",
|
||||
button : "date_to_trigger",
|
||||
singleClick : true,
|
||||
dateStr : "",
|
||||
step : 1
|
||||
{rdelim}
|
||||
);
|
||||
</script>
|
||||
</td>
|
||||
</tr><tr>
|
||||
<td class="dataLabel" width="5%" nowrap="nowrap">Typ zamówienia</td>
|
||||
<td class="dataField" width="10%" nowrap="nowrap">
|
||||
<select id="pdf_type" name="order_type">
|
||||
<option value="" { if $order_type eq '' } selected="selected" {/if} >Wszystkie</option>
|
||||
<option value="K" {if $order_type eq 'K'} selected="selected" {/if}>Okresowe</option>
|
||||
<option value="E" {if $order_type eq 'E'} selected="selected" {/if}>Normalne</option>
|
||||
</select>
|
||||
</td>
|
||||
<td class="dataLabel" width="5%" nowrap="nowrap">Status</td>
|
||||
<td class="dataField" width="10%" nowrap="nowrap">
|
||||
<select id="status" multiple name="status[]">
|
||||
{foreach from=$STATUS_ARRAY item=item name=loop key="key}
|
||||
<option value="{$key}" {if $key|in_array:$status_selected}selected="selected"{/if}>{$item}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</td>
|
||||
</tr><tr>
|
||||
<td class="dataLabel" width="5%" nowrap="nowrap">Kategoria produktu</td>
|
||||
<td class="dataField" width="10%" nowrap="nowrap">
|
||||
<input name="product_category_name_basic" class="sqsEnabled" tabindex="" id="product_category_name_basic" size="" value="{$product_category_name_basic}" title="" autocomplete="off" type="text">
|
||||
<input name="product_category_id_basic" id="product_category_id_basic" value="{$product_category_id_basic}" type="hidden">
|
||||
<span class="id-ff multiple">
|
||||
|
||||
<button type="button" name="btn_product_category_name_basic" tabindex="" title="Wybierz [Alt+T]"
|
||||
accesskey="T" class="button firstChild" value="Wybierz"
|
||||
onclick="{literal}open_popup('EcmProductCategories', 600, 400, '', true, false, {'call_back_function':'set_return','form_name':'searchReportSales','field_to_name_array':{'id':'product_category_id_basic','name':'product_category_name_basic'}}, 'single', true);{/literal}"><img src='themes/default/images/id-ff-select.png?s=bed8cd35065048ceebdc639ebe305e2c&c=1'>
|
||||
</button><button type="button" name="btn_clr_product_category_name_basic" tabindex="" title="Wyczyść[Alt+C]" accesskey="C" class="button lastChild" onclick="this.form.product_category_name_basic.value = ''; this.form.product_category_id_basic.value = '';" value="Wyczyść"><img src="themes/default/images/id-ff-clear.png?s=bed8cd35065048ceebdc639ebe305e2c&c=1"></button>
|
||||
</span>
|
||||
</td>
|
||||
<td class="dataLabel" width="5%" nowrap="nowrap">Bez dokumentu WZ</td>
|
||||
<td class="dataField" width="10%" nowrap="nowrap"><input type="checkbox" name="no_wz" id='no_wz' {if $checked==1}checked="checked"{/if}></td>
|
||||
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="dataLabel" width="5%" nowrap="nowrap">Grupa produktowa</td>
|
||||
<td class="dataField" width="10%" nowrap="nowrap">
|
||||
<input name="product_group_name_basic" class="sqsEnabled" tabindex="" id="product_group_name_basic" size="" value="{$product_group_name_basic}" title="" autocomplete="off" type="text">
|
||||
<input name="product_group_id_basic" id="product_group_id_basic" value="{$product_group_id_basic}" type="hidden">
|
||||
<span class="id-ff multiple">
|
||||
|
||||
<button type="button" name="btn_product_group_name_basic" tabindex="" title="Wybierz [Alt+T]"
|
||||
accesskey="T" class="button firstChild" value="Wybierz"
|
||||
onclick="{literal}open_popup('EcmProductGroups', 600, 400, '', true, false, {'call_back_function':'set_return','form_name':'searchReportSales','field_to_name_array':{'id':'product_group_id_basic','name':'product_group_name_basic'}}, 'single', true);{/literal}"><img src='themes/default/images/id-ff-select.png?s=bed8cd35065048ceebdc639ebe305e2c&c=1'>
|
||||
</button><button type="button" name="btn_clr_product_group_name_basic" tabindex="" title="Wyczyść[Alt+C]" accesskey="C" class="button lastChild" onclick="this.form.product_group_name_basic.value = ''; this.form.product_group_id_basic.value = '';" value="Wyczyść"><img src="themes/default/images/id-ff-clear.png?s=bed8cd35065048ceebdc639ebe305e2c&c=1"></button>
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<input class="button" name="submit" id="submit" value="{$MOD.LBL_EXECUTE}" type="submit">
|
||||
<input class="button" name="clear" value="{$MOD.LBL_CLEAR}" type="button" onclick="location.href='index.php?module=EcmReports&action=RaportZamowien';">
|
||||
<input class="button" name="pdf" value="Generuj PDF" type="button" onclick="$('#searchReportSales').attr('target','_blank');$('#to_pdf').val(1);$('#submit').click();">
|
||||
|
||||
<br>
|
||||
<br>
|
||||
</form>
|
||||
{if $DATA!=NULL}
|
||||
<div class="outer">
|
||||
<div class="inner">
|
||||
<table id="myTable" class="tablesorter tablesorter-blue" role="grid">
|
||||
<thead>
|
||||
<tr class="tablesorter-headerRow" role="row">
|
||||
|
||||
<th width="10%" 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;" aria-sort="none" aria-label="">Produkt</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;" aria-sort="none" aria-label="">Stan</th>
|
||||
{foreach from=$DATE_RANGE item=item name=loop}
|
||||
<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;" aria-sort="none" aria-label="">{$item}</th>
|
||||
{/foreach}
|
||||
<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;" aria-sort="none" aria-label="">Razem</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
{foreach from=$DATA item=item name=loop key=id}
|
||||
<tr>
|
||||
<td class="oddListRowS1" style="text-align:left;"><a target="_blank" href="index.php?module=EcmProducts&action=DetailView&record={$item.id}"><span title="{$item.name}">{$item.code}</span></a></td>
|
||||
|
||||
<td class="oddListRowS1" style="text-align:right;color:blue;" data-value="{$item.state}">{$item.state|number_format:2:".":""}</td>
|
||||
{foreach from=$item.array item=value key=key name=loop}
|
||||
|
||||
<td class="oddListRowS1" data-value="{$value}" ><span data-content="" id="{$item.id}" data-status="hidden" onclick="getProductOrders('{$id}','{$key}','{$item.id}');"style="color:{if $value>0}green;{else}red;{/if}">{$value|number_format:2:".":""}</span></td>
|
||||
|
||||
{/foreach}
|
||||
|
||||
<td class="oddListRowS1" style="text-align:right;" data-value="{$item.total}">{$item.total|number_format:2:".":""}</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="back2Top">
|
||||
<span onclick="moveLeft();"><</span>
|
||||
<span onclick="moveRight();">></span>
|
||||
<script>
|
||||
{literal}
|
||||
$(document).ready(function(){
|
||||
$( '.inner' ).css('width',$( window ).width()-100);
|
||||
$( window ).resize(function() {
|
||||
$( '.inner' ).css('width',$( window ).width()-100);
|
||||
});
|
||||
var el = $($('.tablesorter-headerRow')[3]).children()[0];
|
||||
|
||||
$(el).css('display','none');
|
||||
});
|
||||
|
||||
function moveRight(){
|
||||
var el = $($('.tablesorter-scroller-table')[1]);
|
||||
var maxWidth = el.width();
|
||||
|
||||
var procent = maxWidth*0.1;
|
||||
|
||||
|
||||
var current=el.scrollLeft();
|
||||
el.scrollLeft(current+procent);
|
||||
}
|
||||
|
||||
function moveLeft(){
|
||||
var el = $($('.tablesorter-scroller-table')[1]);
|
||||
var maxWidth = el.width();
|
||||
|
||||
var procent = maxWidth*0.1;
|
||||
|
||||
|
||||
var current=el.scrollLeft();
|
||||
el.scrollLeft(current-procent);
|
||||
}
|
||||
|
||||
function setUrl(el,date1,date2){
|
||||
var url='index.php?module=EcmSales&action=ListNewSales&date_from='+date1+'&date_to='+date2+'&submit=Szukaj&wz='+($('#no_wz').prop('checked')?'1':'0');
|
||||
$(el).attr("href",url);
|
||||
}
|
||||
{/literal}
|
||||
</script>
|
||||
<br/>
|
||||
{/if}
|
||||
Reference in New Issue
Block a user