Merge commit 'origin/master' into account
[platal.git] / include / reminder / promotion_ml.inc.php
index b67b59b..dca2fc1 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /***************************************************************************
- *  Copyright (C) 2003-2009 Polytechnique.org                              *
+ *  Copyright (C) 2003-2010 Polytechnique.org                              *
  *  http://opensource.polytechnique.org/                                   *
  *                                                                         *
  *  This program is free software; you can redistribute it and/or modify   *
@@ -26,11 +26,11 @@ class ReminderPromotionMl extends Reminder
         switch ($action) {
           case 'yes':
             $res = XDB::query('SELECT  id
-                                 FROM  groupex.asso
+                                 FROM  groups
                                 WHERE  diminutif = {?}',
                             S::v('promo'));
             $asso_id = $res->fetchOneCell();
-            XDB::execute('REPLACE INTO  groupex.membres (uid, asso_id)
+            XDB::execute('REPLACE INTO  group_members (uid, asso_id)
                                 VALUES  ({?}, {?})',
                          S::v('uid'), $asso_id);
             $mmlist = new MMList(S::v('uid'), S::v('password'));
@@ -67,9 +67,9 @@ class ReminderPromotionMl extends Reminder
         // 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.
         $res = XDB::query('SELECT  COUNT(*)
-                             FROM  groupex.membres
+                             FROM  group_members
                             WHERE  uid = {?} AND asso_id = (SELECT  id
-                                                              FROM  groupex.asso
+                                                              FROM  groups
                                                              WHERE  diminutif = {?})',
                           $user->id(), S::v('promo'));