summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2021-02-28 13:46:33 +0300
committerAndrew Dolgov <[email protected]>2021-02-28 13:46:33 +0300
commitc6a30c93a3f8f1946a59ec9310b1d8d688e2c37d (patch)
treebb3f69016bbf6cf433b7a94cf70871d6956d6a87
parent11cb07af01c2dd357b855ef2056bb42d629429eb (diff)
show delayed post totals
-rwxr-xr-xinit.php12
1 files changed, 11 insertions, 1 deletions
diff --git a/init.php b/init.php
index 32ff379..d8e8e3d 100755
--- a/init.php
+++ b/init.php
@@ -221,7 +221,17 @@ class Reddit_Delay extends Plugin {
<hr/>
- <h3><?= __("Currently delayed posts (by feed)") ?></h3>
+ <?php
+ $sth = $this->pdo->prepare("SELECT COUNT(c.id) AS count
+ FROM ttrss_plugin_reddit_delay_cache c, ttrss_feeds f
+ WHERE f.id = c.feed_id AND f.owner_uid = ?");
+ $sth->execute([$_SESSION["uid"]]);
+
+ $row = $sth->fetch();
+ $total_delayed = $row["count"];
+ ?>
+
+ <h3><?= T_sprintf("Currently delayed posts (by feed, %d total)", $total_delayed) ?></h3>
<?php
$sth = $this->pdo->prepare("SELECT COUNT(c.id) AS count, f.title, f.id AS feed_id