Correction pour exercice sur 2 années civiles
FossilOrigin-Name: 24d7a87d9007dfb118ffb7a612b9eae155b1f45cb7f05577dc389240b848014d
This commit is contained in:
parent
457ee5f958
commit
86bc9c8ae1
|
@ -52,6 +52,7 @@ class Utils
|
|||
$sql = sprintf(
|
||||
'SELECT
|
||||
acc_accounts.id,
|
||||
acc_years.label,
|
||||
acc_accounts.code as codeCompte,
|
||||
acc_accounts.label as nomCompte
|
||||
FROM acc_transactions_users
|
||||
|
@ -63,12 +64,14 @@ class Utils
|
|||
ON acc_transactions_lines.id_transaction = acc_transactions.id
|
||||
INNER JOIN acc_accounts
|
||||
ON acc_transactions_lines.id_account = acc_accounts.id
|
||||
INNER JOIN acc_years
|
||||
ON acc_transactions.id_year = acc_years.id
|
||||
WHERE
|
||||
(strftime("%%Y", acc_transactions.date) = "%d"
|
||||
AND
|
||||
acc_accounts.%s
|
||||
)
|
||||
GROUP by acc_accounts.code
|
||||
GROUP by acc_accounts.id
|
||||
ORDER by acc_accounts.code',
|
||||
$annee,
|
||||
$db->where('code', $op, $comptes)
|
||||
|
|
|
@ -34,6 +34,7 @@
|
|||
$tarifCourant = $versement->idTarif;
|
||||
$personneCourante = $versement->idUser;
|
||||
$compteCourant = $versement->idCompte;
|
||||
$codeCompte = $versement->codeCompte;
|
||||
?>
|
||||
{afficher_debut_tarif versement=$versement}
|
||||
{afficher_debut_personne user=$personneCourante idVersement="%s_%s"|args:$tarifCourant,$personneCourante}
|
||||
|
@ -48,6 +49,7 @@
|
|||
$tarifCourant = $versement->idTarif;
|
||||
$personneCourante = $versement->idUser;
|
||||
$compteCourant = $versement->idCompte;
|
||||
$codeCompte = $versement->codeCompte;
|
||||
?>
|
||||
{afficher_debut_tarif versement=$versement}
|
||||
{afficher_debut_personne user=$personneCourante idVersement="%s_%s"|args:$tarifCourant,$personneCourante}
|
||||
|
@ -60,15 +62,17 @@
|
|||
$pair = true;
|
||||
$personneCourante = $versement->idUser;
|
||||
$compteCourant = $versement->idCompte;
|
||||
$codeCompte = $versement->codeCompte;
|
||||
?>
|
||||
{afficher_debut_personne user=$personneCourante idVersement="%s_%s"|args:$tarifCourant,$personneCourante}
|
||||
{afficher_debut_compte idCompte=$compteCourant}
|
||||
{elseif $versement.idCompte != $compteCourant}
|
||||
{elseif $versement.codeCompte != $codeCompte}
|
||||
{fin_compte}
|
||||
{* changement de compte *}
|
||||
<?php
|
||||
$pair = true;
|
||||
$compteCourant = $versement->idCompte;
|
||||
$codeCompte = $versement->codeCompte;
|
||||
?>
|
||||
{afficher_debut_compte idCompte=$compteCourant}
|
||||
{else}
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
form="versements_personnes"
|
||||
formaction="generer_recus.php?type=personne&format=pdf"
|
||||
onclick="return verifierChoix(this.form)"}
|
||||
{button type="submit" target="_dialog" label="Imprimer les reçus" shape="print"
|
||||
{button type="submit" label="Imprimer les reçus" shape="print"
|
||||
form="versements_personnes"
|
||||
formaction="generer_recus.php?type=personne&format=print"
|
||||
onclick="return verifierChoix(this.form)"}
|
||||
|
@ -25,12 +25,14 @@
|
|||
|
||||
{* Itération sur les personnes *}
|
||||
{foreach from=$lesVersements key="rang" item="versement"}
|
||||
|
||||
{if $rang == 0}
|
||||
{* 1ère personne *}
|
||||
<?php
|
||||
$pair = true;
|
||||
$personneCourante = $versement->idUser;
|
||||
$compteCourant = $versement->idCompte;
|
||||
$codeCompte = $versement->codeCompte;
|
||||
?>
|
||||
{afficher_debut_personne user=$personneCourante idVersement=$personneCourante}
|
||||
{afficher_debut_compte idCompte=$compteCourant}
|
||||
|
@ -42,15 +44,17 @@
|
|||
$pair = true;
|
||||
$personneCourante = $versement->idUser;
|
||||
$compteCourant = $versement->idCompte;
|
||||
$codeCompte = $versement->codeCompte;
|
||||
?>
|
||||
{afficher_debut_personne user=$personneCourante idVersement=$personneCourante}
|
||||
{afficher_debut_compte idCompte=$compteCourant}
|
||||
{elseif $versement.idCompte != $compteCourant}
|
||||
{elseif $versement.codeCompte != $codeCompte}
|
||||
{fin_compte}
|
||||
{* changement de compte *}
|
||||
<?php
|
||||
$pair = true;
|
||||
$compteCourant = $versement->idCompte;
|
||||
$codeCompte = $versement->codeCompte;
|
||||
?>
|
||||
{afficher_debut_compte idCompte=$compteCourant}
|
||||
{else}
|
||||
|
|
Loading…
Reference in New Issue