feat: reorder character selection screen (#6555)

* feat: reorder character selection screen
This commit is contained in:
Axel Cocat
2021-06-30 20:08:06 +02:00
committed by GitHub
parent 0789e87b52
commit c6173e88bd
2 changed files with 21 additions and 2 deletions

View File

@@ -0,0 +1,19 @@
INSERT INTO `version_db_characters` (`sql_rev`) VALUES ('1624468542752528700');
SET @dbname = DATABASE();
SET @tablename = "characters";
SET @columnname = "order";
SET @preparedStatement = (SELECT IF(
(
SELECT COUNT(*) FROM information_schema.COLUMNS
WHERE
(TABLE_NAME = @tablename)
AND (TABLE_SCHEMA = @dbname)
AND (COLUMN_NAME = @columnname)
) > 0,
"SELECT 1 WHERE false",
CONCAT("ALTER TABLE `", @tablename, "` ADD `", @columnname, "` TINYINT NULL DEFAULT NULL AFTER `grantableLevels`;")
));
PREPARE alterIfNotExists FROM @preparedStatement;
EXECUTE alterIfNotExists;
DEALLOCATE PREPARE alterIfNotExists;