Improves note deletions (#25460)

* Improves not deletions

* balls

* balls the second
This commit is contained in:
AffectedArc07
2024-05-17 14:01:13 +01:00
committed by GitHub
parent 0339ef65dd
commit f3a24e24bb
5 changed files with 118 additions and 83 deletions
+4 -1
View File
@@ -404,8 +404,11 @@ CREATE TABLE `notes` (
`server` varchar(50) NOT NULL,
`crew_playtime` mediumint(8) UNSIGNED DEFAULT '0',
`automated` TINYINT(3) UNSIGNED NULL DEFAULT '0',
`deleted` TINYINT(4) NOT NULL DEFAULT '0',
`deletedby` VARCHAR(32) NULL DEFAULT NULL COLLATE 'utf8mb4_general_ci',
PRIMARY KEY (`id`),
KEY `ckey` (`ckey`)
KEY `ckey` (`ckey`),
KEY `deleted` (`deleted`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
/*!40101 SET character_set_client = @saved_cs_client */;
+7
View File
@@ -0,0 +1,7 @@
# Updating DB from 55-56 ~AffectedArc07
# Adds a new column to the notes table for tracking deleted notes
ALTER TABLE `notes`
ADD COLUMN `deleted` TINYINT NOT NULL DEFAULT 0 AFTER `automated`,
ADD COLUMN `deletedby` VARCHAR(32) NULL DEFAULT NULL AFTER `deleted`,
ADD INDEX `deleted` (`deleted`);