Overview
Comment: | Corriger statut cotisation |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk | stable |
Files: | files | file ages | folders |
SHA1: |
c5da0736f08a1ce88c53e4f2311d251e |
User & Date: | bohwaz on 2020-01-31 01:29:51 |
Other Links: | manifest | tags |
Context
2020-01-31
| ||
01:50 | Mise à jour test travis check-in: a9f23ad861 user: bohwaz tags: trunk | |
01:29 | Corriger statut cotisation check-in: c5da0736f0 user: bohwaz tags: trunk, stable | |
01:06 | * Gérer les fichiers CSV provenant des vieilles versions d'Excel pour Mac OS. * Ajouter la mention de la taille limite du fichier check-in: b81cf4d462 user: bohwaz tags: trunk, stable | |
Changes
Modified src/include/lib/Garradin/Membres/Cotisations.php from [cf23856e38] to [f4bbf2cd01].
︙ | ︙ | |||
343 344 345 346 347 348 349 350 351 352 353 354 355 356 | * @param integer $id Numéro de membre * @return array Liste des cotisations en cours de validité */ public function listSubscriptionsForMember($id) { $db = DB::getInstance(); return $db->get('SELECT c.*, CASE WHEN c.duree IS NOT NULL THEN date(cm.date, \'+\'||c.duree||\' days\') >= date() WHEN c.fin IS NOT NULL THEN (cm.id IS NOT NULL AND cm.date <= c.fin AND cm.date >= c.debut) WHEN cm.id IS NOT NULL THEN 1 ELSE 0 END AS a_jour, CASE WHEN c.duree IS NOT NULL THEN date(cm.date, \'+\'||c.duree||\' days\') WHEN c.fin IS NOT NULL THEN c.fin ELSE 1 END AS expiration, (julianday(date()) - julianday(CASE WHEN c.duree IS NOT NULL THEN date(cm.date, \'+\'||c.duree||\' days\') WHEN c.fin IS NOT NULL THEN c.fin END)) AS nb_jours | > | 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 | * @param integer $id Numéro de membre * @return array Liste des cotisations en cours de validité */ public function listSubscriptionsForMember($id) { $db = DB::getInstance(); return $db->get('SELECT c.*, MAX(cm.date), CASE WHEN c.duree IS NOT NULL THEN date(cm.date, \'+\'||c.duree||\' days\') >= date() WHEN c.fin IS NOT NULL THEN (cm.id IS NOT NULL AND cm.date <= c.fin AND cm.date >= c.debut) WHEN cm.id IS NOT NULL THEN 1 ELSE 0 END AS a_jour, CASE WHEN c.duree IS NOT NULL THEN date(cm.date, \'+\'||c.duree||\' days\') WHEN c.fin IS NOT NULL THEN c.fin ELSE 1 END AS expiration, (julianday(date()) - julianday(CASE WHEN c.duree IS NOT NULL THEN date(cm.date, \'+\'||c.duree||\' days\') WHEN c.fin IS NOT NULL THEN c.fin END)) AS nb_jours |
︙ | ︙ |