-- ----------------------------
-- Table structure for BLADE_LOG_ERROR
-- ----------------------------
-- DROP TABLE "BLADE_LOG_ERROR";
CREATE TABLE "BLADE_LOG_ERROR"
(
    "ID"             NUMBER(20) NOT NULL,
    "TENANT_ID"      NVARCHAR2(12) DEFAULT 000000,
    "SERVICE_ID"     NVARCHAR2(32),
    "SERVER_HOST"    NVARCHAR2(255),
    "SERVER_IP"      NVARCHAR2(255),
    "ENV"            NVARCHAR2(255),
    "METHOD"         NVARCHAR2(10),
    "REQUEST_URI"    NVARCHAR2(255),
    "USER_AGENT"     NVARCHAR2(1000),
    "STACK_TRACE"    NCLOB,
    "EXCEPTION_NAME" NVARCHAR2(255),
    "MESSAGE"        NCLOB,
    "LINE_NUMBER"    NUMBER(11),
    "REMOTE_IP"      NVARCHAR2(255),
    "METHOD_CLASS"   NVARCHAR2(255),
    "FILE_NAME"      NVARCHAR2(1000),
    "METHOD_NAME"    NVARCHAR2(255),
    "PARAMS"         NCLOB,
    "CREATE_BY"      NVARCHAR2(64),
    "CREATE_TIME"    DATE
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."ID" IS '编号';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."TENANT_ID" IS '租户ID';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."SERVICE_ID" IS '服务ID';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."SERVER_HOST" IS '服务器名';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."SERVER_IP" IS '服务器IP地址';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."ENV" IS '系统环境';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."METHOD" IS '操作方式';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."REQUEST_URI" IS '请求URI';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."USER_AGENT" IS '用户代理';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."STACK_TRACE" IS '堆栈';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."EXCEPTION_NAME" IS '异常名';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."MESSAGE" IS '异常信息';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."LINE_NUMBER" IS '错误行数';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."REMOTE_IP" IS '操作IP地址';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."METHOD_CLASS" IS '方法类';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."FILE_NAME" IS '文件名';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."METHOD_NAME" IS '方法名';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."PARAMS" IS '操作提交的数据';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."CREATE_BY" IS '创建者';
COMMENT
    ON COLUMN "BLADE_LOG_ERROR"."CREATE_TIME" IS '创建时间';
COMMENT
    ON TABLE "BLADE_LOG_ERROR" IS '错误日志表';

-- ----------------------------
-- Primary Key structure for table BLADE_LOG_ERROR
-- ----------------------------
ALTER TABLE "BLADE_LOG_ERROR"
    ADD CONSTRAINT "1655780219PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_LOG_ERROR
-- ----------------------------
ALTER TABLE "BLADE_LOG_ERROR"
    ADD CONSTRAINT "SYS_C0023656" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_CLIENT
-- ----------------------------
-- DROP TABLE "BLADE_CLIENT";
CREATE TABLE "BLADE_CLIENT"
(
    "ID"                      NUMBER(20)     NOT NULL,
    "CLIENT_ID"               NVARCHAR2(48)  NOT NULL,
    "CLIENT_SECRET"           NVARCHAR2(256) NOT NULL,
    "RESOURCE_IDS"            NVARCHAR2(256),
    "SCOPE"                   NVARCHAR2(256) NOT NULL,
    "AUTHORIZED_GRANT_TYPES"  NVARCHAR2(256) NOT NULL,
    "WEB_SERVER_REDIRECT_URI" NVARCHAR2(256),
    "AUTHORITIES"             NVARCHAR2(256),
    "ACCESS_TOKEN_VALIDITY"   NUMBER(11)     NOT NULL,
    "REFRESH_TOKEN_VALIDITY"  NUMBER(11)     NOT NULL,
    "ADDITIONAL_INFORMATION"  NCLOB,
    "AUTOAPPROVE"             NVARCHAR2(256),
    "CREATE_USER"             NUMBER(20),
    "CREATE_DEPT"             NUMBER(20),
    "CREATE_TIME"             DATE,
    "UPDATE_USER"             NUMBER(20),
    "UPDATE_TIME"             DATE,
    "STATUS"                  NUMBER(11)     NOT NULL,
    "IS_DELETED"              NUMBER(11)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_CLIENT"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_CLIENT"."CLIENT_ID" IS '客户端id';
COMMENT
    ON COLUMN "BLADE_CLIENT"."CLIENT_SECRET" IS '客户端密钥';
COMMENT
    ON COLUMN "BLADE_CLIENT"."RESOURCE_IDS" IS '资源集合';
COMMENT
    ON COLUMN "BLADE_CLIENT"."SCOPE" IS '授权范围';
COMMENT
    ON COLUMN "BLADE_CLIENT"."AUTHORIZED_GRANT_TYPES" IS '授权类型';
COMMENT
    ON COLUMN "BLADE_CLIENT"."WEB_SERVER_REDIRECT_URI" IS '回调地址';
COMMENT
    ON COLUMN "BLADE_CLIENT"."AUTHORITIES" IS '权限';
COMMENT
    ON COLUMN "BLADE_CLIENT"."ACCESS_TOKEN_VALIDITY" IS '令牌过期秒数';
COMMENT
    ON COLUMN "BLADE_CLIENT"."REFRESH_TOKEN_VALIDITY" IS '刷新令牌过期秒数';
COMMENT
    ON COLUMN "BLADE_CLIENT"."ADDITIONAL_INFORMATION" IS '附加说明';
COMMENT
    ON COLUMN "BLADE_CLIENT"."AUTOAPPROVE" IS '自动授权';
COMMENT
    ON COLUMN "BLADE_CLIENT"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_CLIENT"."CREATE_DEPT" IS '创建部门';
COMMENT
    ON COLUMN "BLADE_CLIENT"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_CLIENT"."UPDATE_USER" IS '修改人';
COMMENT
    ON COLUMN "BLADE_CLIENT"."UPDATE_TIME" IS '修改时间';
COMMENT
    ON COLUMN "BLADE_CLIENT"."STATUS" IS '状态';
COMMENT
    ON TABLE "BLADE_CLIENT" IS '客户端表';

-- ----------------------------
-- Primary Key structure for table BLADE_CLIENT
-- ----------------------------
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "1655780185PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_CLIENT
-- ----------------------------
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "SYS_C0023577" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "SYS_C0023578" CHECK ("CLIENT_ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "SYS_C0023579" CHECK ("CLIENT_SECRET" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "SYS_C0023580" CHECK ("SCOPE" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "SYS_C0023581" CHECK ("AUTHORIZED_GRANT_TYPES" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "SYS_C0023582" CHECK ("ACCESS_TOKEN_VALIDITY" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "SYS_C0023583" CHECK ("REFRESH_TOKEN_VALIDITY" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_CLIENT"
    ADD CONSTRAINT "SYS_C0023584" CHECK ("STATUS" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_I18N_DATA
-- ----------------------------
-- DROP TABLE "BLADE_I18N_DATA";
CREATE TABLE "BLADE_I18N_DATA"
(
    "ID"           NUMBER(20) NOT NULL,
    "LANGUAGE_TAG" NVARCHAR2(10),
    "CODE"         NVARCHAR2(255),
    "MESSAGE"      NVARCHAR2(255),
    "REMARK"       NVARCHAR2(255),
    "CREATE_USER"  NUMBER(20),
    "UPDATE_USER"  NUMBER(20),
    "CREATE_TIME"  DATE,
    "UPDATE_TIME"  DATE
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."LANGUAGE_TAG" IS '语言标签';
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."CODE" IS '唯一标识 = 业务:关键词';
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."MESSAGE" IS '文本值，可以使用 { } 加角标，作为占位符';
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."REMARK" IS '备注';
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."UPDATE_USER" IS '修改人';
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_I18N_DATA"."UPDATE_TIME" IS '修改时间';


-- ----------------------------
-- Primary Key structure for table BLADE_I18N_DATA
-- ----------------------------
ALTER TABLE "BLADE_I18N_DATA"
    ADD CONSTRAINT "1655780215PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_I18N_DATA
-- ----------------------------
ALTER TABLE "BLADE_I18N_DATA"
    ADD CONSTRAINT "SYS_C0023644" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_TENANT
-- ----------------------------
-- DROP TABLE "BLADE_TENANT";
CREATE TABLE "BLADE_TENANT"
(
    "ID"             NUMBER(20)    NOT NULL,
    "TENANT_ID"      NVARCHAR2(12) DEFAULT 000000,
    "TENANT_NAME"    NVARCHAR2(50) NOT NULL,
    "DOMAIN_NAME"    NVARCHAR2(255),
    "BACKGROUND_URL" NVARCHAR2(1000),
    "LINKMAN"        NVARCHAR2(20),
    "CONTACT_NUMBER" NVARCHAR2(20),
    "ADDRESS"        NVARCHAR2(255),
    "ACCOUNT_NUMBER" NUMBER(11)    DEFAULT -1,
    "EXPIRE_TIME"    DATE,
    "DATASOURCE_ID"  NUMBER(20),
    "LICENSE_KEY"    NVARCHAR2(1000),
    "CREATE_USER"    NUMBER(20),
    "CREATE_DEPT"    NUMBER(20),
    "CREATE_TIME"    DATE,
    "UPDATE_USER"    NUMBER(20),
    "UPDATE_TIME"    DATE,
    "STATUS"         NUMBER(11),
    "IS_DELETED"     NUMBER(11),
    "BLADE_LICENSE"  NCLOB
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_TENANT"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_TENANT"."TENANT_ID" IS '租户ID';
COMMENT
    ON COLUMN "BLADE_TENANT"."TENANT_NAME" IS '租户名称';
COMMENT
    ON COLUMN "BLADE_TENANT"."DOMAIN_NAME" IS '域名地址';
COMMENT
    ON COLUMN "BLADE_TENANT"."BACKGROUND_URL" IS '系统背景';
COMMENT
    ON COLUMN "BLADE_TENANT"."LINKMAN" IS '联系人';
COMMENT
    ON COLUMN "BLADE_TENANT"."CONTACT_NUMBER" IS '联系电话';
COMMENT
    ON COLUMN "BLADE_TENANT"."ADDRESS" IS '联系地址';
COMMENT
    ON COLUMN "BLADE_TENANT"."ACCOUNT_NUMBER" IS '账号额度';
COMMENT
    ON COLUMN "BLADE_TENANT"."EXPIRE_TIME" IS '过期时间';
COMMENT
    ON COLUMN "BLADE_TENANT"."DATASOURCE_ID" IS '数据源ID';
COMMENT
    ON COLUMN "BLADE_TENANT"."LICENSE_KEY" IS '授权码';
COMMENT
    ON COLUMN "BLADE_TENANT"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_TENANT"."CREATE_DEPT" IS '创建部门';
COMMENT
    ON COLUMN "BLADE_TENANT"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_TENANT"."UPDATE_USER" IS '修改人';
COMMENT
    ON COLUMN "BLADE_TENANT"."UPDATE_TIME" IS '修改时间';
COMMENT
    ON COLUMN "BLADE_TENANT"."STATUS" IS '状态';
COMMENT
    ON COLUMN "BLADE_TENANT"."BLADE_LICENSE" IS '单体授权码';
COMMENT
    ON TABLE "BLADE_TENANT" IS '租户表';


-- ----------------------------
-- Primary Key structure for table BLADE_TENANT
-- ----------------------------
ALTER TABLE "BLADE_TENANT"
    ADD CONSTRAINT "1655780278PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_TENANT
-- ----------------------------
ALTER TABLE "BLADE_TENANT"
    ADD CONSTRAINT "SYS_C0023738" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_TENANT"
    ADD CONSTRAINT "SYS_C0023739" CHECK ("TENANT_NAME" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_MENU
-- ----------------------------
-- DROP TABLE "BLADE_MENU";
CREATE TABLE "BLADE_MENU"
(
    "ID"                  NUMBER(20)                   NOT NULL,
    "PARENT_ID"           NUMBER(20)     DEFAULT 0,
    "CODE"                NVARCHAR2(255),
    "NAME"                NVARCHAR2(255),
    "ALIAS"               NVARCHAR2(255),
    "PATH"                NVARCHAR2(255),
    "SOURCE"              NVARCHAR2(255),
    "SORT"                NUMBER(11),
    "CATEGORY"            NUMBER(11),
    "ACTION"              NUMBER(11)     DEFAULT 0,
    "IS_OPEN"             NUMBER(11)     DEFAULT 1,
    "REMARK"              NVARCHAR2(255),
    "IS_DELETED"          NUMBER(11),
    "BELONG_APPLICATION"  NVARCHAR2(255) DEFAULT 'CPS' NOT NULL,
    "KEEP_ALIVE"          NUMBER(4)      DEFAULT 1
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_MENU"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_MENU"."PARENT_ID" IS '父级菜单';
COMMENT
    ON COLUMN "BLADE_MENU"."CODE" IS '菜单编号';
COMMENT
    ON COLUMN "BLADE_MENU"."NAME" IS '菜单名称';
COMMENT
    ON COLUMN "BLADE_MENU"."ALIAS" IS '菜单别名';
COMMENT
    ON COLUMN "BLADE_MENU"."PATH" IS '请求地址';
COMMENT
    ON COLUMN "BLADE_MENU"."SOURCE" IS '菜单资源';
COMMENT
    ON COLUMN "BLADE_MENU"."SORT" IS '排序';
COMMENT
    ON COLUMN "BLADE_MENU"."CATEGORY" IS '菜单类型';
COMMENT
    ON COLUMN "BLADE_MENU"."ACTION" IS '操作按钮类型';
COMMENT
    ON COLUMN "BLADE_MENU"."IS_OPEN" IS '是否打开新页面';
COMMENT
    ON COLUMN "BLADE_MENU"."REMARK" IS '备注';
COMMENT
    ON COLUMN "BLADE_MENU"."BELONG_APPLICATION" IS '所属应用';
COMMENT
    ON COLUMN "BLADE_MENU"."KEEP_ALIVE" IS '路由缓存 1启用缓冲 0 停用缓冲';
COMMENT
    ON TABLE "BLADE_MENU" IS '菜单表';

-- ----------------------------
-- Primary Key structure for table BLADE_MENU
-- ----------------------------
ALTER TABLE "BLADE_MENU"
    ADD CONSTRAINT "1655780233PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_MENU
-- ----------------------------
ALTER TABLE "BLADE_MENU"
    ADD CONSTRAINT "SYS_C0023673" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_DEPT
-- ----------------------------
-- DROP TABLE "BLADE_DEPT";
CREATE TABLE "BLADE_DEPT"
(
    "ID"            NUMBER(20) NOT NULL,
    "TENANT_ID"     NVARCHAR2(12) DEFAULT 000000,
    "PARENT_ID"     NUMBER(20)    DEFAULT 0,
    "ANCESTORS"     NCLOB,
    "DEPT_CATEGORY" NUMBER(11),
    "DEPT_NAME"     NVARCHAR2(45),
    "FULL_NAME"     NVARCHAR2(45),
    "SORT"          NUMBER(11),
    "REMARK"        NVARCHAR2(255),
    "IS_DELETED"    NUMBER(11)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_DEPT"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_DEPT"."TENANT_ID" IS '租户ID';
COMMENT
    ON COLUMN "BLADE_DEPT"."PARENT_ID" IS '父主键';
COMMENT
    ON COLUMN "BLADE_DEPT"."ANCESTORS" IS '祖级列表';
COMMENT
    ON COLUMN "BLADE_DEPT"."DEPT_CATEGORY" IS '部门类型';
COMMENT
    ON COLUMN "BLADE_DEPT"."DEPT_NAME" IS '部门名';
COMMENT
    ON COLUMN "BLADE_DEPT"."FULL_NAME" IS '部门全称';
COMMENT
    ON COLUMN "BLADE_DEPT"."SORT" IS '排序';
COMMENT
    ON COLUMN "BLADE_DEPT"."REMARK" IS '备注';
COMMENT
    ON TABLE "BLADE_DEPT" IS '机构表';


-- ----------------------------
-- Primary Key structure for table BLADE_DEPT
-- ----------------------------
ALTER TABLE "BLADE_DEPT"
    ADD CONSTRAINT "1655780191PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_DEPT
-- ----------------------------
ALTER TABLE "BLADE_DEPT"
    ADD CONSTRAINT "SYS_C0023594" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_USER
-- ----------------------------
-- DROP TABLE "BLADE_USER";
CREATE TABLE "BLADE_USER"
(
    "ID"                 NUMBER(20) NOT NULL,
    "TENANT_ID"          NVARCHAR2(12) DEFAULT 000000,
    "CODE"               NVARCHAR2(45),
    "USER_TYPE"          NUMBER(11),
    "ACCOUNT"            NVARCHAR2(45),
    "PASSWORD"           NVARCHAR2(45),
    "NAME"               NVARCHAR2(45),
    "REAL_NAME"          NVARCHAR2(45),
    "AVATAR"             NVARCHAR2(500),
    "EMAIL"              NVARCHAR2(45),
    "PHONE"              NVARCHAR2(45),
    "BIRTHDAY"           DATE,
    "SEX"                NUMBER(11),
    "ROLE_ID"            NVARCHAR2(1000),
    "DEPT_ID"            NVARCHAR2(1000),
    "POST_ID"            NVARCHAR2(1000),
    "CREATE_USER"        NUMBER(20),
    "CREATE_DEPT"        NUMBER(20),
    "CREATE_TIME"        DATE,
    "UPDATE_USER"        NUMBER(20),
    "UPDATE_TIME"        DATE,
    "STATUS"             NUMBER(11),
    "IS_DELETED"         NUMBER(11)    DEFAULT 0,
    "PWD_SECURITY_LEVEL" NUMBER(4),
    "PWD_UPDATE_DATE"    DATE,
    "PWD_UPDATE_RECORD"  NCLOB
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_USER"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_USER"."TENANT_ID" IS '租户ID';
COMMENT
    ON COLUMN "BLADE_USER"."CODE" IS '用户编号';
COMMENT
    ON COLUMN "BLADE_USER"."USER_TYPE" IS '用户平台';
COMMENT
    ON COLUMN "BLADE_USER"."ACCOUNT" IS '账号';
COMMENT
    ON COLUMN "BLADE_USER"."PASSWORD" IS '密码';
COMMENT
    ON COLUMN "BLADE_USER"."NAME" IS '昵称';
COMMENT
    ON COLUMN "BLADE_USER"."REAL_NAME" IS '真名';
COMMENT
    ON COLUMN "BLADE_USER"."AVATAR" IS '头像';
COMMENT
    ON COLUMN "BLADE_USER"."EMAIL" IS '邮箱';
COMMENT
    ON COLUMN "BLADE_USER"."PHONE" IS '手机';
COMMENT
    ON COLUMN "BLADE_USER"."BIRTHDAY" IS '生日';
COMMENT
    ON COLUMN "BLADE_USER"."SEX" IS '性别';
COMMENT
    ON COLUMN "BLADE_USER"."ROLE_ID" IS '角色id';
COMMENT
    ON COLUMN "BLADE_USER"."DEPT_ID" IS '部门id';
COMMENT
    ON COLUMN "BLADE_USER"."POST_ID" IS '岗位id';
COMMENT
    ON COLUMN "BLADE_USER"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_USER"."CREATE_DEPT" IS '创建部门';
COMMENT
    ON COLUMN "BLADE_USER"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_USER"."UPDATE_USER" IS '修改人';
COMMENT
    ON COLUMN "BLADE_USER"."UPDATE_TIME" IS '修改时间';
COMMENT
    ON COLUMN "BLADE_USER"."STATUS" IS '状态';
COMMENT
    ON COLUMN "BLADE_USER"."IS_DELETED" IS '是否已删除';
COMMENT
    ON COLUMN "BLADE_USER"."PWD_SECURITY_LEVEL" IS '密码安全级别（0初始  1弱 2安全 3很安全）记录当前密码存储时候等级，如果后面更改密码等级时候是否需要强制修改';
COMMENT
    ON COLUMN "BLADE_USER"."PWD_UPDATE_DATE" IS '密码最后更新时间';
COMMENT
    ON COLUMN "BLADE_USER"."PWD_UPDATE_RECORD" IS '密码修改记录，每次修改时候记录原密码，以逗号分隔开，防止以后要做不允许输入以往密码';
COMMENT
    ON TABLE "BLADE_USER" IS '用户表';


-- ----------------------------
-- Primary Key structure for table BLADE_USER
-- ----------------------------
ALTER TABLE "BLADE_USER"
    ADD CONSTRAINT "1655780292PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_USER
-- ----------------------------
ALTER TABLE "BLADE_USER"
    ADD CONSTRAINT "SYS_C0023757" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_OSS
-- ----------------------------
-- DROP TABLE "BLADE_OSS";
CREATE TABLE "BLADE_OSS"
(
    "ID"          NUMBER(20) NOT NULL,
    "TENANT_ID"   NVARCHAR2(12) DEFAULT 000000,
    "CATEGORY"    NUMBER(11),
    "OSS_CODE"    NVARCHAR2(32),
    "ENDPOINT"    NVARCHAR2(255),
    "ACCESS_KEY"  NVARCHAR2(255),
    "SECRET_KEY"  NVARCHAR2(255),
    "BUCKET_NAME" NVARCHAR2(255),
    "APP_ID"      NVARCHAR2(255),
    "REGION"      NVARCHAR2(255),
    "REMARK"      NVARCHAR2(255),
    "CREATE_USER" NUMBER(20),
    "CREATE_DEPT" NUMBER(20),
    "CREATE_TIME" DATE,
    "UPDATE_USER" NUMBER(20),
    "UPDATE_TIME" DATE,
    "STATUS"      NUMBER(11),
    "IS_DELETED"  NUMBER(11)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_OSS"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_OSS"."TENANT_ID" IS '租户ID';
COMMENT
    ON COLUMN "BLADE_OSS"."CATEGORY" IS '分类';
COMMENT
    ON COLUMN "BLADE_OSS"."OSS_CODE" IS '资源编号';
COMMENT
    ON COLUMN "BLADE_OSS"."ENDPOINT" IS '资源地址';
COMMENT
    ON COLUMN "BLADE_OSS"."ACCESS_KEY" IS 'accessKey';
COMMENT
    ON COLUMN "BLADE_OSS"."SECRET_KEY" IS 'secretKey';
COMMENT
    ON COLUMN "BLADE_OSS"."BUCKET_NAME" IS '空间名';
COMMENT
    ON COLUMN "BLADE_OSS"."APP_ID" IS '应用ID';
COMMENT
    ON COLUMN "BLADE_OSS"."REGION" IS '地域简称';
COMMENT
    ON COLUMN "BLADE_OSS"."REMARK" IS '备注';
COMMENT
    ON COLUMN "BLADE_OSS"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_OSS"."CREATE_DEPT" IS '创建部门';
COMMENT
    ON COLUMN "BLADE_OSS"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_OSS"."UPDATE_USER" IS '修改人';
COMMENT
    ON COLUMN "BLADE_OSS"."UPDATE_TIME" IS '修改时间';
COMMENT
    ON COLUMN "BLADE_OSS"."STATUS" IS '状态';
COMMENT
    ON TABLE "BLADE_OSS" IS '对象存储表';

-- ----------------------------
-- Primary Key structure for table BLADE_OSS
-- ----------------------------
ALTER TABLE "BLADE_OSS"
    ADD CONSTRAINT "1655780246PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_OSS
-- ----------------------------
ALTER TABLE "BLADE_OSS"
    ADD CONSTRAINT "SYS_C0023702" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_COMMON_GROUP
-- ----------------------------
-- DROP TABLE "BLADE_COMMON_GROUP";
CREATE TABLE "BLADE_COMMON_GROUP"
(
    "ID"                   NUMBER(20)              NOT NULL,
    "TENANT_ID"            NVARCHAR2(12) DEFAULT 000000,
    "PARENT_ID"            NUMBER(20)    DEFAULT 0,
    "EXTEND_ID"            NVARCHAR2(64),
    "CODE"                 NVARCHAR2(255),
    "GROUP_TYPE"           NVARCHAR2(45),
    "GROUP_CATEGORY"       NUMBER(4),
    "GROUP_TAG"            NVARCHAR2(32),
    "NAME"                 NVARCHAR2(45),
    "FULL_NAME"            NVARCHAR2(45),
    "SORT"                 NUMBER(11),
    "REMARK"               NVARCHAR2(255),
    "IS_DELETED"           NUMBER(11),
    "STATUS"               NUMBER(4)     DEFAULT 1 NOT NULL,
    "PRODUCTION_LINE_TYPE" NVARCHAR2(50) DEFAULT NULL
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."TENANT_ID" IS '租户ID';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."PARENT_ID" IS '父主键';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."EXTEND_ID" IS '扩展ID，例如 DMP UUID';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."CODE" IS '拼接的虚拟路径字符串代码';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."GROUP_TYPE" IS '组别,
                对应字典编号';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."GROUP_CATEGORY" IS '组子类，对应字典项';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."GROUP_TAG" IS '工位组标签(fms_beltline,beltline)';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."NAME" IS '组名';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."FULL_NAME" IS '组完整名称';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."SORT" IS '排序';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."REMARK" IS '备注';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."STATUS" IS '业务状态 1启用 0 停用';
COMMENT
    ON COLUMN "BLADE_COMMON_GROUP"."PRODUCTION_LINE_TYPE" IS '产线类型：fms_beltline 柔性产线/ beltline 产线';
COMMENT
    ON TABLE "BLADE_COMMON_GROUP" IS '组';

-- ----------------------------
-- Primary Key structure for table BLADE_COMMON_GROUP
-- ----------------------------
ALTER TABLE "BLADE_COMMON_GROUP"
    ADD CONSTRAINT "1655780188PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_COMMON_GROUP
-- ----------------------------
ALTER TABLE "BLADE_COMMON_GROUP"
    ADD CONSTRAINT "SYS_C0023588" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_COMMON_GROUP"
    ADD CONSTRAINT "SYS_C0023589" CHECK ("STATUS" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_INTERFACE_CONFIG_FIELD
-- ----------------------------
-- DROP TABLE "BLADE_INTERFACE_CONFIG_FIELD";
CREATE TABLE "BLADE_INTERFACE_CONFIG_FIELD"
(
    "ID"               NUMBER(20)           NOT NULL,
    "STATUS"           NUMBER(11) DEFAULT 1 NOT NULL,
    "IS_DELETED"       NUMBER(20),
    "CREATE_USER"      NUMBER(20),
    "CREATE_DEPT"      NUMBER(20),
    "CREATE_TIME"      DATE,
    "UPDATE_USER"      NUMBER(20),
    "UPDATE_TIME"      DATE,
    "CONFIG_ID"        NUMBER(20)           NOT NULL,
    "LABEL"            NVARCHAR2(255),
    "NAME"             NVARCHAR2(255)       NOT NULL,
    "IS_REQUIRED"      NUMBER(4)  DEFAULT 0 NOT NULL,
    "DATA_TYPE"        NUMBER(11)           NOT NULL,
    "DATA_SOURCE"      NVARCHAR2(255),
    "IS_SINGLE_CHOICE" NUMBER(4)  DEFAULT 0,
    "CHECKED_PARENT"   NUMBER(4),
    "RELATION_FIELD"   NVARCHAR2(255),
    "METHOD"           NVARCHAR2(10)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."STATUS" IS '业务状态';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."IS_DELETED" IS '删除标记：0-未删除，1-已删除';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."CREATE_DEPT" IS '创建部门';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."UPDATE_USER" IS '更新人';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."UPDATE_TIME" IS '更新时间';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."CONFIG_ID" IS '接口配置id';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."LABEL" IS '字段标题';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."NAME" IS '字段名称';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."IS_REQUIRED" IS '是否必填： 0 - 不必填；1 - 必填';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."DATA_TYPE" IS '0-文本；1-数值；2-下拉；3-日期； 4-树选择';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."DATA_SOURCE" IS '当数据类型是下拉，树选择的时候指定数据源的地址。用于获取这些选项的数据。';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."IS_SINGLE_CHOICE" IS '当下拉选择的时候指定是否单选：- 0 多选； 1 - 单选';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."CHECKED_PARENT" IS '树选择的情况下是否可选择父节点';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."RELATION_FIELD" IS '依赖字段';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG_FIELD"."METHOD" IS '请求方法';
COMMENT
    ON TABLE "BLADE_INTERFACE_CONFIG_FIELD" IS '接口字段表';



-- ----------------------------
-- Primary Key structure for table BLADE_INTERFACE_CONFIG_FIELD
-- ----------------------------
ALTER TABLE "BLADE_INTERFACE_CONFIG_FIELD"
    ADD CONSTRAINT "1655780217PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_INTERFACE_CONFIG_FIELD
-- ----------------------------
ALTER TABLE "BLADE_INTERFACE_CONFIG_FIELD"
    ADD CONSTRAINT "SYS_C0023649" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_INTERFACE_CONFIG_FIELD"
    ADD CONSTRAINT "SYS_C0023650" CHECK ("STATUS" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_INTERFACE_CONFIG_FIELD"
    ADD CONSTRAINT "SYS_C0023651" CHECK ("CONFIG_ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_INTERFACE_CONFIG_FIELD"
    ADD CONSTRAINT "SYS_C0023652" CHECK ("NAME" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_INTERFACE_CONFIG_FIELD"
    ADD CONSTRAINT "SYS_C0023653" CHECK ("IS_REQUIRED" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_INTERFACE_CONFIG_FIELD"
    ADD CONSTRAINT "SYS_C0023654" CHECK ("DATA_TYPE" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_INTERFACE_CONFIG
-- ----------------------------
-- DROP TABLE "BLADE_INTERFACE_CONFIG";
CREATE TABLE "BLADE_INTERFACE_CONFIG"
(
    "ID"           NUMBER(20)     NOT NULL,
    "STATUS"       NUMBER(4) DEFAULT 1,
    "IS_DELETED"   NUMBER(20),
    "CREATE_USER"  NUMBER(20),
    "CREATE_DEPT"  NUMBER(20),
    "CREATE_TIME"  DATE,
    "UPDATE_USER"  NUMBER(20),
    "UPDATE_TIME"  DATE,
    "URL"          NVARCHAR2(255),
    "URL_NAME"     NVARCHAR2(64)  NOT NULL,
    "URL_TYPE"     NUMBER(11)     NOT NULL,
    "OWNING_CHART" NVARCHAR2(255) NOT NULL
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."STATUS" IS '业务状态 1启用 0 停用';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."IS_DELETED" IS '删除标记：0-未删除，1-已删除';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."CREATE_DEPT" IS '创建部门';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."UPDATE_USER" IS '更新人';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."UPDATE_TIME" IS '更新时间';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."URL" IS '接口url';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."URL_NAME" IS '接口中文名';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."URL_TYPE" IS '接口类型 0 - POST； 1 - PUT； 2 - GET';
COMMENT
    ON COLUMN "BLADE_INTERFACE_CONFIG"."OWNING_CHART" IS '1图表类型 bar-柱状 line-折线图 pie-饼图 GanttChart 甘特图 table-表格';
COMMENT
    ON TABLE "BLADE_INTERFACE_CONFIG" IS '接口配置表';


-- ----------------------------
-- Primary Key structure for table BLADE_INTERFACE_CONFIG
-- ----------------------------
ALTER TABLE "BLADE_INTERFACE_CONFIG"
    ADD CONSTRAINT "1655780216PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_INTERFACE_CONFIG
-- ----------------------------
ALTER TABLE "BLADE_INTERFACE_CONFIG"
    ADD CONSTRAINT "SYS_C0023645" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_INTERFACE_CONFIG"
    ADD CONSTRAINT "SYS_C0023646" CHECK ("URL_NAME" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_INTERFACE_CONFIG"
    ADD CONSTRAINT "SYS_C0023647" CHECK ("URL_TYPE" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_INTERFACE_CONFIG"
    ADD CONSTRAINT "SYS_C0023648" CHECK ("OWNING_CHART" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_VISUAL
-- ----------------------------
-- DROP TABLE "BLADE_VISUAL";
CREATE TABLE "BLADE_VISUAL"
(
    "ID"             NUMBER(20) NOT NULL,
    "TITLE"          NVARCHAR2(255),
    "BACKGROUND_URL" NCLOB,
    "CATEGORY"       NUMBER(11),
    "PASSWORD"       NVARCHAR2(255),
    "CREATE_USER"    NUMBER(20),
    "CREATE_DEPT"    NUMBER(20),
    "CREATE_TIME"    DATE,
    "UPDATE_USER"    NUMBER(20),
    "UPDATE_TIME"    DATE,
    "STATUS"         NUMBER(11) NOT NULL,
    "IS_DELETED"     NUMBER(11),
    "GROUP_NAME"     NVARCHAR2(255),
    "GROUP_INDEX"    NUMBER(11),
    "SLIDING_SECOND" NUMBER(11)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_VISUAL"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_VISUAL"."TITLE" IS '大屏标题';
COMMENT
    ON COLUMN "BLADE_VISUAL"."BACKGROUND_URL" IS '大屏背景';
COMMENT
    ON COLUMN "BLADE_VISUAL"."CATEGORY" IS '大屏类型';
COMMENT
    ON COLUMN "BLADE_VISUAL"."PASSWORD" IS '发布密码';
COMMENT
    ON COLUMN "BLADE_VISUAL"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_VISUAL"."CREATE_DEPT" IS '创建部门';
COMMENT
    ON COLUMN "BLADE_VISUAL"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_VISUAL"."UPDATE_USER" IS '修改人';
COMMENT
    ON COLUMN "BLADE_VISUAL"."UPDATE_TIME" IS '修改时间';
COMMENT
    ON COLUMN "BLADE_VISUAL"."STATUS" IS '状态';
COMMENT
    ON COLUMN "BLADE_VISUAL"."GROUP_NAME" IS '大屏分组名称';
COMMENT
    ON COLUMN "BLADE_VISUAL"."GROUP_INDEX" IS '大屏分组顺序';
COMMENT
    ON COLUMN "BLADE_VISUAL"."SLIDING_SECOND" IS '大屏轮播间隔';
COMMENT
    ON TABLE "BLADE_VISUAL" IS '可视化表';



-- ----------------------------
-- Primary Key structure for table BLADE_VISUAL
-- ----------------------------
ALTER TABLE "BLADE_VISUAL"
    ADD CONSTRAINT "1655780297PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_VISUAL
-- ----------------------------
ALTER TABLE "BLADE_VISUAL"
    ADD CONSTRAINT "SYS_C0023762" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;
ALTER TABLE "BLADE_VISUAL"
    ADD CONSTRAINT "SYS_C0023763" CHECK ("STATUS" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;


-- ----------------------------
-- Table structure for BLADE_PARAM
-- ----------------------------
-- DROP TABLE "BLADE_PARAM";
CREATE TABLE "BLADE_PARAM"
(
    "ID"          NUMBER(20) NOT NULL,
    "PARAM_NAME"  NVARCHAR2(255),
    "PARAM_KEY"   NVARCHAR2(255),
    "PARAM_VALUE" NVARCHAR2(255),
    "REMARK"      NVARCHAR2(500),
    "CREATE_USER" NUMBER(20),
    "CREATE_DEPT" NUMBER(20),
    "CREATE_TIME" DATE,
    "UPDATE_USER" NUMBER(20),
    "UPDATE_TIME" DATE,
    "STATUS"      NUMBER(11),
    "IS_DELETED"  NUMBER(11)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_PARAM"."ID" IS '主键';
COMMENT
    ON COLUMN "BLADE_PARAM"."PARAM_NAME" IS '参数名';
COMMENT
    ON COLUMN "BLADE_PARAM"."PARAM_KEY" IS '参数键';
COMMENT
    ON COLUMN "BLADE_PARAM"."PARAM_VALUE" IS '参数值';
COMMENT
    ON COLUMN "BLADE_PARAM"."REMARK" IS '备注';
COMMENT
    ON COLUMN "BLADE_PARAM"."CREATE_USER" IS '创建人';
COMMENT
    ON COLUMN "BLADE_PARAM"."CREATE_DEPT" IS '创建部门';
COMMENT
    ON COLUMN "BLADE_PARAM"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "BLADE_PARAM"."UPDATE_USER" IS '修改人';
COMMENT
    ON COLUMN "BLADE_PARAM"."UPDATE_TIME" IS '修改时间';
COMMENT
    ON COLUMN "BLADE_PARAM"."STATUS" IS '状态';
COMMENT
    ON TABLE "BLADE_PARAM" IS '参数表';

-- ----------------------------
-- Primary Key structure for table BLADE_PARAM
-- ----------------------------
ALTER TABLE "BLADE_PARAM"
    ADD CONSTRAINT "1655780247PrimaryId" PRIMARY KEY ("ID");

-- ----------------------------
-- Checks structure for table BLADE_PARAM
-- ----------------------------
ALTER TABLE "BLADE_PARAM"
    ADD CONSTRAINT "SYS_C0023703" CHECK ("ID" IS NOT NULL) NOT DEFERRABLE INITIALLY IMMEDIATE NORELY VALIDATE;

CREATE TABLE "BLADE_APPLICATION"
(
    "ID"             NUMBER(20)     NOT NULL,
    "NAME"           NVARCHAR2(255) NOT NULL,
    "CODE"           NVARCHAR2(255)  DEFAULT NULL,
    "LOGO"           NVARCHAR2(255)  DEFAULT NULL,
    "BACKGROUND_URL" NVARCHAR2(1000) DEFAULT NULL,
    "DOMAIN_URL"     NVARCHAR2(255)  DEFAULT NULL,
    "IS_DEFAULT"     NUMBER(4)       DEFAULT NULL,
    "IS_SHOW"        NUMBER(4)      DEFAULT '2',
    "SORT"           NUMBER(11)      DEFAULT NULL,
    "REMARK"         NVARCHAR2(255)  DEFAULT NULL,
    "IS_DELETED"     NUMBER(11)      DEFAULT NULL
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "BLADE_APPLICATION"."NAME" IS '应用名称';
COMMENT
    ON COLUMN "BLADE_APPLICATION"."CODE" IS '应用标识';
COMMENT
    ON COLUMN "BLADE_APPLICATION"."LOGO" IS '应用Logo';
COMMENT
    ON COLUMN "BLADE_APPLICATION"."BACKGROUND_URL" IS '应用系统背景';
COMMENT
    ON COLUMN "BLADE_APPLICATION"."DOMAIN_URL" IS '访问域名或地址';
COMMENT
    ON COLUMN "BLADE_APPLICATION"."IS_DEFAULT" IS '是否默认应用';
COMMENT
    ON COLUMN "BLADE_APPLICATION"."SORT" IS '排序';
COMMENT
    ON COLUMN "BLADE_APPLICATION"."REMARK" IS '备注';
COMMENT
    ON COLUMN "BLADE_APPLICATION"."IS_SHOW" IS '是否显示 1显示 2关闭';

-- ----------------------------
-- Primary Key structure for table BLADE_APPLICATION
-- ----------------------------
ALTER TABLE "BLADE_APPLICATION"
    ADD CONSTRAINT "SYS_C0031748" PRIMARY KEY ("ID");

-- ----------------------------
-- Records of BLADE_APPLICATION
-- ----------------------------
INSERT INTO "BLADE_APPLICATION"
VALUES (1001, 'CPS', 'CPS', '', '', '', 1, 1, 2, '离散线', 0);
INSERT INTO "BLADE_APPLICATION"
VALUES (1002, '大屏', 'VISION', '', '', '', 1, 2, 2, '可视化大屏', 0);
INSERT INTO "BLADE_APPLICATION"
VALUES (1003, 'HMI', 'HMI', '', '', '', 1, 2, 3, 'HMI', 0);

-- ----------------------------
-- Records of BLADE_CLIENT
-- ----------------------------
INSERT INTO "BLADE_CLIENT"
VALUES ('1123598811738675201', 'sword', 'sword_secret', NULL, 'all',
        'refresh_token,password,authorization_code,captcha,social', 'http://localhost:8888', NULL, '3600', '604800',
        NULL, NULL, '1123598815738675201', '1123598813738675201',
        TO_DATE('2019-03-24 10:40:55', 'SYYYY-MM-DD HH24:MI:SS'), '1123598815738675201',
        TO_DATE('2019-03-24 10:40:59', 'SYYYY-MM-DD HH24:MI:SS'), '1', '0');
INSERT INTO "BLADE_CLIENT"
VALUES ('1123598811738675202', 'saber', 'saber_secret', NULL, 'all',
        'refresh_token,password,authorization_code,captcha,social', 'http://localhost:8080', NULL, '3600', '604800',
        NULL, NULL, '1123598815738675201', '1123598813738675201',
        TO_DATE('2019-03-24 10:42:29', 'SYYYY-MM-DD HH24:MI:SS'), '1123598815738675201',
        TO_DATE('2019-03-24 10:42:32', 'SYYYY-MM-DD HH24:MI:SS'), '1', '0');
INSERT INTO "BLADE_CLIENT"
VALUES ('1123598811738675203', 'h5', 'h5_secret', NULL, 'all',
        'refresh_token,password,authorization_code,captcha,social', 'http://localhost:8080', NULL, '604800', '604800',
        NULL, NULL, '1123598815738675201', '1123598813738675201',
        TO_DATE('2019-03-24 10:42:29', 'SYYYY-MM-DD HH24:MI:SS'), '1123598815738675201',
        TO_DATE('2019-03-24 10:42:32', 'SYYYY-MM-DD HH24:MI:SS'), '1', '0');

CREATE TABLE "JIMU_DICT"
(
    "ID"          NVARCHAR2(32) NOT NULL,
    "DICT_NAME"   NVARCHAR2(100),
    "DICT_CODE"   NVARCHAR2(100),
    "DESCRIPTION" NVARCHAR2(255),
    "DEL_FLAG"    NUMBER(11),
    "CREATE_BY"   NVARCHAR2(32),
    "CREATE_TIME" DATE,
    "UPDATE_BY"   NVARCHAR2(32),
    "UPDATE_TIME" DATE,
    "TYPE"        NUMBER(11) DEFAULT 0
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_DICT"."DICT_NAME" IS '字典名称';
COMMENT
    ON COLUMN "JIMU_DICT"."DICT_CODE" IS '字典编码';
COMMENT
    ON COLUMN "JIMU_DICT"."DESCRIPTION" IS '描述';
COMMENT
    ON COLUMN "JIMU_DICT"."DEL_FLAG" IS '删除状态';
COMMENT
    ON COLUMN "JIMU_DICT"."CREATE_BY" IS '创建人';
COMMENT
    ON COLUMN "JIMU_DICT"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "JIMU_DICT"."UPDATE_BY" IS '更新人';
COMMENT
    ON COLUMN "JIMU_DICT"."UPDATE_TIME" IS '更新时间';
COMMENT
    ON COLUMN "JIMU_DICT"."TYPE" IS '字典类型0为string,1为number';

-- ----------------------------
-- Table structure for JIMU_DICT_ITEM
-- ----------------------------
-- DROP TABLE "JIMU_DICT_ITEM";
CREATE TABLE "JIMU_DICT_ITEM"
(
    "ID"          NVARCHAR2(32) NOT NULL,
    "DICT_ID"     NVARCHAR2(32),
    "ITEM_TEXT"   NVARCHAR2(100),
    "ITEM_VALUE"  NVARCHAR2(100),
    "DESCRIPTION" NVARCHAR2(255),
    "SORT_ORDER"  NUMBER(11),
    "STATUS"      NUMBER(11),
    "CREATE_BY"   NVARCHAR2(32),
    "CREATE_TIME" DATE,
    "UPDATE_BY"   NVARCHAR2(32),
    "UPDATE_TIME" DATE
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_DICT_ITEM"."DICT_ID" IS '字典id';
COMMENT
    ON COLUMN "JIMU_DICT_ITEM"."ITEM_TEXT" IS '字典项文本';
COMMENT
    ON COLUMN "JIMU_DICT_ITEM"."ITEM_VALUE" IS '字典项值';
COMMENT
    ON COLUMN "JIMU_DICT_ITEM"."DESCRIPTION" IS '描述';
COMMENT
    ON COLUMN "JIMU_DICT_ITEM"."SORT_ORDER" IS '排序';
COMMENT
    ON COLUMN "JIMU_DICT_ITEM"."STATUS" IS '状态（1启用 0不启用）';

-- ----------------------------
-- Table structure for JIMU_REPORT
-- ----------------------------
-- DROP TABLE "JIMU_REPORT";
CREATE TABLE "JIMU_REPORT"
(
    "ID"          NVARCHAR2(32) NOT NULL,
    "CODE"        NVARCHAR2(50),
    "NAME"        NVARCHAR2(50),
    "NOTE"        NVARCHAR2(255),
    "STATUS"      NVARCHAR2(10),
    "TYPE"        NVARCHAR2(10),
    "JSON_STR"    NCLOB,
    "API_URL"     NVARCHAR2(255),
    "THUMB"       NCLOB,
    "CREATE_BY"   NVARCHAR2(50),
    "CREATE_TIME" DATE,
    "UPDATE_BY"   NVARCHAR2(50),
    "UPDATE_TIME" DATE,
    "DEL_FLAG"    NUMBER(4),
    "API_METHOD"  NVARCHAR2(255),
    "API_CODE"    NVARCHAR2(255),
    "TEMPLATE"    NUMBER(4),
    "VIEW_COUNT"  NUMBER(20) DEFAULT 0,
    "CSS_STR"     NCLOB,
    "JS_STR"      NCLOB
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_REPORT"."ID" IS '主键';
COMMENT
    ON COLUMN "JIMU_REPORT"."CODE" IS '编码';
COMMENT
    ON COLUMN "JIMU_REPORT"."NAME" IS '名称';
COMMENT
    ON COLUMN "JIMU_REPORT"."NOTE" IS '说明';
COMMENT
    ON COLUMN "JIMU_REPORT"."STATUS" IS '状态';
COMMENT
    ON COLUMN "JIMU_REPORT"."TYPE" IS '类型';
COMMENT
    ON COLUMN "JIMU_REPORT"."JSON_STR" IS 'json字符串';
COMMENT
    ON COLUMN "JIMU_REPORT"."API_URL" IS '请求地址';
COMMENT
    ON COLUMN "JIMU_REPORT"."THUMB" IS '缩略图';
COMMENT
    ON COLUMN "JIMU_REPORT"."CREATE_BY" IS '创建人';
COMMENT
    ON COLUMN "JIMU_REPORT"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "JIMU_REPORT"."UPDATE_BY" IS '修改人';
COMMENT
    ON COLUMN "JIMU_REPORT"."UPDATE_TIME" IS '修改时间';
COMMENT
    ON COLUMN "JIMU_REPORT"."DEL_FLAG" IS '删除标识0-正常,1-已删除';
COMMENT
    ON COLUMN "JIMU_REPORT"."API_METHOD" IS '请求方法0-get,1-post';
COMMENT
    ON COLUMN "JIMU_REPORT"."API_CODE" IS '请求编码';
COMMENT
    ON COLUMN "JIMU_REPORT"."TEMPLATE" IS '是否是模板 0-是,1-不是';
COMMENT
    ON COLUMN "JIMU_REPORT"."VIEW_COUNT" IS '浏览次数';
COMMENT
    ON COLUMN "JIMU_REPORT"."CSS_STR" IS 'css增强';
COMMENT
    ON COLUMN "JIMU_REPORT"."JS_STR" IS 'js增强';
COMMENT
    ON TABLE "JIMU_REPORT" IS '在线excel设计器';

-- ----------------------------
-- Table structure for JIMU_REPORT_DATA_SOURCE
-- ----------------------------
-- DROP TABLE "JIMU_REPORT_DATA_SOURCE";
CREATE TABLE "JIMU_REPORT_DATA_SOURCE"
(
    "ID"            NVARCHAR2(36) NOT NULL,
    "NAME"          NVARCHAR2(100),
    "REPORT_ID"     NVARCHAR2(100),
    "CODE"          NVARCHAR2(100),
    "REMARK"        NVARCHAR2(200),
    "DB_TYPE"       NVARCHAR2(10),
    "DB_DRIVER"     NVARCHAR2(100),
    "DB_URL"        NVARCHAR2(500),
    "DB_USERNAME"   NVARCHAR2(100),
    "DB_PASSWORD"   NVARCHAR2(100),
    "CREATE_BY"     NVARCHAR2(50),
    "CREATE_TIME"   DATE,
    "UPDATE_BY"     NVARCHAR2(50),
    "UPDATE_TIME"   DATE,
    "CONNECT_TIMES" NUMBER(11) DEFAULT 0
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."NAME" IS '数据源名称';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."REPORT_ID" IS '报表_id';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."CODE" IS '编码';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."REMARK" IS '备注';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."DB_TYPE" IS '数据库类型';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."DB_DRIVER" IS '驱动类';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."DB_URL" IS '数据源地址';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."DB_USERNAME" IS '用户名';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."DB_PASSWORD" IS '密码';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."CREATE_BY" IS '创建人';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."CREATE_TIME" IS '创建日期';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."UPDATE_BY" IS '更新人';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."UPDATE_TIME" IS '更新日期';
COMMENT
    ON COLUMN "JIMU_REPORT_DATA_SOURCE"."CONNECT_TIMES" IS '连接失败次数';
-- ----------------------------
-- Table structure for JIMU_REPORT_DB
-- ----------------------------
-- DROP TABLE "JIMU_REPORT_DB";
CREATE TABLE "JIMU_REPORT_DB"
(
    "ID"               NVARCHAR2(36) NOT NULL,
    "JIMU_REPORT_ID"   NVARCHAR2(32),
    "CREATE_BY"        NVARCHAR2(50),
    "UPDATE_BY"        NVARCHAR2(50),
    "CREATE_TIME"      DATE,
    "UPDATE_TIME"      DATE,
    "DB_CODE"          NVARCHAR2(32),
    "DB_CH_NAME"       NVARCHAR2(50),
    "DB_TYPE"          NVARCHAR2(32),
    "DB_TABLE_NAME"    NVARCHAR2(32),
    "DB_DYN_SQL"       NCLOB,
    "DB_KEY"           NVARCHAR2(32),
    "TB_DB_KEY"        NVARCHAR2(32),
    "TB_DB_TABLE_NAME" NVARCHAR2(32),
    "JAVA_TYPE"        NVARCHAR2(32),
    "JAVA_VALUE"       NVARCHAR2(255),
    "API_URL"          NVARCHAR2(255),
    "API_METHOD"       NVARCHAR2(255),
    "IS_LIST"          NVARCHAR2(10) DEFAULT 0,
    "IS_PAGE"          NVARCHAR2(10),
    "DB_SOURCE"        NVARCHAR2(255),
    "DB_SOURCE_TYPE"   NVARCHAR2(50),
    "JSON_DATA"        NCLOB,
    "API_CONVERT"      NVARCHAR2(255)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."ID" IS 'id';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."JIMU_REPORT_ID" IS '主键字段';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."CREATE_BY" IS '创建人登录名称';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."UPDATE_BY" IS '更新人登录名称';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."CREATE_TIME" IS '创建日期';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."UPDATE_TIME" IS '更新日期';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."DB_CODE" IS '数据集编码';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."DB_CH_NAME" IS '数据集名字';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."DB_TYPE" IS '数据源类型';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."DB_TABLE_NAME" IS '数据库表名';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."DB_DYN_SQL" IS '动态查询SQL';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."DB_KEY" IS '数据源KEY';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."TB_DB_KEY" IS '填报数据源';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."TB_DB_TABLE_NAME" IS '填报数据表';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."JAVA_TYPE" IS 'java类数据集  类型（spring:springkey,class:java类名）';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."JAVA_VALUE" IS 'java类数据源  数值（bean key/java类名）';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."API_URL" IS '请求地址';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."API_METHOD" IS '请求方法0-get,1-post';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."IS_LIST" IS '是否是列表0否1是 默认0';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."IS_PAGE" IS '是否作为分页,0:不分页，1:分页';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."DB_SOURCE" IS '数据源';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."DB_SOURCE_TYPE" IS '数据库类型 MYSQL ORACLE SQLSERVER';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."JSON_DATA" IS 'json数据，直接解析json内容';
COMMENT
    ON COLUMN "JIMU_REPORT_DB"."API_CONVERT" IS 'api转换器';

-- ----------------------------
-- Table structure for JIMU_REPORT_DB_FIELD
-- ----------------------------
-- DROP TABLE "JIMU_REPORT_DB_FIELD";
CREATE TABLE "JIMU_REPORT_DB_FIELD"
(
    "ID"                NVARCHAR2(36) NOT NULL,
    "CREATE_BY"         NVARCHAR2(50),
    "CREATE_TIME"       DATE,
    "UPDATE_BY"         NVARCHAR2(50),
    "UPDATE_TIME"       DATE,
    "JIMU_REPORT_DB_ID" NVARCHAR2(32),
    "FIELD_NAME"        NVARCHAR2(80),
    "FIELD_TEXT"        NVARCHAR2(50),
    "WIDGET_TYPE"       NVARCHAR2(50),
    "WIDGET_WIDTH"      NUMBER(11),
    "ORDER_NUM"         NUMBER(11),
    "SEARCH_FLAG"       NUMBER(11) DEFAULT 0,
    "SEARCH_MODE"       NUMBER(11),
    "DICT_CODE"         NVARCHAR2(255),
    "SEARCH_VALUE"      NVARCHAR2(100),
    "SEARCH_FORMAT"     NVARCHAR2(50),
    "EXT_JSON"          NCLOB
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."ID" IS 'id';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."CREATE_BY" IS '创建人登录名称';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."CREATE_TIME" IS '创建日期';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."UPDATE_BY" IS '更新人登录名称';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."UPDATE_TIME" IS '更新日期';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."JIMU_REPORT_DB_ID" IS '数据源ID';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."FIELD_NAME" IS '字段名';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."FIELD_TEXT" IS '字段文本';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."WIDGET_TYPE" IS '控件类型';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."WIDGET_WIDTH" IS '控件宽度';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."ORDER_NUM" IS '排序';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."SEARCH_FLAG" IS '查询标识0否1是 默认0';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."SEARCH_MODE" IS '查询模式1简单2范围';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."DICT_CODE" IS '字典编码支持从表中取数据';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."SEARCH_VALUE" IS '查询默认值';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."SEARCH_FORMAT" IS '查询时间格式化表达式';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_FIELD"."EXT_JSON" IS '参数配置';

-- ----------------------------
-- Table structure for JIMU_REPORT_DB_PARAM
-- ----------------------------
-- DROP TABLE "JIMU_REPORT_DB_PARAM";
CREATE TABLE "JIMU_REPORT_DB_PARAM"
(
    "ID"                  NVARCHAR2(36) NOT NULL,
    "JIMU_REPORT_HEAD_ID" NVARCHAR2(36) NOT NULL,
    "PARAM_NAME"          NVARCHAR2(32) NOT NULL,
    "PARAM_TXT"           NVARCHAR2(32),
    "PARAM_VALUE"         NVARCHAR2(1000),
    "ORDER_NUM"           NUMBER(11),
    "CREATE_BY"           NVARCHAR2(50),
    "CREATE_TIME"         DATE,
    "UPDATE_BY"           NVARCHAR2(50),
    "UPDATE_TIME"         DATE,
    "SEARCH_FLAG"         NUMBER(11),
    "WIDGET_TYPE"         NVARCHAR2(50),
    "SEARCH_MODE"         NUMBER(11),
    "DICT_CODE"           NVARCHAR2(255),
    "SEARCH_FORMAT"       NVARCHAR2(50),
    "EXT_JSON"            NCLOB
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."JIMU_REPORT_HEAD_ID" IS '动态报表ID';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."PARAM_NAME" IS '参数字段';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."PARAM_TXT" IS '参数文本';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."PARAM_VALUE" IS '参数默认值';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."ORDER_NUM" IS '排序';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."CREATE_BY" IS '创建人登录名称';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."CREATE_TIME" IS '创建日期';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."UPDATE_BY" IS '更新人登录名称';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."UPDATE_TIME" IS '更新日期';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."SEARCH_FLAG" IS '查询标识0否1是 默认0';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."WIDGET_TYPE" IS '查询控件类型';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."SEARCH_MODE" IS '查询模式1简单2范围';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."DICT_CODE" IS '字典';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."SEARCH_FORMAT" IS '查询时间格式化表达式';
COMMENT
    ON COLUMN "JIMU_REPORT_DB_PARAM"."EXT_JSON" IS '参数配置';

-- ----------------------------
-- Table structure for JIMU_REPORT_LINK
-- ----------------------------
-- DROP TABLE "JIMU_REPORT_LINK";
CREATE TABLE "JIMU_REPORT_LINK"
(
    "ID"            NVARCHAR2(32) NOT NULL,
    "REPORT_ID"     NVARCHAR2(32),
    "PARAMETER"     NCLOB,
    "EJECT_TYPE"    NVARCHAR2(1),
    "LINK_NAME"     NVARCHAR2(255),
    "API_METHOD"    NVARCHAR2(1),
    "LINK_TYPE"     NVARCHAR2(1),
    "API_URL"       NVARCHAR2(1000),
    "LINK_CHART_ID" NVARCHAR2(50),
    "EXPRESSION"    NVARCHAR2(255),
    "REQUIREMENT"   NVARCHAR2(255)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."ID" IS '主键id';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."REPORT_ID" IS '积木设计器id';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."PARAMETER" IS '参数';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."EJECT_TYPE" IS '弹出方式（0 当前页面 1 新窗口）';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."LINK_NAME" IS '链接名称';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."API_METHOD" IS '请求方法0-get,1-post';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."LINK_TYPE" IS '链接方式(0 网络报表 1 网络连接 2 图表联动)';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."API_URL" IS '外网api';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."LINK_CHART_ID" IS '联动图表的ID';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."EXPRESSION" IS '表达式';
COMMENT
    ON COLUMN "JIMU_REPORT_LINK"."REQUIREMENT" IS '条件';
COMMENT
    ON TABLE "JIMU_REPORT_LINK" IS '超链接配置表';

-- ----------------------------
-- Table structure for JIMU_REPORT_MAP
-- ----------------------------
-- DROP TABLE "JIMU_REPORT_MAP";
CREATE TABLE "JIMU_REPORT_MAP"
(
    "ID"           NVARCHAR2(64) NOT NULL,
    "LABEL"        NVARCHAR2(125),
    "NAME"         NVARCHAR2(125),
    "DATA"         NCLOB,
    "CREATE_BY"    NVARCHAR2(32),
    "CREATE_TIME"  DATE,
    "UPDATE_BY"    NVARCHAR2(32),
    "UPDATE_TIME"  DATE,
    "DEL_FLAG"     NVARCHAR2(1),
    "SYS_ORG_CODE" NVARCHAR2(64)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."ID" IS '主键';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."LABEL" IS '地图名称';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."NAME" IS '地图编码';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."DATA" IS '地图数据';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."CREATE_BY" IS '创建人';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."CREATE_TIME" IS '创建时间';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."UPDATE_BY" IS '修改人';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."UPDATE_TIME" IS '修改时间';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."DEL_FLAG" IS '0表示未删除,1表示删除';
COMMENT
    ON COLUMN "JIMU_REPORT_MAP"."SYS_ORG_CODE" IS '所属部门';
COMMENT
    ON TABLE "JIMU_REPORT_MAP" IS '地图配置表';

-- ----------------------------
-- Table structure for JIMU_REPORT_SHARE
-- ----------------------------
-- DROP TABLE "JIMU_REPORT_SHARE";
CREATE TABLE "JIMU_REPORT_SHARE"
(
    "ID"               NVARCHAR2(32) NOT NULL,
    "REPORT_ID"        NVARCHAR2(32),
    "PREVIEW_URL"      NVARCHAR2(1000),
    "PREVIEW_LOCK"     NVARCHAR2(4),
    "LAST_UPDATE_TIME" DATE,
    "TERM_OF_VALIDITY" NVARCHAR2(1),
    "STATUS"           NVARCHAR2(1)
) TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT
    ON COLUMN "JIMU_REPORT_SHARE"."ID" IS '主键';
COMMENT
    ON COLUMN "JIMU_REPORT_SHARE"."REPORT_ID" IS '在线excel设计器id';
COMMENT
    ON COLUMN "JIMU_REPORT_SHARE"."PREVIEW_URL" IS '预览地址';
COMMENT
    ON COLUMN "JIMU_REPORT_SHARE"."PREVIEW_LOCK" IS '密码锁';
COMMENT
    ON COLUMN "JIMU_REPORT_SHARE"."LAST_UPDATE_TIME" IS '最后更新时间';
COMMENT
    ON COLUMN "JIMU_REPORT_SHARE"."TERM_OF_VALIDITY" IS '有效期(0:永久有效，1:1天，2:7天)';
COMMENT
    ON COLUMN "JIMU_REPORT_SHARE"."STATUS" IS '是否过期(0未过期，1已过期)';
COMMENT
    ON TABLE "JIMU_REPORT_SHARE" IS '积木报表预览权限表';

-- 第三方应用配置
-- ----------------------------
-- Table structure for BLADE_OUTER_APP_CONFIG
-- ----------------------------
-- DROP TABLE "BLADE_OUTER_APP_CONFIG";
CREATE TABLE "BLADE_OUTER_APP_CONFIG"
(
    "ID"                  NUMBER(20) NOT NULL,
    "WX_CORP_ID"          NVARCHAR2(255),
    "WX_APP_SECRET"       NVARCHAR2(255),
    "WX_BOOK_SECRET"      NVARCHAR2(255),
    "WX_CALLBACK_TOKEN"   NVARCHAR2(255),
    "WX_AGENT_ID"         NVARCHAR2(255),
    "WX_AES_KEY"          NVARCHAR2(255),
    "DING_APP_KEY"        NVARCHAR2(255),
    "DING_APP_SECRET"     NVARCHAR2(255),
    "DING_AES_KEY"        NVARCHAR2(255),
    "DING_CALLBACK_TOKEN" NVARCHAR2(255),
    "DING_CORP_ID"        NVARCHAR2(255),
    "APP_TYPE"            NUMBER(11),
    "LAST_SYNC_TIME"      DATE,
    "DOMAIN_URL"          NVARCHAR2(255),
    "STATUS"              NUMBER(11) NOT NULL,
    "CREATE_USER"         NUMBER(20),
    "CREATE_DEPT"         NUMBER(20),
    "CREATE_TIME"         DATE,
    "UPDATE_USER"         NUMBER(20),
    "UPDATE_TIME"         DATE,
    "REMARK"              NVARCHAR2(255),
    "IS_DELETED"          NUMBER(11),
    "DING_AGENT_ID"       NVARCHAR2(255)
)
    TABLESPACE "USERS"
    LOGGING
    NOCOMPRESS
    PCTFREE 10
    INITRANS 1
    STORAGE
(
    BUFFER_POOL DEFAULT
)
    PARALLEL 1
    NOCACHE
    DISABLE ROW MOVEMENT
;
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."WX_CORP_ID" IS '企业微信企业corpId';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."WX_APP_SECRET" IS '企业微信应用secret';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."WX_BOOK_SECRET" IS '企业微信通讯录secret';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."WX_CALLBACK_TOKEN" IS '企业微信回调配置token';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."WX_AGENT_ID" IS '企业微信应用的AgentId';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."WX_AES_KEY" IS '企业微信回调配置加解密aes_key';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."DING_APP_KEY" IS '钉钉应用key';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."DING_APP_SECRET" IS '钉钉应用secret';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."DING_AES_KEY" IS '钉钉加解密aes_key';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."DING_CALLBACK_TOKEN" IS '钉钉回调token';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."DING_CORP_ID" IS '钉钉企业corpId';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."APP_TYPE" IS '应用类型 1企业微信 2钉钉';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."LAST_SYNC_TIME" IS '上次同步时间';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."DOMAIN_URL" IS '第三方回调域名';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."STATUS" IS '状态';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."CREATE_USER" IS '创建人';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."CREATE_DEPT" IS '创建部门';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."CREATE_TIME" IS '创建时间';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."UPDATE_USER" IS '更新人';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."UPDATE_TIME" IS '更新时间';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."REMARK" IS '备注/说明';
COMMENT ON COLUMN "BLADE_OUTER_APP_CONFIG"."DING_AGENT_ID" IS '钉钉应用AgentId';

-- ----------------------------
-- Primary Key structure for table JIMU_DICT
-- ----------------------------
ALTER TABLE "JIMU_DICT"
    ADD CONSTRAINT "SYS_C0031977" PRIMARY KEY ("ID");

-- ----------------------------
-- Indexes structure for table JIMU_DICT
-- ----------------------------
CREATE UNIQUE INDEX "UK_SD_DICT_CODE"
    ON "JIMU_DICT" ("DICT_CODE" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );

-- ----------------------------
-- Primary Key structure for table JIMU_DICT_ITEM
-- ----------------------------
ALTER TABLE "JIMU_DICT_ITEM"
    ADD CONSTRAINT "SYS_C0031978" PRIMARY KEY ("ID");


-- ----------------------------
-- Indexes structure for table JIMU_DICT_ITEM
-- ----------------------------
CREATE INDEX "IDX_SDI_DICT_VAL"
    ON "JIMU_DICT_ITEM" ("ITEM_VALUE" ASC, "DICT_ID" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "IDX_SDI_ROLE_DICT_ID"
    ON "JIMU_DICT_ITEM" ("DICT_ID" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "IDX_SDI_ROLE_SORT_ORDER"
    ON "JIMU_DICT_ITEM" ("SORT_ORDER" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "IDX_SDI_STATUS"
    ON "JIMU_DICT_ITEM" ("STATUS" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );

-- ----------------------------
-- Primary Key structure for table JIMU_REPORT
-- ----------------------------
ALTER TABLE "JIMU_REPORT"
    ADD CONSTRAINT "SYS_C0031979" PRIMARY KEY ("ID");

-- ----------------------------
-- Indexes structure for table JIMU_REPORT
-- ----------------------------
CREATE UNIQUE INDEX "UNIQ_JMREPORT_CODE"
    ON "JIMU_REPORT" ("CODE" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "UNIQ_JMREPORT_CREATEBY"
    ON "JIMU_REPORT" ("CREATE_BY" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "UNIQ_JMREPORT_DELFLAG"
    ON "JIMU_REPORT" ("DEL_FLAG" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );

-- ----------------------------
-- Primary Key structure for table JIMU_REPORT_DATA_SOURCE
-- ----------------------------
ALTER TABLE "JIMU_REPORT_DATA_SOURCE"
    ADD CONSTRAINT "SYS_C0031980" PRIMARY KEY ("ID");

-- ----------------------------
-- Indexes structure for table JIMU_REPORT_DATA_SOURCE
-- ----------------------------
CREATE INDEX "IDX_JMDATASOURCE_CODE"
    ON "JIMU_REPORT_DATA_SOURCE" ("CODE" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "IDX_JMDATASOURCE_REPORT_ID"
    ON "JIMU_REPORT_DATA_SOURCE" ("REPORT_ID" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    INITIAL 65536
    NEXT 1048576
    MINEXTENTS 1
    MAXEXTENTS 2147483645
    BUFFER_POOL DEFAULT
    );

-- ----------------------------
-- Primary Key structure for table JIMU_REPORT_DB
-- ----------------------------
ALTER TABLE "JIMU_REPORT_DB"
    ADD CONSTRAINT "SYS_C0031981" PRIMARY KEY ("ID");

-- ----------------------------
-- Indexes structure for table JIMU_REPORT_DB
-- ----------------------------
CREATE INDEX "IDX_DB_SOURCE_ID"
    ON "JIMU_REPORT_DB" ("DB_SOURCE" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "IDX_JIMU_REPORT_ID"
    ON "JIMU_REPORT_DB" ("JIMU_REPORT_ID" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "IDX_JMREPORTDB_DB_KEY"
    ON "JIMU_REPORT_DB" ("DB_KEY" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );

-- ----------------------------
-- Primary Key structure for table JIMU_REPORT_DB_FIELD
-- ----------------------------
ALTER TABLE "JIMU_REPORT_DB_FIELD"
    ADD CONSTRAINT "SYS_C0031982" PRIMARY KEY ("ID");

-- ----------------------------
-- Indexes structure for table JIMU_REPORT_DB_FIELD
-- ----------------------------
CREATE INDEX "IDX_DBFIELD_ORDER_NUM"
    ON "JIMU_REPORT_DB_FIELD" ("ORDER_NUM" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
CREATE INDEX "IDX_JRDF_JIMU_REPORT_DB_ID"
    ON "JIMU_REPORT_DB_FIELD" ("JIMU_REPORT_DB_ID" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );


-- ----------------------------
-- Primary Key structure for table JIMU_REPORT_DB_PARAM
-- ----------------------------
ALTER TABLE "JIMU_REPORT_DB_PARAM"
    ADD CONSTRAINT "SYS_C0031983" PRIMARY KEY ("ID");

-- ----------------------------
-- Indexes structure for table JIMU_REPORT_DB_PARAM
-- ----------------------------
CREATE INDEX "IDX_JMRHEADID"
    ON "JIMU_REPORT_DB_PARAM" ("JIMU_REPORT_HEAD_ID" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );

-- ----------------------------
-- Primary Key structure for table JIMU_REPORT_LINK
-- ----------------------------
ALTER TABLE "JIMU_REPORT_LINK"
    ADD CONSTRAINT "SYS_C0031991" PRIMARY KEY ("ID");

-- ----------------------------
-- Indexes structure for table JIMU_REPORT_LINK
-- ----------------------------
CREATE INDEX "UNIQ_LINK_REPORTID"
    ON "JIMU_REPORT_LINK" ("REPORT_ID" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );

-- ----------------------------
-- Primary Key structure for table JIMU_REPORT_MAP
-- ----------------------------
ALTER TABLE "JIMU_REPORT_MAP"
    ADD CONSTRAINT "SYS_C0031992" PRIMARY KEY ("ID");


-- ----------------------------
-- Indexes structure for table JIMU_REPORT_MAP
-- ----------------------------
CREATE UNIQUE INDEX "UNIQ_JMREPORT_MAP_NAME"
    ON "JIMU_REPORT_MAP" ("NAME" ASC) LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );

-- ----------------------------
-- Primary Key structure for table JIMU_REPORT_SHARE
-- ----------------------------
ALTER TABLE "JIMU_REPORT_SHARE"
    ADD CONSTRAINT "SYS_C0031990" PRIMARY KEY ("ID");

-- ----------------------------
-- Primary Key structure for table BLADE_OUTER_APP_CONFIG
-- ----------------------------
ALTER TABLE "BLADE_OUTER_APP_CONFIG"
    ADD CONSTRAINT "SYS_C0040016" PRIMARY KEY ("ID");

-- ----------------------------
-- Indexes structure for table BLADE_OUTER_APP_CONFIG
-- ----------------------------
CREATE UNIQUE INDEX "APPTYPEUNIQUE"
    ON "BLADE_OUTER_APP_CONFIG" ("APP_TYPE" ASC)
    LOGGING
    TABLESPACE "USERS"
    VISIBLE
    PCTFREE 10
    INITRANS 2
    STORAGE (
    BUFFER_POOL DEFAULT
    );
