CREATE TABLE "public"."hs_config_table" (
  "id" uuid NOT NULL,
  "created_time" int8,
  "created_user" uuid,
  "tenant_id" uuid,
  "updated_time" int8,
  "updated_user" uuid,
  "key" varchar(255) COLLATE "pg_catalog"."default",
  "notes" varchar(255) COLLATE "pg_catalog"."default",
  "json_value" varchar COLLATE "pg_catalog"."default",
  CONSTRAINT "hs_config_table_pkey" PRIMARY KEY ("id")
)
;

ALTER TABLE "public"."hs_config_table" OWNER TO "postgres";

ALTER TABLE "public"."hs_device_switch" ADD COLUMN "on_line_time" int8;

COMMENT ON COLUMN "public"."hs_device_switch"."on_line_time" IS '在线时长';

ALTER TABLE "public"."hs_device_switch_hour" ADD COLUMN "on_line_time" int8;

COMMENT ON COLUMN "public"."hs_device_switch_hour"."on_line_time" IS '在线时长';

CREATE TABLE "public"."hs_level_role" (
  "role_id" uuid NOT NULL,
  "p_id" uuid NOT NULL,
  CONSTRAINT "hs_level_role_pkey" PRIMARY KEY ("role_id", "p_id")
)
;

ALTER TABLE "public"."hs_level_role" OWNER TO "postgres";

ALTER TABLE "public"."hs_role" ADD COLUMN "role_public" bool;

ALTER TABLE "public"."hs_role" DROP COLUMN "factory_id";

ALTER TABLE "public"."hs_role" DROP COLUMN "type";

ALTER TABLE "public"."hs_role" DROP COLUMN "user_level";

CREATE TABLE "public"."hs_role_menu_relation" (
  "id" uuid NOT NULL,
  "created_time" int8,
  "created_user" uuid,
  "tenant_id" uuid,
  "updated_time" int8,
  "updated_user" uuid,
  "menu_id" uuid,
  "notes" varchar(255) COLLATE "pg_catalog"."default",
  "role_id" uuid,
  "flg" varchar(255) COLLATE "pg_catalog"."default",
  CONSTRAINT "role_menu_relation_pkey" PRIMARY KEY ("id")
)
;

ALTER TABLE "public"."hs_role_menu_relation" OWNER TO "postgres";

CREATE TABLE "public"."hs_user_extension" (
  "id" uuid NOT NULL,
  "created_time" int8,
  "created_user" uuid,
  "tenant_id" uuid,
  "updated_time" int8,
  "updated_user" uuid,
  "address" varchar(255) COLLATE "pg_catalog"."default",
  "avatar" varchar(255) COLLATE "pg_catalog"."default",
  "bind_time" int8,
  "include_nick_name" varchar(255) COLLATE "pg_catalog"."default",
  "open_id" varchar(255) COLLATE "pg_catalog"."default",
  "phone_number" varchar(255) COLLATE "pg_catalog"."default",
  "registrate_applet" varchar(255) COLLATE "pg_catalog"."default",
  "user_code" varchar(255) COLLATE "pg_catalog"."default",
  "user_id" uuid,
  "user_name" varchar(255) COLLATE "pg_catalog"."default",
  "virtual_code" int4,
  "wechat_nick_name" varchar(255) COLLATE "pg_catalog"."default",
  "wechat_sign_status" varchar(255) COLLATE "pg_catalog"."default",
  CONSTRAINT "hs_user_extension_pkey" PRIMARY KEY ("id")
)
;

ALTER TABLE "public"."hs_user_extension" OWNER TO "postgres";

CREATE TABLE "public"."hs_user_role_relation" (
  "id" uuid NOT NULL,
  "created_time" int8,
  "created_user" uuid,
  "tenant_id" uuid,
  "updated_time" int8,
  "updated_user" uuid,
  "notes" varchar(255) COLLATE "pg_catalog"."default",
  "role_id" uuid,
  "user_id" uuid,
  CONSTRAINT "user_role_relation_pkey" PRIMARY KEY ("id")
)
;

ALTER TABLE "public"."hs_user_role_relation" OWNER TO "postgres";

