From: Raphaël Barrois Date: Wed, 23 Jun 2010 00:46:25 +0000 (+0200) Subject: Fix display of pending marketings (Closes #1117) X-Git-Tag: xorg/1.0.0~84 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=11f2c0a75264106fe46a897453b00d375fabf027;p=platal.git Fix display of pending marketings (Closes #1117) Signed-off-by: Raphaël Barrois --- diff --git a/modules/marketing.php b/modules/marketing.php index d382124..d5f9ed8 100644 --- a/modules/marketing.php +++ b/modules/marketing.php @@ -301,11 +301,13 @@ class MarketingModule extends PLModule if (!is_null($promo)) { - $it = XDB::iterator('SELECT m.uid, m.email + $it = XDB::iterator('SELECT m.uid, m.email, s.alias AS forlife FROM register_marketing AS m INNER JOIN account_profiles AS ap ON (m.uid = ap.uid AND FIND_IN_SET(\'owner\', ap.perms)) INNER JOIN profile_display AS pd ON (pd.pid = ap.pid) - WHERE pd.promo = {?}', $promo); + LEFT JOIN aliases AS s ON (m.sender = s.uid AND s.type = \'a_vie\') + WHERE pd.promo = {?} + ORDER BY pd.sort_name', $promo); $page->assign('addr', $it); } }