Clean code (use Adh constant and precise comment)
This commit is contained in:
parent
046215f64a
commit
f5ec96bfce
@ -69,7 +69,7 @@ $sql .= " d.morphy as code";
|
|||||||
$sql .= " FROM ".MAIN_DB_PREFIX."adherent as d";
|
$sql .= " FROM ".MAIN_DB_PREFIX."adherent as d";
|
||||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."subscription as s ON s.fk_adherent = d.rowid";
|
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."subscription as s ON s.fk_adherent = d.rowid";
|
||||||
$sql .= " WHERE d.entity IN (".getEntity('adherent').")";
|
$sql .= " WHERE d.entity IN (".getEntity('adherent').")";
|
||||||
$sql .= " AND d.statut <> -1"; // Not draft
|
$sql .= " AND d.statut <> ".Adherent::STATUS_DRAFT;
|
||||||
$sql .= " GROUP BY d.morphy";
|
$sql .= " GROUP BY d.morphy";
|
||||||
$foundphy = $foundmor = 0;
|
$foundphy = $foundmor = 0;
|
||||||
|
|
||||||
@ -104,7 +104,7 @@ $sql .= " d.morphy as code";
|
|||||||
$sql .= " FROM ".MAIN_DB_PREFIX."adherent as d";
|
$sql .= " FROM ".MAIN_DB_PREFIX."adherent as d";
|
||||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."subscription as s ON s.fk_adherent = d.rowid";
|
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."subscription as s ON s.fk_adherent = d.rowid";
|
||||||
$sql .= " WHERE d.entity IN (".getEntity('adherent').")";
|
$sql .= " WHERE d.entity IN (".getEntity('adherent').")";
|
||||||
$sql .= " AND d.statut >= 1"; // Active (not draft=-1, not resiliated=0)
|
$sql .= " AND d.statut >= 1"; // Active (not excluded=-2, not draft=-1, not resiliated=0)
|
||||||
$sql .= " GROUP BY d.morphy";
|
$sql .= " GROUP BY d.morphy";
|
||||||
$foundphy = $foundmor = 0;
|
$foundphy = $foundmor = 0;
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user