Harmonisation identifiants immobilisations et amortissements
This commit is contained in:
parent
8357b39d39
commit
92c47983e5
17 changed files with 109 additions and 110 deletions
|
|
@ -3,7 +3,7 @@
|
|||
{{*
|
||||
Enregistrer les écritures de sortie du bilan
|
||||
paramètres :
|
||||
- immo_id : numéro de ligne de l'écriture d'immobilisation
|
||||
- immo_line_id : numéro de ligne de l'écriture d'immobilisation
|
||||
- amort_amount : montant des amortissements
|
||||
- year : exercice de la date de sortie de l'immobilisation
|
||||
- date_mes : date de mise en service de l'immobilisation
|
||||
|
|
@ -24,8 +24,8 @@
|
|||
FROM acc_transactions_lines AS line
|
||||
INNER JOIN acc_transactions AS trans ON line.id_transaction = trans.id
|
||||
INNER JOIN acc_accounts AS acc ON line.id_account = acc.id
|
||||
WHERE line.id = :immo_id;
|
||||
:immo_id = $_GET.immo_id|intval
|
||||
WHERE line.id = :immo_line_id;
|
||||
:immo_line_id = $_GET.immo_line_id|intval
|
||||
assign="ligne_immo"
|
||||
}}
|
||||
{{/select}}
|
||||
|
|
@ -35,7 +35,7 @@
|
|||
*}}
|
||||
{{:assign total_credits=0}}
|
||||
{{#select
|
||||
CASE links.id_related = :immo_id
|
||||
CASE links.id_related = :immo_trans_id
|
||||
WHEN true THEN links.id_transaction
|
||||
WHEN false THEN links.id_related
|
||||
END as other_id,
|
||||
|
|
@ -45,8 +45,8 @@
|
|||
ON (trans.id = links.id_transaction OR trans.id = links.id_related)
|
||||
INNER JOIN acc_transactions_lines AS line on line.id_transaction = other_id
|
||||
INNER JOIN acc_accounts AS acc ON line.id_account = acc.id
|
||||
WHERE trans.id = :immo_id AND line.credit > 0 AND acc.code = :account;
|
||||
:immo_id=$ligne_immo.trans_id
|
||||
WHERE trans.id = :immo_trans_id AND line.credit > 0 AND acc.code = :account;
|
||||
:immo_trans_id=$ligne_immo.trans_id
|
||||
:account=$ligne_immo.account_code
|
||||
}}
|
||||
{{:assign total_credits="%d+%d"|math:$total_credits:$credit}}
|
||||
|
|
@ -258,7 +258,7 @@
|
|||
key=""|uuid
|
||||
validate_schema="schema.json"
|
||||
type="immo"
|
||||
line=$_GET.immo_id|intval
|
||||
line=$_GET.immo_line_id|intval
|
||||
duration=$_GET.duree_amort|intval
|
||||
date=$_GET.date_mes|date:"Y-m-d"
|
||||
status="archived"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue