From: Roland Häder Date: Wed, 24 Oct 2012 20:33:43 +0000 (+0000) Subject: Extension ext-top10 improved: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=e6d652be2682d4b095b055274303aafcb88826fa;p=mailer.git Extension ext-top10 improved: - calculation of top earners changed - added notice about above change - moved out text to language file --- diff --git a/inc/language/top10_de.php b/inc/language/top10_de.php index 03f7c011be..10e01b4145 100644 --- a/inc/language/top10_de.php +++ b/inc/language/top10_de.php @@ -42,8 +42,20 @@ if (!defined('__SECURITY')) { // Language definitions addMessages(array( + // Admin - config 'ADMIN_CONFIG_TOP10_TITLE' => "Einstellungen an TOP-Listen", 'ADMIN_CONFIG_TOP10_MAX_TOP10' => "Maximale Plätze pro Liste", + + // Guest - title + 'GUEST_TOP10_LOGINS_TITLE' => "TOP{?top10_max?} - Logins", + 'GUEST_TOP10_EARNER_TITLE' => "TOP{?top10_max?} - {?POINTS?}-Verdiener", + 'GUEST_TOP10_REFERRAL_TITLE' => "TOP{?top10_max?} - Werber", + + // Guest - notice + 'GUEST_TOP10_LOGINS_NOTICE' => "Diese Liste zeigt Ihnen, wer am häufigsten eingeloggt hat.", + 'GUEST_TOP10_EARNER_NOTICE1' => "Diese Liste zeigt Ihnen, wer die meisten {?POINTS?} selber verdient hat.", + 'GUEST_TOP10_EARNER_NOTICE2' => "Seit dem Update vom 24.10.2012 wird nicht mehr der Abzug verrechnet aber dafür der gesperrte Eigenverdienst mit verrechnet.", + 'GUEST_TOP10_REFERRAL_NOTICE' => "Diese Liste zeigt Ihnen, wer die meisten Mitglieder geworben hat.", )); // [EOF] diff --git a/inc/modules/guest/what-top10.php b/inc/modules/guest/what-top10.php index db8fb817a3..190bfd144d 100644 --- a/inc/modules/guest/what-top10.php +++ b/inc/modules/guest/what-top10.php @@ -102,24 +102,24 @@ SQL_FREERESULT($result); // TOP earners $result = SQL_QUERY("SELECT - d.userid, - (SUM(p.points) - d.used_points) AS `points`, - d.last_online + d.`userid`, + SUM(p.`points` + p.`locked_points`) AS `points`, + d.`last_online` FROM - `{?_MYSQL_PREFIX?}_user_data` AS d + `{?_MYSQL_PREFIX?}_user_data` AS `d` LEFT JOIN - {?_MYSQL_PREFIX?}_user_points AS p + {?_MYSQL_PREFIX?}_user_points AS `p` ON - p.userid=d.userid + p.`userid`=d.`userid` WHERE - p.points > 0 AND + p.`points` > 0 AND d.`status`='CONFIRMED' " . runFilterChain('user_exclusion_sql', ' ') . " GROUP BY - p.userid + p.`userid` ORDER BY - points DESC, - d.last_online DESC + `points` DESC, + d.`last_online` DESC LIMIT {?top10_max?}", __FILE__, __LINE__); $OUT = ''; $count = 1; @@ -156,24 +156,24 @@ SQL_FREERESULT($result); // TOP referral "hunter" $result = SQL_QUERY("SELECT - d.userid, - SUM(r.counter) AS refs, - d.last_online + d.`userid`, + SUM(r.`counter`) AS `refs`, + d.`last_online` FROM - `{?_MYSQL_PREFIX?}_user_data` AS d + `{?_MYSQL_PREFIX?}_user_data` AS `d` LEFT JOIN - {?_MYSQL_PREFIX?}_refsystem AS r + {?_MYSQL_PREFIX?}_refsystem AS `r` ON - r.userid=d.userid + r.`userid`=d.`userid` WHERE - r.counter > 0 AND + r.`counter` > 0 AND d.`status`='CONFIRMED' " . runFilterChain('user_exclusion_sql', ' ') . " GROUP BY - r.userid + r.`userid` ORDER BY - refs DESC, - d.last_online DESC + `refs` DESC, + d.`last_online` DESC LIMIT {?top10_max?}", __FILE__, __LINE__); $OUT = ''; $count = 1; diff --git a/templates/de/html/guest/guest_top10.tpl b/templates/de/html/guest/guest_top10.tpl index b3f0df34b8..29fcde2a8a 100644 --- a/templates/de/html/guest/guest_top10.tpl +++ b/templates/de/html/guest/guest_top10.tpl @@ -3,7 +3,7 @@ class="table dashed"> - TOP{?top10_max?} - Logins + {--GUEST_TOP10_LOGINS_TITLE--} @@ -26,7 +26,7 @@ $content[logins_out] -
Diese Liste zeigt Ihnen, wer am häufigsten eingeloggt hat.
+
{--GUEST_TOP10_LOGINS_NOTICE--}
@@ -39,7 +39,7 @@ class="table dashed"> - TOP{?top10_max?} - {?POINTS?}-Verdiener + {--GUEST_TOP10_EARNER_TITLE--} @@ -59,12 +59,16 @@ $content[points_out] -
Diese Liste zeigt Ihnen, wer die meisten {?POINTS?} verdient hat.
+
{--GUEST_TOP10_EARNER_NOTICE--}
+
+ {--GUEST_TOP10_EARNER_NOTICE2--} +
+
@@ -72,7 +76,7 @@ class="table dashed"> - TOP{?top10_max?} - Werber + {--GUEST_TOP10_REFERRAL_TITLE--} @@ -95,7 +99,7 @@ $content[referrals_out] -
Diese Liste zeigt Ihnen, wer die meisten Mitglieder geworben hat.
+
{--GUEST_TOP10_REFERRAL_NOTICE--}