Added field filtering to API endpoints and store colour presets in the database.
This commit is contained in:
parent
12d40e69a5
commit
a1398fb179
16 changed files with 727 additions and 117 deletions
20
database/2025_03_27_213508_colours_presets.php
Normal file
20
database/2025_03_27_213508_colours_presets.php
Normal file
|
@ -0,0 +1,20 @@
|
|||
<?php
|
||||
use Index\Db\DbConnection;
|
||||
use Index\Db\Migration\DbMigration;
|
||||
|
||||
final class ColoursPresets_20250327_213508 implements DbMigration {
|
||||
public function migrate(DbConnection $conn): void {
|
||||
$conn->execute(<<<SQL
|
||||
CREATE TABLE msz_colours_presets (
|
||||
preset_id INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
|
||||
preset_order INT(11) NOT NULL DEFAULT '0',
|
||||
preset_name VARCHAR(255) NOT NULL COLLATE 'ascii_general_ci',
|
||||
preset_title VARCHAR(255) NULL DEFAULT NULL COLLATE 'utf8mb4_bin',
|
||||
preset_colour INT(11) UNSIGNED NOT NULL,
|
||||
PRIMARY KEY (preset_id),
|
||||
UNIQUE KEY msz_colours_presets_name_unique (preset_name),
|
||||
KEY msz_colours_presets_order_index (preset_order)
|
||||
) COLLATE='utf8mb4_bin' ENGINE=InnoDB;
|
||||
SQL);
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue