From: Stéphane Jacob Date: Sun, 31 May 2009 12:46:22 +0000 (+0200) Subject: Fixes IsCandidate in reminders. X-Git-Tag: xorg/0.10.1~71 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=0e4b87b287fc40f2d33be0379980e16d6fa30055;p=platal.git Fixes IsCandidate in reminders. --- diff --git a/include/reminder/ax_letter.inc.php b/include/reminder/ax_letter.inc.php index 09abe5c..afa167e 100644 --- a/include/reminder/ax_letter.inc.php +++ b/include/reminder/ax_letter.inc.php @@ -44,7 +44,7 @@ class ReminderAxLetter extends Reminder informations importantes de l'AX."; } - public static function IsCandidate(User &$user) + public static function IsCandidate(User &$user, $candidate) { Platal::load('axletter', 'axletter.inc.php'); return !(AXLetter::subscriptionState()); diff --git a/include/reminder/email_backup.inc.php b/include/reminder/email_backup.inc.php index 53eb021..0dc5899 100644 --- a/include/reminder/email_backup.inc.php +++ b/include/reminder/email_backup.inc.php @@ -48,7 +48,7 @@ class ReminderEmailBackup extends Reminder sur ton adresse Polytechnique.org."; } - public static function IsCandidate(User &$user) + public static function IsCandidate(User &$user, $candidate) { require_once 'emails.inc.php'; $storage = new EmailStorage($user, 'imap'); diff --git a/include/reminder/gapps.inc.php b/include/reminder/gapps.inc.php index 3938db8..976399d 100644 --- a/include/reminder/gapps.inc.php +++ b/include/reminder/gapps.inc.php @@ -47,7 +47,7 @@ class ReminderGapps extends Reminder habituelle (en savoir plus)."; } - public static function IsCandidate(User &$user) + public static function IsCandidate(User &$user, $candidate) { require_once 'googleapps.inc.php'; return GoogleAppsAccount::account_status($user->id()); diff --git a/include/reminder/ml.inc.php b/include/reminder/ml.inc.php index 2e8deec..81a4766 100644 --- a/include/reminder/ml.inc.php +++ b/include/reminder/ml.inc.php @@ -85,7 +85,7 @@ class ReminderMl extends Reminder $page->assign_by_ref('lists', $lists); } - public static function IsCandidate(User &$user) + public static function IsCandidate(User &$user, $candidate) { $res = XDB::execute("SELECT COUNT(*) AS lists FROM register_subs diff --git a/include/reminder/nl.inc.php b/include/reminder/nl.inc.php index fe3d704..d6be4c1 100644 --- a/include/reminder/nl.inc.php +++ b/include/reminder/nl.inc.php @@ -45,7 +45,7 @@ class ReminderNl extends Reminder communauté des X."; } - public static function IsCandidate(User &$user) + public static function IsCandidate(User &$user, $candidate) { require_once 'newsletter.inc.php'; return !(Newsletter::subscriptionState()); diff --git a/include/reminder/profile_update.inc.php b/include/reminder/profile_update.inc.php index 2852707..5327b6c 100644 --- a/include/reminder/profile_update.inc.php +++ b/include/reminder/profile_update.inc.php @@ -76,7 +76,7 @@ class ReminderProfileUpdate extends Reminder (count($res) > 0 ? 1 : 0)); } - public static function IsCandidate(User &$user) + public static function IsCandidate(User &$user, $candidate) { $res = XDB::query('SELECT date < DATE_SUB(NOW(), INTERVAL 365 DAY) AS is_profile_old, p.attach AS photo diff --git a/include/reminder/promotion_ml.inc.php b/include/reminder/promotion_ml.inc.php index 6a70e67..ca36dca 100644 --- a/include/reminder/promotion_ml.inc.php +++ b/include/reminder/promotion_ml.inc.php @@ -58,7 +58,7 @@ class ReminderPromotionMl extends Reminder S::user()->promo() . '.'; } - public static function IsCandidate(User &$user) + public static function IsCandidate(User &$user, $candidate) { // We only test if the user is in her promotion group for it is too // expensive to check if she is in the corresponding ML as well.