feat: add db templates
This commit is contained in:
parent
22db664291
commit
36d7686ce0
3 changed files with 905 additions and 0 deletions
55
configs/fox-api/mysql/migration_table.sql
Normal file
55
configs/fox-api/mysql/migration_table.sql
Normal file
|
@ -0,0 +1,55 @@
|
||||||
|
-- MySQL dump 10.13 Distrib 8.0.33, for macos13.3 (arm64)
|
||||||
|
--
|
||||||
|
-- Host: 127.0.0.1 Database: portal_dev
|
||||||
|
-- ------------------------------------------------------
|
||||||
|
-- Server version 8.0.34-0ubuntu0.20.04.1
|
||||||
|
|
||||||
|
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||||
|
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||||
|
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||||
|
/*!50503 SET NAMES utf8mb4 */;
|
||||||
|
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
|
||||||
|
/*!40103 SET TIME_ZONE='+00:00' */;
|
||||||
|
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
|
||||||
|
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
|
||||||
|
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
|
||||||
|
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `phinxlog`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `phinxlog`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `phinxlog` (
|
||||||
|
`version` bigint NOT NULL,
|
||||||
|
`migration_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`start_time` timestamp NULL DEFAULT NULL,
|
||||||
|
`end_time` timestamp NULL DEFAULT NULL,
|
||||||
|
`breakpoint` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
PRIMARY KEY (`version`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Dumping data for table `phinxlog`
|
||||||
|
--
|
||||||
|
|
||||||
|
LOCK TABLES `phinxlog` WRITE;
|
||||||
|
/*!40000 ALTER TABLE `phinxlog` DISABLE KEYS */;
|
||||||
|
INSERT INTO `phinxlog` VALUES (20210918124810,'EventsAutomationUpdate','2021-09-18 13:10:36','2021-09-18 13:10:36',0),(20210918131542,'InstancesAutomationUpdate','2021-09-18 13:17:38','2021-09-18 13:17:38',0),(20210918131933,'AddEventFeedback','2021-09-18 13:28:37','2021-09-18 13:28:38',0),(20210918234041,'AddDealerBooth','2021-09-18 23:56:19','2021-09-18 23:56:20',0),(20210919000022,'AddDealerBoothTags','2021-09-19 00:10:19','2021-09-19 00:10:20',0),(20210919001148,'AddDealerBoothTagLinks','2021-09-19 00:19:16','2021-09-19 00:19:17',0),(20210922152406,'EventsAutomationFieldUpdate','2021-09-28 01:02:54','2021-09-28 01:02:54',0),(20210925232232,'AddAttendeeBans','2021-09-28 00:45:39','2021-09-28 00:45:39',0),(20211011015555,'CreateDealerBookmarkTable','2021-10-11 06:02:51','2021-10-11 06:02:52',0),(20211011015613,'CreateAttendeeLocationsTable','2021-10-11 06:02:52','2021-10-11 06:02:53',0),(20211011015625,'UpdateJoinHistoryTableWithTrigger','2021-10-11 06:13:32','2021-10-11 06:13:32',0),(20211011021746,'CreateFriendsTable','2021-10-11 06:13:32','2021-10-11 06:13:32',0),(20211013011218,'AddNSFWColumnToDealersBoothTable','2021-10-15 01:51:29','2021-10-15 01:51:30',0),(20211013014703,'AddReceiptIDToPaymentsTable','2021-10-15 01:51:30','2021-10-15 01:51:30',0),(20211013040013,'AddPayPalEmailToPaymentTable','2021-10-15 01:51:30','2021-10-15 01:51:30',0),(20211013085053,'AddTwitchAndYoutubeToDealersBooth','2021-10-15 01:51:30','2021-10-15 01:51:30',0),(20211029013645,'AddAvatarsAndDiscordIDToDealerBooth','2021-10-29 04:45:59','2021-10-29 04:45:59',0),(20211102060513,'AddDealerMetricsTable','2021-11-02 08:05:45','2021-11-02 08:05:45',0),(20211103015441,'AddSessionsTable','2021-11-03 18:57:07','2021-11-03 18:57:07',0),(20211103185142,'AddIndexToJoinHistoryTable','2021-11-03 18:57:07','2021-11-03 19:02:14',0),(20220205234357,'CreatePermissionTables','2022-04-05 21:16:20','2022-04-05 21:16:20',0),(20220206005116,'AddPermissionKeys','2022-04-05 21:16:20','2022-04-05 21:16:20',0),(20220328215853,'AddAttendeePatronsTable','2022-04-06 00:16:22','2022-04-06 00:16:22',0),(20220329095257,'UpdateJoinHistoryTable','2022-05-01 19:59:27','2022-05-01 19:59:27',0),(20220329095311,'CreateModerationLogTable','2022-05-01 19:59:27','2022-05-01 19:59:27',0),(20220412182628,'CreatePaymentWebhookEventTable','2022-05-01 19:59:27','2022-05-01 19:59:28',0),(20220429120859,'CreateFilesTable','2022-05-31 02:05:20','2022-05-31 02:05:20',0),(20220429120909,'CreateFilePermissionsTable','2022-05-31 02:05:20','2022-05-31 02:05:21',0),(20220429120916,'CreateFileAccessLogsTable','2022-05-31 02:05:21','2022-05-31 02:05:21',0),(20220524123925,'CreateNewFilePermissions','2022-05-31 02:05:21','2022-05-31 02:05:21',0),(20220605145118,'MakeEventSubtypeRequired','2022-06-13 02:51:39','2022-06-13 02:51:39',0),(20220605145133,'CreateServiceAccountTable','2022-06-13 02:51:39','2022-06-13 02:51:39',0),(20220605145142,'CreateServiceAccountPermissionsTable','2022-06-13 02:51:39','2022-06-13 02:51:39',0),(20220610005213,'AddRestrictedAndSupporterFieldsToInstanceAndEventTable','2022-06-13 02:51:39','2022-06-13 02:51:40',0),(20220611034231,'AddSupporterInviteBypassPermission','2022-06-13 02:51:40','2022-06-13 02:51:40',0),(20220611134015,'CreateTaintInstancePermission','2022-06-13 02:51:40','2022-06-13 02:51:40',0),(20220611171131,'AddViewUserRestrictedPermission','2022-06-13 02:51:40','2022-06-13 02:51:40',0),(20220617012205,'CreateDonationMessageTable','2022-06-18 21:19:31','2022-06-18 21:19:31',0);
|
||||||
|
/*!40000 ALTER TABLE `phinxlog` ENABLE KEYS */;
|
||||||
|
UNLOCK TABLES;
|
||||||
|
SET @@SESSION.SQL_LOG_BIN = @MYSQLDUMP_TEMP_LOG_BIN;
|
||||||
|
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
|
||||||
|
|
||||||
|
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
|
||||||
|
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
|
||||||
|
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
|
||||||
|
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||||
|
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||||
|
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
||||||
|
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
|
||||||
|
|
||||||
|
-- Dump completed on 2023-09-26 20:24:44
|
849
configs/fox-api/mysql/schema.sql
Normal file
849
configs/fox-api/mysql/schema.sql
Normal file
|
@ -0,0 +1,849 @@
|
||||||
|
-- MySQL dump 10.13 Distrib 8.0.33, for macos13.3 (arm64)
|
||||||
|
--
|
||||||
|
-- Host: 127.0.0.1 Database: portal_dev
|
||||||
|
-- ------------------------------------------------------
|
||||||
|
-- Server version 8.0.34-0ubuntu0.20.04.1
|
||||||
|
|
||||||
|
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||||
|
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||||
|
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||||
|
/*!50503 SET NAMES utf8mb4 */;
|
||||||
|
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
|
||||||
|
/*!40103 SET TIME_ZONE='+00:00' */;
|
||||||
|
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
|
||||||
|
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
|
||||||
|
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
|
||||||
|
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `attendee_bans`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `attendee_bans`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `attendee_bans` (
|
||||||
|
`ban_id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`reason` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`added_by` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`expiration` datetime DEFAULT NULL,
|
||||||
|
`created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`ban_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=64 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `attendee_friends`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `attendee_friends`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `attendee_friends` (
|
||||||
|
`vrchat_user_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`friend_user_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
PRIMARY KEY (`vrchat_user_id`,`friend_user_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `attendee_locations`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `attendee_locations`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `attendee_locations` (
|
||||||
|
`vrchat_user_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`hidden` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`instance_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`event_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`event_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`updated` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`vrchat_user_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `attendee_patrons`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `attendee_patrons`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `attendee_patrons` (
|
||||||
|
`id` int unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
`patron_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`patron_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_id` int DEFAULT NULL,
|
||||||
|
`tier` int NOT NULL,
|
||||||
|
`shopify_discount_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`shopify_discount_code` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`pledge_start` datetime NOT NULL,
|
||||||
|
`pledge_end` datetime DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `attendee_sessions`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `attendee_sessions`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `attendee_sessions` (
|
||||||
|
`vrchat_user_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`session_id` varchar(90) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`session_id`),
|
||||||
|
KEY `vrchat_user_id` (`vrchat_user_id`,`session_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `attendees`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `attendees`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `attendees` (
|
||||||
|
`vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_display_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_username` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_avatar_thumbnail` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`discord_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`discord_usertag` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`patron_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`patron_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`fox_token` varchar(15) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`role` varchar(15) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`email` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`friend` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`friend_req_sent` tinyint(1) DEFAULT NULL,
|
||||||
|
`blocked_by_user` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`stacker_link` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`email_sent` tinyint(1) DEFAULT NULL,
|
||||||
|
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`updated` datetime DEFAULT NULL,
|
||||||
|
`furality_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`vrchat_id`),
|
||||||
|
UNIQUE KEY `discord_id` (`discord_id`),
|
||||||
|
KEY `attendee_vrc_id` (`vrchat_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `convention_attended`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `convention_attended`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `convention_attended` (
|
||||||
|
`convention_id` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`payment_method` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`paid` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`reg_level` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`reg_status` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`platform` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`airtable_id` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`reg_created` datetime DEFAULT NULL,
|
||||||
|
`reg_confirmed` datetime DEFAULT NULL,
|
||||||
|
`reg_log_sent` tinyint DEFAULT '0',
|
||||||
|
PRIMARY KEY (`convention_id`,`vrchat_id`),
|
||||||
|
KEY `index2` (`convention_id`,`reg_status`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `dealer_booth`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `dealer_booth`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `dealer_booth` (
|
||||||
|
`booth_id` int NOT NULL,
|
||||||
|
`name` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`owner_vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`owner_display_location` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`nsfw` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`description_short` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`description_long` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`banner_img` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`booth_img` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`booth_video` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`primary_contact` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`email` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`telegram` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`discord` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`twitter` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`website` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`twitch` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`youtube` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`avatar_1` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`avatar_2` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`avatar_3` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`discord_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`booth_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `dealer_booth_bookmark`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `dealer_booth_bookmark`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `dealer_booth_bookmark` (
|
||||||
|
`booth_id` int NOT NULL,
|
||||||
|
`vrchat_user_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
PRIMARY KEY (`booth_id`,`vrchat_user_id`),
|
||||||
|
KEY `vrchat_user_id` (`vrchat_user_id`),
|
||||||
|
CONSTRAINT `dealer_booth_bookmark_ibfk_1` FOREIGN KEY (`booth_id`) REFERENCES `dealer_booth` (`booth_id`),
|
||||||
|
CONSTRAINT `dealer_booth_bookmark_ibfk_2` FOREIGN KEY (`vrchat_user_id`) REFERENCES `attendees` (`vrchat_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `dealer_booth_tag_links`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `dealer_booth_tag_links`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `dealer_booth_tag_links` (
|
||||||
|
`booth_id` int NOT NULL,
|
||||||
|
`tag_id` int NOT NULL,
|
||||||
|
PRIMARY KEY (`booth_id`,`tag_id`),
|
||||||
|
KEY `tag_id` (`tag_id`),
|
||||||
|
CONSTRAINT `dealer_booth_tag_links_ibfk_1` FOREIGN KEY (`booth_id`) REFERENCES `dealer_booth` (`booth_id`),
|
||||||
|
CONSTRAINT `dealer_booth_tag_links_ibfk_2` FOREIGN KEY (`tag_id`) REFERENCES `dealer_booth_tags` (`tag_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `dealer_booth_tags`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `dealer_booth_tags`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `dealer_booth_tags` (
|
||||||
|
`tag_id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`tag_name` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
PRIMARY KEY (`tag_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=66 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `dealer_metrics`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `dealer_metrics`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `dealer_metrics` (
|
||||||
|
`hit_id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`booth_id` int NOT NULL,
|
||||||
|
`user_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`action` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`source` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`user_ip` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`created` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`hit_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=1599 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `donation_messages`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `donation_messages`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `donation_messages` (
|
||||||
|
`id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`vrchat_user_id` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`payment_id` int NOT NULL,
|
||||||
|
`donation_message` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`is_completed` tinyint(1) NOT NULL,
|
||||||
|
`created_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`updated_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `idx_vrc_user_id` (`vrchat_user_id`,`payment_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=19 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `event_feedback`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `event_feedback`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `event_feedback` (
|
||||||
|
`event_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vote` int NOT NULL,
|
||||||
|
PRIMARY KEY (`event_id`,`vrchat_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `event_rsvp`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `event_rsvp`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `event_rsvp` (
|
||||||
|
`event_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
PRIMARY KEY (`vrchat_id`,`event_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `events`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `events`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `events` (
|
||||||
|
`id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`name` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`start` datetime NOT NULL,
|
||||||
|
`end` datetime NOT NULL,
|
||||||
|
`user_cap` smallint unsigned DEFAULT NULL,
|
||||||
|
`is_dynamic` tinyint(1) DEFAULT NULL,
|
||||||
|
`description` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci,
|
||||||
|
`event_type` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_world` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`host_vrchat_world` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`image_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`is_private` tinyint(1) DEFAULT NULL,
|
||||||
|
`status` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`state` varchar(45) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`allow_audience` tinyint(1) DEFAULT '0',
|
||||||
|
`quest_compatible` tinyint(1) DEFAULT NULL,
|
||||||
|
`pc_compatible` tinyint(1) DEFAULT '1',
|
||||||
|
`live_stream` tinyint(1) DEFAULT NULL,
|
||||||
|
`automation` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`updated` datetime DEFAULT NULL,
|
||||||
|
`created` datetime NOT NULL,
|
||||||
|
`restricted` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`supporter` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `worlds_type_index` (`event_type`),
|
||||||
|
KEY `index3` (`event_type`,`type`,`start`),
|
||||||
|
KEY `index4` (`event_type`,`is_private`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `file_access_logs`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `file_access_logs`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `file_access_logs` (
|
||||||
|
`id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`file_uuid` varchar(56) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_id` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`referrer` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`accessed_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `idx_file_access_logs_search_key` (`file_uuid`,`accessed_at`,`vrchat_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=21 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `file_permissions`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `file_permissions`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `file_permissions` (
|
||||||
|
`file_uuid` varchar(56) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`permission_group_id` int NOT NULL,
|
||||||
|
`accessible_at` datetime DEFAULT NULL,
|
||||||
|
`expired_at` datetime DEFAULT NULL,
|
||||||
|
`status` int NOT NULL,
|
||||||
|
PRIMARY KEY (`file_uuid`,`permission_group_id`),
|
||||||
|
KEY `idx_file_permissions_search_key` (`permission_group_id`,`file_uuid`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `files`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `files`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `files` (
|
||||||
|
`file_uuid` varchar(56) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`name` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`description` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`bucket_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`is_public` tinyint(1) NOT NULL,
|
||||||
|
`created_by` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`created_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`updated_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`file_uuid`),
|
||||||
|
KEY `idx_file_search_key` (`created_at`,`file_uuid`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `gumroad_coupons`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `gumroad_coupons`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `gumroad_coupons` (
|
||||||
|
`coupon_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`convention_id` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`coupon_code` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`owner_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`coupon_id`),
|
||||||
|
UNIQUE KEY `coupon_code_UNIQUE` (`coupon_code`),
|
||||||
|
KEY `index3` (`owner_id`,`convention_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `instances`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `instances`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `instances` (
|
||||||
|
`id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`event_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`instance_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`world_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`invite_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`instance_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`is_private` tinyint(1) DEFAULT NULL,
|
||||||
|
`is_host` tinyint(1) DEFAULT NULL,
|
||||||
|
`auto_number` smallint unsigned NOT NULL,
|
||||||
|
`status` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`player_count` smallint unsigned DEFAULT NULL,
|
||||||
|
`count_updated` datetime DEFAULT NULL,
|
||||||
|
`usr_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`instance_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`user_cap` tinyint unsigned DEFAULT NULL,
|
||||||
|
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`restricted` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`supporter` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `event_id_fk_idx` (`event_id`),
|
||||||
|
CONSTRAINT `event_id_fk` FOREIGN KEY (`event_id`) REFERENCES `events` (`id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `join_history`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `join_history`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `join_history` (
|
||||||
|
`history_id` int unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
`instance_name` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`instance_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`world_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`user_vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`user_username` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`user_display_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`user_platform` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`user_developer_type` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`user_trust` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`user_troll` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`user_supporter` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`time_joined` datetime NOT NULL,
|
||||||
|
`time_left` datetime DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`history_id`),
|
||||||
|
KEY `index2` (`user_vrchat_id`),
|
||||||
|
KEY `instance_name` (`instance_name`),
|
||||||
|
KEY `instance_id` (`instance_id`),
|
||||||
|
KEY `time_joined` (`time_joined`),
|
||||||
|
KEY `time_left` (`time_left`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=841 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
/*!50003 SET @saved_cs_client = @@character_set_client */ ;
|
||||||
|
/*!50003 SET @saved_cs_results = @@character_set_results */ ;
|
||||||
|
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
|
||||||
|
/*!50003 SET character_set_client = utf8mb4 */ ;
|
||||||
|
/*!50003 SET character_set_results = utf8mb4 */ ;
|
||||||
|
/*!50003 SET collation_connection = utf8mb4_0900_ai_ci */ ;
|
||||||
|
/*!50003 SET @saved_sql_mode = @@sql_mode */ ;
|
||||||
|
/*!50003 SET sql_mode = 'REAL_AS_FLOAT,PIPES_AS_CONCAT,IGNORE_SPACE,ONLY_FULL_GROUP_BY,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION' */ ;
|
||||||
|
DELIMITER ;;
|
||||||
|
/*!50003 CREATE*/ /*!50017 DEFINER=`doadmin`@`%`*/ /*!50003 TRIGGER `join_history_to_attendee_locations` AFTER INSERT ON `join_history` FOR EACH ROW BEGIN
|
||||||
|
SET @EVENTID = (SELECT instances.event_id FROM instances WHERE instances.instance_id = NEW.instance_id);
|
||||||
|
SET @INSTANCEID = (SELECT id from instances WHERE instances.instance_id = NEW.instance_id);
|
||||||
|
SET @EVENTNAME = (SELECT events.name FROM events WHERE events.id = @EVENTID);
|
||||||
|
INSERT INTO attendee_locations (vrchat_user_id, instance_id, event_id, event_name, updated) VALUES
|
||||||
|
(NEW.user_vrchat_id, @INSTANCEID, @EVENTID, @EVENTNAME, NOW()) ON DUPLICATE KEY UPDATE
|
||||||
|
instance_id = @INSTANCEID, event_id = @EVENTID, event_name = @EVENTNAME, updated = NOW();
|
||||||
|
END */;;
|
||||||
|
DELIMITER ;
|
||||||
|
/*!50003 SET sql_mode = @saved_sql_mode */ ;
|
||||||
|
/*!50003 SET character_set_client = @saved_cs_client */ ;
|
||||||
|
/*!50003 SET character_set_results = @saved_cs_results */ ;
|
||||||
|
/*!50003 SET collation_connection = @saved_col_connection */ ;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `logs`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `logs`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `logs` (
|
||||||
|
`log_id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`message` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci,
|
||||||
|
`channel` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`created` datetime DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`log_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=54866 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `moderation_log`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `moderation_log`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `moderation_log` (
|
||||||
|
`id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`moderator_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`target` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`type` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`data` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`created_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `idx_action_by_time_type_target` (`moderator_id`,`created_at`,`type`,`target`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `parties`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `parties`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `parties` (
|
||||||
|
`party_id` varchar(5) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`is_owner` tinyint(1) NOT NULL,
|
||||||
|
`accepted` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
PRIMARY KEY (`party_id`,`vrchat_id`),
|
||||||
|
KEY `index2` (`vrchat_id`),
|
||||||
|
KEY `index3` (`vrchat_id`,`is_owner`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `payment_webhook_events`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `payment_webhook_events`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `payment_webhook_events` (
|
||||||
|
`id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`source` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`transaction_id` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`event_type` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`status` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`create_time` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`created_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `idx_payment_webhook_events_key` (`source`,`transaction_id`,`event_type`,`status`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `payments`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `payments`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `payments` (
|
||||||
|
`payment_id` int unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
`convention_id` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`vrchat_user_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`type` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`product` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`reg_total` varchar(6) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`donation_total` varchar(6) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`payment_total` varchar(6) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`payment_method` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`paypal_email` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`transaction_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`transaction_intent_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`transaction_status` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`receipt_sent` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
`discord_updated` tinyint(1) DEFAULT '0',
|
||||||
|
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`updated` datetime DEFAULT NULL,
|
||||||
|
`airtable_id` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`receipt_id` varchar(11) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`payment_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=11510 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `permission_group_users`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `permission_group_users`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `permission_group_users` (
|
||||||
|
`group_id` int NOT NULL,
|
||||||
|
`vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
PRIMARY KEY (`group_id`,`vrchat_id`),
|
||||||
|
KEY `vrchat_id` (`vrchat_id`),
|
||||||
|
CONSTRAINT `permission_group_users_ibfk_1` FOREIGN KEY (`group_id`) REFERENCES `permission_groups` (`group_id`) ON DELETE CASCADE ON UPDATE CASCADE,
|
||||||
|
CONSTRAINT `permission_group_users_ibfk_2` FOREIGN KEY (`vrchat_id`) REFERENCES `attendees` (`vrchat_id`) ON DELETE CASCADE ON UPDATE CASCADE
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `permission_groups`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `permission_groups`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `permission_groups` (
|
||||||
|
`group_id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`description` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`group_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=20 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `permission_links`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `permission_links`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `permission_links` (
|
||||||
|
`group_id` int NOT NULL,
|
||||||
|
`permission_key` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
PRIMARY KEY (`group_id`,`permission_key`),
|
||||||
|
KEY `permission_key` (`permission_key`),
|
||||||
|
CONSTRAINT `permission_links_ibfk_1` FOREIGN KEY (`group_id`) REFERENCES `permission_groups` (`group_id`) ON DELETE CASCADE ON UPDATE CASCADE,
|
||||||
|
CONSTRAINT `permission_links_ibfk_2` FOREIGN KEY (`permission_key`) REFERENCES `permissions` (`permission_key`) ON DELETE CASCADE ON UPDATE CASCADE
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `permissions`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `permissions`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `permissions` (
|
||||||
|
`permission_key` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`description` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`permission_key`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `phinxlog`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `phinxlog`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `phinxlog` (
|
||||||
|
`version` bigint NOT NULL,
|
||||||
|
`migration_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`start_time` timestamp NULL DEFAULT NULL,
|
||||||
|
`end_time` timestamp NULL DEFAULT NULL,
|
||||||
|
`breakpoint` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
PRIMARY KEY (`version`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `service_accounts`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `service_accounts`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `service_accounts` (
|
||||||
|
`id` int NOT NULL AUTO_INCREMENT,
|
||||||
|
`name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`hash` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`creator_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`created_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`updated_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`expires_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`is_active` tinyint(1) NOT NULL DEFAULT '1',
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `idx_service_accounts_key` (`name`,`hash`,`creator_id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `service_accounts_links`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `service_accounts_links`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `service_accounts_links` (
|
||||||
|
`service_account_id` int NOT NULL,
|
||||||
|
`permission_key` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
PRIMARY KEY (`service_account_id`,`permission_key`),
|
||||||
|
KEY `permission_key` (`permission_key`),
|
||||||
|
CONSTRAINT `service_accounts_links_ibfk_1` FOREIGN KEY (`service_account_id`) REFERENCES `service_accounts` (`id`) ON DELETE CASCADE ON UPDATE CASCADE,
|
||||||
|
CONSTRAINT `service_accounts_links_ibfk_2` FOREIGN KEY (`permission_key`) REFERENCES `permissions` (`permission_key`) ON DELETE CASCADE ON UPDATE CASCADE
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `vouchers`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `vouchers`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `vouchers` (
|
||||||
|
`voucher_id` int unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
`convention_id` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`voucher_code` varchar(30) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`reg_level` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`created_by` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`used_by` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`active` tinyint(1) NOT NULL,
|
||||||
|
`reason` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`voucher_id`),
|
||||||
|
UNIQUE KEY `voucher_code` (`voucher_code`),
|
||||||
|
KEY `index3` (`created_by`,`convention_id`),
|
||||||
|
KEY `index4` (`convention_id`,`voucher_code`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=4595 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `vrchat_api`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `vrchat_api`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `vrchat_api` (
|
||||||
|
`authcookie` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`apikey` varchar(40) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`username` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`active` tinyint NOT NULL DEFAULT '1',
|
||||||
|
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`authcookie`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `vrchat_api_log`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `vrchat_api_log`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `vrchat_api_log` (
|
||||||
|
`log_id` int unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
`target` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`status` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`status_code` varchar(5) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`response` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci,
|
||||||
|
`authcookie` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
PRIMARY KEY (`log_id`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=22947179 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `vrchat_invites`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `vrchat_invites`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `vrchat_invites` (
|
||||||
|
`id` int unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
`vrchat_id` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`world_id` varchar(80) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`instance_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`send_after` datetime DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`sent` tinyint DEFAULT '0',
|
||||||
|
`created` datetime DEFAULT CURRENT_TIMESTAMP,
|
||||||
|
`sent_time` datetime DEFAULT NULL,
|
||||||
|
PRIMARY KEY (`id`),
|
||||||
|
KEY `index2` (`vrchat_id`),
|
||||||
|
KEY `index3` (`id`,`created`)
|
||||||
|
) ENGINE=InnoDB AUTO_INCREMENT=257004 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `worlds`
|
||||||
|
--
|
||||||
|
|
||||||
|
DROP TABLE IF EXISTS `worlds`;
|
||||||
|
/*!40101 SET @saved_cs_client = @@character_set_client */;
|
||||||
|
/*!50503 SET character_set_client = utf8mb4 */;
|
||||||
|
CREATE TABLE `worlds` (
|
||||||
|
`id` varchar(25) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL,
|
||||||
|
`world_id` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL,
|
||||||
|
`updated` datetime DEFAULT NULL,
|
||||||
|
`created` datetime NOT NULL,
|
||||||
|
PRIMARY KEY (`id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
|
||||||
|
/*!40101 SET character_set_client = @saved_cs_client */;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Dumping routines for database 'portal_dev'
|
||||||
|
--
|
||||||
|
SET @@SESSION.SQL_LOG_BIN = @MYSQLDUMP_TEMP_LOG_BIN;
|
||||||
|
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
|
||||||
|
|
||||||
|
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
|
||||||
|
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
|
||||||
|
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
|
||||||
|
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||||
|
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||||
|
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
||||||
|
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
|
||||||
|
|
||||||
|
-- Dump completed on 2023-09-26 18:07:27
|
|
@ -0,0 +1 @@
|
||||||
|
#!/bin/bash
|
Loading…
Reference in a new issue