summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2009-10-10 15:51:57 +0200
committerYorhel <git@yorhel.nl>2009-10-10 15:51:57 +0200
commit5ce2ce4c494feef5940c032549472a52b5282ad1 (patch)
tree89efb88dc1fc0afbb2d4ba3b29a37e154453edeb /util
parent1e125f67ab50a5de477c538b3f7dd27a9ec3c62f (diff)
Display number of unread posts in user menu
Instead of displaying the total number of threads. Posts are marked as read when the thread is opened.
Diffstat (limited to 'util')
-rw-r--r--util/dump.sql1
-rw-r--r--util/updates/update_2.8.sql5
2 files changed, 6 insertions, 0 deletions
diff --git a/util/dump.sql b/util/dump.sql
index 10d13b9d..c952c162 100644
--- a/util/dump.sql
+++ b/util/dump.sql
@@ -240,6 +240,7 @@ CREATE TABLE threads_boards (
tid integer NOT NULL DEFAULT 0,
type character(2) NOT NULL DEFAULT 0,
iid integer NOT NULL DEFAULT 0,
+ lastread smallint NOT NULL,
PRIMARY KEY(tid, type, iid)
);
diff --git a/util/updates/update_2.8.sql b/util/updates/update_2.8.sql
index 2993467c..a90b3ac2 100644
--- a/util/updates/update_2.8.sql
+++ b/util/updates/update_2.8.sql
@@ -59,3 +59,8 @@ ALTER TABLE releases_producers ADD COLUMN developer boolean NOT NULL DEFAULT FAL
ALTER TABLE releases_producers ADD COLUMN publisher boolean NOT NULL DEFAULT TRUE;
ALTER TABLE releases_producers ADD CHECK(developer OR publisher);
+
+-- Keep track of last read post for PMs
+ALTER TABLE threads_boards ADD COLUMN lastread smallint;
+
+