-- Deploy gaia:2019_11_06_add_bar to mysql

BEGIN;

CREATE TABLE `api_service_index_jump` (
    `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    `name` varchar(20) NOT NULL UNIQUE,
    `url` varchar(1024) NOT NULL,
    `start_time` datetime(6) NOT NULL,
    `end_time` datetime(6) NOT NULL,
    `is_online` bool NOT NULL,
    `create_time` datetime(6) NOT NULL,
    `update_time` datetime(6) NOT NULL
)
;
CREATE TABLE `api_default_bar` (
    `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    `bar_type` integer NOT NULL,
    `start_time` datetime(6) NOT NULL,
    `end_time` datetime(6) NOT NULL,
    `is_online` bool NOT NULL,
    `create_time` datetime(6) NOT NULL,
    `update_time` datetime(6) NOT NULL
)
;

COMMIT;
