mirror of
https://github.com/wbbaddons/Tims-Chat.git
synced 2025-01-02 23:20:08 +00:00
Indent with tabs
This commit is contained in:
parent
18b097ff9b
commit
7ce9f47acc
66
install.sql
66
install.sql
@ -1,46 +1,46 @@
|
|||||||
DROP TABLE IF EXISTS wcf1_chat_message;
|
DROP TABLE IF EXISTS wcf1_chat_message;
|
||||||
CREATE TABLE wcf1_chat_message (
|
CREATE TABLE wcf1_chat_message (
|
||||||
messageID int(10) NOT NULL AUTO_INCREMENT,
|
messageID int(10) NOT NULL AUTO_INCREMENT,
|
||||||
roomID int(10) NOT NULL,
|
roomID int(10) NOT NULL,
|
||||||
sender int(10) DEFAULT NULL,
|
sender int(10) DEFAULT NULL,
|
||||||
username varchar(255) DEFAULT NULL,
|
username varchar(255) DEFAULT NULL,
|
||||||
receiver int(10) DEFAULT NULL,
|
receiver int(10) DEFAULT NULL,
|
||||||
time int(10) NOT NULL,
|
time int(10) NOT NULL,
|
||||||
type tinyint(3) NOT NULL DEFAULT 1,
|
type tinyint(3) NOT NULL DEFAULT 1,
|
||||||
message mediumtext NOT NULL,
|
message mediumtext NOT NULL,
|
||||||
enableSmilies tinyint(1) NOT NULL DEFAULT 1,
|
enableSmilies tinyint(1) NOT NULL DEFAULT 1,
|
||||||
enableHTML tinyint(1) NOT NULL DEFAULT 0,
|
enableHTML tinyint(1) NOT NULL DEFAULT 0,
|
||||||
color1 int(10) NOT NULL DEFAULT 0,
|
color1 int(10) NOT NULL DEFAULT 0,
|
||||||
color2 int(10) NOT NULL DEFAULT 0,
|
color2 int(10) NOT NULL DEFAULT 0,
|
||||||
PRIMARY KEY (messageID),
|
PRIMARY KEY (messageID),
|
||||||
KEY roomID (roomID),
|
KEY roomID (roomID),
|
||||||
KEY sender (sender),
|
KEY sender (sender),
|
||||||
KEY receiver (receiver)
|
KEY receiver (receiver)
|
||||||
);
|
);
|
||||||
|
|
||||||
DROP TABLE IF EXISTS wcf1_chat_room;
|
DROP TABLE IF EXISTS wcf1_chat_room;
|
||||||
CREATE TABLE wcf1_chat_room (
|
CREATE TABLE wcf1_chat_room (
|
||||||
roomID int(10) NOT NULL AUTO_INCREMENT,
|
roomID int(10) NOT NULL AUTO_INCREMENT,
|
||||||
title varchar(25) NOT NULL,
|
title varchar(25) NOT NULL,
|
||||||
topic varchar(255) NOT NULL,
|
topic varchar(255) NOT NULL,
|
||||||
position int(10) NOT NULL DEFAULT 0,
|
position int(10) NOT NULL DEFAULT 0,
|
||||||
permanent tinyint(1) NOT NULL DEFAULT 1,
|
permanent tinyint(1) NOT NULL DEFAULT 1,
|
||||||
owner int(10) DEFAULT NULL,
|
owner int(10) DEFAULT NULL,
|
||||||
PRIMARY KEY (roomID),
|
PRIMARY KEY (roomID),
|
||||||
KEY positionKey (position),
|
KEY positionKey (position),
|
||||||
KEY owner (owner)
|
KEY owner (owner)
|
||||||
);
|
);
|
||||||
|
|
||||||
DROP TABLE IF EXISTS wcf1_chat_room_suspension;
|
DROP TABLE IF EXISTS wcf1_chat_room_suspension;
|
||||||
CREATE TABLE wcf1_chat_room_suspension (
|
CREATE TABLE wcf1_chat_room_suspension (
|
||||||
roomID int(10) NOT NULL,
|
roomID int(10) NOT NULL,
|
||||||
userID int(10) NOT NULL,
|
userID int(10) NOT NULL,
|
||||||
type tinyint(3) NOT NULL,
|
type tinyint(3) NOT NULL,
|
||||||
time int(10) NOT NULL,
|
time int(10) NOT NULL,
|
||||||
PRIMARY KEY (roomID, userID),
|
PRIMARY KEY (roomID, userID),
|
||||||
KEY userID (userID),
|
KEY userID (userID),
|
||||||
KEY type (type, time),
|
KEY type (type, time),
|
||||||
KEY time (time)
|
KEY time (time)
|
||||||
);
|
);
|
||||||
|
|
||||||
ALTER TABLE wcf1_chat_message ADD FOREIGN KEY (receiver) REFERENCES wcf1_user (userID) ON DELETE CASCADE;
|
ALTER TABLE wcf1_chat_message ADD FOREIGN KEY (receiver) REFERENCES wcf1_user (userID) ON DELETE CASCADE;
|
||||||
|
Loading…
Reference in New Issue
Block a user