1
0
mirror of https://github.com/FatttSnake/Pinnacle-OA.git synced 2026-04-04 22:41:24 +08:00

Added login, logout and getUserinfo (Include ui and server)

This commit is contained in:
2023-05-05 20:59:09 +08:00
parent a8dce8f8e0
commit 60b8460e03
32 changed files with 1022 additions and 151 deletions

60
sql/Insert.sql Normal file
View File

@@ -0,0 +1,60 @@
SET FOREIGN_KEY_CHECKS=0;
truncate t_menu;
truncate t_element;
truncate t_file;
truncate t_operation_log;
truncate t_operation;
truncate t_power;
truncate t_power_type;
insert into t_power_type (id, name)
values (1, 'operation'),
(2, 'menu'),
(3, 'element'),
(4, 'file');
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, power_id, parent_id)
values ('Select All Power Type', 'system:power_type:all', last_insert_id(), null);
commit;
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, power_id, parent_id)
values ('Select All Power', 'system:power:all', last_insert_id(), null);
commit;
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, power_id, parent_id)
values ('Select All User', 'system:operation:all', last_insert_id(), null);
commit;
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, power_id, parent_id)
values ('Select All User', 'system:menu:all', last_insert_id(), null);
commit;
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, power_id, parent_id)
values ('Select All User', 'system:element:all', last_insert_id(), null);
commit;
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, power_id, parent_id)
values ('Select All User', 'system:file:all', last_insert_id(), null);
commit;
SET FOREIGN_KEY_CHECKS=1;

View File

@@ -69,7 +69,6 @@ create table `t_operation`
`id` bigint not null primary key auto_increment,
`name` varchar(50) not null comment '功能名',
`code` varchar(50) null comment '功能编码',
`url_prefix` varchar(100) null comment 'URL 前缀',
`power_id` bigint not null comment '权限ID',
`parent_id` bigint null comment '父ID',
constraint t_operation_power_id_fk foreign key (power_id) references t_power (id)
@@ -298,32 +297,4 @@ create table `t_attendance`
`version` int not null default 0,
constraint t_attendance_user_id_fk foreign key (user_id) references t_user (id),
constraint t_attendance_modify_id_fk foreign key (modify_id) references t_user (id)
) comment '考勤';
insert into t_power_type (id, name)
values (1, 'operation'),
(2, 'menu'),
(3, 'element'),
(4, 'file');
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, url_prefix, power_id, parent_id)
values ('Select All Power Type', 'select_all_power_type', 'GET:/powerType', last_insert_id(), null);
commit;
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, url_prefix, power_id, parent_id)
values ('Select All Power Type', 'select_all_power_type', 'GET:/powerType', last_insert_id(), null);
commit;
begin;
insert into t_power (type_id)
values (1);
insert into t_operation (name, code, url_prefix, power_id, parent_id)
values ('Select All User', 'select_all_user', 'GET:/user', last_insert_id(), null);
commit;
) comment '考勤';