Amélioration gestion numéro de reçu et impression adresse courriel
FossilOrigin-Name: 7ec287c7e2886a4a91151abf97e5044eb9bf1617063fc3d0c818b5d7ab88eafb
This commit is contained in:
parent
e219afb405
commit
25cba953a7
10 changed files with 249 additions and 126 deletions
|
|
@ -8,6 +8,8 @@ namespace Garradin\Plugin\RecusFiscaux;
|
|||
class Personne
|
||||
{
|
||||
public $id;
|
||||
public $numero;
|
||||
public $courriel;
|
||||
public $rang; // par ordre alpha de nomPrenom ; sert aux tris
|
||||
public $nomPrenom;
|
||||
public $adresse;
|
||||
|
|
@ -17,6 +19,8 @@ class Personne
|
|||
|
||||
public function __construct(
|
||||
$id,
|
||||
$numero,
|
||||
$courriel,
|
||||
$rang,
|
||||
$nomPrenom,
|
||||
$adresse,
|
||||
|
|
@ -25,6 +29,8 @@ class Personne
|
|||
)
|
||||
{
|
||||
$this->id = $id;
|
||||
$this->numero = $numero;
|
||||
$this->courriel = $courriel;
|
||||
$this->rang = $rang;
|
||||
$this->nomPrenom = $nomPrenom;
|
||||
$this->adresse = $adresse;
|
||||
|
|
@ -40,6 +46,8 @@ class Personne
|
|||
{
|
||||
return new Personne(
|
||||
$this->id,
|
||||
$this->numero,
|
||||
$this->courriel,
|
||||
$this->rang,
|
||||
$this->nomPrenom,
|
||||
$this->adresse,
|
||||
|
|
|
|||
|
|
@ -297,6 +297,8 @@ class Utils
|
|||
$sql = sprintf(
|
||||
'SELECT
|
||||
membres.id as idUser,
|
||||
membres.numero,
|
||||
membres.email,
|
||||
row_number() over(order by %s) as rang,
|
||||
%s as nom,
|
||||
membres.adresse as adresse,
|
||||
|
|
@ -327,6 +329,8 @@ class Utils
|
|||
foreach (DB::getInstance()->iterate($sql) as $personne)
|
||||
{
|
||||
$donateurs[$personne->idUser] = new Personne($personne->idUser,
|
||||
$personne->numero,
|
||||
$personne->email,
|
||||
$personne->rang,
|
||||
$personne->nom,
|
||||
$personne->adresse,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue