From: Vincent Zanotti Date: Mon, 17 Mar 2008 23:08:39 +0000 (+0100) Subject: Advertises GApps real name change in 'nom d'usage' validation email for active Google... X-Git-Tag: xorg/0.9.16~92 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=fc0342c3035e1c50f6ca8dcab9ed6bddf8ab5c0e;p=platal.git Advertises GApps real name change in 'nom d'usage' validation email for active Google Apps users. Signed-off-by: Vincent Zanotti --- diff --git a/include/validations/nomusage.inc.php b/include/validations/nomusage.inc.php index c3ff4bf..26181b6 100644 --- a/include/validations/nomusage.inc.php +++ b/include/validations/nomusage.inc.php @@ -92,6 +92,13 @@ class UsageReq extends Validate if ($this->nom_usage) { $res .= "\n\n Les alias {$this->alias}@{$globals->mail->domain} et @{$globals->mail->domain2} sont maintenant à ta disposition !"; } + if ($globals->mailstorage->googleapps_domain) { + require_once 'googleapps.inc.php'; + $account = new GoogleAppsAccount(S::v('uid'), S::v('forlife')); + if ($account->active()) { + $res .= "\n\n Si tu utilises Google Apps, tu peux changer ton nom d'usage sur https://mail.google.com/a/polytechnique.org/#settings/accounts"; + } + } return $res; } else { return " La demande de changement de nom d'usage que tu avais faite a été refusée.";