X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-list_norefs.php;h=a541084bacefccf7e0653f1571cce42d00bdf993;hb=2142149f3f72f1a2476f95a87937c044d63bbaf2;hp=83ea7425cef2015b6458be206db38f638f003193;hpb=b73c135350d7ed266c0cac680105707139bd892d;p=mailer.git
diff --git a/inc/modules/admin/what-list_norefs.php b/inc/modules/admin/what-list_norefs.php
index 83ea7425ce..a541084bac 100644
--- a/inc/modules/admin/what-list_norefs.php
+++ b/inc/modules/admin/what-list_norefs.php
@@ -6,7 +6,7 @@
* -------------------------------------------------------------------- *
* File : what-list_norefs.php *
* -------------------------------------------------------------------- *
- * Short description : Show all members w/o a referral *
+ * Short description : Show all members w/o a referal *
* -------------------------------------------------------------------- *
* Kurzbeschreibung : Alle Mitgliederaccounts ohne Werber auflisten *
* -------------------------------------------------------------------- *
@@ -42,7 +42,7 @@ if ((!defined('__SECURITY')) || (!IS_ADMIN())) {
}
// Add description as navigation point
-ADD_DESCR("admin", basename(__FILE__));
+ADD_DESCR("admin", __FILE__);
$MORE = ", userid"; $colspan = "4"; // 27
if (EXT_IS_ACTIVE("nickname")) { $MORE = ", nickname"; }
@@ -52,16 +52,24 @@ if (empty($_GET['sortby'])) { $_GET['sortby'] = "userid"; }
if (empty($_GET['page'])) { $_GET['page'] = "1"; }
// Set base URL
-$BASE = " 0)
{
- // Free memory
- SQL_FREERESULT($result_master);
-
// We have some (new?) registrations!
define('__COLSPAN1' , $colspan);
define('__COLSPAN2' , ($colspan + 2));
define('__USER_CNT' , $user_count);
define('__ALPHA_SORT', alpha($_GET['sortby'], $colspan, true));
define('__SORT_LINKS', SortLinks($_GET['letter'], $_GET['sortby'], $colspan, true));
- if ($PAGES > 1)
- {
+ define('__TITLE' , ADMIN_LIST_NOREFS_ACCOUNTS);
+
+ if ($PAGES > 1) {
+ // Add navigation
define('__PAGE_NAV', ADD_PAGENAV($PAGES, $_CONFIG['user_limit'], true, $colspan, true));
- }
- else
- {
+ } else {
// No page navigation is required
define('__PAGE_NAV', "");
}
// Column with nickname when nickname extension is present
- if (EXT_IS_ACTIVE("nickname"))
- {
+ if (EXT_IS_ACTIVE("nickname")) {
// Nickname extension found
define('__NICKNAME_TH', "
".NICKNAME." | ");
- }
- else
- {
+ } else {
// Not found
define('__NICKNAME_TH', "");
}
$SW = 2; $OUT = "";
- while (list($uid, $gender, $sname, $fname, $email, $IP, $ref, $status, $nick) = SQL_FETCHROW($result))
- {
- if ($ref > 0) $ref = ADMIN_USER_PROFILE_LINK($ref);
- $LINKS = TRANSLATE_COMMA(GET_TOTAL_DATA($uid, "user_links", "id", "userid", true));
- if ($LINKS > 0) $LINKS = $BASE."&what=list_links&u_id=".$uid."\">".$LINKS."";
+ while (list($uid, $gender, $sname, $fname, $email, $IP, $ref, $status, $emails_sent, $mails_confirmed, $emails_received, $nick) = SQL_FETCHROW($result)) {
+ // Get unconfirmed emails
+ $LINKS = GET_TOTAL_DATA($uid, "user_links", "id", "userid", true);
+
+ // Set link to unconfirmed emails
+ if ($LINKS > 0) {
+ // Translate value
+ $LINKS = TRANSLATE_COMMA($LINKS);
+
+ // Add link
+ $LINKS = $BASE."&what=list_links&u_id=".$uid."\">".$LINKS."]";
+ } // END - if
// Add nickname
if ((empty($nick)) || ($uid == $nick)) $nick = "---";
+ // Sent emails
+ $SENT = $emails_sent;
+ if ($emails_sent > 0) $SENT = $BASE."&what=email_details&u_id=".$uid."\">".TRANSLATE_COMMA($emails_sent)."]";
+
+ // Calculate total points
+ $pointsTotal = GET_TOTAL_DATA($uid, "user_points", "points") - GET_TOTAL_DATA($uid, "user_data", "used_points");
+
+ // Clickrate
+ $clickRate = 0;
+ if ($emails_received > 0) {
+ $clickRate = $mails_confirmed / $emails_received * 100;
+ } // END - if
+
// Transfer data to array
$content = array(
'sw' => $SW,
@@ -128,18 +150,23 @@ if (SQL_NUMROWS($result_master) > 0)
'gender' => TRANSLATE_GENDER($gender),
'sname' => $sname,
'fname' => $fname,
- 'email' => "".$email."",
+ 'email' => "[".$email."]",
'addr' => $IP,
'ref' => $ref,
'status' => TRANSLATE_STATUS($status),
'links' => $LINKS,
- 'nick' => $nick
+ 'alinks' => MEMBER_ACTION_LINKS($uid, $status),
+ 'nick' => $nick,
+ 'points' => TRANSLATE_COMMA($pointsTotal),
+ 'sent' => $SENT,
+ 'rate' => TRANSLATE_COMMA($clickRate),
+ 'locked' => TRANSLATE_COMMA(GET_TOTAL_DATA($uid, "user_points", "locked_points"))
);
// Load row template and switch colors
$OUT .= LOAD_TEMPLATE("admin_list_user_row", true, $content);
$SW = 3 - $SW;
- }
+ } // END - while
// Free memory
SQL_FREERESULT($result);
@@ -151,12 +178,13 @@ if (SQL_NUMROWS($result_master) > 0)
// Free some memory
SQL_FREERESULT($result_master);
-}
- else
-{
+} else {
// No one as registered so far! :-(
LOAD_TEMPLATE("admin_settings_saved", false, ADMIN_ACCOUNT_NOREFS_404);
}
+// Free memory
+SQL_FREERESULT($result_master);
+
//
?>