Add TPL files

This commit is contained in:
2025-05-12 15:46:37 +00:00
parent 4a4ed02e8a
commit b4d54ba40b
894 changed files with 120580 additions and 0 deletions

View File

@@ -0,0 +1,66 @@
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery-table/jquery.appendGrid-1.3.1.css"/>
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery-ui/themes/base/jquery-ui.css"/>
<script type="text/javascript" src="include/jQuery/jquery-2.1.0.min.js"></script>
<script type="text/javascript" src="include/jQuery/jquery-table/jquery.appendGrid-1.3.1.js"></script>
<script type="text/javascript" src="include/jQuery/jquery-ui/ui/jquery-ui.js"></script>
<script type="text/javascript" src="modules/EcmPaymentStates/javascript/summary.js"></script>
<style type="text/css">
{literal}
thead, tfoot {font-weight: bold;}
{/literal}
</style>
<table cellpadding="0" cellspacing="0" border="0" class="ListView" style="width:100%;">
<thead>
<tr>
<td class="oddListRowS1" style="text-align:left; width: 45%">
<p style="cursor: pointer;">{$MOD.LBL_SUMMARY_ACCOUNT}
</p>
</td>
<td class="oddListRowS1" style="text-align:right; width: 10%">
<p style="cursor: pointer;" >Saldo
</p>
</td>
<td class="oddListRowS1" style="text-align:right; width: 10%">
<p style="cursor: pointer;">Saldo na dziś
</p>
</td>
</tr>
</thead>
<tbody>
{foreach from=$DATA item=ROW name=loop}
{if $smarty.foreach.loop.index % 2 == 1}
<tr>
{else}
<tr style="background-color: #e6e6e6;">
{/if}
<td class="oddListRowS1" style="text-align:left;">
<img src="modules/EcmQuotes/images/search.gif" style="cursor: pointer;" onclick="showDetails('{$ROW.id}')"/>&nbsp;
<a href="index.php?module=EcmPaymentStates&action=AccountPaymentStates&return_module=EcmPaymentStates&return_action=DetailView&parentTab=Rozrachunki&account_id={$ROW.id}">
{$ROW.name}
</a>
</td>
<td class="oddListRowS1" style="text-align:right;">{$ROW.saldo}</td>
<td class="oddListRowS1" style="text-align:right;color: red;">{$ROW.today_saldo}</td>
</tr>
<tr id="details_{$ROW.id}" style="border-collapse: collapse; display:none;">
</tr>
{/foreach}
</tbody>
<tfoot>
<td class="oddListRowS1" style="text-align:left;">&nbsp;</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.saldo}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.today_saldo}</td>
</tr>
<tfoot>
</table>

View File

@@ -0,0 +1,115 @@
{*
/**
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004 - 2009 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
* details.
*
* You should have received a copy of the GNU General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU General Public License version 3.
*
* In accordance with Section 7(b) of the GNU General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
*/
*}
<script type="text/javascript" src="modules/EcmCharts/javascript/jquery-2.1.1.min.js"></script>
<script type="text/javascript">
{literal}
function listenerFunction() {
//location.reload();
};
$("#chartTypeSelector").change(function() {
if( $(this).val() == 'pie' )
{
$("#documentTypeSelector").val("normal");
}
});
$("#documentTypeSelector").change(function(){
if( $(this).val() == 'correct' && $("#chartTypeSelector").val() == 'pie' )
{
$("#chartTypeSelector").val("column");
}
});
{/literal}
</script>
<style type="text/css">
{literal}
table tr td {
padding-top: 20px;
}
table tr td select {
width: 140px;
}
{/literal}
</style>
<div style='width: 600px'>
<form name="configure_{$id}" action="index.php" method="post" onSubmit='return SUGAR.dashlets.postForm("configure_{$id}", SUGAR.mySugar.uncoverPage);'>
<input type='hidden' name='id' value='{$id}'>
<input type='hidden' name='module' value='Home'>
<input type='hidden' name='action' value='ConfigureDashlet'>
<input type='hidden' name='to_pdf' value='true'>
<input type='hidden' name='configure' value='true'>
<table width="600" cellpadding="0" cellspacing="0" border="0" class="tabForm" align="center">
<tr>
<td>{$LANG.LBL_TITLE}: </td>
<td>
<input type="text" value="{$title}" name="title" />
</td>
</tr>
<tr>
<td>Od: </td>
<td class="dataField" width="10%" nowrap="nowrap">
<input autocomplete="off" name="date_from" id="date_from" value="{$date_from}" title="" tabindex="" size="11" maxlength="10" type="text">
<img src="themes/default/images/jscalendar.gif" alt="Enter Date" id="date_from_trigger" align="absmiddle" border="0">
<script type="text/javascript">
Calendar.setup ({ldelim}
inputField : "date_from",
daFormat : "{$dateFormat}",
button : "date_from_trigger",
singleClick : true,
dateStr : "",
step : 1
{rdelim}
);
</script>
</td>
</tr>
<tr>
<td colspan="4" style="text-align: center;">
<input id="submitButton" type="submit" class="button" style="margin-top: 30px;" value="{$LANG.LBL_SAVECHANGES}" onclick="setTimeout(listenerFunction, 1000);">
</td>
</tr>
</table>
</form>
</div>

View File

