chore: 更新数据库结构及数据文件

This commit is contained in:
BenjaminNH 2025-07-21 11:20:11 +08:00
parent a94ab466d2
commit bbf03e2254
4 changed files with 626 additions and 8 deletions

6
db/data_role.sql Normal file
View File

@ -0,0 +1,6 @@
-- 初始角色数据
INSERT INTO roles (id, code, name)
VALUES (1, 'ADMIN', '系统管理员'),
(2, 'LEADER', '团队负责人'),
(3, 'DEVICE_ADMIN', '设备管理员'),
(4, 'USER', '用户');

9
db/data_teams.sql Normal file
View File

@ -0,0 +1,9 @@
INSERT INTO teams (id, name) VALUES (1, '绝缘(电缆)');
INSERT INTO teams (id, name) VALUES (2, '绝缘(电容器)');
INSERT INTO teams (id, name) VALUES (3, '磁性(超薄硅钢)');
INSERT INTO teams (id, name) VALUES (4, '磁性(高磁感硅钢)');
INSERT INTO teams (id, name) VALUES (5, '导体');
INSERT INTO teams (id, name) VALUES (6, '防护(降噪)');
INSERT INTO teams (id, name) VALUES (7, '防护(腐蚀)');
INSERT INTO teams (id, name) VALUES (8, '交叉(实验室)');
INSERT INTO teams (id, name) VALUES (9, '交叉(环氧)');

610
db/data_users.sql Normal file
View File

@ -0,0 +1,610 @@
START TRANSACTION;
-- 用户数据与角色关联
-- 管理员
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('admin', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '总管理员', '', 1);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 1);
-- 用户: 李文鹏
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liwenpeng', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '李文鹏', '15300341553', 1);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 史晓宁
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('shixiaoning', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '史晓宁', '18611951666', 1);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 赵维佳
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhaoweijia', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '赵维佳', '13693020532', 1);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 李石琨
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('lishikun', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '李石琨', '13020095677', 1);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 刘英健
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liuyingjian', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘英健', '18810085301', 1);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 周洋
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhouyang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '周洋', '15910777276', 1);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 毕舒馨
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('bishuxin', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '毕舒馨', '17888803487', 1);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 邢照亮
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('xingzhaoliang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '邢照亮', '15811444029', 2);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 郭少玮
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('guoshaowei', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '郭少玮', '18810702981', 2);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 苏尧天
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('suyaotian', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '苏尧天', '15369275910', 2);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 刘炬阳
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liujuyang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘炬阳', '17602637613', 2);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 王博
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('wangbo', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '王博', '13621001394', 2);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 杨博
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('yangbo', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '杨博', '15510260661', 2);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 张兆天
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhangzhaotian', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '张兆天', '19912458230', 2);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 刘天兴
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liutianxing', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘天兴', '13466589533', 2);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 杨富尧
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('yangfuyao', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '杨富尧', '18612978836', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 高洁
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('gaojie', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '高洁', '18500972707', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 刘洋
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liuyang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘洋', '18612694337', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 王聪
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('wangcong', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '王聪', '13264467237', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 孙浩
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('sunhao', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '孙浩', '15101136606', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 刘成宇
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liuchengyu', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘成宇', '13840525697', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 李伟
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liwei', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '李伟', '18660898500', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 尚以磊
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('shangyilei', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '尚以磊', '15998820462', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 时宇新
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('shiyuxin', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '时宇新', '15321306918', 3);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 马光
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('maguang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '马光', '13811679926', 4);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 何承绪
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('hechengxu', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '何承绪', '18813056867', 4);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 田丛宽
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('tiancongkuan', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '田丛宽', '18810561393', 4);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 邓凯伟
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('dengkaiwei', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '邓凯伟', '13613213772', 4);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 丁一
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('dingyi', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '丁一', '13693265696', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 陈保安
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('chenbaoan', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '陈保安', '15001236907', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 刘倓
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liutan', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘倓', '15201243807', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 庞震
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('pangzhen', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '庞震', '17810288985', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 高健峰
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('gaojianfeng', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '高健峰', '18801251185', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 赵兴雨
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhaoxingyu', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '赵兴雨', '18611572588', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 张丛睿
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhangcongrui', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '张丛睿', '18613838958', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 李梦琳
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('limenglin1', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '李梦琳', '18811505739', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 张捷欣
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhangjiexin', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '张捷欣', '15071109936', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 刘文杰
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liuwenjie', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘文杰', '18810393772', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 陈瑞
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('chenrui1', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '陈瑞', '18801183169', 5);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 聂京凯
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('niejingkai1', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '聂京凯', '13811205510', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 何强
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('heqiang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '何强', '15810868821', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 张一铭
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhangyiming', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '张一铭', '18519696605', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 田一
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('tianyi', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '田一', '18501949381', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 樊超
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('fanchao', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '樊超', '13681563658', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 刘晓圣
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liuxiaosheng', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘晓圣', '18811345505', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 侯东
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('houdong', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '侯东', '15101052027', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 姬军
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('jijun', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '姬军', '15201457665', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 刘浩
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('liuhao', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '刘浩', '17716537109', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 尹航
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('yinhang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '尹航', '18500738660', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 张世乘
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhangshicheng', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '张世乘', '13231339242', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 田辰
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('tianchen', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '田辰', '13844645059', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 张陈博凡
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhangchen', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '张陈博凡', '13284227163', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 何兴
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('hexing', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '何兴', '17717154888', 6);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 张强
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhangqiang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '张强', '13601210056', 7);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 王晓芳
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('wangxiaofang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '王晓芳', '13811432198', 7);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 陈云
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('chenyun', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '陈云', '13651214286', 7);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 杨丙坤
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('yangbingkun', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '杨丙坤', '15711469923', 7);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 卢壹梁
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('luyiliang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '卢壹梁', '15270852029', 7);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 赵广耀
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhaoguangyao', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '赵广耀', '15210674244', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 潘学东
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('panxuedong', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '潘学东', '13426432632', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 姚佳康
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('yaojiakang', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '姚佳康', '15226501286', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 郭玉龙
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('guoyulong', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '郭玉龙', '13146654667', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 赵蕊
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhaorui1', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '赵蕊', '13621012074', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 肖永明
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('xiaoyongming', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '肖永明', '15901504096', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 杨立新
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('yanglixin', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '杨立新', '13488882505', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 程娜
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('chengna', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '程娜', '15201461257', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 赵哲惠
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhaozhehui', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '赵哲惠', '18101123770', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 张思行
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhangsixing', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '张思行', '15521305044', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 李震
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('lzh', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '李震', '18612978848', 8);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 崔惠泽
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('cuihuize', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '崔惠泽', '13669234892', 9);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 2);
-- 用户: 陈铄
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('chenshuo', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '陈铄', '18222779112', 9);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 3);
-- 用户: 郭瑞鲁
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('guoruilu', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '郭瑞鲁', '18810663757', 9);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 罗楚濛
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('luochumeng', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '罗楚濛', '18810793857', 9);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 赵超锋
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('zhaochaofeng', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '赵超锋', '18810078180', 9);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
-- 用户: 顾雯雯
INSERT INTO users (username, password, name, phone, team_id)
VALUES ('guwenwen', '$2a$10$U64Wy8Yz4BlrtmrZG8xXSu9r/NUuoGv2ZVqu.A.gUqNolxZgDHGtq', '顾雯雯', '13141308181', 9);
INSERT INTO user_roles (user_id, role_id)
VALUES (LAST_INSERT_ID(), 4);
COMMIT;

View File

@ -81,11 +81,4 @@ CREATE TABLE approvals
approver_id BIGINT NOT NULL,
decision TINYINT NOT NULL,
timestamp DATETIME DEFAULT CURRENT_TIMESTAMP
);
-- 初始角色数据
INSERT INTO roles (code, name)
VALUES ('ADMIN', '系统管理员'),
('LEADER', '团队负责人'),
('DEVICE_ADMIN', '设备管理员'),
('USER', '普通用户');
);