diff --git a/_archives.html b/_archives.html index 8a8f8ad..be33053 100644 --- a/_archives.html +++ b/_archives.html @@ -34,6 +34,7 @@ Montant N° compte Compte + Projet @@ -53,11 +54,13 @@ line.debit AS debit, account.id as account_id, account.code as account_code, - account.label as account_label + account.label as account_label, + project.label as project_label FROM acc_transactions AS trans INNER JOIN acc_transactions_lines AS line ON line.id_transaction = trans.id INNER JOIN acc_accounts AS account ON line.id_account = account.id INNER JOIN acc_years AS years ON trans.id_year = years.id + LEFT JOIN acc_projects AS project ON line.id_project = project.id WHERE !condition ORDER BY trans.date DESC; !condition=$condition @@ -152,8 +155,8 @@ {{"%f"|math:$montant_immo|money_html:false|raw}} {{$account_code}} {{$account_label}} + {{$project_label}} - {{:linkbutton label="Modifier" href="exit_step3.html?immo_doc_id=%s"|args:$info_immo.id shape="edit"}} {{/select}} diff --git a/_get_credit_lines.html b/_get_credit_lines.html index c06adc5..2bef7fb 100644 --- a/_get_credit_lines.html +++ b/_get_credit_lines.html @@ -3,8 +3,8 @@ {{* chercher des écritures liées à l'immo paramètre au crédit du même compte @param immo_doc_id : id du doc associé à l'immobilisation - @result linked_immos : liste des écritures liées - @result total_credits : montant total des écritures + @param linked_immos : liste des écritures liées + @param total_credits : montant total des écritures *}} {{:assign linked_immos=null}} {{:assign total_credits=0}} @@ -14,19 +14,14 @@ line.id as line_id, trans.id as trans_id, trans.label, - trans.date, - trans.id_year as year, - account.id as account_id, - account.code as account_code, - account.label as account_label + trans.date FROM acc_transactions_lines AS line INNER JOIN acc_transactions AS trans ON line.id_transaction = trans.id - INNER join acc_accounts AS account on line.id_account = account.id WHERE line.id = :credit_line_id; :credit_line_id=$credit_line_id }} {{:assign credit=$credit}} - {{:assign var="linked_immos." doc=$id trans_id=$trans_id credit_line_id=$line_id label=$label amount=$credit date=$date account_id=$account_id account_code=$account_code account_label=$account_label year=$year}} + {{:assign var="linked_immos." doc=$id trans_id=$trans_id credit_line_id=$line_id label=$label amount=$credit date=$date}} {{/select}} {{if $amount == null}} {{:assign total_credits="%d+%d"|math:$total_credits:$credit}} diff --git a/_immobilisations_autres.html b/_immobilisations_autres.html index bacef59..992e20c 100644 --- a/_immobilisations_autres.html +++ b/_immobilisations_autres.html @@ -172,8 +172,8 @@ label="Paramètres" href="add_infos.html?immo_line_id=%s"|args:$immo_line_id shape="settings" - target="_dialog" }} +{{* target="_dialog"*}} {{/foreach}} diff --git a/add_infos.html b/add_infos.html index d78097c..382025b 100644 --- a/add_infos.html +++ b/add_infos.html @@ -1,22 +1,21 @@ {{* -*- brindille -*- *}} {{* - Classer une immobilisation non prise en charge @param immo_line_id + + TODO ? : + - séparer les cas des immo simples et complexes (BOI) + par exemple pour la durée d'amort par défaut {{:input ...}} + - prise en charge immo => param = immo_line_id + - modif param immo => param = immo_doc_id *}} +{{* cas de la prise en charge *}} {{* données de l'immobilisation *}} {{:assign montant_affecte=0}} {{#load type="immo" where="$$.line = :line_id" :line_id=$_GET.immo_line_id|intval assign="info_immo"}} {{:assign montant_affecte="%d+%d"|math:$montant_affecte:$amount}} {{/load}} -{{if $info_immo != null}} - {{:assign date_defaut=$info_immo.date}} - {{:assign duree_defaut=$info_immo.duration}} - {{:assign choix_defaut=$info_immo.status}} -{{else}} - {{:assign duree_defaut=null}} -{{/if}} {{#select trans.id as immo_trans_id, @@ -60,7 +59,7 @@ type="immo" line=$_GET.immo_line_id|intval duration=0 - status="managed" + status="archived" assign_new_id="immo_doc_id" }} {{:redirect force="exit_step1.html?immo_doc_id=%s"|args:$immo_doc_id}} @@ -140,7 +139,7 @@ status=$status }} - {{if $_POST.classify == "managed"}} + {{if $_POST.amortir}} {{:assign type_immo="managed"}} {{else}} {{:assign type_immo="other"}} @@ -220,7 +219,6 @@ function toggleInputs(event) { const managed = classement_immo.querySelector('input[type=radio][value=managed]'); if (managed.checked) { g.toggle('.masquable', true); - document.getElementById('f_duree').focus(); } else { g.toggle('.masquable', false); } diff --git a/amortization.html b/amortization.html index 2613641..3efc74f 100644 --- a/amortization.html +++ b/amortization.html @@ -27,7 +27,7 @@ {{/if}} {{* déduire le montant des écritures liées à l'immo courante au crédit du même compte *}} -{{:include file="_get_credit_lines.html" immo_doc_id=$_GET.immo_doc_id keep="linked_immos, total_credits"}} +{{:include file="_get_credit_lines.html" immo_doc_id=$_GET.immo_doc_id keep="total_credits"}} {{:assign solde="%d-%d"|math:$ligne_immo.amount:$total_credits}} {{if $info_immo.status == "amortized"}} @@ -42,7 +42,7 @@ {{:assign valeur_residuelle="%d-%d"|math:$valeur_residuelle:$total_amort}} {{if $valeur_residuelle > 0}} - {{* lister les amortissements non attachés à une immo *}} + {{* lister les amortissements non rattachés à une immo *}} {{:include file="./_get_free_amort.html" filter_condition="1" keep="free_amort_lines"}} {{/if}} @@ -69,14 +69,10 @@ }} {{if $_GET.ok}} - {{if $_GET.msg|match:"attach_amort"}} - {{:assign msg="Attachement amortissement effectué"}} - {{elseif $_GET.msg|match:"detach_amort"}} - {{:assign msg="Détachement amortissement affectué"}} - {{elseif $_GET.msg|match:"attach_avoir"}} - {{:assign msg="Attachement avoir affectué"}} - {{elseif $_GET.msg|match:"detach_avoir"}} - {{:assign msg="Détachement avoir affectué"}} + {{if $_GET.msg|match:"attach"}} + {{:assign msg="Attachement amortissement %s effectué"|args:$_GET.trans_id}} + {{elseif $_GET.msg|match:"detach"}} + {{:assign msg="Détachement amortissement %s affectué"|args:$_GET.trans_id}} {{elseif $_GET.msg|match:"amortissement"}} {{:assign msg="Amortissement enregistré"}} {{/if}} @@ -108,49 +104,6 @@ - - -{{if $linked_immos != null}} - -{{/if}} -
Immobilisation
@@ -227,17 +180,15 @@ +{{else}} +

Aucun amortissement enregistré pour cette immobilisation

{{/if}} {{if $free_amort_lines}}

- Il y a des écritures d'amortissement qui ne sont pas attachées à une immobilisation !
- Utilisez le bouton « Attacher un amortissement » pour les afficher ; vous pourrez choisir d'en attacher certaines à cette immobilisation. + Il y a des écritures d'amortissement qui ne sont pas rattachées à une immobilisation !
+ Utilisez le bouton « Rattacher un amortissement » pour les afficher ; vous pourrez choisir d'en attacher certaines à cette immobilisation.

{{/if}} - -{{if $linked_amort == null}} -

Aucun amortissement enregistré pour cette immobilisation ; utilisez le bouton « Enregistrer un amortissement » pour enregistrer un nouvel amortissement

-{{/if}} {{:form_errors}} {{:admin_footer}} diff --git a/attach_amort.html b/attach_amort.html index adf9e5c..755ff70 100644 --- a/attach_amort.html +++ b/attach_amort.html @@ -144,9 +144,9 @@ {{/if}} {{if $_GET.from == "exit"}} - {{:redirect force="exit_step2.html?immo_doc_id=%s&ok=1&msg=attach_amort"|args:$_GET.immo_doc_id}} + {{:redirect to="exit_step2.html?immo_doc_id=%s"|args:$_GET.immo_doc_id}} {{else}} - {{:redirect force="amortization.html?immo_doc_id=%s&type_immo=%s&ok=1&msg=attach_amort"|args:$_GET.immo_doc_id:$status}} + {{:redirect to="amortization.html?immo_doc_id=%s&type_immo=%s&ok=1&msg=attach_amort"|args:$_GET.immo_doc_id:$status}} {{/if}} {{/form}} diff --git a/attach_credit.html b/attach_credit.html index 5028718..7cd7b16 100644 --- a/attach_credit.html +++ b/attach_credit.html @@ -125,11 +125,11 @@ {{/if}} {{if $_GET.from == "exit"}} - {{:redirect force="exit_step1.html?immo_doc_id=%s&ok=1&msg=attach_avoir"|args:$_GET.immo_doc_id}} + {{:redirect force="exit_step1.html?immo_doc_id=%s"|args:$_GET.immo_doc_id}} {{else}} - {{:redirect force="details_immo.html?immo_doc_id=%s&ok=1&msg=attach_credit"|args:$_GET.immo_doc_id}} - {{*:redirect force="amortization.html?immo_doc_id=%s&ok=1&msg=attach_avoir"|args:$_GET.immo_doc_id*}} + {{:redirect to="amortization.html?immo_doc_id=%s&ok=1&msg=attach_avoir"|args:$_GET.immo_doc_id}} {{/if}} +{{*:redirect to="details_immo.html?immo_doc_id=%s&ok=1&msg=attach_credit"|args:$_GET.immo_doc_id*}} {{/form}} {{:admin_header title="Écritures au crédit du compte d'immobilisation" custom_css="./style.css" current="module_amortization"}} diff --git a/delete_infos.html b/delete_infos.html index 8af819c..6ec1875 100644 --- a/delete_infos.html +++ b/delete_infos.html @@ -20,9 +20,10 @@ {{#select trans.id FROM acc_transactions_lines AS line - INNER JOIN !table AS credit_link ON $$.credit_line_id = line.id + INNER JOIN !table ON $$.credit_line_id = line.id INNER JOIN acc_transactions AS trans ON line.id_transaction = trans.id - WHERE $$.type = "credit_link" AND $$.immo_doc_id = :immo_doc_id + WHERE $$.type = + "credit_link" AND $$.immo_doc_id = :immo_doc_id ; !table = $module.table :immo_doc_id = $_GET.immo_doc_id|intval @@ -59,7 +60,8 @@ }} {{* supprimer les docs de liaison *}} - {{:delete type="credit_link" where="$$.immo_doc_id = :immo_doc_id" :immo_doc_id = $_GET.immo_doc_id|intval}} + {{:delete type="immo_link" where="$$.immo_doc_id = :immo_doc_id" :immo_doc_id = $_GET.immo_doc_id|intval}} + {{/if}} {{* supprimer les infos de l'immobilisation *}} diff --git a/detach_amort.html b/detach_amort.html index eba97ee..14be3bc 100644 --- a/detach_amort.html +++ b/detach_amort.html @@ -26,7 +26,7 @@ }} {{if $_GET.from == "exit"}} - {{:redirect force="exit_step2.html?immo_doc_id=%s&ok=1&msg=detach_amort"|args:$_GET.immo_doc_id}} + {{:redirect to="exit_step2.html?immo_doc_id=%s"|args:$_GET.immo_doc_id}} {{else}} - {{:redirect force="amortization.html?immo_doc_id=%s&ok=1&msg=detach_amort"|args:$_GET.immo_doc_id:}} + {{:redirect to="amortization.html?immo_doc_id=%s&ok=1&msg=detach_amort"|args:$_GET.immo_doc_id:}} {{/if}} diff --git a/detach_credit.html b/detach_credit.html index 1abc8d9..fb13fcc 100644 --- a/detach_credit.html +++ b/detach_credit.html @@ -25,8 +25,8 @@ }} {{if $_GET.from == "exit"}} - {{:redirect force="exit_step1.html?immo_doc_id=%s&ok=1&msg=detach_avoir"|args:$_GET.immo_doc_id}} + {{:redirect to="exit_step1.html?immo_doc_id=%s"|args:$_GET.immo_doc_id}} {{else}} - {{:redirect force="details_immo.html?immo_doc_id=%s&ok=1&msg=detach&"|args:$_GET.immo_doc_id}} - {{*:redirect force="amortization.html?immo_doc_id=%s&ok=1&msg=detach_avoir"|args:$_GET.immo_doc_id*}} + {{:redirect to="amortization.html?immo_doc_id=%s&ok=1&msg=detach_avoir&"|args:$_GET.immo_doc_id}} {{/if}} +{{*:redirect to="details_immo.html?immo_doc_id=%s&ok=1&msg=detach&"|args:$_GET.immo_doc_id*}} diff --git a/details_immo.html b/details_immo.html index ca3d93b..0896717 100644 --- a/details_immo.html +++ b/details_immo.html @@ -31,19 +31,25 @@ {{:admin_header title="Détails de l'immobilisation" custom_css="./style.css" current="module_amortization"}} +{{* {{if ! $dialog}} {{:assign subsubcurrent=null}} - {{if $total_amort == 0}} + {{if $total_credits == 0 && $total_amort == 0}} {{:assign subsubcurrent="credit"}} {{/if}} + {{if $total_amort == 0}} + {{:assign subsubcurrent=$subsubcurrent|cat:"-modif"}} + {{/if}} {{:include file="_nav.html" current="index" subcurrent="details" subsubcurrent=$subsubcurrent}} {{/if}} +*}} {{:assign trans_url="%s/acc/transactions/details.php?id=%s"|args:$admin_url:$ligne_immo.trans_id}} -{{* -*}} {{if $_GET.ok}} {{if $_GET.msg|match:"attach_amort"}} @@ -91,9 +96,7 @@ {{$line.date|date_short}} {{"%f"|math:$line.amount|money_currency_html:false|raw}} - {{if $total_amort == 0}} - {{:linkbutton label="Détacher" href="detach_credit.html?immo_doc_id=%s&credit_line_id=%s"|args:$_GET.immo_doc_id:$line.credit_line_id shape="minus"}} - {{/if}} + {{:linkbutton label="Détacher" href="detach_credit.html?immo_doc_id=%s&credit_line_id=%s"|args:$_GET.immo_doc_id:$line.credit_line_id shape="minus"}} {{/foreach}} diff --git a/exit_step1.html b/exit_step1.html index d3cc904..c736e67 100644 --- a/exit_step1.html +++ b/exit_step1.html @@ -27,11 +27,11 @@ {{* lister les amortissements liés à l'immobilisation *}} {{:include file="./_get_amort_lines.html" immo_doc_id=$_GET.immo_doc_id keep="linked_amort, total_amort"}} +{{* chercher des écritures au crédit du compte de l'immo sans doc associé *}} {{* - chercher des écritures au crédit du compte de l'immo sans doc associé - - line.credit < ligne_immo.amount => peut-être un avoir - - line.credit = ligne_immo.amount - avoirs => écriture de sortie du bilan -*}} + - line.credit < ligne_immo.amount => peut-être un avoir + - line.credit = ligne_immo.amount - avoirs => écriture de sortie du bilan + *}} {{#select trans.id as trans_id, trans.label as trans_label, @@ -51,12 +51,8 @@ acc.code = :acc_code AND line.credit > 0 AND credit_line_id NOT IN ( - SELECT json_extract(credit_link.document, '$.credit_line_id') AS line_id FROM !table as credit_link - WHERE json_extract(credit_link.document, '$.type') == "credit_link" - UNION - SELECT json_extract(exit_link.document, '$.exit_line_id') AS line_id FROM !table as exit_link - WHERE json_extract(exit_link.document, '$.type') == "exit_link" - ) + SELECT json_extract(link.document, '$.credit_line_id') AS line_id FROM !table as link + WHERE json_extract(link.document, '$.type') == "credit_link") ; :acc_code=$ligne_immo.account_code !table =$module.table @@ -64,6 +60,8 @@ }} {{if $credit_line.amount < $solde}} {{:assign var="credit_lines." value=$credit_line}} + {{elseif $credit_line.amount == $solde}} + {{:assign var="exit_lines." value=$credit_line}} {{/if}} {{/select}} @@ -124,15 +122,6 @@ {{:admin_header title="Immobilisation sortie du bilan" custom_css="./style.css" current="module_amortization"}} -{{if $_GET.ok}} - {{if $_GET.msg|match:"attach_avoir"}} - {{:assign msg="Écriture d'avoir attachée"}} - {{elseif $_GET.msg|match:"detach_avoir"}} - {{:assign msg="Écriture d'avoir détachée"}} - {{/if}} -

{{$msg}}

-{{/if}} -
Immobilisation
@@ -158,27 +147,25 @@ {{if $linked_immos != null}}

Écritures d'avoir attachées à l'immobilisation

+{{/if}} + +{{if $linked_immos != null}} - - {{#foreach from=$linked_immos item="line"}} {{:assign 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}} - - @@ -186,13 +173,9 @@ {{/foreach}}
Date Libellé MontantN° compteCompte
#{{$line.trans_id}} {{$line.date|date_short}} {{$line.label}} {{"%f"|math:$line.amount|money_currency_html:false|raw}}{{$line.account_code}}{{$line.account_label}} {{:linkbutton label="Détacher" href="detach_credit.html?immo_doc_id=%s&credit_line_id=%s&from=exit"|args:$_GET.immo_doc_id:$line.credit_line_id shape="minus"}}
-{{elseif $credit_lines}} -

- Vous pouvez attacher une ou plusieurs écritures d'avoir à votre immobilisation -

{{else}}

- Aucune écriture au crédit du compte d'immobilisation ; vous pouvez passer à la suite + Vous pouvez attacher une ou plusieurs écritures d'avoir à votre immobilisation

{{/if}} diff --git a/exit_step2.html b/exit_step2.html index 699b947..72deafe 100644 --- a/exit_step2.html +++ b/exit_step2.html @@ -1,16 +1,18 @@ {{* -*- brindille -*- *}} {{* - Associer les différentes écritures à une immo créée et sortie du - bilan avant la mise en service du module + Associer les différentes écritures à une immo créée avant la mise + en service du module et sortie du bilan @param immo_doc_id : id du doc associé à l'immobilisation *}} {{* données de l'immobilisation *}} -{{:include file="_get_immo_data.html" immo_doc_id=$_GET.immo_doc_id keep="info_immo, ligne_immo, message"}} +{{:include file="_get_immo_data.html" immo_doc_id=$_GET.immo_doc_id keep="ligne_immo, message"}} {{if $message != null}} {{:error message=$message}} {{/if}} +{{* voir si un document a été associé à l'immo *}} +{{#load id=$ligne_immo.line_id assign="info_immo"}}{{/load}} {{#form on="backward"}} {{:redirect to="exit_step1.html?immo_doc_id=%s"|args:$_GET.immo_doc_id}} @@ -35,6 +37,44 @@ {{* lister les amortissements liés à l'immobilisation *}} {{:include file="./_get_amort_lines.html" immo_doc_id=$_GET.immo_doc_id keep="linked_amort, total_amort"}} +{{* + chercher des écritures au crédit du compte de l'immo sans doc associé + - line.credit < ligne_immo.amount => peut-être un avoir + - line.credit = ligne_immo.amount - avoirs => écriture de sortie du bilan +*}} +{{#select + trans.id as trans_id, + trans.label as trans_label, + trans.date as date, + trans.id_year as year, + line.id as credit_line_id, + line.label as line_label, + line.credit as amount, + acc.id as account_id, + acc.code as account_code, + acc.label as account_label + FROM acc_transactions AS trans + INNER JOIN acc_transactions_lines AS line ON line.id_transaction = trans.id + INNER JOIN acc_accounts AS acc ON line.id_account = acc.id + LEFT JOIN module_data_amortization AS mda ON json_extract(mda.document, '$.amort_line_id') = line.id + WHERE + acc.code = :acc_code + AND line.credit > 0 + AND credit_line_id NOT IN ( + SELECT json_extract(link.document, '$.credit_line_id') AS line_id FROM !table as link + WHERE json_extract(link.document, '$.type') == "credit_link") + ; + :acc_code=$ligne_immo.account_code + !table =$module.table + assign="credit_line" + }} + {{if $credit_line.amount < $solde}} + {{:assign var="credit_lines." value=$credit_line}} + {{elseif $credit_line.amount == $solde}} + {{:assign var="exit_lines." value=$credit_line}} + {{/if}} +{{/select}} + {{* déterminer le compte d'amortissement en fonction du compte d'immobilisation *}} {{:include file="./_get_amort_code.html" @@ -92,15 +132,6 @@ {{:admin_header title="Immobilisation sortie du bilan" custom_css="./style.css" current="module_amortization"}} -{{if $_GET.ok}} - {{if $_GET.msg|match:"attach_amort"}} - {{:assign msg="Écriture d'amortissement attachée"}} - {{elseif $_GET.msg|match:"detach_amort"}} - {{:assign msg="Écriture d'amortissement détachée"}} - {{/if}} -

{{$msg}}

-{{/if}} -
Immobilisation
@@ -149,9 +180,6 @@ {{if $line.line_label != null}} {{$line.line_label}} - {{if $line.trans_label != $line.line_label}} - — {{$line.trans_label}} - {{/if}} {{else}} {{$line.trans_label}} {{/if}} @@ -166,19 +194,15 @@ {{/foreach}} -{{elseif $free_amort_lines}} -

- Vous pouvez attacher une ou plusieurs écritures d'amortissement à l'immobilisation -

{{else}}

- Aucune écriture d'amortissement à rattacher ; vous pouvez passer à la suite + Vous pouvez attacher une ou plusieurs écritures d'amortissement à votre immobilisation

{{/if}} +

Autres écritures d'amortissements

{{if $free_amort_lines}} -

Autres écritures d'amortissements

@@ -199,19 +223,8 @@ - diff --git a/exit_step3.html b/exit_step3.html index 671b415..045cdc5 100644 --- a/exit_step3.html +++ b/exit_step3.html @@ -1,11 +1,15 @@ {{* -*- brindille -*- *}} {{* - Associer les différentes écritures à une immo créée et sortie du - bilan avant la mise en service du module + Associer les différentes écritures à une immo créée avant la mise + en service du module et sortie du bilan @param immo_doc_id : id du doc associé à l'immobilisation *}} +{{* + TODO : affichage après attachement écriture sortie bilan (ligne attachée, bouton détacher) +*}} + {{* données de l'immobilisation *}} {{:include file="_get_immo_data.html" immo_doc_id=$_GET.immo_doc_id keep="info_immo, ligne_immo, message"}} {{if $message != null}} @@ -25,10 +29,6 @@ {{:redirect to="index.html?type_immo=archived"}} {{/form}} -{{#form on="finish"}} - {{:redirect to="index.html?type_immo=managed"}} -{{/form}} - {{:assign label_immo=$info_immo.label|or:$ligne_immo.trans_label}} {{if $ligne_immo.line_label != null && $ligne_immo.line_label != $label_immo}} {{:assign label_immo=$label_immo|cat:" — "|cat:$ligne_immo.line_label}} @@ -68,11 +68,11 @@ {{/select}} {{/if}} +{{* chercher des écritures au crédit du compte de l'immo sans doc associé *}} {{* - chercher des écritures au crédit du compte de l'immo sans doc associé - - line.credit < ligne_immo.amount => peut-être un avoir - - line.credit = ligne_immo.amount - avoirs => écriture de sortie du bilan -*}} + - line.credit < ligne_immo.amount => peut-être un avoir + - line.credit = ligne_immo.amount - avoirs => écriture de sortie du bilan + *}} {{#select trans.id as trans_id, trans.label as trans_label, @@ -103,7 +103,9 @@ !table =$module.table assign="credit_line" }} - {{if $credit_line.amount == $solde}} + {{if $credit_line.amount < $solde}} + {{:assign var="credit_lines." value=$credit_line}} + {{elseif $credit_line.amount == $solde}} {{:assign var="exit_lines." value=$credit_line}} {{/if}} {{/select}} @@ -231,9 +233,9 @@
#{{$line.amort_trans_id}} {{$line.date|date_short}} - {{if $line.line_label != null}} - {{$line.line_label}} - {{if $line.trans_label != $line.line_label}} - — {{$line.trans_label}} - {{/if}} - {{else}} - {{$line.trans_label}} - {{/if}} -{{* - {{$line.trans_label}} + {{$line.trans_label}} {{if $line.line_label != null && $line.line_label != $line.trans_label}} — {{$line.line_label}}{{/if}} -*}} {{"%f"|math:$line.amort_amount|money_html:false|raw}} {{$line.account_code}}
-{{elseif $exit_lines}} +{{else}}

- Vous pouvez attacher une écriture de sortie du bilan à l'immobilisation + Vous pouvez attacher une écriture de sortie du bilan à votre immobilisation

{{/if}} @@ -273,16 +275,14 @@ {{elseif $exit_line == null}} -

Aucune écriture de sortie du bilan. Vérifiez l'attachement d'écriture d'avoir.

+

Aucune écriture de sortie du bilan

{{/if}}

{{:button type="submit" name="backward" label="Revenir à l'étape précédente" shape="left" class="main"}} {{if $exit_line}} - {{:button type="submit" name="validate" label="Terminer" shape="check" class="main"}} - {{else}} - {{:button type="submit" name="finish" label="Terminer" shape="export" class="main"}} + {{:button type="submit" name="validate" label="Valider" shape="check" class="main"}} {{/if}}

diff --git a/link_immo.html b/link_immo.html index 77f5cd1..a05eab1 100644 --- a/link_immo.html +++ b/link_immo.html @@ -10,10 +10,6 @@ {{if $message != null}} {{:error message=$message}} {{/if}} -{{:assign label_immo=$ligne_immo.trans_label}} -{{if $ligne_immo.line_label != null && $ligne_immo.line_label != $label_immo}} - {{:assign label_immo=$label_immo|cat:" — "|cat:$ligne_immo.line_label}} -{{/if}} {{* lister les écritures au crédit du compte de l'immobilisation diff --git a/modify_infos.html b/modify_infos.html index 1b6d615..354b3f3 100644 --- a/modify_infos.html +++ b/modify_infos.html @@ -168,7 +168,7 @@ {{else}} {{:assign type_immo="other"}} {{/if}} - {{:redirect force="details_immo.html?immo_doc_id=%s&type_immo=%s&ok=1&msg=infos"|args:$_GET.immo_doc_id:$type_immo}} + {{:redirect force="index.html?ok=1&msg=infos&type_immo=%s"|args:$type_immo}} {{/form}} @@ -219,7 +219,6 @@ {{/if}} {{:input type="date" name="date_achat" label="Date d'acquisition" default=$info_immo.date_achat}} {{:input type="date" name="date_mes" label="Date de mise en service" default=$info_immo.date_mes}} -{{* {{if $linked_immos != null}}
@@ -234,7 +233,6 @@
{{/if}} -*}}
diff --git a/other_amortizations.html b/other_amortizations.html index 6838cbf..c08211b 100644 --- a/other_amortizations.html +++ b/other_amortizations.html @@ -32,12 +32,6 @@ {{* lister les amortissements non rattachés à une immo *}} {{:include file="./_get_free_amort.html" filter_condition=$filter_condition keep="free_amort_lines"}} -{{* déterminer le compte d'amortissement en fonction du compte d'immobilisation *}} -{{:include - file="./_get_amort_code.html" - code_immo=$ligne_immo.account_code - keep="code_amort" -}} {{:admin_header title="Amortissements non rattachés" custom_css="./style.css" current="module_amortization"}} {{* barre de navigation *}} @@ -58,7 +52,7 @@
- {{:input type="checkbox" value=1 name="unhide" checked="%s"|args:$checked label="Afficher toutes les écritures"}} + {{:input type="checkbox" value=1 name="unhide" checked="%s"|args:$checked label="Afficher les écritures ignorées"}}
@@ -79,23 +73,13 @@ {{#foreach from=$free_amort_lines item="line"}} - {{if $_POST.unhide == null && $line.account_code != $code_amort}} - {{:continue}} - {{/if}} {{:assign trans_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}} #{{$line.trans_id}} {{$line.trans_date|date_short}} - - {{if $line.line_label != null}} - {{$line.line_label}} - {{if $line.trans_label != $line.line_label}} - — {{$line.trans_label}} - {{/if}} - {{else}} - {{$line.trans_label}} - {{/if}} + {{$line.trans_label}} + {{if $line.line_label != null && $line.line_label != $line.trans_label}} - {{$line.line_label}}{{/if}} {{"%f"|math:$line.amount|money_html:false|raw}} {{$line.account_code}} diff --git a/transfer.html b/transfer.html index cb6643c..fdcbe3e 100644 --- a/transfer.html +++ b/transfer.html @@ -271,7 +271,6 @@ {{/foreach}} -