Email::activate_storage($user, 'imap');
break;
case 'ml_promo':
- $r = XDB::query('SELECT id FROM groups WHERE diminutif = {?}', $yearpromo);
- if ($r->numRows()) {
- $asso_id = $r->fetchOneCell();
- XDB::execute('INSERT IGNORE INTO group_members (uid, asso_id)
- VALUES ({?}, {?})',
- $uid, $asso_id);
- try {
- $mmlist = new MMList($user);
- $mmlist->subscribe("promo" . $yearpromo);
- } catch (Exception $e) {
- PlErrorReport::report($e);
- $page->trigError("L'inscription à la liste promo" . $yearpromo . " a échouée.");
+ if ($isX) {
+ $r = XDB::query('SELECT id FROM groups WHERE diminutif = {?}', $yearpromo);
+ if ($r->numRows()) {
+ $asso_id = $r->fetchOneCell();
+ XDB::execute('INSERT IGNORE INTO group_members (uid, asso_id)
+ VALUES ({?}, {?})',
+ $uid, $asso_id);
+ try {
+ $mmlist = new MMList($user);
+ $mmlist->subscribe("promo" . $yearpromo);
+ } catch (Exception $e) {
+ PlErrorReport::report($e);
+ $page->trigError("L'inscription à la liste promo" . $yearpromo . " a échouée.");
+ }
}
}
break;
<dd>
de recevoir les informations importantes de l'AX.
</dd>
+ {if $smarty.session.subState.edu_type eq 'X'}
<dt><label><input type="checkbox" checked="checked" name="ml_promo" /> ta promotion</label></dt>
<dd>
de recevoir les informations plus spécifiques de ta promotion pour pouvoir participer plus facilement aux événements
qu'elle organise. Nous t'inscrivons donc dans le groupe de la promotion {$smarty.session.subState.promo}.
</dd>
+ {/if}
<dt><label><input type="checkbox" checked="checked" name="imap" />sauvegardes d'emails</label></dt>
<dd>
d'avoir un accès de secours aux 30 derniers jours d'emails reçus sur ton adresse Polytechnique.org.