CREATE TABLE "public"."hs_wechat_apply_history" (
  "id" uuid NOT NULL,
  "created_time" int8,
  "created_user" uuid,
  "tenant_id" uuid,
  "updated_time" int8,
  "updated_user" uuid,
  "apply_info" varchar(255) COLLATE "pg_catalog"."default",
  "avatar" varchar(255) COLLATE "pg_catalog"."default",
  "factory_id" uuid,
  "wechat_nick_name" varchar(255) COLLATE "pg_catalog"."default",
  "notes" varchar(255) COLLATE "pg_catalog"."default",
  "open_id" varchar(255) COLLATE "pg_catalog"."default",
  "review_status" varchar(255) COLLATE "pg_catalog"."default",
  "sex" varchar(255) COLLATE "pg_catalog"."default"
)
;

ALTER TABLE "public"."hs_wechat_apply_history" OWNER TO "postgres";

CREATE TABLE "public"."role_menu_relation" (
  "id" uuid NOT NULL,
  "created_time" int8,
  "created_user" uuid,
  "tenant_id" uuid,
  "updated_time" int8,
  "updated_user" uuid,
  "menu_id" uuid,
  "notes" varchar(255) COLLATE "pg_catalog"."default",
  "role_id" uuid,
  CONSTRAINT "role_menu_relation_pkey1" PRIMARY KEY ("id")
)
;

ALTER TABLE "public"."role_menu_relation" OWNER TO "postgres";


CREATE TABLE "public"."tcode_model" (
  "id" uuid NOT NULL,
  "gid" uuid,
  "code" varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
  "name" varchar(255) COLLATE "pg_catalog"."default",
  "created_user" uuid,
  "updated_user" uuid,
  "driver_version" varchar(255) COLLATE "pg_catalog"."default",
  "tenant_id" uuid,
  "updated_time" int8,
  "created_time" int8,
  CONSTRAINT "tcode_model_pkey" PRIMARY KEY ("id", "code")
)
;

ALTER TABLE "public"."tcode_model" OWNER TO "postgres";

CREATE TABLE "public"."tcode_model_detail" (
  "id" uuid NOT NULL,
  "gid" uuid,
  "code" varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
  "key" varchar(255) COLLATE "pg_catalog"."default" NOT NULL,
  "grpcode" varchar(255) COLLATE "pg_catalog"."default",
  "unit_id" uuid,
  "kup" varchar(255) COLLATE "pg_catalog"."default",
  "kdwn" varchar(255) COLLATE "pg_catalog"."default",
  "ksetup" varchar(255) COLLATE "pg_catalog"."default",
  "sort" varchar(255) COLLATE "pg_catalog"."default" DEFAULT '1000'::character varying,
  "halt" char(1) COLLATE "pg_catalog"."default" DEFAULT 'F'::bpchar,
  "ex_s1" varchar(255) COLLATE "pg_catalog"."default",
  "ex_s2" varchar(255) COLLATE "pg_catalog"."default",
  "ex_s3" varchar(255) COLLATE "pg_catalog"."default",
  "ex_s4" varchar(255) COLLATE "pg_catalog"."default",
  "ex_s5" varchar(255) COLLATE "pg_catalog"."default",
  "created_user" uuid,
  "updated_user" uuid,
  "standard" varchar(255) COLLATE "pg_catalog"."default",
  "hour" bool,
  "day" bool,
  "change" bool,
  "tenant_id" uuid,
  "val" varchar(255) COLLATE "pg_catalog"."default",
  "created_time" int8,
  "updated_time" int8,
  "kup_time" int8,
  "ksetup_time" int8,
  "kdwn_time" int8,
  CONSTRAINT "tcode_model_detail_pkey" PRIMARY KEY ("id", "code", "key")
)
;

ALTER TABLE "public"."tcode_model_detail" OWNER TO "postgres";

COMMENT ON COLUMN "public"."tcode_model_detail"."id" IS '属性ID';

COMMENT ON COLUMN "public"."tcode_model_detail"."gid" IS '网关ID';

COMMENT ON COLUMN "public"."tcode_model_detail"."code" IS '模型代码';

COMMENT ON COLUMN "public"."tcode_model_detail"."key" IS '属性key';

COMMENT ON COLUMN "public"."tcode_model_detail"."grpcode" IS '分组ID';

COMMENT ON COLUMN "public"."tcode_model_detail"."unit_id" IS '单位ID';

COMMENT ON COLUMN "public"."tcode_model_detail"."kup" IS '上限值';