@@ -0,0 +1,445 @@
<!-- Tablesorter -->
<img id = "loading" src = "ajax-loader.gif" alt = "Loading indicator" style="display:none;">
<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>
<link rel="stylesheet" type="text/css" href="modules/EcmInvoiceOuts/javascript/helper.css" media="screen" />
<div class="loading_panel" style="display:none"></div>
<input type="hidden" name="system_name" value="{$system_name}" id="system_name"/>
<script type="text/javascript" src="modules/EcmPaymentStates/javascript/AccountPaymentStates2.js"></script>
<style type="text/css">
{literal}
#loading {
position: absolute;
top: 50%;
left: 50%;
width: 100px;
height: 100px;
/* 1/2 of the height and width of the actual gif */
margin: -16px 0 0 -16px;
z-index: 100;
}
thead, tfoot {font-weight: bold;}
/* 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;
}
table.tablesorter tbody tr.alt-row:hover td {
background: #B8E8E8;
color: #343432;
}
table.tablesorter tbody tr.sumTr td {
background: #AAC1D5;
color: black;
}
table.tablesorter tbody tr.sumTr:hover td {
background: #9AAEC1;
color: black;
font-weight: bold;
}
.settle_panel {
display: none;
position: fixed;
z-index: 1000;
top: 0;
left: 0;
height: 100%;
width: 100%;
text-align: center;
padding-top: 5%;
background: rgba( 255, 255, 255, .8 );
text-align: center;
}
.settle_panel_main {
background: white;
border: 1px solid black;
width: 40%;
height: 40%;
display: inline-block;
}
#edit {
list-style-image: url('modules/EcmQuotes/images/edit_position.gif');
}
#delete {
list-style-image: url('modules/EcmSales/images/deleterow.gif');
}
#settled {
list-style-image: url('modules/EcmQuotes/images/search.gif');
}
#rel {
list-style-image: url('modules/EcmSales/images/relation.png');
}
#note {
list-style-image: url('modules/EcmQuotes/images/note.gif');
}
#email {
list-style-image: url('modules/EcmQuotes/images/email.gif');
}
{/literal}
</style>
<!-- begin header & search form -->
<table cellspacing="0" cellpadding="0" border="0">
<tbody>
<tr>
<td>
<img src="modules/EcmQuotes/images/options.gif" style="margin-top: 3px; margin-right: 3px;" alt="Opcje" onclick="showOptions('1')">
{if $ACCOUNT.NAME!=''}
<div id="div_options_search_1" class="hide_all" style="border: 1px solid #cccccc;background:#e6e6e6;padding:5px;position:absolute;display:none;text-align:left;">
<form action="index.php" method="post" name="searchForm" id="searchForm">
<input type="hidden" name="module" value="EcmPaymentStates" />
<input type="hidden" name="action" value="AccountPaymentStates" />
<input name="account_name" tabindex="" id="account_name" size="" value="{$ACCOUNT.NAME}" title="" type="hidden">
<input type="hidden" id="switch_show" name="switch_show" value="{$SWITCH_SHOW}">
<input name="account_id" id="account_id" value="{$ACCOUNT.ID}" type="hidden">
<input class="button" name="switch_all" value="{if $SWITCH_SHOW==1}{$MOD.LBL_SHOW_ALL_OFF}{else}{$MOD.LBL_SHOW_ALL_ON}{/if}" onclick="sendPost();" type="button"><br><br>
<input class="button" name="switch" value="{if $SWITCH_SHOW==2}{$MOD.LBL_SHOW_SETTLED_OFF}{else}{$MOD.LBL_SHOW_SETTLED_ON}{/if}" onclick="sendPost2();" type="button"><br><br>
<input class="button" name="switch2" value="{if $SWITCH_SHOW==3}{$MOD.LBL_SHOW_NOT_SETTLED_OFF}{else}{$MOD.LBL_SHOW_NOT_SETTLED_ON}{/if}" onclick="sendPost3();" type="button"><br><br>
<input class="button" name="show_after_p" value="{if $SWITCH_SHOW==4}{$MOD.LBL_AFER_P_OFF}{else}{$MOD.LBL_AFER_P_ON}{/if}" onclick="sendPost4();" type="button"><br><br>
<input class="button" name="show_after_t" value="{if $SWITCH_SHOW==5}{$MOD.LBL_AFER_T_OFF}{else}{$MOD.LBL_AFER_T_ON}{/if}" onclick="sendPost5();" type="button">
<input class="hidden" name="toPDF" id="toPDF" value="0" type="hidden">
<input class="hidden" name="to_pdf" id="to_pdf" value="0" type="hidden">
<input class="button" name="submit" id="submit" value="{$APP.LBL_SEARCH}" type="submit" style="display:none">
</div>
{/if}
</td>
<td>
{if $umowy|@count>0}
Wybierz umowę:
<select name="agreement" id="agreement">
<option value="">brak</option>
{foreach from=$umowy item=umowa}
{$umowa}
<option value="{$umowa.id}" {if $umowa_sel==$umowa.id}selected="selected"{/if}>{$umowa.document_no}</option>
{/foreach}
</select><input type="button" value="Filtruj" onClick="submitForm();">
{/if}
<h2><a href="index.php?module=Accounts&action=DetailView&record={$ACCOUNT.ID}">{$ACCOUNT.NAME} ({$currency})</a></h2>
</td>
</tr>
</table>
</form>
<div style="width:100%" align="center">
{if $SWITCH_SHOW==4}
<form action="index.php" method="post" name="createNote" id="createNote">
<input type="hidden" name="module" value="EcmPaymentStates" />
<input type="hidden" name="action" value="createNote" />
<input type="hidden" name="id_list" value="" id="id_list"/>
<input type="hidden" name="to_pdf" value="1" id="to_pdf"/>
<input name="account_id" id="account_id" value="{$ACCOUNT.ID}" type="hidden">
<input type="button" class="button" value="Wystaw note(y)" onclick="makeNote();"/>
<input type="submit" id="submitNote" class="button" value="" style="display:none"/>
</form>
{elseif $SWITCH_SHOW==5}
<input type="button" class="button" value="Wyślij Monit" onclick="{literal}if($('#div_send_monit').css('display') == 'none'){$('#div_send_monit').show('slow'); }
else { $('#div_send_monit').hide('slow'); }{/literal}"/>
<input type="button" class="button" value="Pobierz Monit" onclick="createMonit(1);"/>
<input type="button" class="button" value="Wyślij SMS" onclick="{literal}if(createSmsFromError()!=false){createSmsText();if($('#div_send').css('display') == 'none'){$('#div_send').show('slow'); } }
else { $('#div_send').hide('slow'); }{/literal}"/>
<script src="include/ECM/comboselectbox.js"></script>
<link rel="stylesheet" type="text/css" href="include/ECM/EcmSendPdfButton/EcmSendPdfButton.css">
<!-- monit -->
<script src="include/ECM/EcmSendPdfButton/EcmSendPdfButton.js"></script>
{assign var='text' value='W załączniku przesyłamy informację o zaległości, włączając specyfikacje nierozliczonych faktur.'}
<div id="div_send_monit" style="border: 1px solid #cccccc;background:#e6e6e6;padding:5px;display:none;left:40% ">
Wybierz email:
<select name="addr_email" id="addr_email" style="width:250px;">
{foreach from=$EMAILLIST item=email}
<option value="{$email.email_address}">{$email.email_address}</option>
{/foreach}
</select>
{if !empty($PDF_OPT)}
{$PDF_OPT}
{/if}
<br>Treść:<br>
<textarea id="textarea" rows="7" style="width:250px;">
{$text}
</textarea><br>
<input name="send_mail" id="send_mail" title="Wyślij Email" accessKey="" class="button"
onclick=" createMonit(0)" type="button" value="Wyślij Email"><br /><br /></div>
<!-- koniec monitu -->
<div id="div_send" style="border: 1px solid #cccccc;background:#e6e6e6;padding:5px;display:none;">
Wybierz numer:
<select name="number_phone" id="number_phone" style="width:250px;">
<option value="{$number}">{$number}</option>
</select>
<br>Treść:<br>
<textarea id="textarea" rows="7" style="width:250px;">
Prosze o uregulowanie zaleglych platnosci na kwote {$SUM.WINIEN}. Firma {$CURRENT_COMPANY}.
</textarea><br>
<input name="cat_xls" id="cat_xls" title="Wyślij Email" accessKey="" class="button"
onclick="{literal}sendSMS();{/literal}" type="button" value="Wyślij"><br /><br /></div>
{else}
<input type="button" class="button" value="Do rozliczenia" onclick="showSettlePanel();"/>
{/if}
<input type="button" class="button" value="PDF" onclick="sendPDF();"/>
</div>
<table style="width: 100%">
<tr>
<td align="left">
<input type="button" value="Utwórz transakcje Winien" onClick="createTransactionWinien('{$ACCOUNT.ID}')"/>
</td>
<td align="right">
<input type="button" value="Utwórz transakcje Ma" onClick="createTransactionMa('{$ACCOUNT.ID}')"/>
</td>
</tr>
</table>
<table style="border-top: 0px none; margin-bottom: 4px;width:100%" class="tabForm" border="0" cellpadding="0" cellspacing="0">
<tr>
<td align="left" style="width: 33%">
{$MOD.LBL_TOTAL_WINIEN}
<br>
<span id="w_ck"> </span>
</td>
<td align="center" style="width: 34%">
{$MOD.LBL_SALDO}
<br>
<span id="total_ck"> </span>
</td>
<td align="right" style="width: 33%">
{$MOD.LBL_TOTAL_MA}
<br>
<span id="m_ck"> </span>
</td>
</tr>
<tr>
<td align="left" style="width: 33%;font-size:14px;">
{$SUM.WINIEN}
</td>
<td align="center" style="width: 34%;font-size:14px;">
<p {if $SUM.SALDO < 0} style="color: red;" {/if}>
{$SUM.SALDO}
</p>
</td>
<td align="right" style="width: 33%;font-size:14px;">
{$SUM.MA}
</td>
</tr>
</table>
{if $ACCOUNT.NAME==''}
<form action="index.php" method="post" name="searchForm">
<input type="hidden" name="module" value="EcmPaymentStates" />
<input type="hidden" name="action" value="AccountPaymentStates" />
<table style="border-top: 0px none; margin-bottom: 4px;width:100%" class="tabForm" border="0" cellpadding="0" cellspacing="0">
<tr>
<td class="dataLabel" width="10%" nowrap="nowrap">{$MOD.LBL_ACCOUNT_NAME}</td>
<td class="dataField" width="30%" nowrap="nowrap">
<input name="account_name" tabindex="" id="account_name" size="" value="{$ACCOUNT.NAME}" title="" type="text" disabled>
<input name="account_id" id="account_id" value="{$ACCOUNT.ID}" type="hidden">
<span class="id-ff multiple">
{literal}
<button type="button" name="btn_account_name" id="btn_account_name" tabindex="103" title="Wybierz [Alt+T]" accessKey="T" class="button firstChild" value="Wybierz"
onclick='open_popup(
"Accounts",
800,
500,
"",
true,
false,
{"call_back_function":"set_return","form_name":"searchForm","field_to_name_array":{"id":"account_id","name":"account_name"}},
"single",
true
); {/literal}' ><img src="themes/default/images/id-ff-select.png?s=bed8cd35065048ceebdc639ebe305e2c&c=1"></button><button type="button" name="btn_clr_parent_name" id="btn_clr_parent_name" tabindex="103" title="Wyczyść[Alt+C]" accessKey="C" class="button lastChild"
onclick="this.form.account_name.value = ''; this.form.account_id.value = '';"
value="Wyczyść" ><img src="themes/default/images/id-ff-clear.png?s=bed8cd35065048ceebdc639ebe305e2c&c=1"></button>
</span>
</td>
<td class="dataLabel" width="10%" nowrap="nowrap">{$MOD.LBL_SHOW_SETTLED}</td>
<td class="dataField" width="30%" nowrap="nowrap">
<input type="checkbox" id="show_settled" name="show_settled" {$SHOW_SETTLED}>
</td>
<td class="dataLabel" width="10%" nowrap="nowrap">{$MOD.LBL_AFER_P}</td>
<td class="dataField" width="30%" nowrap="nowrap">
<input type="checkbox" id="show_after_p" name="show_after_p" {$SHOW_AFTER_P}>
</td>
</tr>
</tbody>
</table>
<input class="button" name="submit" value="{$APP.LBL_SEARCH}" type="submit">
<input class="button" name="clear" value="{$APP.LBL_CLEAR_BUTTON_LABEL}" type="button" onclick="location.href='index.php?module=EcmPaymentStates&action=AccountPaymentStates';">
{/if}
<br />
<!-- end header && search form-->
{if $PROCESS}
<div style="width: 100%; height: 500px; border: 1px sold blue; overflow: scrool;">
<div style="width: 49.8%; height: 500px; float: left; overflow: auto;">
<!-- WINIEN -->
<table id="winien" class="tablesorter tablesorter-blue" role="grid" style="width: 100%;">
<thead>
<tr class="tablesorter-headerRow" role="row">
<th width="5%" 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: center;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_DATE}</th>
<th width="35%" 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: center;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_NAME}</th>
<th width="10%" class="sorter-saas 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">{$MOD.LBL_VALUE}</th>
<th width="10%" class="sorter-saas 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">{$MOD.LBL_SETTLED}</th>
<th width="10%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="4" 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">{$MOD.LBL_UNSETTLED}</th>
<th width="2%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="4" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none; text-align: center;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_ACTIONS}</th>
<th width="5%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="5" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">&nbsp;</th>
</tr>
</thead>
<tbody aria-live="polite" aria-relevant="all">
{foreach from=$WINIEN item=w}
{if $w.is_settled!=0}
{assign var="b" value="<b><span style=\"color:green;\">"}
{assign var="b2" value="</span></b>"}
{elseif $w.total!=$w.settled && $w.total!=$w.unsettled}
{assign var="b" value="<b><span style=\"color:orange;\">"}
{assign var="b2" value="</span></b>"}
{else}
{assign var="b" value=""}
{assign var="b2" value=""}
{/if}
<tr>
<td style="text-align: center;" id="trans_date_{$w.id}">{$b}{$w.register_date}{$b2}</td>
<td style="text-align: left;" id="trans_name_{$w.id}">{$b}{$w.document_no}{$b2}{if $w.note == '1'}(NOTA){/if}</td>
<td style="text-align: right;">{$b}{$w.total}{$b2}</td>
<td style="text-align: right;">{$b}{$w.settled}{$b2}</td>
<td style="text-align: right;" id="winien_val_{$w.id}">{$b}{$w.unsettled}{$b2}</td>
<td style="text-align:center;">
<img src="modules/EcmQuotes/images/options.gif" style="cursor: pointer;" onclick="showActions('{$w.id}')"/>
<div id="div_options_{$w.id}" class="hide_all" style="border: 1px solid #cccccc;background:#e6e6e6;padding:5px;position:absolute;display:none;text-align:left;">
<ul>
{if $w.is_settled!=0}
<li id="settled" onclick="showDetails('{$w.id}')">Rozliczenia</li>
<li id="rel" onclick="deleteRelation('{$w.id}');">Usuń relacje</li>
{elseif $w.total!=$w.settled && $w.total!=$w.unsettled}
<li id="settled" onclick="showDetails('{$w.id}')">Rozliczenia</li>
<li id="rel" onclick="deleteRelation('{$w.id}');">Usuń relacje</li>
{else}
<li id="edit" onclick="editTransaction('{$w.id}');">Edytuj</li>
<li id="delete" onclick="deleteTransaction('{$w.id}');">Usuń</li>
{/if}
{if $w.note == '1'}
<li id="note" onclick="showNote('{$w.note_id}');">Pokaż note</li>
<li id="email" onclick="sendNote('{$w.note_id}');">Wyślij note</li>
{/if}
</ul>
</div>
</td>
{if $w.is_settled == '0' ||( $w.is_settled != '0' && $SWITCH_SHOW==4 && $w.note != '1')}
<td style="text-align: center;"><input type="checkbox" name="winien[]" class="check" value="{$w.id}"/></td>
{else}
<td> &nbsp </td>
{/if}
</tr>
<tr id="details_{$w.id}" style="border-collapse: collapse; display:none;">
<td>&nbsp;</td>
<td>&nbsp;</td>
<td>&nbsp;</td>
<td><div id="details_div_{$w.id}" style="width: 100%"></div></td>
<td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
{/foreach}
</tbody>
</table>
</div>
<div style="width: 0.2%; height: 500px; float: left; background-color: #000000;"></div>
<div style="width: 49.8%; height: 500px; float: right; overflow: auto;">
<!-- MA -->
<table id="ma" class="tablesorter tablesorter-blue" role="grid" style="width: 100%;">
<thead>
<tr class="tablesorter-headerRow" role="row">
<th width="5%" 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; text-align: center;" aria-label="Name: No sort applied, activate to apply an ascending sort">&nbsp</th>
<th width="2%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="4" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none; text-align: center;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_ACTIONS}</th>
<th width="10%" 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;" aria-sort="none; text-align: center;" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_UNSETTLED}</th>
<th width="10%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="2" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none; text-align: right;" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_SETTLED}</th>
<th width="10%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="3" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none; text-align: right;" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_VALUE}</th>
<th width="32%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="4" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none; text-align: right;" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_NAME}</th>
<th width="8%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="5" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">{$MOD.LBL_DATE}</th>
</tr>
</thead>
<tbody aria-live="polite" aria-relevant="all">
{foreach from=$MA item=m}
{if $m.is_settled!=0}
{assign var="b" value="<b><span style=\"color:green;\">"}
{assign var="b2" value="</span></b>"}
{elseif $m.total!=$m.settled && $m.total!=$m.unsettled}
{assign var="b" value="<b><span style=\"color:orange;\">"}
{assign var="b2" value="</span></b>"}
{else}
{assign var="b" value=""}
{assign var="b2" value=""}
{/if}
<tr>
{if $m.is_settled == '0'}
<td style="text-align: center;"><input type="checkbox" class="check" name="ma[]" value="{$m.id}"/></td>
{else}
<td> &nbsp </td>
{/if}
<td style="text-align:center;">
<img src="modules/EcmQuotes/images/options.gif" style="cursor: pointer;" onclick="showActions('{$m.id}')"/>
<div id="div_options_{$m.id}" class="hide_all" style="border: 1px solid #cccccc;background:#e6e6e6;padding:5px;position:absolute;display:none;text-align:left;">
<ul>
{if $m.is_settled!=0}
<li id="settled" onclick="showDetails('{$m.id}')">Rozliczenia</li>
<li id="rel" onclick="deleteRelation('{$m.id}');">Usuń relacje</li>
{elseif $m.total!=$m.settled && $m.total!=$m.unsettled}
<li id="settled" onclick="showDetails('{$m.id}')">Rozliczenia</li>
<li id="rel" onclick="deleteRelation('{$m.id}');">Usuń relacje</li>
{else}
<li id="edit" onclick="editTransaction('{$m.id}');">Edytuj</li>
<li id="delete" onclick="deleteTransaction('{$m.id}');">Usuń</li>
{/if}
</ul>
</div>
<td style="text-align: right;" id="ma_val_{$m.id}">{$b}{$m.unsettled}{$b2}&nbsp&nbsp&nbsp</td>
<td style="text-align: right;">{$b}{$m.settled}{$b2}</td>
<td style="text-align: right;">{$b}{$m.total}{$b2}</td>
<td style="text-align: right;">{$b}{$m.name}{$b2}&nbsp</td>
<td style="text-align: center;">{$b}{$m.register_date}{$b2}</td>
</tr>
<tr id="details_{$m.id}" style="border-collapse: collapse; display:none;">
<td>&nbsp;</td>
<td>&nbsp;</td>
<td>&nbsp;</td>
<td><div id="details_div_{$m.id}" style="width: 100%"></div></td>
<td>&nbsp;</td>
<td>&nbsp;</td>
</tr>
{/foreach}
</tbody>
</table>
</div>
</div>
</form>
<div class="settle_panel">
<div class="settle_panel_main">
</div>
</div>
{/if}

View File

@@ -0,0 +1,17 @@
<table style="width: 100%">
<tr>
<td>
<img src="modules/EcmQuotes/images/deleterow.gif" style="cursor: pointer;" onclick="hideDetails('{$ID}')"/>
</td>
</tr>
{foreach from=$RES item=r}
<tr>
<td align="center">
<a href="index.php?module=EcmTransactions&action=DetailView&record={$r.id}">{$r.name}</a>
</td>
<td align="right">
{$r.value}
</td>
</tr>
{/foreach}
</table>

View File

@@ -0,0 +1,340 @@
<style type="text/css">
{literal}
body {
font-size: 9px;
}
/* overall */
.tablesorter-blue {
width: 100%;
background-color: #fff;
margin: 10px 0 15px;
text-align: left;
border-spacing: 0;
border: #fff 1px solid;
border-width: 1px 0 0 1px;
}
.tablesorter-blue td {
border: #fff 1px solid;
border-width: 0 1px 1px 0;
}
.tablesorter-blue th {
border: #000 1px solid;
border-color: #000 solid;
border-width: 1px 1px 1px 1px solid;
}
/* header */
.tablesorter-blue th,
.tablesorter-blue thead td {
font: bold 11px/18px Arial, Sans-serif;
color: #000;
border-collapse: collapse;
padding: 4px;
border-top: 2px solid #ABC3D7;
}
.tablesorter-blue tbody td,
.tablesorter-blue tfoot th,
.tablesorter-blue tfoot td {
padding: 4px;
vertical-align: top;
}
.tablesorter-blue .header,
.tablesorter-blue .tablesorter-header {
/* black (unsorted) double arrow */
/* white (unsorted) double arrow */
/* background-image: url(data:image/gif;base64,R0lGODlhFQAJAIAAAP///////yH5BAEAAAEALAAAAAAVAAkAAAIXjI+AywnaYnhUMoqt3gZXPmVg94yJVQAAOw==); */
/* image */
/* background-image: url(images/black-unsorted.gif); */
background-repeat: no-repeat;
background-position: center right;
padding: 3px 18px 3px 3px;
white-space: normal;
cursor: pointer;
}
.tablesorter-blue .headerSortUp,
.tablesorter-blue .tablesorter-headerSortUp,
.tablesorter-blue .tablesorter-headerAsc {
background-color: #E7E7E9;
/* black asc arrow */
/* white asc arrow */
/* background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAAP///////yH5BAEAAAEALAAAAAAVAAQAAAINjI8Bya2wnINUMopZAQA7); */
/* image */
/* background-image: url(images/black-asc.gif); */
}
.tablesorter-blue .headerSortDown,
.tablesorter-blue .tablesorter-headerSortDown,
.tablesorter-blue .tablesorter-headerDesc {
background-color: #E7E7E9;
/* black desc arrow */
/* white desc arrow */
/* background-image: url(data:image/gif;base64,R0lGODlhFQAEAIAAAP///////yH5BAEAAAEALAAAAAAVAAQAAAINjB+gC+jP2ptn0WskLQA7); */
/* image */
/* background-image: url(images/black-desc.gif); */
}
.tablesorter-blue thead .sorter-false {
background-image: none;
padding: 4px;
}
/* tfoot */
.tablesorter-blue tfoot .tablesorter-headerSortUp,
.tablesorter-blue tfoot .tablesorter-headerSortDown,
.tablesorter-blue tfoot .tablesorter-headerAsc,
.tablesorter-blue tfoot .tablesorter-headerDesc {
/* remove sort arrows from footer */
background-image: none;
}
/* tbody */
.tablesorter-blue td {
color: #3d3d3d;
background-color: #fff;
padding: 0px;
vertical-align: top;
}
/* hovered row colors
you'll need to add additional lines for
rows with more than 2 child rows
*/
.tablesorter-blue tbody > tr:hover > td,
.tablesorter-blue tbody > tr:hover + tr.tablesorter-childRow > td,
.tablesorter-blue tbody > tr:hover + tr.tablesorter-childRow + tr.tablesorter-childRow > td,
.tablesorter-blue tbody > tr.even:hover > td,
.tablesorter-blue tbody > tr.even:hover + tr.tablesorter-childRow > td,
.tablesorter-blue tbody > tr.even:hover + tr.tablesorter-childRow + tr.tablesorter-childRow > td {
background: #d9d9d9;
}
.tablesorter-blue tbody > tr.odd:hover > td,
.tablesorter-blue tbody > tr.odd:hover + tr.tablesorter-childRow > td,
.tablesorter-blue tbody > tr.odd:hover + tr.tablesorter-childRow + tr.tablesorter-childRow > td {
background: #bfbfbf;
}
/* table processing indicator */
.tablesorter-blue .tablesorter-processing {
background-position: center center !important;
background-repeat: no-repeat !important;
/* background-image: url(../addons/pager/icons/loading.gif) !important; */
}
/* Zebra Widget - row alternating colors */
.tablesorter-blue tbody tr.odd td {
background-color: #ebf2fa;
}
.tablesorter-blue tbody tr.even td {
background-color: #fff;
}
/* Column Widget - column sort colors */
.tablesorter-blue td.primary,
.tablesorter-blue tr.odd td.primary {
background-color: #99b3e6;
}
.tablesorter-blue tr.even td.primary {
background-color: #c2d1f0;
}
.tablesorter-blue td.secondary,
.tablesorter-blue tr.odd td.secondary {
background-color: #c2d1f0;
}
.tablesorter-blue tr.even td.secondary {
background-color: #d6e0f5;
}
.tablesorter-blue td.tertiary,
.tablesorter-blue tr.odd td.tertiary {
background-color: #d6e0f5;
}
.tablesorter-blue tr.even td.tertiary {
background-color: #ebf0fa;
}
/* caption */
caption {
background: #fff;
}
/* filter widget */
.tablesorter-blue .tablesorter-filter-row td {
background: #eee;
line-height: normal;
text-align: center; /* center the input */
-webkit-transition: line-height 0.1s ease;
-moz-transition: line-height 0.1s ease;
-o-transition: line-height 0.1s ease;
transition: line-height 0.1s ease;
}
/* optional disabled input styling */
.tablesorter-blue .tablesorter-filter-row .disabled {
opacity: 0.5;
filter: alpha(opacity=50);
cursor: not-allowed;
}
/* hidden filter row */
.tablesorter-blue .tablesorter-filter-row.hideme td {
/*** *********************************************** ***/
/*** change this padding to modify the thickness ***/
/*** of the closed filter row (height = padding x 2) ***/
padding: 2px;
/*** *********************************************** ***/
margin: 0;
line-height: 0;
cursor: pointer;
}
.tablesorter-blue .tablesorter-filter-row.hideme .tablesorter-filter {
height: 1px;
min-height: 0;
border: 0;
padding: 0;
margin: 0;
/* don't use visibility: hidden because it disables tabbing */
opacity: 0;
filter: alpha(opacity=0);
}
/* filters */
.tablesorter-blue .tablesorter-filter {
width: 98%;
height: auto;
margin: 0;
padding: 4px;
background-color: #fff;
border: 1px solid #bbb;
color: #333;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
-webkit-transition: height 0.1s ease;
-moz-transition: height 0.1s ease;
-o-transition: height 0.1s ease;
transition: height 0.1s ease;
}
/* ajax error row */
.tablesorter .tablesorter-errorRow td {
cursor: pointer;
background-color: #e6bf99;
}
#myTable tbody tr td.subcategory {
padding-left: 30px;
}
#myTable tbody tr td.product {
padding-left: 55px;
}
#myTable tbody tr.category td {
background-color: #96FF7C;
}
#myTable tbody tr.sumAll td{
background-color: #242424;
color: #fff;
}
#myTable tbody tr td.sumRow {
text-align: right;
}
#myTable tbody tr td.oddListRowS1 {
text-align: right;
}
#myTable tbody tr td.alignLeft {
text-align: left;
}
{/literal}
</style>
<table id="myTable" class="tablesorter tablesorter-blue" role="grid" width="100%">
<thead>
<tr class="tablesorter-headerRow" role="row">
<th colspan="5">Strona winien</th>
<th colspan="5">Strona ma</th>
</tr>
</thead>
<thead>
<tr class="tablesorter-headerRow" role="row">
<th width="5%" 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="Name: No sort applied, activate to apply an ascending sort">Data</th>
<th width="30%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="5" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Nazwa</th>
<th width="5%" 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;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Wartość</th>
<th width="5%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="5" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Rozliczone</th>
<th width="5%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="6" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Nie rozl.</th>
<th width="5%" 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="Name: No sort applied, activate to apply an ascending sort">Nie rozl.</th>
<th width="5%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="5" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Rozliczone</th>
<th width="5%" 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;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Wartość</th>
<th width="30%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="5" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Nazwa</th>
<th width="5%" class="sorter-saas tablesorter-header tablesorter-headerUnSorted" data-column="6" tabindex="0" scope="col" role="columnheader" aria-disabled="false" unselectable="on" style="-moz-user-select: none;" aria-sort="none" aria-label="Name: No sort applied, activate to apply an ascending sort">Data</th>
</tr>
</thead>
<tbody id="functions-core" class="tablesorter-infoOnly">
{foreach from=$transactions key="key" item="item" name=loop}
<tr style="border-bottom:1pt solid black;">
{if $item.type==0}
<td class="oddListRowS1 alignLeft" style="border-bottom:1pt solid black;"><b>{$item.register_date}</b></td>
<td class="oddListRowS1" style="border-bottom:1pt solid black;text-align:left;"><b>{$item.document_no}</b></td>
<td class="oddListRowS1" style="border-bottom:1pt solid black;"><b>{$item.total}</b></td>
<td class="oddListRowS1 sumRow" style="border-bottom:1pt solid black;"><b>{$item.settled}</b></td>
<td class="oddListRowS1 sumRow" style="border-bottom:1pt solid black;"><b>{$item.unsettled}</b></td>
<td colspan="5"></td>
{else}
<td colspan="5"></td>
<td class="oddListRowS1 sumRow" style="border-bottom:1pt solid black;"><b>{$item.unsettled}</b></td>
<td class="oddListRowS1 sumRow" style="border-bottom:1pt solid black;"><b>{$item.settled}</b></td>
<td class="oddListRowS1" style="border-bottom:1pt solid black;"><b>{$item.total}</b></td>
<td class="oddListRowS1" style="border-bottom:1pt solid black;text-align:right;"><b>{$item.name}</b></td>
<td class="oddListRowS1 alignLeft" style="border-bottom:1pt solid black;"><b>{$item.register_date}</b></td>
{/if}
</tr>
{/foreach}
</tbody>
<tr style="border-bottom:1pt solid black;">
<td class="oddListRowS1 alignLeft" style="border-bottom:1pt solid black;"><b>Razem:</b></td>
<td class="oddListRowS1" style="border-bottom:1pt solid black;text-align:left;"><b></b></td>
<td class="oddListRowS1" style="text-align:right;border-bottom:1pt solid black;"><b>{$totals_w.wartosc|number_format:2:",":"."}</b></td>
<td class="oddListRowS1 sumRow" style="text-align:right;border-bottom:1pt solid black;"><b>{$totals_w.roz|number_format:2:",":"."}</b></td>
<td class="oddListRowS1 sumRow" style="text-align:right;border-bottom:1pt solid black;"><b>{$totals_w.nie|number_format:2:",":"."}</b></td>
<td class="oddListRowS1 sumRow" style="text-align:right;border-bottom:1pt solid black;"><b>{$totals_m.nie|number_format:2:",":"."}</b></td>
<td class="oddListRowS1 sumRow" style="text-align:right;border-bottom:1pt solid black;"><b>{$totals_m.roz|number_format:2:",":"."}</b></td>
<td class="oddListRowS1" style="text-align:right;border-bottom:1pt solid black;"><b>{$totals_m.wartosc|number_format:2:",":"."}</b></td>
<td class="oddListRowS1" style="border-bottom:1pt solid black;text-align:right;"><b></b></td>
<td class="oddListRowS1 alignLeft" style="border-bottom:1pt solid black;"><b></b></td>
</tr>
<tr style="border-bottom:1pt solid black;">
<td class="oddListRowS1 alignLeft" style="border-bottom:1pt solid black;"><b>Saldo:</b></td>
<td class="oddListRowS1" style="border-bottom:1pt solid black;text-align:left;"><b></b></td>
<td class="oddListRowS1" style="text-align:right;border-bottom:1pt solid black;"><b></b></td>
<td class="oddListRowS1 sumRow" style="text-align:right;border-bottom:1pt solid black;"><b></b></td>
<td class="oddListRowS1 sumRow" colspan="2" style="text-align:center;border-bottom:1pt solid black;"><b>{$saldo|number_format:2:",":"."}</b></td>
<td class="oddListRowS1 sumRow" style="text-align:right;border-bottom:1pt solid black;"><b></b></td>
<td class="oddListRowS1" style="text-align:right;border-bottom:1pt solid black;"><b></b></td>
<td class="oddListRowS1" style="border-bottom:1pt solid black;text-align:right;"><b></b></td>
<td class="oddListRowS1 alignLeft" style="border-bottom:1pt solid black;"><b></b></td>
</tr>
</table>
<br/>

