Added notion of author (owner) and editor to allow the editing of node by non owner users.
This commit is contained in:
@@ -8,6 +8,7 @@ CREATE TABLE nodes (
|
||||
`content` TEXT,
|
||||
`format` VARCHAR(128),
|
||||
`author` INTEGER,
|
||||
`editor` INTEGER,
|
||||
`publish` DATETIME,
|
||||
`created` DATETIME NOT NULL,
|
||||
`changed` DATETIME NOT NULL,
|
||||
@@ -23,6 +24,7 @@ CREATE TABLE node_revisions (
|
||||
`content` TEXT,
|
||||
`format` VARCHAR(128),
|
||||
`author` INTEGER,
|
||||
`editor` INTEGER,
|
||||
`changed` DATETIME NOT NULL,
|
||||
`status` INTEGER,
|
||||
CONSTRAINT Unique_nid_revision PRIMARY KEY (nid,revision)
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
ALTER TABLE nodes ADD editor INTEGER ;
|
||||
UPDATE nodes SET editor = author;
|
||||
|
||||
ALTER TABLE node_revisions ADD editor INTEGER ;
|
||||
UPDATE node_revisions SET editor = author;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user