数据结构
12114表总览
普通表
_cache
- 缓存表
CREATE TABLE `_cache` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`userId` varchar(255) NOT NULL COMMENT '用户Id',
`content` longtext COMMENT '缓存数据',
`recordStatus` varchar(255) DEFAULT 'active',
`operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '缓存表'
_constant
- 常量表; 软删除未启用;
CREATE TABLE `_constant` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`constantKey` varchar(255) DEFAULT NULL,
`constantType` varchar(255) DEFAULT NULL COMMENT '常量类型; object, array',
`desc` varchar(255) DEFAULT NULL COMMENT '描述',
`constantValue` text COMMENT '常量内容; object, array',
`operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 23 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '常量表; 软删除未启用;'
_page
- 页面表; 软删除未启用;
CREATE TABLE `_page` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`pageId` varchar(255) DEFAULT NULL COMMENT 'pageId',
`pageFile` varchar(255) DEFAULT NULL,
`pageName` varchar(255) DEFAULT NULL COMMENT 'page name',
`pageType` varchar(255) DEFAULT NULL COMMENT '页面类型; showInMenu, dynamicInMenu',
`sort` varchar(255) DEFAULT NULL,
`operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 18 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '页面表; 软删除未启用;'
_pull_down_list
CREATE TABLE `_pull_down_list` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`pullDownName` varchar(255) DEFAULT NULL,
`pullDownValue` longtext ,
`sort` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 8 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin
_record_history
CREATE TABLE `_record_history` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`table` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL COMMENT '表',
`recordId` int(11) DEFAULT NULL COMMENT '数据在table中的主键id; recordContent.id',
`recordContent` text CHARACTER SET utf8mb4 NOT NULL COMMENT '数据JSON',
`packageContent` text CHARACTER SET utf8mb4 NOT NULL COMMENT '当时请求的 package JSON',
`operation` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL COMMENT '操作; jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL COMMENT '操作者userId; recordContent.operationByUserId',
`operationByUser` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL COMMENT '操作者用户名; recordContent.operationByUser',
`operationAt` varchar(255) CHARACTER SET utf8mb4 DEFAULT NULL COMMENT '操作时间; recordContent.operationAt; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 79654 DEFAULT CHARSET = utf8mb4
_resource
- 请求资源表; 软删除未启用; resourceId=
${appId}.${pageId}.${actionId}
CREATE TABLE `_resource` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`accessControlTable` varchar(255) DEFAULT NULL COMMENT '数据规则控制表',
`resourceHook` text COMMENT '[ "before": {"service": "xx", "serviceFunction": "xxx"}, "after": [] }',
`pageId` varchar(255) DEFAULT NULL COMMENT 'page id; E.g: index',
`actionId` varchar(255) DEFAULT NULL COMMENT 'action id; E.g: selectXXXByXXX',
`desc` varchar(255) DEFAULT NULL COMMENT '描述',
`resourceType` varchar(255) DEFAULT NULL COMMENT 'resource 类型; E.g: auth service sql',
`appDataSchema` text COMMENT 'appData 参数校验',
`resourceData` text COMMENT 'resource 数据; { "service": "auth", "serviceFunction": "passwordLogin" } or { "table": "${tableName}", "action": "select", "whereCondition": ".where(function() {this.whereNot( { recordStatus: \\"active\\" })})" }',
`requestDemo` text COMMENT '请求Demo',
`responseDemo` text COMMENT '响应Demo',
`operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 416 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '请求资源表; 软删除未启用; resourceId=`${appId}.${pageId}.${actionId}`'
_resource_request_log
- 文件表; 软删除未启用;
CREATE TABLE `_resource_request_log` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`resourceId` varchar(255) DEFAULT NULL COMMENT 'resource id;',
`packageId` varchar(255) DEFAULT NULL COMMENT 'resource package id',
`userIp` varchar(255) DEFAULT NULL COMMENT '用户ip;',
`userAgent` varchar(255) DEFAULT NULL COMMENT '设备信息',
`userId` varchar(255) DEFAULT NULL COMMENT '用户ID',
`deviceId` varchar(255) DEFAULT NULL COMMENT '设备id',
`userIpRegion` varchar(255) DEFAULT NULL COMMENT '用户Ip区域',
`executeSql` varchar(255) DEFAULT NULL COMMENT '执行的sql',
`requestBody` mediumtext COMMENT '请求body',
`responseBody` mediumtext COMMENT '响应body',
`responseStatus` varchar(255) DEFAULT NULL COMMENT '执行的结果; success, fail',
`operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE,
KEY `resourceId_index` (`resourceId`) USING BTREE,
KEY `packageId_index` (`packageId`) USING BTREE
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '文件表; 软删除未启用;'
_test_case
- 测试用例表
CREATE TABLE `_test_case` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`pageId` varchar(255) DEFAULT NULL COMMENT '页面Id',
`testId` varchar(255) DEFAULT NULL COMMENT '测试用例Id; 10000 ++',
`testName` varchar(255) DEFAULT NULL COMMENT '测试用例名',
`uiActionIdList` varchar(255) DEFAULT NULL COMMENT 'uiAction列表; 一个测试用例对应多个uiActionId',
`testOpeartion` text COMMENT '测试用例步骤;',
`operation` varchar(255) DEFAULT NULL COMMENT '操作; jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId; recordContent.operationByUserId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名; recordContent.operationByUser',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; recordContent.operationAt; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '测试用例表'
_ui
- ui 施工方案
CREATE TABLE `_ui` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`pageId` varchar(255) DEFAULT NULL COMMENT 'page id; E.g: index',
`uiActionType` varchar(255) DEFAULT NULL COMMENT 'ui 动作类型,如:fetchData, postData, changeUi',
`uiActionId` varchar(255) DEFAULT NULL COMMENT 'action id; E.g: selectXXXByXXX',
`desc` varchar(255) DEFAULT NULL COMMENT '描述',
`uiActionConfig` text COMMENT 'ui 动作数据',
`appDataSchema` text COMMENT 'ui 校验数据',
`operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 107 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = 'ui 施工方案'
_user_session
- 用户session表; deviceId 维度;软删除未启用;
CREATE TABLE `_user_session` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`userId` varchar(255) DEFAULT NULL COMMENT '用户id',
`userIp` varchar(255) DEFAULT NULL COMMENT '用户ip',
`userIpRegion` varchar(255) DEFAULT NULL COMMENT '用户Ip区域',
`userAgent` text COMMENT '请求的 agent',
`deviceId` varchar(255) DEFAULT NULL COMMENT '设备id',
`deviceType` varchar(255) DEFAULT 'web' COMMENT '设备类型; flutter, web, bot_databot, bot_chatbot, bot_xiaochengxu',
`socketStatus` varchar(255) DEFAULT 'offline' COMMENT 'socket状态',
`authToken` varchar(255) DEFAULT NULL COMMENT 'auth token',
`operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE,
KEY `userId_index` (`userId`) USING BTREE,
KEY `userId_deviceId_index` (`userId`, `deviceId`) USING BTREE,
KEY `authToken_index` (`authToken`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 38 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '用户session表; deviceId 维度;软删除未启用;'
arrange_task
CREATE TABLE `arrange_task` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`year` varchar(255) NOT NULL COMMENT '年',
`semester` varchar(255) NOT NULL COMMENT '学期',
`name` varchar(255) NOT NULL COMMENT '配置name',
`segment` varchar(255) DEFAULT NULL COMMENT '学部',
`level` varchar(255) DEFAULT NULL COMMENT '年级',
`enableWeekDay` varchar(255) DEFAULT NULL COMMENT '上课时间',
`morningLessonCount` int(11) DEFAULT NULL COMMENT '早读数量',
`amLessonCount` int(11) DEFAULT NULL COMMENT '上午上课数量',
`pmLessonCount` int(11) DEFAULT NULL COMMENT '下午上课数量',
`eveningLessonCount` int(11) DEFAULT NULL COMMENT '晚上上课数量',
`normalOrDouble` varchar(255) DEFAULT NULL COMMENT '排课模式',
`disableSlots` text COMMENT '固定无课时间',
`fixedMorningSection` text COMMENT '早自习设定',
`fixedSection` text COMMENT '固定学科',
`teacherGroup` text COMMENT '教研组',
`sectionMap` varchar(255) DEFAULT NULL COMMENT '节次别名',
`arrangeReport` text COMMENT '排课报告',
`operation` varchar(255) DEFAULT NULL,
`operationByUserId` varchar(255) DEFAULT NULL,
`operationByUser` varchar(255) DEFAULT NULL,
`operationAt` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE,
KEY `year` (`year`) USING BTREE,
KEY `semester` (`semester`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 34 DEFAULT CHARSET = utf8
arrange_task_history
CREATE TABLE `arrange_task_history` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`year` varchar(255) NOT NULL COMMENT '年',
`semester` varchar(255) NOT NULL COMMENT '学期',
`name` varchar(255) NOT NULL COMMENT '配置name',
`level` varchar(255) NOT NULL COMMENT '年级',
`enableWeekDay` varchar(255) NOT NULL COMMENT '上课时间',
`morningLessonCount` int(11) NOT NULL COMMENT '早读数量',
`amLessonCount` int(11) NOT NULL COMMENT '上午上课数量',
`pmLessonCount` int(11) NOT NULL COMMENT '下午上课数量',
`eveningLessonCount` int(11) NOT NULL COMMENT '晚上上课数量',
`normalOrDouble` varchar(255) DEFAULT NULL COMMENT '排课模式',
`disableSlots` text COMMENT '固定无课时间',
`operation` varchar(255) DEFAULT NULL,
`operationByUserId` varchar(255) DEFAULT NULL,
`operationByUser` varchar(255) DEFAULT NULL,
`operationAt` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE,
KEY `year` (`year`) USING BTREE,
KEY `semester` (`semester`) USING BTREE
) ENGINE = InnoDB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin
exclusion_rule
CREATE TABLE `exclusion_rule` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`taskId` int(11) NOT NULL COMMENT '排课任务id',
`year` varchar(255) DEFAULT NULL COMMENT '年',
`semester` varchar(255) DEFAULT NULL COMMENT '学期',
`type` varchar(255) DEFAULT NULL COMMENT '规则类型',
`target` varchar(255) DEFAULT NULL COMMENT '对象',
`rule` text COMMENT '规则',
`remark` varchar(255) DEFAULT NULL COMMENT '描述',
`operation` varchar(255) DEFAULT NULL,
`operationByUserId` varchar(255) DEFAULT NULL,
`operationByUser` varchar(255) DEFAULT NULL,
`operationAt` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE,
KEY `taskId` (`taskId`) USING BTREE,
KEY `year` (`year`) USING BTREE,
KEY `semester` (`semester`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 1617 DEFAULT CHARSET = utf8
teaching_plan
CREATE TABLE `teaching_plan` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`taskId` int(11) NOT NULL COMMENT '排课任务id',
`year` varchar(255) DEFAULT NULL COMMENT '年',
`semester` varchar(255) DEFAULT NULL COMMENT '学期',
`daytimeLessonCount` int(11) NOT NULL DEFAULT '0' COMMENT '一周上几次',
`morningLessonCount` int(11) DEFAULT '0' COMMENT '早自习',
`eveningLessonCount` int(11) DEFAULT '0' COMMENT '晚自习',
`daytimeConsecutive` int(11) DEFAULT '0' COMMENT '白天连续',
`eveningConsecutive` int(11) DEFAULT '0' COMMENT '晚自习连课',
`classId` varchar(255) NOT NULL COMMENT '班级id',
`subject` varchar(255) NOT NULL COMMENT '科目',
`teacherId` varchar(255) DEFAULT NULL COMMENT '老师id',
`teacherName` varchar(255) DEFAULT NULL COMMENT '老师name',
`operation` varchar(255) DEFAULT NULL,
`operationByUserId` varchar(255) DEFAULT NULL,
`operationByUser` varchar(255) DEFAULT NULL,
`operationAt` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE,
KEY `taskId` (`taskId`) USING BTREE,
KEY `year` (`year`) USING BTREE,
KEY `semester` (`semester`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 2918 DEFAULT CHARSET = utf8
teaching_plan_history
CREATE TABLE `teaching_plan_history` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`taskId` int(11) NOT NULL COMMENT '排课任务id',
`year` varchar(255) DEFAULT NULL COMMENT '年',
`semester` varchar(255) DEFAULT NULL COMMENT '学期',
`daytimeLessonCount` int(11) NOT NULL COMMENT '一周上几次',
`morningLessonCount` int(11) DEFAULT NULL COMMENT '早自习',
`eveningLessonCount` int(11) DEFAULT NULL COMMENT '晚自习',
`daytimeConsecutive` int(11) DEFAULT NULL COMMENT '白天连续',
`eveningConsecutive` int(11) DEFAULT NULL COMMENT '晚自习连课',
`classId` varchar(255) NOT NULL COMMENT '班级id',
`subject` varchar(255) NOT NULL COMMENT '科目',
`teacherId` varchar(255) NOT NULL COMMENT '老师id',
`teacherName` varchar(255) DEFAULT NULL COMMENT '老师name',
`operation` varchar(255) DEFAULT NULL,
`operationByUserId` varchar(255) DEFAULT NULL,
`operationByUser` varchar(255) DEFAULT NULL,
`operationAt` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE,
KEY `taskId` (`taskId`) USING BTREE,
KEY `year` (`year`) USING BTREE,
KEY `semester` (`semester`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 206 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin
timetable
CREATE TABLE `timetable` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`taskId` int(11) NOT NULL COMMENT '排课任务id',
`year` varchar(255) CHARACTER SET utf8 DEFAULT NULL COMMENT '年',
`semester` varchar(255) CHARACTER SET utf8 DEFAULT NULL COMMENT '学期',
`weekday` varchar(255) CHARACTER SET utf8 NOT NULL COMMENT '星期几',
`section` varchar(255) CHARACTER SET utf8 NOT NULL COMMENT '节次排序',
`sectionName` varchar(255) CHARACTER SET utf8 NOT NULL COMMENT '节次名称',
`classId` varchar(255) CHARACTER SET utf8 NOT NULL COMMENT '班级id',
`subject` varchar(255) CHARACTER SET utf8 DEFAULT NULL COMMENT '单周科目',
`teacherId` varchar(255) CHARACTER SET utf8 DEFAULT NULL COMMENT '单周老师id',
`teacherName` varchar(255) CHARACTER SET utf8 DEFAULT NULL COMMENT '单周老师name',
`sectionType` varchar(255) CHARACTER SET utf8 DEFAULT 'auto' COMMENT '节次类型',
`mergeTimetableIds` text CHARACTER SET utf8 COMMENT '合班上课课表ids',
`operation` varchar(255) CHARACTER SET utf8 DEFAULT NULL,
`operationByUserId` varchar(255) CHARACTER SET utf8 DEFAULT NULL,
`operationByUser` varchar(255) CHARACTER SET utf8 DEFAULT NULL,
`operationAt` varchar(255) CHARACTER SET utf8 DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE,
UNIQUE KEY `uniq` (`taskId`, `weekday`, `sectionName`, `classId`) USING BTREE,
KEY `year` (`year`) USING BTREE,
KEY `task` (`taskId`) USING BTREE,
KEY `semester` (`semester`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 89115 DEFAULT CHARSET = utf8mb4
timetable_history
CREATE TABLE `timetable_history` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`taskId` int(11) NOT NULL COMMENT '排课任务id',
`year` varchar(255) DEFAULT NULL COMMENT '年',
`semester` varchar(255) DEFAULT NULL COMMENT '学期',
`weekday` varchar(255) NOT NULL COMMENT '星期几',
`section` varchar(255) NOT NULL COMMENT '节次排序',
`sectionName` varchar(255) NOT NULL COMMENT '节次名称',
`sectionType` varchar(255) NOT NULL DEFAULT 'auto' COMMENT '节次类型',
`classId` varchar(255) NOT NULL COMMENT '班级id',
`subject` varchar(255) DEFAULT NULL COMMENT '单周科目',
`teacherId` varchar(255) DEFAULT NULL COMMENT '单周老师id',
`teacherName` varchar(255) DEFAULT NULL COMMENT '单周老师name',
`mergeTimetableIds` text COMMENT '合班上课课表ids',
`operation` varchar(255) DEFAULT NULL,
`operationByUserId` varchar(255) DEFAULT NULL,
`operationByUser` varchar(255) DEFAULT NULL,
`operationAt` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`) USING BTREE,
KEY `year` (`year`) USING BTREE,
KEY `task` (`taskId`) USING BTREE,
KEY `semester` (`semester`) USING BTREE
) ENGINE = InnoDB DEFAULT CHARSET = utf8
视图
_directory_user_session
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `_directory_user_session` AS
select
`lms_data_repository`.`enterprise_directory_user_session`.`id` AS `id`,
`lms_data_repository`.`enterprise_directory_user_session`.`userId` AS `userId`,
`lms_data_repository`.`enterprise_directory_user_session`.`userIp` AS `userIp`,
`lms_data_repository`.`enterprise_directory_user_session`.`userIpRegion` AS `userIpRegion`,
`lms_data_repository`.`enterprise_directory_user_session`.`userAgent` AS `userAgent`,
`lms_data_repository`.`enterprise_directory_user_session`.`deviceId` AS `deviceId`,
`lms_data_repository`.`enterprise_directory_user_session`.`deviceType` AS `deviceType`,
`lms_data_repository`.`enterprise_directory_user_session`.`socketStatus` AS `socketStatus`,
`lms_data_repository`.`enterprise_directory_user_session`.`authToken` AS `authToken`,
`lms_data_repository`.`enterprise_directory_user_session`.`operation` AS `operation`,
`lms_data_repository`.`enterprise_directory_user_session`.`operationByUserId` AS `operationByUserId`,
`lms_data_repository`.`enterprise_directory_user_session`.`operationByUser` AS `operationByUser`,
`lms_data_repository`.`enterprise_directory_user_session`.`operationAt` AS `operationAt`
from
`lms_data_repository`.`enterprise_directory_user_session`
_group
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `_group` AS
select
`lms_data_repository`.`enterprise_group`.`id` AS `id`,
`lms_data_repository`.`enterprise_group`.`groupId` AS `groupId`,
`lms_data_repository`.`enterprise_group`.`groupLastId` AS `groupLastId`,
`lms_data_repository`.`enterprise_group`.`groupPath` AS `groupPath`,
`lms_data_repository`.`enterprise_group`.`groupName` AS `groupName`,
`lms_data_repository`.`enterprise_group`.`groupDeptName` AS `groupDeptName`,
`lms_data_repository`.`enterprise_group`.`groupAllName` AS `groupAllName`,
`lms_data_repository`.`enterprise_group`.`principalId` AS `principalId`,
`lms_data_repository`.`enterprise_group`.`headId` AS `headId`,
`lms_data_repository`.`enterprise_group`.`leadId` AS `leadId`,
`lms_data_repository`.`enterprise_group`.`groupDesc` AS `groupDesc`,
`lms_data_repository`.`enterprise_group`.`operation` AS `operation`,
`lms_data_repository`.`enterprise_group`.`operationByUserId` AS `operationByUserId`,
`lms_data_repository`.`enterprise_group`.`operationByUser` AS `operationByUser`,
`lms_data_repository`.`enterprise_group`.`operationAt` AS `operationAt`
from
`lms_data_repository`.`enterprise_group`
_role
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `_role` AS
select
`lms_data_repository`.`enterprise_role`.`id` AS `id`,
`lms_data_repository`.`enterprise_role`.`roleId` AS `roleId`,
`lms_data_repository`.`enterprise_role`.`roleName` AS `roleName`,
`lms_data_repository`.`enterprise_role`.`roleType` AS `roleType`,
`lms_data_repository`.`enterprise_role`.`roleDesc` AS `roleDesc`,
`lms_data_repository`.`enterprise_role`.`operation` AS `operation`,
`lms_data_repository`.`enterprise_role`.`operationByUserId` AS `operationByUserId`,
`lms_data_repository`.`enterprise_role`.`operationByUser` AS `operationByUser`,
`lms_data_repository`.`enterprise_role`.`operationAt` AS `operationAt`
from
`lms_data_repository`.`enterprise_role`
_user_group_role
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `_user_group_role` AS
select
`lms_data_repository`.`enterprise_user_group_role`.`id` AS `id`,
`lms_data_repository`.`enterprise_user_group_role`.`userId` AS `userId`,
`lms_data_repository`.`enterprise_user_group_role`.`groupId` AS `groupId`,
`lms_data_repository`.`enterprise_user_group_role`.`roleId` AS `roleId`,
`lms_data_repository`.`enterprise_user_group_role`.`roleDeadline` AS `roleDeadline`,
`lms_data_repository`.`enterprise_user_group_role`.`operation` AS `operation`,
`lms_data_repository`.`enterprise_user_group_role`.`operationByUserId` AS `operationByUserId`,
`lms_data_repository`.`enterprise_user_group_role`.`operationByUser` AS `operationByUser`,
`lms_data_repository`.`enterprise_user_group_role`.`operationAt` AS `operationAt`
from
`lms_data_repository`.`enterprise_user_group_role`
_user_group_role_page
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `_user_group_role_page` AS
select
`lms_data_repository`.`enterprise_user_group_role_page`.`id` AS `id`,
`lms_data_repository`.`enterprise_user_group_role_page`.`appId` AS `appId`,
`lms_data_repository`.`enterprise_user_group_role_page`.`user` AS `user`,
`lms_data_repository`.`enterprise_user_group_role_page`.`group` AS `group`,
`lms_data_repository`.`enterprise_user_group_role_page`.`role` AS `role`,
`lms_data_repository`.`enterprise_user_group_role_page`.`page` AS `page`,
`lms_data_repository`.`enterprise_user_group_role_page`.`allowOrDeny` AS `allowOrDeny`,
`lms_data_repository`.`enterprise_user_group_role_page`.`desc` AS `desc`,
`lms_data_repository`.`enterprise_user_group_role_page`.`source` AS `source`,
`lms_data_repository`.`enterprise_user_group_role_page`.`operation` AS `operation`,
`lms_data_repository`.`enterprise_user_group_role_page`.`operationByUserId` AS `operationByUserId`,
`lms_data_repository`.`enterprise_user_group_role_page`.`operationByUser` AS `operationByUser`,
`lms_data_repository`.`enterprise_user_group_role_page`.`operationAt` AS `operationAt`
from
`lms_data_repository`.`enterprise_user_group_role_page`
where
(
(
`lms_data_repository`.`enterprise_user_group_role_page`.`appId` = 'lms-teaching-plan'
)
or (
`lms_data_repository`.`enterprise_user_group_role_page`.`appId` = '*'
)
)
_user_group_role_resource
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `_user_group_role_resource` AS
select
`lms_data_repository`.`enterprise_user_group_role_resource`.`id` AS `id`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`appId` AS `appId`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`user` AS `user`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`group` AS `group`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`role` AS `role`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`resource` AS `resource`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`allowOrDeny` AS `allowOrDeny`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`desc` AS `desc`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`source` AS `source`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`operation` AS `operation`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`operationByUserId` AS `operationByUserId`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`operationByUser` AS `operationByUser`,
`lms_data_repository`.`enterprise_user_group_role_resource`.`operationAt` AS `operationAt`
from
`lms_data_repository`.`enterprise_user_group_role_resource`
where
(
(
`lms_data_repository`.`enterprise_user_group_role_resource`.`appId` = 'lms-teaching-plan'
)
or (
`lms_data_repository`.`enterprise_user_group_role_resource`.`appId` = '*'
)
)
_view01_user
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `_view01_user` AS
select
`lms_data_repository`.`enterprise_view01_user`.`id` AS `id`,
`lms_data_repository`.`enterprise_view01_user`.`idSequence` AS `idSequence`,
`lms_data_repository`.`enterprise_view01_user`.`userId` AS `userId`,
`lms_data_repository`.`enterprise_view01_user`.`username` AS `username`,
`lms_data_repository`.`enterprise_view01_user`.`phoneNumber` AS `phoneNumber`,
`lms_data_repository`.`enterprise_view01_user`.`email` AS `email`,
`lms_data_repository`.`enterprise_view01_user`.`userStatus` AS `userStatus`,
`lms_data_repository`.`enterprise_view01_user`.`qiweiId` AS `qiweiId`,
`lms_data_repository`.`enterprise_view01_user`.`userConfig` AS `userConfig`,
`lms_data_repository`.`enterprise_view01_user`.`password` AS `password`,
`lms_data_repository`.`enterprise_view01_user`.`md5Salt` AS `md5Salt`,
`lms_data_repository`.`enterprise_view01_user`.`clearTextPassword` AS `clearTextPassword`,
`lms_data_repository`.`enterprise_view01_user`.`operation` AS `operation`,
`lms_data_repository`.`enterprise_view01_user`.`operationByUserId` AS `operationByUserId`,
`lms_data_repository`.`enterprise_view01_user`.`operationByUser` AS `operationByUser`,
`lms_data_repository`.`enterprise_view01_user`.`operationAt` AS `operationAt`
from
`lms_data_repository`.`enterprise_view01_user`
_view02_user_app
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `_view02_user_app` AS
select
`lms_data_repository`.`enterprise_view02_user_app`.`id` AS `id`,
`lms_data_repository`.`enterprise_view02_user_app`.`userId` AS `userId`,
`lms_data_repository`.`enterprise_view02_user_app`.`appId` AS `appId`
from
`lms_data_repository`.`enterprise_view02_user_app`
where
(
`lms_data_repository`.`enterprise_view02_user_app`.`appId` = 'lms-teaching-plan'
)
view01_class
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `view01_class` AS
select
`class`.`id` AS `id`,
`class`.`year` AS `year`,
`class`.`academicYear` AS `academicYear`,
`class`.`semester` AS `semester`,
`class`.`segment` AS `segment`,
`class`.`level` AS `level`,
`class`.`number` AS `number`,
`class`.`classId` AS `classId`,
`class`.`className` AS `className`,
`class`.`classNum` AS `classNum`,
`class`.`formTeacherId` AS `formTeacherId`,
`class`.`formTeacherName` AS `formTeacherName`,
`class`.`formTeacherGender` AS `formTeacherGender`,
`class`.`formTeacherContact` AS `formTeacherContact`,
`class`.`learningTrack` AS `learningTrack`,
`class`.`classType` AS `classType`,
`class`.`classTagList` AS `classTagList`,
`class`.`classCreatedBy` AS `classCreatedBy`,
`class`.`remarks` AS `remarks`,
`class`.`classStatus` AS `classStatus`,
`class`.`operation` AS `operation`,
`class`.`operationByUserId` AS `operationByUserId`,
`class`.`operationByUser` AS `operationByUser`,
`class`.`operationAt` AS `operationAt`
from
`lms_data_repository`.`lms_student_admin__class` `class`
view01_employeeld
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `view01_employeeld` AS
select
`lms_data_repository`.`lms_hr__employee`.`id` AS `id`,
`lms_data_repository`.`lms_hr__employee`.`employeeId` AS `employeeId`,
`lms_data_repository`.`lms_hr__employee`.`idSequence` AS `idSequence`,
`lms_data_repository`.`lms_hr__employee`.`employeeName` AS `employeeName`,
`lms_data_repository`.`lms_hr__employee`.`sex` AS `sex`,
`lms_data_repository`.`lms_hr__employee`.`age` AS `age`,
`lms_data_repository`.`lms_hr__employee`.`contactNumber` AS `contactNumber`,
`lms_data_repository`.`lms_hr__employee`.`emergencyContactNumber` AS `emergencyContactNumber`,
`lms_data_repository`.`lms_hr__employee`.`icNumber` AS `icNumber`,
`lms_data_repository`.`lms_hr__employee`.`dateOfBirth` AS `dateOfBirth`,
`lms_data_repository`.`lms_hr__employee`.`institution` AS `institution`,
`lms_data_repository`.`lms_hr__employee`.`major` AS `major`
from
`lms_data_repository`.`lms_hr__employee`
view02_timetable
CREATE ALGORITHM = UNDEFINED DEFINER = `root` @`%` SQL SECURITY DEFINER VIEW `view02_timetable` AS
select
`lms_teaching_plan`.`timetable`.`id` AS `timetableId`,
`class`.`year` AS `year`,
`class`.`academicYear` AS `academicYear`,
`class`.`semester` AS `semester`,
`class`.`level` AS `level`,
`class`.`number` AS `number`,
`lms_teaching_plan`.`timetable`.`taskId` AS `taskId`,
`lms_teaching_plan`.`timetable`.`weekday` AS `weekday`,
`lms_teaching_plan`.`timetable`.`section` AS `section`,
`lms_teaching_plan`.`timetable`.`sectionName` AS `sectionName`,
`lms_teaching_plan`.`timetable`.`classId` AS `classId`,
`lms_teaching_plan`.`timetable`.`subject` AS `subject`,
`lms_teaching_plan`.`timetable`.`teacherId` AS `teacherId`,
`lms_teaching_plan`.`timetable`.`teacherName` AS `teacherName`,
`lms_teaching_plan`.`timetable`.`mergeTimetableIds` AS `mergeTimetableIds`,
`lms_teaching_plan`.`timetable`.`operationAt` AS `operationAt`,
`lms_teaching_plan`.`timetable`.`sectionType` AS `sectionType`
from
(
`lms_teaching_plan`.`timetable`
left join `lms_teaching_plan`.`view01_class` `class` on (
(
convert(
`lms_teaching_plan`.`timetable`.`classId` using utf8mb4
) = `class`.`classId`
)
)
)