View File

@@ -0,0 +1,95 @@
{*
/**
* SugarCRM is a customer relationship management program developed by
* SugarCRM, Inc. Copyright (C) 2004 - 2007 SugarCRM Inc.
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU General Public License version 3 as published by the
* Free Software Foundation with the addition of the following permission added
* to Section 15 as permitted in Section 7(a): FOR ANY PART OF THE COVERED WORK
* IN WHICH THE COPYRIGHT IS OWNED BY SUGARCRM, SUGARCRM DISCLAIMS THE WARRANTY
* OF NON INFRINGEMENT OF THIRD PARTY RIGHTS.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
* details.
*
* You should have received a copy of the GNU General Public License along with
* this program; if not, see http://www.gnu.org/licenses or write to the Free
* Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301 USA.
*
* You can contact SugarCRM, Inc. headquarters at 10050 North Wolfe Road,
* SW2-130, Cupertino, CA 95014, USA. or at email address contact@sugarcrm.com.
*
* The interactive user interfaces in modified source and object code versions
* of this program must display Appropriate Legal Notices, as required under
* Section 5 of the GNU General Public License version 3.
*
* In accordance with Section 7(b) of the GNU General Public License version 3,
* these Appropriate Legal Notices must retain the display of the "Powered by
* SugarCRM" logo. If the display of the logo is not reasonably feasible for
* technical reasons, the Appropriate Legal Notices must display the words
* "Powered by SugarCRM".
*/
*}
<form name="ecmpaymentstatesQuickCreate" id="ecmpaymentstatesQuickCreate" method="POST" action="index.php">
<input type="hidden" name="module" value="EcmPaymentStates">
<input type="hidden" name="email_id" value="{$REQUEST.email_id}">
<input type="hidden" name="account_id" value="{$REQUEST.account_id}">
<input type="hidden" name="case_id" value="{$REQUEST.acase_id}">
<input type="hidden" name="contact_id" value="{$REQUEST.contact_id}">
<input type="hidden" name="return_action" value="{$REQUEST.return_action}">
<input type="hidden" name="return_module" value="{$REQUEST.return_module}">
<input type="hidden" name="return_id" value="{$REQUEST.return_id}">
<input type="hidden" name="action" value='Save'>
<input type="hidden" name="duplicate_parent_id" value="{$REQUEST.duplicate_parent_id}">
<input type="hidden" name="to_pdf" value='1'>
<input id='assigned_user_id' name='assigned_user_id' type="hidden" value="{$ASSIGNED_USER_ID}" />
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<td align="left" style="padding-bottom: 2px;">
<input title="{$APP.LBL_SAVE_BUTTON_TITLE}" accessKey="{$APP.LBL_SAVE_BUTTON_KEY}" class="button" type="submit" name="button" {$saveOnclick|default:"onclick=\"return check_form('EcmPaymentStatesQuickCreate');\""} value=" {$APP.LBL_SAVE_BUTTON_LABEL} " >
<input title="{$APP.LBL_CANCEL_BUTTON_TITLE}" accessKey="{$APP.LBL_CANCEL_BUTTON_KEY}" class="button" type="submit" name="button" {$cancelOnclick|default:"onclick=\"this.form.action.value='$RETURN_ACTION'; this.form.module.value='$RETURN_MODULE'; this.form.record.value='$RETURN_ID'\""} value=" {$APP.LBL_CANCEL_BUTTON_LABEL} ">
<input title="{$APP.LBL_FULL_FORM_BUTTON_TITLE}" accessKey="{$APP.LBL_FULL_FORM_BUTTON_KEY}" class="button" type="submit" name="button" onclick="this.form.to_pdf.value='0';this.form.action.value='EditView'; this.form.module.value='EcmPaymentStates';" value=" {$APP.LBL_FULL_FORM_BUTTON_LABEL} "></td>
<td align="right" nowrap><span class="required">{$APP.LBL_REQUIRED_SYMBOL}</span> {$APP.NTC_REQUIRED}</td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="tabForm">
<tr>
<td>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<th align="left" class="dataLabel" colspan="4"><h4 class="dataLabel"><slot>{$MOD.LBL_ECMPAYMENTSTATE_INFORMATION}</slot></h4></th>
</tr>
<tr>
<td valign="top" class="dataLabel" width="15%"><slot>{$MOD.LBL_SUBJECT} <span class="required">{$APP.LBL_REQUIRED_SYMBOL}</span></slot></td>
<td width="35%"><slot><textarea name='name' cols="40" tabindex='1' rows="1">{$NAME}</textarea></slot></td>
<td class="dataLabel" width="15%"><slot>{$MOD.LBL_TYPE}</slot></td>
<td width="35%"><slot><select tabindex='2' name='type'>{$TYPE_OPTIONS}</select></slot></td>
</tr>
<tr>
<td valign="top" class="dataLabel" rowspan="2" width="15%"><slot>{$MOD.LBL_DESCRIPTION}</slot></td>
<td rowspan="2" width="35%"><slot><textarea name='description' tabindex='1' cols="40" rows="4">{$DESCRIPTION}</textarea></slot></td>
<td class="dataLabel" width="15%"><slot>{$MOD.LBL_PRIORITY}</slot></td>
<td class="dataField" nowrap width="35%"><slot><select tabindex='2' name='priority'>{$PRIORITY_OPTIONS}</select></slot></td>
</tr>
<tr>
<td class="dataLabel" width="15%"><slot>{$MOD.LBL_STATUS}</slot></td>
<td width="35%"><slot><select tabindex='2' name='status'>{$STATUS_OPTIONS}</select></slot></td>
</tr>
</table>
</form>
<script>
{$additionalScripts}
</script>

