summaryrefslogtreecommitdiffstats
path: root/schema.sql
diff options
context:
space:
mode:
authorM <m@lfurio.us>2015-11-20 22:16:27 -0500
committerM <m@lfurio.us>2015-11-20 22:16:27 -0500
commit4f256fbdde3305177aa7e5c80ea715bfd677efee (patch)
treed313a72b69672c44225b6d61f16a8a1879e1d58c /schema.sql
parent81a46c7cf94aae9b39fd2bf3232778ea261281ff (diff)
downloadscrott-4f256fbdde3305177aa7e5c80ea715bfd677efee.tar.gz
scrott-4f256fbdde3305177aa7e5c80ea715bfd677efee.zip
* Moved the `unread` value of messages out into a new table so that this value can now be user-specific
Diffstat (limited to '')
-rw-r--r--schema.sql9
1 files changed, 8 insertions, 1 deletions
diff --git a/schema.sql b/schema.sql
index 5dd4a10..2171cde 100644
--- a/schema.sql
+++ b/schema.sql
@@ -69,6 +69,14 @@ CREATE TABLE `obj_member` (
PRIMARY KEY (`guid`,`member`)
);
+/* Scheme for logging if a message has been seen by a user on a wide scale */
+DROP TABLE IF EXISTS `msg_read`;
+CREATE TABLE `msg_read` (
+ `guid` varchar(10) NOT NULL,
+ `user` varchar(10) NOT NULL,
+ PRIMARY KEY (`guid`,`user`)
+);
+
/* User objects - special attributes */
/* Notice: 'timeUpdated' field should be used to store the time of the start of the user's current session */
/* Notice: 'key' field is the user's hashed and salted password -- SHA256 */
@@ -135,7 +143,6 @@ DROP TABLE IF EXISTS `message`;
CREATE TABLE `message` (
`guid` varchar(10) NOT NULL,
`author` varchar(10) NOT NULL,
- `unread` int(10) unsigned NOT NULL DEFAULT 1,
`message` text DEFAULT NULL,
PRIMARY KEY (`guid`)
);