Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
MyEMS
MyEMS能源管理系统
提交
96f87643
M
MyEMS能源管理系统
项目概览
MyEMS
/
MyEMS能源管理系统
通知
46
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
M
MyEMS能源管理系统
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
96f87643
编写于
6月 01, 2023
作者:
nengyuangzhang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
added command relation tables with microgrids, spaces, stores, shopfloors and tenants
上级
2c596dee
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
126 addition
and
2 deletion
+126
-2
CHANGELOG.md
CHANGELOG.md
+5
-0
database/install/myems_system_db.sql
database/install/myems_system_db.sql
+60
-1
database/upgrade/upgrade3.4.0RC.sql
database/upgrade/upgrade3.4.0RC.sql
+61
-1
未找到文件。
CHANGELOG.md
浏览文件 @
96f87643
...
...
@@ -9,6 +9,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
-
added tbl_combianed_equipments_commands to myems_system_db database
-
added tbl_equipments_commands to myems_system_db database
-
added tbl_meters_commands to myems_system_db database
-
added tbl_microgrids_commands to myems_system_db database
-
added tbl_spaces_commands to myems_system_db database
-
added tbl_stores_commands to myems_system_db database
-
added tbl_shopfloors_commands to myems_system_db database
-
added tbl_tenants_commands to myems_system_db database
-
added command actions to myems-api
-
added command feature to myems-admin
-
added tbl_new_users to myems_user_db database
...
...
database/install/myems_system_db.sql
浏览文件 @
96f87643
...
...
@@ -605,7 +605,7 @@ CREATE TABLE IF NOT EXISTS `myems_system_db`.`tbl_meters_commands` (
`meter_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_meters_com
ands_index_1`
ON
`myems_system_db`
.
`tbl_meters_co
mands`
(
`meter_id`
);
CREATE
INDEX
`tbl_meters_com
mands_index_1`
ON
`myems_system_db`
.
`tbl_meters_com
mands`
(
`meter_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
...
...
@@ -631,6 +631,17 @@ CREATE TABLE IF NOT EXISTS `myems_system_db`.`tbl_microgrids` (
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_microgrids_index_1`
ON
`myems_system_db`
.
`tbl_microgrids`
(
`name`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_microgrids_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_microgrids_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_microgrids_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`microgrid_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_microgrids_commands_index_1`
ON
`myems_system_db`
.
`tbl_microgrids_commands`
(
`microgrid_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_microgrid_architecture_types`
...
...
@@ -815,6 +826,18 @@ CREATE TABLE IF NOT EXISTS `myems_system_db`.`tbl_shopfloors` (
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_shopfloors_index_1`
ON
`myems_system_db`
.
`tbl_shopfloors`
(
`name`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_shopfloors_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_shopfloors_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_shopfloors_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`shopfloor_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_shopfloors_commands_index_1`
ON
`myems_system_db`
.
`tbl_shopfloors_commands`
(
`shopfloor_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_shopfloors_equipments`
-- ---------------------------------------------------------------------------------------------------------------------
...
...
@@ -945,6 +968,18 @@ CREATE TABLE IF NOT EXISTS `myems_system_db`.`tbl_spaces_combined_equipments` (
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_spaces_combined_equipments_index_1`
ON
`myems_system_db`
.
`tbl_spaces_combined_equipments`
(
`space_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_spaces_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_spaces_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_spaces_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`space_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_spaces_commands_index_1`
ON
`myems_system_db`
.
`tbl_spaces_commands`
(
`space_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_spaces_equipments`
-- ---------------------------------------------------------------------------------------------------------------------
...
...
@@ -1133,6 +1168,18 @@ CREATE TABLE IF NOT EXISTS `myems_system_db`.`tbl_stores` (
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_stores_index_1`
ON
`myems_system_db`
.
`tbl_stores`
(
`name`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_stores_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_stores_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_stores_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`store_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_stores_commands_index_1`
ON
`myems_system_db`
.
`tbl_stores_commands`
(
`store_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_store_types`
-- ---------------------------------------------------------------------------------------------------------------------
...
...
@@ -1245,6 +1292,18 @@ CREATE TABLE IF NOT EXISTS `myems_system_db`.`tbl_tenants` (
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_tenants_index_1`
ON
`myems_system_db`
.
`tbl_tenants`
(
`name`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_tenants_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_tenants_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_tenants_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`tenant_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_tenants_commands_index_1`
ON
`myems_system_db`
.
`tbl_tenants_commands`
(
`tenant_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_tenant_types`
-- ---------------------------------------------------------------------------------------------------------------------
...
...
database/upgrade/upgrade3.4.0RC.sql
浏览文件 @
96f87643
...
...
@@ -56,7 +56,67 @@ CREATE TABLE IF NOT EXISTS `myems_system_db`.`tbl_meters_commands` (
`meter_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_meters_comands_index_1`
ON
`myems_system_db`
.
`tbl_meters_comands`
(
`meter_id`
);
CREATE
INDEX
`tbl_meters_commands_index_1`
ON
`myems_system_db`
.
`tbl_meters_commands`
(
`meter_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_microgrids_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_microgrids_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_microgrids_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`microgrid_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_microgrids_commands_index_1`
ON
`myems_system_db`
.
`tbl_microgrids_commands`
(
`microgrid_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_spaces_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_spaces_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_spaces_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`space_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_spaces_commands_index_1`
ON
`myems_system_db`
.
`tbl_spaces_commands`
(
`space_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_tenants_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_tenants_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_tenants_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`tenant_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_tenants_commands_index_1`
ON
`myems_system_db`
.
`tbl_tenants_commands`
(
`tenant_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_shopfloors_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_shopfloors_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_shopfloors_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`shopfloor_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_shopfloors_commands_index_1`
ON
`myems_system_db`
.
`tbl_shopfloors_commands`
(
`shopfloor_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_stores_commands`
-- ---------------------------------------------------------------------------------------------------------------------
DROP
TABLE
IF
EXISTS
`myems_system_db`
.
`tbl_stores_commands`
;
CREATE
TABLE
IF
NOT
EXISTS
`myems_system_db`
.
`tbl_stores_commands`
(
`id`
BIGINT
NOT
NULL
AUTO_INCREMENT
,
`store_id`
BIGINT
NOT
NULL
,
`command_id`
BIGINT
NOT
NULL
,
PRIMARY
KEY
(
`id`
));
CREATE
INDEX
`tbl_stores_commands_index_1`
ON
`myems_system_db`
.
`tbl_stores_commands`
(
`store_id`
);
-- ---------------------------------------------------------------------------------------------------------------------
-- Table `myems_system_db`.`tbl_microgrids`
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录