View File

@@ -0,0 +1,145 @@
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery.appendGrid-master/jquery.appendGrid-1.5.0.css"/>
<link rel="stylesheet" type="text/css" href="modules/Accounts/MyTable.css"/>
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery-ui/themes/base/jquery-ui.css"/>
<script type="text/javascript"
src="include/jQuery/jquery-2.1.0.min.js"></script>
<script type="text/javascript"
src="include/jQuery/jquery.appendGrid-master/jquery.appendGrid-1.5.0.js"></script>
<script type="text/javascript"
src="include/jQuery/jquery-ui/ui/jquery-ui.js"></script>
<script type="text/javascript"
src="modules/EcmPaymentStates/javascript/interestLogic.js"></script>
<!-- begin header & search form -->
<style>
{literal}
input {
text-align: right;
}
{/literal}
</style>
<table 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>{$MOD.LBL_INTERESTTABLE}: Szczegóły</h2>
</td>
</tr>
</table>
<div id="LBL_PANEL_CATEGORIES2">
<form name="interestForm" method="post" action="index.php">
<input type="hidden" name="module" id="module" value='EcmPaymentStates'/>
<input type="hidden" name="action" id="action" value='interestView'/>
<input type="hidden" name="step" id="step" value='calculateAction'/>
<table width="100%" cellspacing="1" cellpadding="0" border="0" class="edit view">
<tbody>
<tr>
<th align="left" colspan="8"><h4>{$MOD.LBL_INTERESTTABLE_INFO}</h4></th>
</tr>
<tr>
<td width="37.5%" valign="top" colspan="3">
<div style="width:90%;border: 1px solid rgb(48,192,255);background-color:white;height:{$OPT.position_table_height}px;max-height:{$OPT.position_table_height}px;overflow:auto;">
<table cellpadding="0" cellspacing="0" border="0" class="list view">
<tr class="oddListRowS1">
<th style="text-align:center;"><b>Od</b></th>
<th style="text-align:center;"><b>Do</b></th>
<th style="text-align:center;"><b>%</b></th>
<th style="text-align:center;"><b>Symbol</b></th>
</tr>
{foreach from=$POSITIONS item=w}
<tr>
<td style="text-align:center;">{$w.date_from}</td>
<td style="text-align:center;">{$w.date_to}</td>
<td style="text-align:center;">{$w.rate}</td>
<td style="text-align:center;">{$w.symbol}</td>
</tr>
{/foreach}
</table>
</div>
</td>
</tr>
<tr>
<th align="left" colspan="8"><h4>{$MOD.LBL_INTEREST_CALC}</h4></th>
</tr>
<tr>
<td width="12.5%" valign="top" scope="row" id="_label">{$MOD.LBL_INTEREST_PAYMENT_TERM}</td>
<td width="37.5%" valign="top"><input type="text" value="{$REQ.payment_date}" name="payment_date" id="payment_date"><img border="0" src="themes/Sugar5/images/jscalendar.gif?s=bed8cd35065048ceebdc639ebe305e2c&amp;c=1" alt="Wprowadź datę" id="payment_date_trigger" align="absmiddle">
&nbsp;(<span class="dateFormat">dd.mm.yyyy</span>)
<script type="text/javascript">
{literal}
Calendar.setup ({
inputField : "payment_date",
daFormat : "%d.%m.%Y %H:%M",
button : "payment_date_trigger",
singleClick : true,
dateStr : "03.02.2015",
step : 1,
weekNumbers:false
}
);
{/literal}
</script></td>
<td width="12.5%" valign="top" scope="row" id="_label"></td>
<td width="37.5%" valign="top"></td>
</tr>
<tr>
<td width="12.5%" valign="top" scope="row" id="_label">{$MOD.LBL_INTEREST_AMOUNT}</td>
<td width="37.5%" valign="top"><input type="text" value="{$REQ.payment_after_date}" name="payment_after_date" id="payment_after_date"><img border="0" src="themes/Sugar5/images/jscalendar.gif?s=bed8cd35065048ceebdc639ebe305e2c&amp;c=1" alt="Wprowadź datę" id="payment_date_after_trigger" align="absmiddle">
&nbsp;(<span class="dateFormat">dd.mm.yyyy</span>)
<script type="text/javascript">
{literal}
Calendar.setup ({
inputField : "payment_after_date",
daFormat : "%d.%m.%Y %H:%M",
button : "payment_date_after_trigger",
singleClick : true,
dateStr : "03.02.2015",
step : 1,
weekNumbers:false
}
);
{/literal}
</script></td>
<td width="12.5%" valign="top" scope="row" id="_label"></td>
<td width="37.5%" valign="top"></td>
</tr>
<tr>
<td width="12.5%" valign="top" scope="row" id="_label">{$MOD.LBL_INTEREST_AFTER_PAID}</td>
<td width="37.5%" valign="top"><input type="text" value="{$REQ.amount}" name="amount" id="amount" onchange="$(this).val(FormatNumber($(this).val(),2))" onclick="$(this).select();"></td>
<td width="12.5%" valign="top" scope="row" id="_label"></td>
<td width="37.5%" valign="top"></td>
</tr>
{if $TABLE}
<tr>
<td width="37.5%" valign="top" colspan="3">
<div style="width:90%;border: 1px solid rgb(48,192,255);background-color:white;height:{$OPT.position_table_height}px;max-height:{$OPT.position_table_height}px;overflow:auto;">
<table cellpadding="0" cellspacing="0" border="0" class="list view">
<tr class="oddListRowS1">
<th style="text-align:center;"><b>Od</b></th>
<th style="text-align:center;"><b>Do</b></th>
<th style="text-align:center;"><b>Dni</b></th>
<th style="text-align:center;"><b>Kwota</b></th>
</tr>
{foreach from=$TABLE item=w}
<tr>
<td style="text-align:center;">{$w.date_from}</td>
<td style="text-align:center;">{$w.date_to}</td>
<td style="text-align:center;">{$w.days}</td>
<td style="text-align:right;">{$w.amount|number_format:3:".":","}</td>
</tr>
{/foreach}
</table>
</div>
</td>
</tr>
<tr>
<td width="12.5%" valign="top" scope="row" id="_label">Naliczonych odsetek</td>
<td width="37.5%" valign="top" style="color:red">{$TOTAL|number_format:2:".":","}</td></tr>
{/if}
</tbody>
</table>
</div>
<input class="button primary" type="button" value="Edytuj" name="button" onclick="window.location.href='index.php?module=EcmPaymentStates&action=interestView&step=editAction';" accesskey="S" title="Zapisz [Alt+S]">
<input class="button primary" type="submit" value="Oblicz" name="submit" accesskey="S" title="Zapisz [Alt+S]">

View File

@@ -0,0 +1,59 @@
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery.appendGrid-master/jquery.appendGrid-1.5.0.css"/>
<link rel="stylesheet" type="text/css" href="modules/Accounts/MyTable.css"/>
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery-ui/themes/base/jquery-ui.css"/>
<script type="text/javascript"
src="include/jQuery/jquery-2.1.0.min.js"></script>
<script type="text/javascript"
src="include/jQuery/jquery.appendGrid-master/jquery.appendGrid-1.5.0.js"></script>
<script type="text/javascript"
src="include/jQuery/jquery-ui/ui/jquery-ui.js"></script>
<script type="text/javascript"
src="modules/EcmPaymentStates/javascript/interestLogic.js"></script>
<script type="text/javascript"
src="modules/EcmPaymentStates/javascript/interestEditView.js"></script>
<link rel="stylesheet" type="text/css" href="modules/EcmInvoiceOuts/javascript/helper.css" media="screen" />
<div class="loading_panel" style="display:none"></div>
<!-- begin header & search form -->
<table 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>{$MOD.LBL_INTERESTTABLE}: Edycja</h2>
</td>
</tr>
</table>
<form name="interestForm" method="post" action="index.php">
<input type="hidden" name="module" id="module" value='EcmPaymentStates'/>
<input type="hidden" name="action" id="action" value='interestView'/>
<input type="hidden" name="step" id="step" value='saveAction'/>
<div id="LBL_PANEL_CATEGORIES2">
<table width="100%" cellspacing="1" cellpadding="0" border="0" class="edit view">
<tbody>
<tr>
<th align="left" colspan="8"><h4>{$MOD.LBL_INTERESTTABLE_INFO}</h4></th>
</tr>
<tr>
<td width="37.5%" valign="top" colspan="3">
<input type="hidden" name="positions" id="positions" value='{$POSITIONS}'/>
<div style="width:90%;border: 1px solid rgb(48,192,255);background-color:white;height:{$OPT.position_table_height}px;max-height:{$OPT.position_table_height}px;overflow:auto;">
<table id="tblAppendGrid" class="positions">
</table>
</div>
</td>
</tr>
<tr>
<td width="12.5%" valign="top" scope="row" id="_label"></td>
<td width="37.5%" valign="top"></td>
<td width="12.5%" valign="top" scope="row" id="_label"></td>
<td width="37.5%" valign="top"></td>
</tr>
</tbody>
</table>
</div>
<input class="button primary" type="submit" value="Zapisz" name="button" onclick="return check_form('EditView');" accesskey="S" title="Zapisz [Alt+S]">
<input class="button primary" type="button" value="Anuluj" name="button" onclick="window.location.href='index.php?module=EcmPaymentStates&action=interestView&step=detailAction';" accesskey="S" title="Anuluj">
</form>

