diff --git a/htdocs/adherents/cotisations.php b/htdocs/adherents/cotisations.php index e9691e63d75..5266f2051af 100644 --- a/htdocs/adherents/cotisations.php +++ b/htdocs/adherents/cotisations.php @@ -63,6 +63,7 @@ if(isset($date_select) && $date_select != ''){ } $result = $db->query($sql); $Total=array(); +$Number=array(); if ($result) { $num = $db->num_rows(); @@ -71,6 +72,7 @@ if ($result) { $objp = $db->fetch_object( $i); $Total[strftime("%Y",$objp->dateadh)]+=price($objp->cotisation); + $Number[strftime("%Y",$objp->dateadh)]+=1; $i++; } } @@ -93,12 +95,14 @@ if ($result) print "
| Annee | "; + print 'Montant | '; print "Montant | "; + print "Moyenne | \n"; // print "Prenom Nom / Société | "; print "
| $key | ".price($value)." | |||
| $key | ".price($value)." | ".$Number[$key]." | ".price($value/$Number[$key])." |