Réorganisation sortie bilan (onglets) + contrôle cohérence montant

This commit is contained in:
Jean-Christophe Engel 2026-07-13 10:25:11 +02:00
parent 9e620c3efb
commit 24707afd31
17 changed files with 327 additions and 173 deletions

View file

@ -92,7 +92,6 @@
{{:assign var="free_cessions." value=$line}}
{{/select}}
{{/select}}
{{*:debug linked_cessions=$linked_cessions free_cessions=$free_cessions total_cession=$total_cession*}}
{{:admin_header title="Immobilisation sortie du bilan" custom_css="./style.css" current="module_amortization"}}
{{if $_GET.from == "exit"}}
@ -100,7 +99,6 @@
{{else}}
{{:assign current="archived"}}
{{/if}}
{{*:include file="_nav.html" current=$current subcurrent="exit"*}}
{{if $_GET.ok}}
{{if $_GET.msg|match:"attach_cession"}}
@ -138,6 +136,15 @@
</dl>
</div>
{{if $linked_cessions == null && $free_cessions != null}}
<nav class="actions">
{{:linkbutton
label="Attacher une écriture de cession"
href="list_cessions.html?immo_doc_id=%s&filter=true&from=%s"|args:$_GET.immo_doc_id:$_GET.from shape="link"
target="_dialog"}}
</nav>
{{/if}}
<h3 class="ruler">Écriture de cession attachée à l'immobilisation</h3>
{{if $linked_cessions != null}}
<table class="list">
@ -190,51 +197,6 @@
</p>
{{/if}}
{{if $free_cessions}}
<h3 class="ruler">Autres écritures de cession</h3>
<table class="list">
<thead>
<tr>
<td class="num"></td>
<td>Date</td>
<td>Libellé</td>
<td class="nombre">Montant</td>
<td>N° compte</td>
<td>Compte</td>
<td class="actions"></td>
</tr>
</thead>
<tbody>
{{#foreach from=$free_cessions item="line"}}
{{:assign cession_url="%s/acc/transactions/details.php?id=%s"|args:$admin_url:$line.trans_id}}
{{:assign compte_url="%s/acc/accounts/journal.php?id=%s&year=%s"|args:$admin_url:$line.account_id:$line.year}}
<tr>
<td class="num"><a href="{{$cession_url}}">#{{$line.trans_id}}</a></td>
<td>{{$line.date|date_short}}</td>
<td>
{{if $line.line_label != null}}
{{$line.line_label}}
{{if $line.trans_label != $line.line_label}}
— {{$line.trans_label}}
{{/if}}
{{else}}
{{$line.trans_label}}
{{/if}}
</td>
<td class="money">{{"%f"|math:$line.amount|money_html:false|raw}}</td>
<td><a href="{{$compte_url}}">{{$line.account_code}}</a></td>
<td>{{$line.account_label}}</td>
<td class="actions">
{{:linkbutton label="Attacher" href="attach_cession.html?immo_doc_id=%s&cession_line_id=%s&from=exit"|args:$_GET.immo_doc_id:$line.line_id shape="plus"}}
</td>
</tr>
{{/foreach}}
</tbody>
</table>
{{/if}}
<form method="post" action="">
<p class="submit">
{{:button type="submit" name="backward" label="Revenir à l'étape précédente" shape="left" class="main"}}