summaryrefslogtreecommitdiffstats
path: root/schema
diff options
context:
space:
mode:
authorLukas Fleischer <lfleischer@archlinux.org>2019-11-23 18:00:52 +0100
committerLukas Fleischer <lfleischer@archlinux.org>2019-11-23 18:30:46 +0100
commit2422fb020b79b387ef667d146cf3e0dd7b1faebf (patch)
tree4cfc7ab7f9e81ee1f6aa49dc6106a0e6960c5797 /schema
parent4b97789bab8dae01987ffa4cdeb1e1257c95834f (diff)
downloadaur-2422fb020b79b387ef667d146cf3e0dd7b1faebf.tar.gz
aur-2422fb020b79b387ef667d146cf3e0dd7b1faebf.tar.xz
Store timestamp and user ID when closing requests
Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
Diffstat (limited to 'schema')
-rw-r--r--schema/aur-schema.sql5
1 files changed, 4 insertions, 1 deletions
diff --git a/schema/aur-schema.sql b/schema/aur-schema.sql
index f05f40a3..fa991ba6 100644
--- a/schema/aur-schema.sql
+++ b/schema/aur-schema.sql
@@ -336,11 +336,14 @@ CREATE TABLE PackageRequests (
Comments TEXT NOT NULL,
ClosureComment TEXT NOT NULL,
RequestTS BIGINT UNSIGNED NOT NULL DEFAULT 0,
+ ClosedTS BIGINT UNSIGNED NULL DEFAULT NULL,
+ ClosedUID INTEGER UNSIGNED NULL DEFAULT NULL,
Status TINYINT UNSIGNED NOT NULL DEFAULT 0,
PRIMARY KEY (ID),
FOREIGN KEY (ReqTypeID) REFERENCES RequestTypes(ID) ON DELETE NO ACTION,
FOREIGN KEY (UsersID) REFERENCES Users(ID) ON DELETE SET NULL,
- FOREIGN KEY (PackageBaseID) REFERENCES PackageBases(ID) ON DELETE SET NULL
+ FOREIGN KEY (PackageBaseID) REFERENCES PackageBases(ID) ON DELETE SET NULL,
+ FOREIGN KEY (ClosedUID) REFERENCES Users(ID) ON DELETE SET NULL
) ENGINE = InnoDB;
CREATE INDEX RequestsUsersID ON PackageRequests (UsersID);
CREATE INDEX RequestsPackageBaseID ON PackageRequests (PackageBaseID);