diff options
| author | M <m@lfurio.us> | 2015-11-20 22:16:27 -0500 | 
|---|---|---|
| committer | M <m@lfurio.us> | 2015-11-20 22:16:27 -0500 | 
| commit | 4f256fbdde3305177aa7e5c80ea715bfd677efee (patch) | |
| tree | d313a72b69672c44225b6d61f16a8a1879e1d58c | |
| parent | 81a46c7cf94aae9b39fd2bf3232778ea261281ff (diff) | |
| download | scrott-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.sql | 9 | 
1 files changed, 8 insertions, 1 deletions
| @@ -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`)  ); | 
