Warn migration

This commit is contained in:
Dawid Bepierszcz
2024-08-12 02:05:54 +02:00
parent f56e3f6fe9
commit af46f0bca1
2 changed files with 17 additions and 0 deletions

View File

@@ -19,6 +19,9 @@
<ItemGroup>
<None Update="lang\**\*.*" CopyToOutputDirectory="PreserveNewest" />
<None Update="Database\Migrations\010_CreateWarnsTable.sql">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
</ItemGroup>
<ItemGroup>

View File

@@ -0,0 +1,14 @@
CREATE TABLE IF NOT EXISTS `sa_warns` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`player_name` varchar(128) DEFAULT NULL,
`player_steamid` varchar(64) NOT NULL,
`admin_steamid` varchar(64) NOT NULL,
`admin_name` varchar(128) NOT NULL,
`reason` varchar(255) NOT NULL,
`duration` int(11) NOT NULL,
`ends` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(),
`created` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
`server_id` int(11) DEFAULT NULL,
`status` enum('ACTIVE','EXPIRED','') NOT NULL DEFAULT 'ACTIVE',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;