Ajout totaux dans les onglets Amortissables, Amorties et En cours
This commit is contained in:
parent
900b0f5a47
commit
3e9f215816
4 changed files with 119 additions and 4 deletions
|
|
@ -72,6 +72,7 @@
|
|||
{{*:debug condition=$condition*}}
|
||||
|
||||
{{:assign nb_immo=0}}
|
||||
{{:assign total_immo = 0}}
|
||||
{{#select
|
||||
trans.id as trans_id,
|
||||
trans.label as trans_label,
|
||||
|
|
@ -122,6 +123,9 @@
|
|||
{{:assign trans_url="%s/acc/transactions/details.php?id=%s"|args:$admin_url:$trans_id}}
|
||||
{{:assign compte_url="%s/acc/accounts/journal.php?id=%s&year=%s"|args:$admin_url:$account_id:$trans_id_year}}
|
||||
{{:assign nb_immo="%d+1"|math:$nb_immo}}
|
||||
{{:assign total_immo="%d+%d"|math:$total_immo:$debit}}
|
||||
{{:assign var="montant" from="sommes_immo.%s"|args:$account_code}}
|
||||
{{:assign var="sommes_immo.%s"|args:$account_code value="%d+%d"|math:$montant:$debit}}
|
||||
|
||||
<tr>
|
||||
<td class="check">{{:input type="checkbox" name="selected[]" value=$trans_id}}</td>
|
||||
|
|
@ -145,6 +149,20 @@
|
|||
</table>
|
||||
{{if $nb_immo == 0}}
|
||||
<p class="block alert">Aucune immobilisation</p>
|
||||
{{else}}
|
||||
<aside class="describe totals">
|
||||
<h3 class="ruler">Totaux</h3>
|
||||
{{if $total_immo != 0}}
|
||||
<dl class="describe">
|
||||
{{#foreach from=$sommes_immo|ksort key="code" item="value"}}
|
||||
<dt>Total du compte {{$code}}</dt>
|
||||
<dd>{{$value|money}}
|
||||
{{/foreach}}
|
||||
<dt>Montant total des immobilisations</dt>
|
||||
<dd><span class="strong">{{$total_immo|money}}</span></dd>
|
||||
</dl>
|
||||
{{/if}}
|
||||
</aside>
|
||||
{{/if}}
|
||||
</section>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue