Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
ioc_sixiang_license
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zengtianlai3
ioc_sixiang_license
Commits
609280a3
Commit
609280a3
authored
Jan 31, 2023
by
AfirSraftGarrier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更新文档
parent
fae7b1f2
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
88 additions
and
91 deletions
+88
-91
update.2023.1.sql
license/doc/update.2023.1.sql
+87
-0
update.sql
license/doc/update.sql
+1
-91
No files found.
license/doc/update.2023.1.sql
0 → 100644
View file @
609280a3
ALTER
TABLE
`user`
ADD
COLUMN
`notify`
varchar
(
50
)
NULL
DEFAULT
NULL
COMMENT
'报警的邮箱,注册的时候用户名是邮箱则这里自动填那个邮箱,可以修改'
AFTER
`company`
,
ADD
COLUMN
`parent`
int
(
11
)
NULL
COMMENT
'父账号标识,空则表示超管,一级'
AFTER
`notify`
,
ADD
COLUMN
`level`
int
(
1
)
NULL
COMMENT
'账号等级(共有三级),空则表示二级'
AFTER
`parent`
;
CREATE
TABLE
`permission`
(
`id`
int
(
10
)
NOT
NULL
AUTO_INCREMENT
,
`desc`
varchar
(
50
)
DEFAULT
NULL
COMMENT
'权限说明'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
int
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除标识 1:删除,0:未删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
0
DEFAULT
CHARSET
=
utf8
COMMENT
=
'权限表'
;
CREATE
TABLE
`user_permission`
(
`id`
int
(
10
)
NOT
NULL
AUTO_INCREMENT
,
`permission`
int
(
10
)
NOT
NULL
COMMENT
'权限标识'
,
`user`
int
(
11
)
NOT
NULL
COMMENT
'用户标识'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
int
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除标识 1:删除,0:未删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
0
DEFAULT
CHARSET
=
utf8
COMMENT
=
'用户权限表'
;
--添加权限--
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
1
,
'邀请注册'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
2
,
'删除用户'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
3
,
'应用管理'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
4
,
'设备管理'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
5
,
'运维管理'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
6
,
'日志管理'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
7
,
'安全报警'
,
NULL
,
NULL
,
0
);
-- 报警类型表 --
DROP
TABLE
IF
EXISTS
`report_type`
;
CREATE
TABLE
`report_type`
(
`id`
int
(
10
)
NOT
NULL
AUTO_INCREMENT
,
`category`
int
(
1
)
DEFAULT
NULL
COMMENT
'报警大类 1:系统,0:设备'
,
`desc`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'说明'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
int
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除标识 1:删除,0:未删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
0
DEFAULT
CHARSET
=
utf8
COMMENT
=
'报警类型表'
;
-- 报警表 --
DROP
TABLE
IF
EXISTS
`report`
;
CREATE
TABLE
`report`
(
`id`
int
(
10
)
NOT
NULL
AUTO_INCREMENT
,
`category`
int
(
1
)
DEFAULT
NULL
COMMENT
'报警大类 1:系统,0:设备'
,
`type`
int
(
3
)
DEFAULT
NULL
COMMENT
'报警类型'
,
`sn`
varchar
(
50
)
DEFAULT
NULL
COMMENT
'设备编码(系统报警该值为空)'
,
`desc`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'报警说明'
,
`user_name`
varchar
(
50
)
DEFAULT
NULL
COMMENT
'报警账户'
,
`user_company`
varchar
(
50
)
DEFAULT
NULL
COMMENT
'报警公司'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
int
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除标识 1:删除,0:未删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
0
DEFAULT
CHARSET
=
utf8
COMMENT
=
'报警表'
;
-- 新增报警类型 --
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
1
,
1
,
'系统故障'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
2
,
1
,
'系统超负荷'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
3
,
1
,
'系统连接失败'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
4
,
0
,
'数据请求失败'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
5
,
0
,
'卡交互失败'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
6
,
0
,
'鉴权失败'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
7
,
0
,
'解码失败'
,
NULL
,
NULL
,
0
);
license/doc/update.sql
View file @
609280a3
...
@@ -22,93 +22,3 @@ ALTER TABLE `device`
...
@@ -22,93 +22,3 @@ ALTER TABLE `device`
ALTER
TABLE
`device`
ALTER
TABLE
`device`
ADD
COLUMN
`sn_bind`
varchar
(
30
)
NULL
DEFAULT
NULL
COMMENT
'绑定的SN'
AFTER
`status`
;
ADD
COLUMN
`sn_bind`
varchar
(
30
)
NULL
DEFAULT
NULL
COMMENT
'绑定的SN'
AFTER
`status`
;
-------------------- 2023年开始修改 --------------------
ALTER
TABLE
`user`
ADD
COLUMN
`notify`
varchar
(
50
)
NULL
DEFAULT
NULL
COMMENT
'报警的邮箱,注册的时候用户名是邮箱则这里自动填那个邮箱,可以修改'
AFTER
`company`
,
ADD
COLUMN
`parent`
int
(
11
)
NULL
COMMENT
'父账号标识,空则表示超管,一级'
AFTER
`notify`
,
ADD
COLUMN
`level`
int
(
1
)
NULL
COMMENT
'账号等级(共有三级),空则表示二级'
AFTER
`parent`
;
CREATE
TABLE
`permission`
(
`id`
int
(
10
)
NOT
NULL
AUTO_INCREMENT
,
`desc`
varchar
(
50
)
DEFAULT
NULL
COMMENT
'权限说明'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
int
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除标识 1:删除,0:未删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
0
DEFAULT
CHARSET
=
utf8
COMMENT
=
'权限表'
;
CREATE
TABLE
`user_permission`
(
`id`
int
(
10
)
NOT
NULL
AUTO_INCREMENT
,
`permission`
int
(
10
)
NOT
NULL
COMMENT
'权限标识'
,
`user`
int
(
11
)
NOT
NULL
COMMENT
'用户标识'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
int
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除标识 1:删除,0:未删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
0
DEFAULT
CHARSET
=
utf8
COMMENT
=
'用户权限表'
;
--添加权限--
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
1
,
'邀请注册'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
2
,
'删除用户'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
3
,
'应用管理'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
4
,
'设备管理'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
5
,
'运维管理'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
6
,
'日志管理'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`permission`
(
`id`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
7
,
'安全报警'
,
NULL
,
NULL
,
0
);
-- 报警类型表 --
DROP
TABLE
IF
EXISTS
`report_type`
;
CREATE
TABLE
`report_type`
(
`id`
int
(
10
)
NOT
NULL
AUTO_INCREMENT
,
`category`
int
(
1
)
DEFAULT
NULL
COMMENT
'报警大类 1:系统,0:设备'
,
`desc`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'说明'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
int
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除标识 1:删除,0:未删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
0
DEFAULT
CHARSET
=
utf8
COMMENT
=
'报警类型表'
;
-- 报警表 --
DROP
TABLE
IF
EXISTS
`report`
;
CREATE
TABLE
`report`
(
`id`
int
(
10
)
NOT
NULL
AUTO_INCREMENT
,
`category`
int
(
1
)
DEFAULT
NULL
COMMENT
'报警大类 1:系统,0:设备'
,
`type`
int
(
3
)
DEFAULT
NULL
COMMENT
'报警类型'
,
`sn`
varchar
(
50
)
DEFAULT
NULL
COMMENT
'设备编码(系统报警该值为空)'
,
`desc`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'报警说明'
,
`user_name`
varchar
(
50
)
DEFAULT
NULL
COMMENT
'报警账户'
,
`user_company`
varchar
(
50
)
DEFAULT
NULL
COMMENT
'报警公司'
,
`create_time`
datetime
DEFAULT
NULL
COMMENT
'创建时间'
,
`update_time`
datetime
DEFAULT
NULL
COMMENT
'更新时间'
,
`deleted`
int
(
1
)
DEFAULT
'0'
COMMENT
'逻辑删除标识 1:删除,0:未删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
0
DEFAULT
CHARSET
=
utf8
COMMENT
=
'报警表'
;
-- 新增报警类型 --
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
1
,
1
,
'系统故障'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
2
,
1
,
'系统超负荷'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
3
,
1
,
'系统连接失败'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
4
,
0
,
'数据请求失败'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
5
,
0
,
'卡交互失败'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
6
,
0
,
'鉴权失败'
,
NULL
,
NULL
,
0
);
INSERT
INTO
`report_type`
(
`id`
,
`category`
,
`desc`
,
`create_time`
,
`update_time`
,
`deleted`
)
VALUES
(
7
,
0
,
'解码失败'
,
NULL
,
NULL
,
0
);
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment