Classification des immobilisations par lot
This commit is contained in:
parent
79e536a0b3
commit
bb7cbc9d3b
8 changed files with 167 additions and 60 deletions
|
|
@ -58,18 +58,16 @@
|
|||
{{: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 duration=null}}
|
||||
|
||||
{{* voir si l'immo est prise en charge *}}
|
||||
{{#load type="immo" where="$$.line = :line_id" :line_id=$immo_id|intval}}
|
||||
{{:assign duration=$duration}}
|
||||
{{if $status == "ignored"}}
|
||||
{{:assign amortissable="non"}}
|
||||
{{else}}
|
||||
{{:assign amortissable="oui"}}
|
||||
{{/if}}
|
||||
{{:assign status=$status}}
|
||||
{{else}}
|
||||
{{:assign amortissable="nsp"}}
|
||||
{{:assign status="unknown"}}
|
||||
{{/load}}
|
||||
{{if $amortissable == "non"}}
|
||||
{{if $status == "ignored"}}
|
||||
{{:continue}}
|
||||
{{/if}}
|
||||
|
||||
|
|
@ -93,8 +91,9 @@
|
|||
:line_id = $immo_id|intval
|
||||
}}
|
||||
{{:assign ignore=true}}
|
||||
{{:assign status="archived"}}
|
||||
{{/select}}
|
||||
{{if $ignore}}
|
||||
{{if $status == "archived"}}
|
||||
{{:continue}}
|
||||
{{/if}}
|
||||
|
||||
|
|
@ -132,13 +131,12 @@
|
|||
{{/if}}
|
||||
{{/select}}
|
||||
|
||||
|
||||
{{* classement par onglet *}}
|
||||
{{if $type_immo == "encours" && $amort_amount >= $debit ||
|
||||
$type_immo == "amortie" && $amort_amount < $debit ||
|
||||
$amortissable == "nsp" && ! $exist_amort
|
||||
}}
|
||||
{{:continue}}
|
||||
{{/if}}
|
||||
{{if $type_immo == "encours" && $amort_amount >= $debit}}{{:continue}}{{/if}}
|
||||
{{if $type_immo == "encours" && $status == "amortized"}}{{:continue}}{{/if}}
|
||||
{{if $status == "unknown" && ! $exist_amort}}{{:continue}}{{/if}}
|
||||
{{if $type_immo == "amortie" && $amort_amount < $debit && $status != "amortized"}}{{:continue}}{{/if}}
|
||||
{{:assign nb_immo="%d+1"|math:$nb_immo}}
|
||||
<tr>
|
||||
<td class="num"><a href={{$trans_url}}>#{{$trans_id}}</a></td>
|
||||
|
|
@ -156,7 +154,7 @@
|
|||
shape="settings"
|
||||
target="_dialog"
|
||||
}}
|
||||
{{elseif $amortissable == "nsp"}}
|
||||
{{elseif $status == "unknown"}}
|
||||
{{:linkbutton
|
||||
label="Paramètres"
|
||||
href="add_infos.html?immo_id=%s&amort=1&op=new&type_immo=%s"|args:$immo_id:$type_immo
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue