From a50f5113fe25ed5f125e3377914a5c0d84b4c1ae Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Thu, 5 Nov 2009 17:24:18 +0000 Subject: [PATCH 1/1] Some rewrites --- inc/modules/admin/what-list_beg.php | 32 +++---- inc/modules/admin/what-list_rallyes.php | 2 +- .../de/html/admin/admin_list_rallyes_row.tpl | 96 +++++++++++-------- 3 files changed, 73 insertions(+), 57 deletions(-) diff --git a/inc/modules/admin/what-list_beg.php b/inc/modules/admin/what-list_beg.php index 051cb49c62..b3d19ef974 100644 --- a/inc/modules/admin/what-list_beg.php +++ b/inc/modules/admin/what-list_beg.php @@ -75,27 +75,27 @@ ORDER BY beg_points DESC, last_online DESC, userid", while ($content = SQL_FETCHARRAY($result)) { // Init variables $WIN1 = ''; $WIN2 = ''; + + // Maybe he can win his active beg? if ($cnt <= getConfig('beg_ranks')) { - // Maybe he can win his active beg? - $WIN1 = ""; - $WIN2 = ""; + // Mark him + $WIN1 = ''; + $WIN2 = ''; } // END - if // Prepare content - // @TODO Rewrite templates so s/family will be replaced by surname/family - // @TODO to shorten this block. Please also do so with userid->userid $content = array( - 'userid' => $content['userid'], - 'email' => generateEmailLink($content['email'], 'user_data'), - 'gender' => translateGender($content['gender']), - 'surname' => $content['surname'], - 'family' => $content['family'], - 'turbo' => translateComma($content['beg_points']), - 'last_online' => generateDateTime($content['last_online'], 2), - 'sw' => $SW, - 'win1' => $WIN1, - 'win2' => $WIN2, - 'cnt' => $cnt, + 'userid' => $content['userid'], + 'email' => generateEmailLink($content['email'], 'user_data'), + 'gender' => translateGender($content['gender']), + 'surname' => $content['surname'], + 'family' => $content['family'], + 'turbo' => translateComma($content['beg_points']), + 'last_online' => generateDateTime($content['last_online'], 2), + 'sw' => $SW, + 'win1' => $WIN1, + 'win2' => $WIN2, + 'cnt' => $cnt, ); // Load template and add it diff --git a/inc/modules/admin/what-list_rallyes.php b/inc/modules/admin/what-list_rallyes.php index 1ddccd1cac..9469dcc38f 100644 --- a/inc/modules/admin/what-list_rallyes.php +++ b/inc/modules/admin/what-list_rallyes.php @@ -327,7 +327,7 @@ ORDER BY $row = array( 'select' => "", 'admin_id' => $data['admin_id'], - 'email_link' => generateEmailLink($data['admin_id']), + 'admin_link' => generateAdminLink($data['admin_id']), 'login' => $data['login'], 'id' => $data['id'], 'sw' => $SW, diff --git a/templates/de/html/admin/admin_list_rallyes_row.tpl b/templates/de/html/admin/admin_list_rallyes_row.tpl index 29b49bebab..c633998d7d 100644 --- a/templates/de/html/admin/admin_list_rallyes_row.tpl +++ b/templates/de/html/admin/admin_list_rallyes_row.tpl @@ -1,54 +1,70 @@ - $content[select] - {--RALLYE_TITLE--}:
- $content[title] - {--RALLYE_DESCR2--}:
- $content[descr] - {--RALLYE_ADMIN_ID--}:
- $content[login] - {--RALLYE_TSTART--}:
- $content[start_date] - {--RALLYE_TEND--}:
- $content[end_date] + $content[select] + + {--RALLYE_TITLE--}:
+ $content[title] + + + {--RALLYE_DESCR2--}:
+ $content[descr] + + + {--RALLYE_ADMIN_ID--}:
+ $content[admin_link] + + + {--RALLYE_TSTART--}:
+ $content[start_date] + + + {--RALLYE_TEND--}:
+ $content[end_date] + - {--RALLYE_TEMPLATE2--}:
- $content[template] - {--RALLYE_AUTO_ADD--}:
- $content[auto_lnk] - {--RALLYE_ACTIVE--}:
- $content[active_lnk] - {--RALLYE_NOTIFY--}:
- $content[notify_lnk] - {--RALLYE_NOTIFIED--}:
- $content[notified] + + {--RALLYE_TEMPLATE2--}:
+ $content[template] + + + {--RALLYE_AUTO_ADD--}:
+ $content[auto_lnk] + + + {--RALLYE_ACTIVE--}:
+ $content[active_lnk] + + + {--RALLYE_NOTIFY--}:
+ $content[notify_lnk] + + + {--RALLYE_NOTIFIED--}:
+ $content[notified] + - {--RALLYE_ASSIGNED_PRICES--}:
- $content[prices_cnt] + + {--RALLYE_ASSIGNED_PRICES--}:
+ $content[prices_cnt] - {--RALLYE_ASSIGNED_USERS--}:
- $content[joined] + {--RALLYE_ASSIGNED_USERS--}:
+ $content[joined] + - {--RALLYE_LIMITATIONS--}: + {--RALLYE_LIMITATIONS--}: + - {--RALLYE_MIN_USERS_MINI--}:
- $content[min_users] + + {--RALLYE_MIN_USERS_MINI--}:
+ $content[min_users] + - {--RALLYE_MIN_PRICES_MINI--}:
- $content[min_prices] + {--RALLYE_MIN_PRICES_MINI--}:
+ $content[min_prices] + -- 2.30.2