Jul 22 - Update - add Rich-text editor, draft/publish, drag-to-reorder

This commit is contained in:
2026-07-22 17:13:26 -04:00
parent a39fa091fa
commit 69b97d51fe
15 changed files with 1295 additions and 23 deletions
+20
View File
@@ -0,0 +1,20 @@
-- Additive migration for the draft/publish feature.
-- Adds topic.is_published to an ALREADY-DEPLOYED jqc_features database.
-- Safe to re-run: guarded by an information_schema existence check (MySQL has
-- no ADD COLUMN IF NOT EXISTS). New deploys don't need this — schema.sql already
-- includes the column.
USE jqc_features;
SET @col := (
SELECT COUNT(*) FROM information_schema.columns
WHERE table_schema = DATABASE()
AND table_name = 'topic'
AND column_name = 'is_published'
);
SET @sql := IF(@col = 0,
'ALTER TABLE topic ADD COLUMN is_published TINYINT(1) NOT NULL DEFAULT 1 AFTER sort_order',
'SELECT 1');
PREPARE stmt FROM @sql;
EXECUTE stmt;
DEALLOCATE PREPARE stmt;