A lot has been rewritten, ext-teams added, ext-forced continued:
[mailer.git] / inc / libs / task_functions.php
index aed64ba5b1637628bb74d969077d41e59898bdfe..3d90337c23a286a42addf19b866e9281a4a77aa8 100644 (file)
@@ -326,20 +326,14 @@ ORDER BY
 
        // Both extensions must be there
        if ((isExtensionInstalledAndNewer('bonus', '0.2.3')) && (isExtensionActive('user'))) {
-               // Active rallye
-               if (isExtensionInstalledAndNewer('bonus', '0.6.9')) {
-                       // Add more bonus points here
-                       $USE = '(0';
-                       if (getConfig('bonus_click_yn') == 'Y') $USE .= ' + `turbo_bonus`';
-                       if (getConfig('bonus_login_yn') == 'Y') $USE .= ' + `login_bonus`';
-                       if (getConfig('bonus_order_yn') == 'Y') $USE .= ' + `bonus_order`';
-                       if (getConfig('bonus_stats_yn') == 'Y') $USE .= ' + `bonus_stats`';
-                       if (getConfig('bonus_ref_yn')   == 'Y') $USE .= ' + `bonus_ref`';
-                       $USE .= ')';
-               } else {
-                       // Old version ???
-                       $USE = 'turbo_bonus';
-               }
+               // Get more columns
+               $add = runFilterChain('add_bonus_points_user_columns', '');
+
+               // Active rallye, so add more point columns, if not empty
+               $USE = '`turbo_bonus`';
+               if (!empty($add)) {
+                       $USE = '(0' . $add . ')';
+               } // END - if
 
                // Init variable
                $lastOnline = '';