COMMENT ON COLUMN "public"."tcode_model_detail"."kdwn" IS '下限值';

COMMENT ON COLUMN "public"."tcode_model_detail"."ksetup" IS '设定值';

COMMENT ON COLUMN "public"."tcode_model_detail"."sort" IS '排序';

COMMENT ON COLUMN "public"."tcode_model_detail"."halt" IS '是否停用';

COMMENT ON COLUMN "public"."tcode_model_detail"."ex_s1" IS '扩展字段1';

COMMENT ON COLUMN "public"."tcode_model_detail"."ex_s2" IS '扩展字段2';

COMMENT ON COLUMN "public"."tcode_model_detail"."ex_s3" IS '扩展字段3';

COMMENT ON COLUMN "public"."tcode_model_detail"."ex_s4" IS '扩展字段4';

COMMENT ON COLUMN "public"."tcode_model_detail"."ex_s5" IS '扩展字段5';

COMMENT ON COLUMN "public"."tcode_model_detail"."standard" IS '标准值';

COMMENT ON COLUMN "public"."tcode_model_detail"."hour" IS '每小时存储';

COMMENT ON COLUMN "public"."tcode_model_detail"."day" IS '每天存储';

COMMENT ON COLUMN "public"."tcode_model_detail"."change" IS '属性值变化存储';

COMMENT ON COLUMN "public"."tcode_model_detail"."val" IS '属性名';

COMMENT ON COLUMN "public"."tcode_model_detail"."kup_time" IS '上限值时间';

COMMENT ON COLUMN "public"."tcode_model_detail"."ksetup_time" IS '设定值更新时间';

COMMENT ON COLUMN "public"."tcode_model_detail"."kdwn_time" IS '下限值设定时间';

CREATE TABLE "public"."tcode_unit" (
  "id" uuid NOT NULL,
  "descript" varchar(255) COLLATE "pg_catalog"."default",
  "created_time" int8,
  "updated_time" int8,
  "created_user" uuid,
  "updated_user" uuid,
  "tenant_id" uuid,
  CONSTRAINT "tcode_unit_pkey" PRIMARY KEY ("id")
)
;

ALTER TABLE "public"."tcode_unit" OWNER TO "postgres";

CREATE TABLE "public"."tmsg" (
  "msg" varchar(255) COLLATE "pg_catalog"."default"
)
;

ALTER TABLE "public"."tmsg" OWNER TO "postgres";

CREATE TABLE "public"."user_role_relation" (
  "id" uuid NOT NULL,
  "created_time" int8,
  "created_user" uuid,
  "tenant_id" uuid,
  "updated_time" int8,
  "updated_user" uuid,
  "notes" varchar(255) COLLATE "pg_catalog"."default",
  "role_id" uuid,
  "user_id" uuid,
  CONSTRAINT "user_role_relation_pkey1" PRIMARY KEY ("id")
)
;

ALTER TABLE "public"."user_role_relation" OWNER TO "postgres";

ALTER TABLE "public"."hs_level_role" ADD CONSTRAINT "fkdksrna0gfh9ct8lth5gq8inyb" FOREIGN KEY ("role_id") REFERENCES "public"."hs_role" ("id") ON DELETE NO ACTION ON UPDATE NO ACTION;

ALTER TABLE "public"."hs_level_role" ADD CONSTRAINT "fkkn8ks2krh0ktkoxf0itq8yx9a" FOREIGN KEY ("p_id") REFERENCES "public"."hs_role" ("id") ON DELETE NO ACTION ON UPDATE NO ACTION;

SELECT setval('"public"."ts_kv_dictionary_key_id_seq"', 543, true);

CREATE VIEW "public"."vcode_key_detail" AS  SELECT hs.tenant_id AS tid,
    hs.factory_id AS fid,
    hs.factory_name AS fname,
    hs.workshop_id AS wid,
    hs.workshop_name AS wname,
    hs.group_id AS grpid,
    hs.group_name AS grpname,
    hs.gateway_id AS gid,
    hs.gateway_name AS gname,
    hs.key,
    hs.key_id,
    hs.entity_id AS did,
    hs.enable,
    hs.device_name AS dname,
    hs.device_type,
    hs.history_lower,
    hs.history_upper,
    hs.volume_on_day,
    concat(ts1.dbl_v, ts1.long_v, ts1.str_v) AS val,
    ts1.dbl_v,
    ts1.long_v,
    ts1.str_v,
    ts1.bool_v,
    ts1.json_v,
    ts1.ts,
    to_char(timezone('UTC-8'::text, to_timestamp((ts1.ts / 1000)::double precision)), 'yyyy-MM-dd HH24:MI:SS'::text) AS update_time
   FROM ts_kv_latest ts1,
    hs_last_expand_extension hs
  WHERE ts1.entity_id = hs.entity_id AND ts1.key = hs.key_id;

ALTER TABLE "public"."vcode_key_detail" OWNER TO "postgres";

CREATE UNIQUE INDEX "tcode_model_index" ON "public"."tcode_model" USING btree (
  "id" "pg_catalog"."uuid_ops" ASC NULLS LAST,
  "code" COLLATE "pg_catalog"."default" "pg_catalog"."text_ops" ASC NULLS LAST
);

CREATE UNIQUE INDEX "tcode_unit_index" ON "public"."tcode_unit" USING btree (
  "id" "pg_catalog"."uuid_ops" ASC NULLS LAST,
  "descript" COLLATE "pg_catalog"."default" "pg_catalog"."text_ops" ASC NULLS LAST
);


INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('ad4cd5a0-37dc-11ed-b2f0-013aa5277d02', 'XTCD1663565645807', '仪表看板', 0, 1, NULL, NULL, 'dashboard', NULL, 'Global', 1663565645833, '85088750-1ea1-11ed-a8be-71239561244e', '1663565645833', NULL, 'PC', NULL, 'f', 'dashboard.dashboard-view');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('cfb48340-37dc-11ed-b2f0-013aa5277d02', 'XTCD1663565703539', '大屏看板', 1, 2, NULL, 'ad4cd5a0-37dc-11ed-b2f0-013aa5277d02', 'mdi:large-screen-dashboard', NULL, 'Global', 1663569960126, '85088750-1ea1-11ed-a8be-71239561244e', '1663569960126', '85088750-1ea1-11ed-a8be-71239561244e', 'PC', '/largeScreenDashboard', 'f', 'dashboard.largescreen-dashboard');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('bdba8e90-37e2-11ed-b2f0-013aa5277d02', 'XTCD1663568250360', 'PC仪表看板', 1, 3, NULL, 'ad4cd5a0-37dc-11ed-b2f0-013aa5277d02', 'mdi:monitor-dashboard', NULL, 'Global', 1663569968676, '85088750-1ea1-11ed-a8be-71239561244e', '1663569968676', '85088750-1ea1-11ed-a8be-71239561244e', 'PC', '/dashboardView', 'f', 'dashboard.dashboard-view-pc');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('18036750-37e8-11ed-9cee-ab412dc6d429', 'XTCD1663570549299', '工厂管理', 1, 5, NULL, 'f6ad4630-37e6-11ed-9cee-ab412dc6d429', 'mdi:factory', NULL, 'Global', 1663570574334, '85088750-1ea1-11ed-a8be-71239561244e', '1663570574334', '85088750-1ea1-11ed-a8be-71239561244e', 'PC', '/factories', 'f', 'factory.factory-mng');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('4c5da7e0-37e8-11ed-9cee-ab412dc6d429', 'XTCD1663570637148', '设备列表', 1, 6, NULL, 'f6ad4630-37e6-11ed-9cee-ab412dc6d429', 'mdi:devices', NULL, 'Global', 1663570646671, '85088750-1ea1-11ed-a8be-71239561244e', '1663570646671', '85088750-1ea1-11ed-a8be-71239561244e', 'PC', '/deviceList', 'f', 'device.device-list');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('782a4590-37e8-11ed-aa50-33c3c4d399b5', 'XTCD1663570710633', '网关列表', 1, 7, NULL, 'f6ad4630-37e6-11ed-9cee-ab412dc6d429', 'router', NULL, 'Global', 1663570710695, '85088750-1ea1-11ed-a8be-71239561244e', '1663570710695', NULL, 'PC', '/gateway', 'f', 'gateway.gateway-devices');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('f6ad4630-37e6-11ed-9cee-ab412dc6d429', 'XTCD1663570063876', '设备管理', 0, 4, NULL, NULL, 'devices', NULL, 'Global', 1663570725071, '85088750-1ea1-11ed-a8be-71239561244e', '1663570725071', '85088750-1ea1-11ed-a8be-71239561244e', 'PC', NULL, 'f', 'device.management');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('b1a8e650-37e8-11ed-aa50-33c3c4d399b5', 'XTCD1663570807093', '权限管理', 0, 8, NULL, NULL, 'verified_user', NULL, 'Global', 1663570819083, '85088750-1ea1-11ed-a8be-71239561244e', '1663570819083', '85088750-1ea1-11ed-a8be-71239561244e', 'PC', NULL, 'f', 'auth-mng.auth-mng');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('13243100-37e9-11ed-aa50-33c3c4d399b5', 'XTCD1663570970640', '小程序申请', 1, 9, NULL, 'b1a8e650-37e8-11ed-aa50-33c3c4d399b5', 'mdi:applet', NULL, 'Global', 1663570970641, '85088750-1ea1-11ed-a8be-71239561244e', '1663570970641', NULL, 'PC', '/authManagement/appletManagement', 'f', 'auth-mng.applet-mng');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('296c1450-37e9-11ed-aa50-33c3c4d399b5', 'XTCD1663571008021', '用户管理', 1, 10, NULL, 'b1a8e650-37e8-11ed-aa50-33c3c4d399b5', 'people', NULL, 'Global', 1663571008022, '85088750-1ea1-11ed-a8be-71239561244e', '1663571008022', NULL, 'PC', '/authManagement/userManagement', 'f', 'auth-mng.user-mng');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('546905f0-37e9-11ed-aa50-33c3c4d399b5', 'XTCD1663571080143', '角色管理', 1, 11, NULL, 'b1a8e650-37e8-11ed-aa50-33c3c4d399b5', 'mdi:shield-account', NULL, 'Global', 1663571080144, '85088750-1ea1-11ed-a8be-71239561244e', '1663571080144', NULL, 'PC', '/authManagement/roleManagemnet', 'f', 'auth-mng.role-mng');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('8b394f90-37e9-11ed-aa50-33c3c4d399b5', 'XTCD1663571172105', '平台管理', 0, 12, NULL, NULL, 'mdi:platform-mng', NULL, 'Global', 1663571172106, '85088750-1ea1-11ed-a8be-71239561244e', '1663571172106', NULL, 'PC', NULL, 'f', 'platform.platform-mng');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('e5562890-37e9-11ed-aa50-33c3c4d399b5', 'XTCD1663571323289', '设备配置', 1, 13, NULL, '8b394f90-37e9-11ed-aa50-33c3c4d399b5', 'mdi:alpha-d-box', NULL, 'Global', 1663571323290, '85088750-1ea1-11ed-a8be-71239561244e', '1663571323290', NULL, 'PC', '/deviceProfiles', 'f', 'device-profile.device-profiles');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('01c89170-37ea-11ed-aa50-33c3c4d399b5', 'XTCD1663571371015', '规则链库', 1, 14, NULL, '8b394f90-37e9-11ed-aa50-33c3c4d399b5', 'settings_ethernet', NULL, 'Global', 1663571371016, '85088750-1ea1-11ed-a8be-71239561244e', '1663571371016', NULL, 'PC', '/ruleChains', 'f', 'rulechain.rulechains');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('ff09f130-37ea-11ed-aa50-33c3c4d399b5', 'XTCD1663571795907', '实体视图', 1, 15, NULL, '8b394f90-37e9-11ed-aa50-33c3c4d399b5', 'view_quilt', NULL, 'Global', 1663571795907, '85088750-1ea1-11ed-a8be-71239561244e', '1663571795907', NULL, 'PC', '/entityViews', 'f', 'entity-view.entity-views');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('12f8c950-37eb-11ed-aa50-33c3c4d399b5', 'XTCD1663571829349', '部件库', 1, 16, NULL, '8b394f90-37e9-11ed-aa50-33c3c4d399b5', 'now_widgets', NULL, 'Global', 1663571829350, '85088750-1ea1-11ed-a8be-71239561244e', '1663571829350', NULL, 'PC', '/widgets-bundles', 'f', 'widget.widget-library');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('bbab6e90-37eb-11ed-aa50-33c3c4d399b5', 'XTCD1663572112377', '仪表板库', 1, 17, NULL, '8b394f90-37e9-11ed-aa50-33c3c4d399b5', 'dashboards', NULL, 'Global', 1663572112378, '85088750-1ea1-11ed-a8be-71239561244e', '1663572112378', NULL, 'PC', '/dashboards', 'f', 'dashboard.dashboards');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('372e63b0-37ec-11ed-aa50-33c3c4d399b5', 'XTCD1663572319595', '日志', 1, 18, NULL, '8b394f90-37e9-11ed-aa50-33c3c4d399b5', 'track_changes', NULL, 'Global', 1663572319595, '85088750-1ea1-11ed-a8be-71239561244e', '1663572319595', NULL, 'PC', '/auditLogs', 'f', 'audit-log.audit-logs');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('842cc710-37ec-11ed-aa50-33c3c4d399b5', 'XTCD1663572448768', 'Api使用统计', 1, 19, NULL, '8b394f90-37e9-11ed-aa50-33c3c4d399b5', 'insert_chart', NULL, 'Global', 1663572460669, '85088750-1ea1-11ed-a8be-71239561244e', '1663572460669', '85088750-1ea1-11ed-a8be-71239561244e', 'PC', '/usage', 'f', 'api-usage.api-usage');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('ebe275d0-37ec-11ed-aa50-33c3c4d399b5', 'XTCD1663572622765', '系统设置', 0, 20, NULL, NULL, 'settings', NULL, 'Global', 1663572622766, '85088750-1ea1-11ed-a8be-71239561244e', '1663572622766', NULL, 'PC', NULL, 'f', 'admin.system-settings');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('66bafa20-37ed-11ed-aa50-33c3c4d399b5', 'XTCD1663572828866', '首页设置', 1, 21, NULL, 'ebe275d0-37ec-11ed-aa50-33c3c4d399b5', 'settings_applications', NULL, 'Global', 1663572828866, '85088750-1ea1-11ed-a8be-71239561244e', '1663572828866', NULL, 'PC', '/settings/home', 'f', 'admin.home-settings');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('1fd0dfc0-37ee-11ed-aa50-33c3c4d399b5', 'XTCD1663573139388', '资源库', 1, 22, NULL, 'ebe275d0-37ec-11ed-aa50-33c3c4d399b5', 'folder', NULL, 'Global', 1663573139389, '85088750-1ea1-11ed-a8be-71239561244e', '1663573139389', NULL, 'PC', '/settings/resources-library', 'f', 'resource.resources-library');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('918f86c0-37ee-11ed-aa50-33c3c4d399b5', 'XTCD1663573330220', '对外接口', 0, 23, NULL, NULL, 'mdi:open-api', NULL, 'Global', 1663573330221, '85088750-1ea1-11ed-a8be-71239561244e', '1663573330221', NULL, 'PC', NULL, 'f', 'open-api.open-api');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('fdabc3f0-37ee-11ed-aa50-33c3c4d399b5', 'XTCD1663573511599', '外部应用管理', 1, 24, NULL, '918f86c0-37ee-11ed-aa50-33c3c4d399b5', 'mdi:app-mng', NULL, 'Global', 1663573511600, '85088750-1ea1-11ed-a8be-71239561244e', '1663573511600', NULL, 'PC', '/openApi/externalApplicationManagement', 'f', 'open-api.external-apps-mng');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('1b13fe80-37ef-11ed-aa50-33c3c4d399b5', 'XTCD1663573560936', '推送配置', 1, 25, NULL, '918f86c0-37ee-11ed-aa50-33c3c4d399b5', 'mdi:push', NULL, 'Global', 1663573560937, '85088750-1ea1-11ed-a8be-71239561244e', '1663573560937', NULL, 'PC', '/openApi/pushProfile', 'f', 'open-api.push-profile');
INSERT INTO "public"."tb_menu" ("id", "code", "name", "level", "sort", "url", "parent_id", "menu_icon", "menu_images", "region", "created_time", "created_user", "updated_time", "updated_user", "menu_type", "path", "is_button", "lang_key") VALUES ('011ad000-3a81-11ed-ba84-5f6a89d54714', 'XTCD1663856126208', '设备', 1, 26, NULL, 'f6ad4630-37e6-11ed-9cee-ab412dc6d429', 'mdi:devices', NULL, 'Global', 1663856126232, '85088750-1ea1-11ed-a8be-71239561244e', '1663856126232', NULL, 'PC', '/devices', 'f', 'device.devices');
