X-Git-Url: http://git.polytechnique.org/?a=blobdiff_plain;f=include%2Freminder%2Fgapps.inc.php;h=a420070a21ede9269c783bf0c315a5ad81866403;hb=7c7d62fce3e3973b576ffbc4051ba443d6a6b849;hp=de0c0e97a39f5c60b17cd296cc2e6e7690df2139;hpb=27531a1312c2ab7134deffa169f72907e4edfeb8;p=platal.git diff --git a/include/reminder/gapps.inc.php b/include/reminder/gapps.inc.php index de0c0e9..a420070 100644 --- a/include/reminder/gapps.inc.php +++ b/include/reminder/gapps.inc.php @@ -25,7 +25,7 @@ class ReminderGapps extends Reminder { switch ($action) { case 'yes': - $this->UpdateOnYes(); + $this->UpdateOnDismiss(); pl_redirect('googleapps'); break; @@ -39,12 +39,9 @@ class ReminderGapps extends Reminder } } - public function text() + public function template() { - return "Polytechnique.org te fournit un compte Google Apps qui te permet - de disposer des applications web de Google (GMail, Google Calendar, - Google Docs, et bien d'autres) sur ton adresse Polytechnique.org - habituelle (en savoir plus)."; + return 'reminder/gapps.tpl'; } public function title() { @@ -59,6 +56,9 @@ class ReminderGapps extends Reminder { require_once 'googleapps.inc.php'; $isSubscribed = GoogleAppsAccount::account_status($user->id()); + if ($isSubscribed == 'disabled') { + $isSubscribed = false; + } if ($isSubscribed) { Reminder::MarkCandidateAsAccepted($user->id(), $candidate); }