From d4b14f91bedca70c5dcbe330ec02c060c87c7ec6 Mon Sep 17 00:00:00 2001 From: Renard Date: Sat, 14 Mar 2020 16:15:26 -0300 Subject: Moderar posts recientes Fix nombre variable Fix nombre variable2 Mod: posts recientes fix typo ultimos arreglos --- cgi/manage.py | 4 +++ cgi/templates/manage/recent.html | 55 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+) create mode 100644 cgi/templates/manage/recent.html (limited to 'cgi') diff --git a/cgi/manage.py b/cgi/manage.py index 0c95268..776747e 100644 --- a/cgi/manage.py +++ b/cgi/manage.py @@ -158,6 +158,10 @@ def manage(self, path_split): threads = FetchAll("SELECT * FROM `posts` WHERE boardid = %s AND parentid = 0 ORDER BY `bumped` DESC" % board["id"]) template_filename = "mod.html" template_values = {"mode": 2, "dir": board["dir"], "threads": threads} + elif path_split[2] == "recent": + posts = FetchAll("SELECT posts.id, posts.subject, dir, parentid, file, thumb, timestamp_formatted, timestamp, posts.message, INET_NTOA(ip) AS ip, posts.name, email, tripcode FROM posts INNER JOIN boards ON posts.boardid = boards.id ORDER BY timestamp DESC LIMIT 50") + template_filename = "recent.html" + template_values = {"posts": posts} elif path_split[2] == 'staff': if staff_account['rights'] != '0': return diff --git a/cgi/templates/manage/recent.html b/cgi/templates/manage/recent.html new file mode 100644 index 0000000..b490a57 --- /dev/null +++ b/cgi/templates/manage/recent.html @@ -0,0 +1,55 @@ + + +
+
Lista de posts recientes
+ + + + + + + + + + + + + + + + + + + + + + + +
IDBoardArchivoTimestampMensajeIPAcciones
#{post['id']}/#{post['dir']}/ + + + +
#{post['timestamp_formatted']}
+
+
#{post['subject']} #{post['name']} + #{post['tripcode']} +
+
#{post['message']}
+ + + +
+ #{post['ip']} + + + + +
+
+
+ \ No newline at end of file -- cgit v1.2.1-18-gbd029