UPDATE `settings` SET `value` = '{\"version\":\"33.0.0\", \"code\":\"3300\"}' WHERE `key` = 'product_info';

-- SEPARATOR --UPDATE `settings` SET `value` = '{\"version\":\"34.0.0\", \"code\":\"3400\"}' WHERE `key` = 'product_info';
-- SEPARATOR --
-- X --

alter table projects drop key project_id;
-- SEPARATOR --
-- X --

alter table notification_handlers drop key notification_handler_id;

-- SEPARATOR --
-- X --

alter table transfers drop key transfer_id;
-- SEPARATOR --UPDATE `settings` SET `value` = '{\"version\":\"35.0.0\", \"code\":\"3500\"}' WHERE `key` = 'product_info';
-- SEPARATOR --
-- SEPARATOR --UPDATE `settings` SET `value` = '{\"version\":\"36.0.0\", \"code\":\"3600\"}' WHERE `key` = 'product_info';
-- SEPARATOR --

alter table pages add footer_category_id varchar(64) null after pages_category_id;

-- SEPARATOR --

alter table pages modify type enum ('internal', 'external', 'feature') null;

-- SEPARATOR --

INSERT INTO `pages` (`pages_category_id`, `footer_category_id`, `plans_ids`, `url`, `title`, `description`, `icon`, `keywords`, `editor`, `content`, `type`, `position`, `language`, `open_in_new_tab`, `order`, `total_views`, `is_published`, `datetime`, `last_datetime`) VALUES
(NULL, 'resources', NULL, 'blog', '', NULL, NULL, NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 2, 0, 1, NOW(), NULL),
(NULL, 'product', NULL, 'affiliate', '', NULL, NULL, NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 4, 0, 1, NOW(), NULL),
(NULL, 'resources', NULL, 'contact', '', NULL, NULL, NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 3, 0, 1, NOW(), NULL),
(NULL, 'product', NULL, 'cookie_consent', '', NULL, NULL, NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 5, 0, 1, NOW(), NULL),
(NULL, 'product', NULL, 'push_notifications', '', NULL, NULL, NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 6, 0, 1, NOW(), NULL),
(NULL, 'resources', NULL, 'pages', '', NULL, NULL, NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 1, 0, 1, NOW(), NULL),
(NULL, 'product', NULL, 'api-documentation', '', NULL, '', NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 3, 0, 1, NOW(), NULL),
(NULL, 'product', NULL, 'plan', '', NULL, NULL, NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 2, 0, 1, NOW(), NULL),
(NULL, 'product', NULL, 'dashboard', '', NULL, NULL, NULL, NULL, NULL, 'feature', 'bottom', NULL, 0, 1, 0, 1, NOW(), NULL);
-- SEPARATOR --UPDATE `settings` SET `value` = '{\"version\":\"37.0.0\", \"code\":\"3700\"}' WHERE `key` = 'product_info';
-- SEPARATOR --
ALTER TABLE `users` ADD COLUMN `latitude` DECIMAL(10, 8) NULL AFTER `ip`, ADD COLUMN `longitude` DECIMAL(11, 8) NULL AFTER `latitude`;
-- SEPARATOR --
-- X --

alter table teams_members add token varchar(32) null after user_id;
-- SEPARATOR --