From 75435aa960997fb4aa7a13c1a084ab3c53111e73 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Thu, 18 Feb 2021 13:00:20 +0300 Subject: [PATCH] user details: cleanup --- classes/pref/users.php | 64 +++++++++++++++++++++++++----------------- 1 file changed, 39 insertions(+), 25 deletions(-) diff --git a/classes/pref/users.php b/classes/pref/users.php index ab1694564..5ac6a7990 100644 --- a/classes/pref/users.php +++ b/classes/pref/users.php @@ -38,7 +38,6 @@ class Pref_Users extends Handler_Administrative { $sth->execute([$id]); if ($row = $sth->fetch()) { - print ""; $last_login = TimeHelper::make_local_datetime( $row["last_login"], true); @@ -48,47 +47,62 @@ class Pref_Users extends Handler_Administrative { $stored_articles = $row["stored_articles"]; - print ""; - print ""; - $sth = $this->pdo->prepare("SELECT COUNT(id) as num_feeds FROM ttrss_feeds WHERE owner_uid = ?"); $sth->execute([$id]); $row = $sth->fetch(); + $num_feeds = $row["num_feeds"]; - print ""; - print ""; + ?> - print "
".__('Registered')."$created
".__('Last logged in')."$last_login
".__('Subscribed feeds count')."$num_feeds
".__('Stored articles')."$stored_articles
"; +
+ + +
- print "

".__('Subscribed feeds')."

"; +
+ + +
- $sth = $this->pdo->prepare("SELECT id,title,site_url FROM ttrss_feeds - WHERE owner_uid = ? ORDER BY title"); - $sth->execute([$id]); +
+ + +
- print " + ".__('User not found').""; + print_error(__('User not found')); } }