View File

@@ -0,0 +1,309 @@
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery-table/jquery.appendGrid-1.3.1.css"/>
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery-ui/themes/base/jquery-ui.css"/>
<script type="text/javascript" src="include/jQuery/jquery-2.1.0.min.js"></script>
<script type="text/javascript" src="include/jQuery/jquery-table/jquery.appendGrid-1.3.1.js"></script>
<script type="text/javascript" src="include/jQuery/jquery-ui/ui/jquery-ui.js"></script>
<script type="text/javascript" src="include/jQuery/tablesorter/jquery.tablesorter.js"></script>
<script type="text/javascript" src="modules/EcmPaymentStates/javascript/summary.js"></script>
<script type="text/javascript" src="include/jQuery/html-table-search.js"></script>
<script>
{literal}
$(document).ready(function()
{
var n;
$('#myTable').tablesorter({
textExtraction : function(node, table, cellIndex){
n = $(node);
return n.attr('data-sort-value') || n.text();
}
});console.log('jaki znak?');
$('table.search-table').tableSearch({
searchText:'Szukaj',
searchPlaceHolder:'Kontrahent'
});
}
);
{/literal}
</script>
<style type="text/css">
{literal}
.line {
border-top: 1px solid black !important;;
}
thead, tfoot {font-weight: bold;}
tr
{
line-height:20px;
}
/* Extra selectors needed to override the default styling */
/* Extra selectors needed to override the default styling */
table.tablesorter tbody tr:hover td {
background: #A8E8E8;
color: #343432;
}
{/literal}
</style>
<table cellspacing="0" cellpadding="0" border="0">
<tr>
<td><h2>Rozrachunki: Salda</h2></td>
</tr>
</table>
<form action="index.php" method="post" name="searchForm">
<input type="hidden" name="module" value="EcmPaymentStates" />
<input type="hidden" name="action" value="summaryNew" />
<table style="border-top: 0px none; margin-bottom: 4px;width:100%" class="tabForm" border="0" cellpadding="0" cellspacing="0">
<tr>
<td class="dataLabel" width="10%" nowrap="nowrap">Rodzaj</td>
<td class="dataField" width="10%" nowrap="nowrap">
{if $account_type === null }
{html_options name=account_type id=account_type options=$account_type_list}
{else}
{html_options name=account_type id=account_type options=$account_type_list selected=$account_type}
{/if}
</td>
<td class="dataLabel" width="10%" nowrap="nowrap">Saldo</td>
<td class="dataField" width="10%" nowrap="nowrap">
<select id="saldo_type" name="saldo_type">
<option value="" {if $saldo_type eq ''} selected {/if}>Wszystkie</option>
<option value="plus" {if $saldo_type eq 'plus'} selected {/if}>Dodatnie</option>
<option value="minus" {if $saldo_type eq 'minus'} selected {/if}>Ujemne</option>
<option value="zero" {if $saldo_type eq 'zero'} selected {/if}>Zerowe</option>
</select>
</td>
<td class="dataLabel" width="10%" nowrap="nowrap">Saldo na dzień:</td>
<td class="dataField" width="10%" nowrap="nowrap">
<input placeholder="data" autocomplete="off" type="text" name="saldo_date_val" id="saldo_date_val" value="{$saldo_date_val}" title="" tabindex="" size="10" maxlength="10">
<img border="0" src="themes/Sugar5/images/jscalendar.gif?s=bed8cd35065048ceebdc639ebe305e2c&amp;c=1" alt="Wprowadź datę" id="saldo_date" align="absmiddle">
<script type="text/javascript">
{literal}
Calendar.setup ({
inputField : "saldo_date_val",
daFormat : "%d.%m.%Y",
button : "saldo_date",
singleClick : true,
dateStr : "",
step : 1,
weekNumbers:false
}
);
function generateString(){
var text= new Array();
$('input[name^="accounts_xls_id"]').each(function() {
if($(this).val()!=''){
text.push('accounts_xls_id[]='+$(this).val());
}
});
return text.join("&");
}
function isDate(txtDate)
{
var currVal = txtDate;
if(currVal == '')
return true;
var rxDatePattern = /^(\d{1,2})(\.)(\d{1,2})(\.)(\d{4})$/; //Declare Regex
var dtArray = currVal.match(rxDatePattern); // is format OK?
if (dtArray == null)
return false;
//Checks for dd/mm/yyyy
dtMonth = dtArray[3];
dtDay= dtArray[1];
dtYear = dtArray[5];
if (dtMonth < 1 || dtMonth > 12)
return false;
else if (dtDay < 1 || dtDay> 31)
return false;
else if ((dtMonth==4 || dtMonth==6 || dtMonth==9 || dtMonth==11) && dtDay ==31)
return false;
else if (dtMonth == 2)
{
var isleap = (dtYear % 4 == 0 && (dtYear % 100 != 0 || dtYear % 400 == 0));
if (dtDay> 29 || (dtDay ==29 && !isleap))
return false;
}
return true;
}
$(document).ready(function() {
var options = {
onComplete: function(cep) {
if(isDate(cep))
$('#saldo_date_val').css("color", "");
else
$('#saldo_date_val').css("color", "red");
return;
},
'translation': {
A: {pattern: /[0-3]/},
B: {pattern: /[0-9]/},
C: {pattern: /[0-1]/},
D: {pattern: /[0-9]/},
Y: {pattern: /[0-9]/}
},
selectOnFocus: true
};
$('#saldo_date_val').mask('AB.CD.YYYY', options);
});
{/literal}
</script></td>
<td class="dataLabel" width="10%" nowrap="nowrap">Typ</td>
<td class="dataField" width="10%" nowrap="nowrap">
<select id="type2" name="type2">
<option value="" {if $type eq ''} selected {/if}>Wszyscy</option>
{foreach from=$type2 item=i key=vv}
{if $vv==$type}
{assign var="ss" value="selected"}
{else}
{assign var="ss" value=""}
{/if}
<option value="{$vv}" {$ss}>{$i}</option>
{/foreach}
</select>
</td>
<td class="dataLabel" width="10%" nowrap="nowrap">Użytkownik</td>
<td class="dataField" width="10%" nowrap="nowrap">
<select id="user_id" name="user_id">
<option value="" {if $type eq ''} selected {/if}>Wszyscy</option>
{foreach from=$users item=i key=vv}
{if $vv==$user_id}
{assign var="ss" value="selected"}
{else}
{assign var="ss" value=""}
{/if}
<option value="{$vv}" {$ss}>{$i}</option>
{/foreach}
</select>
</td>
<td class="dataLabel" width="10%" nowrap="nowrap"><input class="button" name="submit" value="Wykonaj" type="submit"></td>
</tr>
</tbody>
</table>
</form>
<input type="button" value="PDF" id="productcard" name="productcard" onclick="{literal}if($('#div_pdf').css('display') == 'none'){$('#div_pdf').show('slow'); } else { $('#div_pdf').hide('slow'); }{/literal}" class="button" title="PDF">
<input type="button" value="XLS" id="productcard" name="productcard" onclick='{literal}window.open("index.php?to_pdf=1&module=Home&action=Export&settings="+generateString());{/literal}' class="button" title="XLS">
<div style="display:none;border: 1px solid rgb(204, 204, 204); background: rgb(230, 230, 230) none repeat scroll 0% 0%; padding: 5px; position: absolute;" id="div_pdf">
<form method="POST" target="_blank"
{if $account_type eq 'rec'} action="index.php?module=EcmPaymentStates&to_pdf=1&action=rap" {/if}
{if $account_type eq 'sup'} action="index.php?module=EcmPaymentStates&to_pdf=1&action=rap" {/if}
{if $account_type eq 'rs'} action="index.php?module=EcmPaymentStates&to_pdf=1&action=rap" {/if}>
<fieldset id="CreatePDF"><legend>Ustawienia PDF</legend>Typ&nbsp;<select name="pdf_type" id="pdf_type"><option value="0">Salda</option>
<option value="1">Salda z rozbiciem</option></select><br></fieldset>
<input type="hidden" name="idToPdf" value="{$idToPdf}">
<input type="hidden" name="type" value="{$saldo_type}">
<input type="hidden" name='title' value="Rozrachunki z{if $account_type eq 'rec'} Odbiorcami {/if}{if $account_type eq 'sup'} Dostawcami {/if}{if $account_type eq 'rs'} Odbiorca/Dostawca {/if} - salda {if $saldo_type eq ''} wszystki {/if}{if $saldo_type eq 'plus'} dodatnie {/if}{if $saldo_type eq 'minus'} ujemne {/if}
">
<input type="submit" name="submit" value="PDF">
</form>
</div>
<table cellpadding="0" cellspacing="0" border="0" class="tablesorter tablesorter-blue search-table" style="width:100%;" id="myTable">
<thead>
<tr>
<th class="oddListRowS1" style="text-align:left; width: 45%">
<p style="cursor: pointer;">{$MOD.LBL_SUMMARY_ACCOUNT}
{if $SORT.account == 'asc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_down.gif">
{elseif $SORT.account == 'desc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_up.gif">
{else}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow.gif">
{/if}
</p>
</th>
<th class="oddListRowS1" style="text-align:right; width: 10%">
<p style="cursor: pointer;">Saldo
{if $SORT.saldo == 'asc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_down.gif">
{elseif $SORT.saldo == 'desc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_up.gif">
{else}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow.gif">
{/if}
</p>
</th>
<th class="oddListRowS1" style="text-align:right; width: 10%">
<p style="cursor: pointer;">Saldo na dzień
{if $SORT.today_saldo == 'asc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_down.gif">
{elseif $SORT.today_saldo == 'desc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_up.gif">
{else}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow.gif">
{/if}
</p>
</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;">{$MOD.LBL_SUMMARY_OVERDUE_1_30}</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;">{$MOD.LBL_SUMMARY_OVERDUE_31_60}</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;">{$MOD.LBL_SUMMARY_OVERDUE_61_90}</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;">{$MOD.LBL_SUMMARY_OVERDUE_91_180}</th>
<th class="oddListRowS1" style="text-align:right;">{$MOD.LBL_SUMMARY_OVERDUE_181}</th>
</tr>
</thead>
<tbody>
{foreach from=$DATA item=ROW name=loop}
{if $smarty.foreach.loop.index % 2 == 1}
<tr>
{else}
<tr style="background-color: #e6e6e6;">
{/if}
<td class="oddListRowS1" style="text-align:left;">
<input type="hidden" value="{$ROW.id}" name="accounts_xls_id[]">
<a href="index.php?module=EcmPaymentStates&action=AccountPaymentStates&return_module=EcmPaymentStates&return_action=DetailView&parentTab=Rozrachunki&account_id={$ROW.id}">
{$ROW.name}
</a>
</td>
<td class="oddListRowS1" data-sort-value="{$ROW.saldo}" style="text-align:right;">{$ROW.saldo|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.today_saldo}" style="text-align:right;">{$ROW.today_saldo|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.2}" style="text-align:right;">{$ROW.2|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.3}" style="text-align:right;">{$ROW.3|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.4}" style="text-align:right;">{$ROW.4|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.5}" style="text-align:right;">{$ROW.5|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.6}" style="text-align:right;">{$ROW.6|number_format:2:",":"."} {$ROW.currency_id}</td>
</tr>
<tr id="details_{$ROW.id}" style="border-collapse: collapse; display:none;">
</tr>
{/foreach}
</tbody>
<tr>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
</tr>
{foreach from=$SUM key="key" item="item" name=loop}
<tfoot>
<td class="oddListRowS1" style="text-align:right;">Razem:</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.saldo|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.today_saldo|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.2|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.3|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.4|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.5|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.6|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
</tr>
<tfoot>
{/foreach}
</table>

View File

@@ -0,0 +1,311 @@
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery-table/jquery.appendGrid-1.3.1.css"/>
<link rel="stylesheet" type="text/css" href="include/jQuery/jquery-ui/themes/base/jquery-ui.css"/>
<script type="text/javascript" src="include/jQuery/jquery-2.1.0.min.js"></script>
<script type="text/javascript" src="include/jQuery/jquery-table/jquery.appendGrid-1.3.1.js"></script>
<script type="text/javascript" src="include/jQuery/jquery-ui/ui/jquery-ui.js"></script>
<script type="text/javascript" src="include/jQuery/tablesorter/jquery.tablesorter.js"></script>
<script type="text/javascript" src="include/jQuery/html-table-search.js"></script>
<script type="text/javascript" src="modules/EcmPaymentStates/javascript/summary.js"></script>
<script>
{literal}
$(document).ready(function()
{
/* $('table.search-table').tableSearch({
searchText:'Szukaj',
searchPlaceHolder:'Kontrahent'
});*/
}
);
{/literal}
</script>
<style type="text/css">
{literal}
.line {
border-top: 1px solid black !important;;
}
thead, tfoot {font-weight: bold;}
tr
{
line-height:20px;
}
/* Extra selectors needed to override the default styling */
/* Extra selectors needed to override the default styling */
table.tablesorter tbody tr:hover td {
background: #A8E8E8;
color: #343432;
}
{/literal}
</style>
<table cellspacing="0" cellpadding="0" border="0">
<tr>
<td><h2>Rozrachunki: Salda</h2></td>
</tr>
</table>
<form action="index.php" method="post" name="searchForm">
<input type="hidden" name="module" value="EcmPaymentStates" />
<input type="hidden" name="action" value="summaryNew" />
<table style="border-top: 0px none; margin-bottom: 4px;width:100%" class="tabForm" border="0" cellpadding="0" cellspacing="0">
<tr>
<td class="dataLabel" width="10%" nowrap="nowrap">Rodzaj Kontrahenta</td>
<td class="dataField" width="10%" nowrap="nowrap">
{if $account_type === '' }
{html_options name=account_type id=account_type options=$account_type_list selected='a' }
{else}
{html_options name=account_type id=account_type options=$account_type_list selected=$account_type}
{/if}
</td>
<td class="dataLabel" width="10%" nowrap="nowrap">Saldo</td>
<td class="dataField" width="10%" nowrap="nowrap">
<select id="saldo_type" name="saldo_type">
<option value="" {if $saldo_type eq ''} selected {/if}>Wszystkie</option>
<option value="plus" {if $saldo_type eq 'plus'} selected {/if}>Dodatnie</option>
<option value="minus" {if $saldo_type eq 'minus'} selected {/if}>Ujemne</option>
<option value="zero" {if $saldo_type eq 'zero'} selected {/if}>Zerowe</option>
</select>
</td>
<!-- <td class="dataLabel" width="10%" nowrap="nowrap">Saldo na dzień:</td>
<td class="dataField" width="10%" nowrap="nowrap">
<input placeholder="data" autocomplete="off" type="text" name="saldo_date_val" id="saldo_date_val" value="{$saldo_date_val}" title="" tabindex="" size="10" maxlength="10">
<img border="0" src="themes/Sugar5/images/jscalendar.gif?s=bed8cd35065048ceebdc639ebe305e2c&amp;c=1" alt="Wprowadź datę" id="saldo_date" align="absmiddle">
<script type="text/javascript">
{literal}
Calendar.setup ({
inputField : "saldo_date_val",
daFormat : "%d.%m.%Y",
button : "saldo_date",
singleClick : true,
dateStr : "",
step : 1,
weekNumbers:false
}
);
function generateString(){
var text= new Array();
$('input[name^="accounts_xls_id"]').each(function() {
if($(this).val()!=''){
text.push('accounts_xls_id[]='+$(this).val());
}
});
return text.join("&");
}
function isDate(txtDate)
{
var currVal = txtDate;
if(currVal == '')
return true;
var rxDatePattern = /^(\d{1,2})(\.)(\d{1,2})(\.)(\d{4})$/; //Declare Regex
var dtArray = currVal.match(rxDatePattern); // is format OK?
if (dtArray == null)
return false;
//Checks for dd/mm/yyyy
dtMonth = dtArray[3];
dtDay= dtArray[1];
dtYear = dtArray[5];
if (dtMonth < 1 || dtMonth > 12)
return false;
else if (dtDay < 1 || dtDay> 31)
return false;
else if ((dtMonth==4 || dtMonth==6 || dtMonth==9 || dtMonth==11) && dtDay ==31)
return false;
else if (dtMonth == 2)
{
var isleap = (dtYear % 4 == 0 && (dtYear % 100 != 0 || dtYear % 400 == 0));
if (dtDay> 29 || (dtDay ==29 && !isleap))
return false;
}
return true;
}
$(document).ready(function() {
var options = {
onComplete: function(cep) {
if(isDate(cep))
$('#saldo_date_val').css("color", "");
else
$('#saldo_date_val').css("color", "red");
return;
},
'translation': {
A: {pattern: /[0-3]/},
B: {pattern: /[0-9]/},
C: {pattern: /[0-1]/},
D: {pattern: /[0-9]/},
Y: {pattern: /[0-9]/}
},
selectOnFocus: true
};
$('#saldo_date_val').mask('AB.CD.YYYY', options);
});
{/literal}
</script></td> -->
<!--<td class="dataLabel" width="10%" nowrap="nowrap">Typ</td>
<td class="dataField" width="10%" nowrap="nowrap">
<select id="type2" name="type2">
<option value="" {if $type eq ''} selected {/if}>Wszyscy</option>
{foreach from=$type2 item=i key=vv}
{if $vv==$type}
{assign var="ss" value="selected"}
{else}
{assign var="ss" value=""}
{/if}
<option value="{$vv}" {$ss}>{$i}</option>
{/foreach}
</select>
</td> -->
<!--<td class="dataLabel" width="10%" nowrap="nowrap">Użytkownik</td>
<td class="dataField" width="10%" nowrap="nowrap">
<select id="user_id" name="user_id">
<option value="" {if $type eq ''} selected {/if}>Wszyscy</option>
{foreach from=$users item=i key=vv}
{if $vv==$user_id}
{assign var="ss" value="selected"}
{else}
{assign var="ss" value=""}
{/if}
<option value="{$vv}" {$ss}>{$i}</option>
{/foreach}
</select>
</td>-->
<td class="dataLabel" width="10%" nowrap="nowrap"><input class="button" name="submit" value="Wykonaj" type="submit"></td>
</tr>
</tbody>
</table>
</form>
<input type="button" value="PDF" id="productcard" name="productcard" onclick="{literal}if($('#div_pdf').css('display') == 'none'){$('#div_pdf').show('slow'); } else { $('#div_pdf').hide('slow'); }{/literal}" class="button" title="PDF">
<input type="button" value="XLS" id="productcard" name="productcard" onclick='{literal}window.open("index.php?to_pdf=1&module=Home&action=Export&settings="+generateString());{/literal}' class="button" title="XLS">
<div style="display:none;border: 1px solid rgb(204, 204, 204); background: rgb(230, 230, 230) none repeat scroll 0% 0%; padding: 5px; position: absolute;" id="div_pdf">
<form method="POST" target="_blank"
action="index.php?module=EcmPaymentStates&to_pdf=1&action=rap">
<fieldset id="CreatePDF"><legend>Ustawienia PDF</legend>Typ&nbsp;<select name="pdf_type" id="pdf_type"><option value="0">Salda</option>
<option value="1">Salda z rozbiciem</option></select><br></fieldset>
<input type="hidden" name="idToPdf" value="{$idToPdf}">
<input type="hidden" name="type" value="{$saldo_type}">
<input type="hidden" name='title' value="Rozrachunki z{if $account_type eq 'rec'} Odbiorcami {/if}{if $account_type eq 'sup'} Dostawcami {/if}{if $account_type eq 'rs'} Odbiorca/Dostawca {/if} - salda {if $saldo_type eq ''} wszystki {/if}{if $saldo_type eq 'plus'} dodatnie {/if}{if $saldo_type eq 'minus'} ujemne {/if}
">
<input type="submit" name="submit" value="PDF">
</form>
</div>
<table cellpadding="0" cellspacing="0" border="0" class="tablesorter tablesorter-blue search-table" style="width:100%;" id="myTable">
<thead>
<tr>
<th class="oddListRowS1" style="text-align:left; width: 10%">
<p style="cursor: pointer;">Index
{if $SORT.index == 'asc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_down.gif">
{elseif $SORT.index == 'desc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_up.gif">
{else}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow.gif">
{/if}
</p>
</th>
<th class="oddListRowS1" style="text-align:left; width: 38%">
<p style="cursor: pointer;">{$MOD.LBL_SUMMARY_ACCOUNT}
{if $SORT.account == 'asc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_down.gif">
{elseif $SORT.account == 'desc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_up.gif">
{else}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow.gif">
{/if}
</p>
</th>
<th class="oddListRowS1" style="text-align:right; width: 10%">
<p style="cursor: pointer;">Saldo
{if $SORT.saldo == 'asc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_down.gif">
{elseif $SORT.saldo == 'desc'}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow_up.gif">
{else}
<img width="8" height="10" border="0" align="absmiddle" alt="Sortuj" src="themes/Sugar5/images/arrow.gif">
{/if}
</p>
</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;">{$MOD.LBL_SUMMARY_OVERDUE_1_30}</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;">{$MOD.LBL_SUMMARY_OVERDUE_31_60}</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;">{$MOD.LBL_SUMMARY_OVERDUE_61_90}</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;">{$MOD.LBL_SUMMARY_OVERDUE_91_180}</th>
<th class="oddListRowS1" style="text-align:right; width: 7%;"">{$MOD.LBL_SUMMARY_OVERDUE_181}</th>
</tr>
</thead>
<tbody>
{foreach from=$DATA item=ROW name=loop}
{if $smarty.foreach.loop.index % 2 == 1}
<tr>
{else}
<tr style="background-color: #e6e6e6;">
{/if}
<td class="oddListRowS1" style="text-align:left;">
<input type="hidden" value="{$ROW.index}" name="accounts_xls_id[]">
{$ROW.index}
</td>
<td class="oddListRowS1" style="text-align:left;">
<input type="hidden" value="{$ROW.id}" name="accounts_xls_id[]">
<a target='_blank' href="index.php?module=EcmPaymentStates&action=AccountPaymentStates&return_module=EcmPaymentStates&return_action=DetailView&parentTab=Rozrachunki&account_id={$ROW.id}">
{$ROW.name}
</a>
</td>
<td class="oddListRowS1" data-sort-value="{$ROW.saldo}" style="text-align:right;">{$ROW.saldo|number_format:2:",":"."} {$ROW.currency_id}</td>
<!--<td class="oddListRowS1" data-sort-value="{$ROW.today_saldo}" style="text-align:right;">{$ROW.today_saldo|number_format:2:",":"."} {$ROW.currency_id}</td>
--><td class="oddListRowS1" data-sort-value="{$ROW.2}" style="text-align:right;">{$ROW.2|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.3}" style="text-align:right;">{$ROW.3|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.4}" style="text-align:right;">{$ROW.4|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.5}" style="text-align:right;">{$ROW.5|number_format:2:",":"."} {$ROW.currency_id}</td>
<td class="oddListRowS1" data-sort-value="{$ROW.6}" style="text-align:right;">{$ROW.6|number_format:2:",":"."} {$ROW.currency_id}</td>
</tr>
<tr id="details_{$ROW.id}" style="border-collapse: collapse; display:none;">
</tr>
{/foreach}
</tbody>
<tr>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
<td class='line'></td>
</tr>
{foreach from=$SUM key="key" item="item" name=loop}
<tfoot>
<td class="oddListRowS1" style="text-align:left;">Razem:</td>
<td class="oddListRowS1" style="text-align:left;"></td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.saldo|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.2|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.3|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.4|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.5|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
<td class="oddListRowS1" style="text-align:right;">{$SUM.$key.6|number_format:2:",":"."} {$SUM.$key.currency_id}</td>
</tr>
<tfoot>
{/foreach}
</table>

View File

@@ -0,0 +1,76 @@
<td style="border: 1px dashed #e6e6e6;" colspan=3 valign="top">
<img src="modules/EcmQuotes/images/deleterow.gif" style="cursor: pointer;" onclick="hideDetails('{$ID}')"/>
</td>
<td style="text-align: right; border: 1px dashed #e6e6e6;" valign="top">
<table style="width: 100%">
{foreach from=$D10 key=ID item=ROW name=loop}
<tr><td>
<a href="index.php?module=EcmTransactions&action=DetailView&record={$ROW.id}" target="new">
{$ROW.name}</a>&nbsp;&nbsp;</td><td>&nbsp;{$ROW.value}<br>{$ROW.settled}</td></tr>
{/foreach}
</table>
</td>
<td style="text-align: right; border: 1px dashed #e6e6e6;" valign="top">
<table style="width: 100%">
{foreach from=$D9 key=ID item=ROW name=loop}
<tr><td>
<a href="index.php?module=EcmTransactions&action=DetailView&record={$ROW.id}" target="new">
{$ROW.name}</a>&nbsp;&nbsp;</td><td>&nbsp;{$ROW.value}<br>{$ROW.settled}</td></tr>
{/foreach}
</table>
</td>
<td style="text-align: right; border: 1px dashed #e6e6e6;" valign="top">
<table style="width: 100%">
{foreach from=$D8 key=ID item=ROW name=loop}
<tr><td>
<a href="index.php?module=EcmTransactions&action=DetailView&record={$ROW.id}" target="new">
{$ROW.name}</a>&nbsp;&nbsp;</td><td>&nbsp;{$ROW.value}<br>{$ROW.settled}</td></tr>
{/foreach}
</table>
</td>
<td>&nbsp</td>
<td style="text-align: right; border: 1px dashed #e6e6e6;" valign="top">
<table style="width: 100%">
{foreach from=$D2 key=ID item=ROW name=loop}
<tr><td>
<a href="index.php?module=EcmTransactions&action=DetailView&record={$ROW.id}" target="new">
{$ROW.name}</a>&nbsp;&nbsp;</td><td>&nbsp;{$ROW.value}<br>{$ROW.settled}</td></tr>
{/foreach}
</table>
</td>
<td style="text-align: right; border: 1px dashed #e6e6e6;" valign="top">
<table style="width: 100%">
{foreach from=$D3 key=ID item=ROW name=loop}
<tr><td>
<a href="index.php?module=EcmTransactions&action=DetailView&record={$ROW.id}" target="new">
{$ROW.name}</a>&nbsp;&nbsp;</td><td>&nbsp;{$ROW.value}<br>{$ROW.settled}</td></tr>
{/foreach}
</table>
</td>
<td style="text-align: right; border: 1px dashed #e6e6e6;" valign="top">
<table style="width: 100%">
{foreach from=$D4 key=ID item=ROW name=loop}
<tr><td>
<a href="index.php?module=EcmTransactions&action=DetailView&record={$ROW.id}" target="new">
{$ROW.name}</a>&nbsp;&nbsp;</td><td>&nbsp;{$ROW.value}<br>{$ROW.settled}</td></tr>
{/foreach}
</table>
</td>
<td style="text-align: right; border: 1px dashed #e6e6e6;" valign="top">
<table style="width: 100%">
{foreach from=$D5 key=ID item=ROW name=loop}
<tr><td>
<a href="index.php?module=EcmTransactions&action=DetailView&record={$ROW.id}" target="new">
{$ROW.name}</a>&nbsp;&nbsp;</td><td>&nbsp;{$ROW.value}<br>{$ROW.settled}</td></tr>
{/foreach}
</table>
</td>
<td style="text-align: right; border: 1px dashed #e6e6e6;" valign="top">
<table style="width: 100%">
{foreach from=$D6 key=ID item=ROW name=loop}
<tr><td>
<a href="index.php?module=EcmTransactions&action=DetailView&record={$ROW.id}" target="new">
{$ROW.name}</a>&nbsp;&nbsp;</td><td>&nbsp;{$ROW.value}<br>{$ROW.settled}</td></tr>
{/foreach}
</table>
</td>