add topics

This commit is contained in:
2025-05-18 15:56:29 +03:00
parent 86b568d0f4
commit f5485702a8
11 changed files with 250 additions and 10 deletions

View File

@ -29,4 +29,16 @@ return {
})
schema.add_column("users", "avatar_id", "REFERENCES avatars(id) ON DELETE SET NULL")
end,
[4] = function ()
schema.add_column("topics", "description", types.text{default=""})
-- topic locked = no new threads can be created in the topic, but posts can be made in threads
-- thread locked = no new posts can be created in the thread, existing posts can not be edited
-- admins bypass both restrictions
schema.add_column("topics", "is_locked", "BOOLEAN DEFAULT FALSE")
schema.add_column("threads", "is_locked", "BOOLEAN DEFAULT FALSE")
-- will appear on top of non-stickied threads in topic view
schema.add_column("threads", "is_stickied", "BOOLEAN DEFAULT FALSE")
end,
}