Files
crm.twinpol.com/modules/EcmSales/tpls/wzCreator.html.tpl
2025-05-12 15:46:37 +00:00

295 lines
8.8 KiB
Smarty

<!-- Tablesorter -->
<script type="text/javascript" src="include/jQuery/jquery-ui-lite/jquery-1.12.4.js"></script>
<link class="theme" rel="stylesheet" href="include/jQuery/jquery-ui-lite/jquery-ui.css">
<script type="text/javascript" src="include/jQuery/jquery-ui-lite/jquery-ui.js"></script>
<script src="modules/EcmReports/TableSorterNew/js/jquery.tablesorter.js"></script>
<script src="modules/EcmReports/TableSorterNew/js/jquery.tablesorter.widgets.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>
<script type="text/javascript" src="modules/EcmSales/javascript/wzCreator.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;
}
.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;
margin-left: 100px;
}
@media screen and (max-width: 1920px) {
.inner {
overflow-x: scroll;
overflow-y: visible;
width: 1720px;
margin-left: 100px;
}
}
@media screen and (max-width: 1680px) {
.inner {
overflow-x: scroll;
overflow-y: visible;
width: 1520px;
margin-left: 100px;
}
}
@media screen and (max-width: 1600px) {
.inner {
overflow-x: scroll;
overflow-y: visible;
width: 1460px;
margin-left: 100px;
}
}
@media screen and (max-width: 1440px) {
.inner {
overflow-x: scroll;
overflow-y: visible;
width: 1220px;
margin-left: 100px;
}
}
{/literal}
</style>
<script>
// call the tablesorter plugin
{literal}
$(document).ready(function(){
$("table").tablesorter({
// extra css class applied to the table row containing the filters & the inputs within that row
filter_cssFilter : '',
// If there are child rows in the table (rows with class name from "cssChildRow" option)
// and this option is true and a match is found anywhere in the child row, then it will make that row
// visible; default is false
filter_childRows : false,
// if true, filters are collapsed initially, but can be revealed by hovering over the grey bar immediately
// below the header row. Additionally, tabbing through the document will open the filter row when an input gets focus
filter_hideFilters : false,
// Set this option to false to make the searches case sensitive
filter_ignoreCase : true,
// jQuery selector string of an element used to reset the filters
filter_reset : '.reset',
// Use the $.tablesorter.storage utility to save the most recent filters
filter_saveFilters : true,
// Delay in milliseconds before the filter widget starts searching; This option prevents searching for
// every character while typing and should make searching large tables faster.
filter_searchDelay : 300,
// Set this option to true to use the filter to find text from the start of the column
// So typing in "a" will find "albert" but not "frank", both have a's; default is false
filter_startsWith : false,
// if false, filters are collapsed initially, but can be revealed by hovering over the grey bar immediately
// below the header row. Additionally, tabbing through the document will open the filter row when an input gets focus
filter_hideFilters : false,
theme: 'blue',
// initialize zebra striping of the table
widthFixed : false,
// initialize zebra striping of the table
widgets: ['zebra','stickyHeaders'],
// change the default striping class names
// updated in v2.1 to use widgetOptions.zebra = ["even", "odd"]
// widgetZebra: { css: [ "normal-row", "alt-row" ] } still works
widgetOptions : {
zebra : [ "normal-row", "alt-row" ]
},
headers : {
6 : { sorter: 'number' },
7 : { sorter: 'number' },
},
sortList: [[0,0]]
});
});
$( function() {
$( document ).tooltip({
items: "[title]",
content: function() {
var element = $( this );
if ( element.is( "[title]" ) ) {
return element.attr( "title" );
}
}});
} );
{/literal}
</script>
<table cellspacing="0" cellpadding="0" border="0">
<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>Specyfikacja do zamówień: {$orderNo}</h2></td>
</tr>
</table>
<br>
{if $wz_documents_no!=""}
<table cellspacing="0" cellpadding="0" border="0">
<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 style="color:red">UWAGA: Zamówienia nr: {$wz_documents_no}, mają już wystawione dokumenty WZ i zostały pominięte!!!</h2></td>
</tr>
</table>
<br>
{/if}
<table cellspacing="0" cellpadding="0" border="0">
<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>Lista potrzebnych produktów do wystawienia dokumentów WZ</h2></td>
</tr>
</table>
<table cellspacing="0" cellpadding="0" border="0" style="width:100%;" id="myTable" class="tablesorter">
<thead>
<tr>
<th width="5%">&nbsp;</th>
<th width="10%">Kod</th>
<th width="25%">Nazwa</th>
<th width="15%">Wymaga ilość</th>
<th width="5%">Ilość na magazynie</th>
</tr>
</thead>
<tbody>
{foreach from=$products key="key" item="item" name="components"}
<tr style="vertical-align:top;">
<td style="text-align:center;"><input type="checkbox" value="{$item.id}" class="make_pdf" id="make_pdf_{$item.position}" name="selectedid[]"></td>
<td >{$item.code}</td>
<td >{$item.name}</td>
<td style="text-align: right;{if $item.error==true}color:red;{/if}" data-value="{$item.quantity}">{$item.quantity|number_format:2:".":""}</td>
<td style="text-align: right;{if $item.error==true}color:red;{/if}" data-value="{$item.stock}">{$item.stock|number_format:2:".":""}</td>
</tr>
{/foreach}
</tbody><tr>
<td widtd="5%"></td>
<td widtd="40%" colspan=2 style="text-align: right;"><b>{$MOD.LBL_LISTNEWSALES_SUMMARY}</b></td>
<td widtd="15%" style="text-align: right;"><b>{$total_products|number_format:2:".":""}</b></td>
<td widtd="15%" style="text-align: right;"><b>{$total_in_stock|number_format:2:".":""}</b></td></tr>
</table>
{if $error==false}
<form action="index.php" method="GET" name="SearchFormListNewSales">
<input type="hidden" name="module" value="EcmSales">
{foreach from=$no_wz_sales key="key" item="item" name="components"}
<input type="hidden" name="ids[]" value="{$item}">
{/foreach}
<input type="hidden" name="action" value="saveDocuments">
<input type="button" id="selectAll" value="Zaznacz wszystkie produkty"/>
<input type="submit" name="submit" value="Wystaw dokumenty WZ">
</form>
{else}
<h2 style="color:red">UWAGA: Do pozycji zaznaczonych na czerwono brakuje wystarczającej ilości magazynowe! Aby wystawić dokumenty magazynowe, uzupełnij magazyn o brakujące ilości</h2>
{/if}