Merge branch 'training-bug' into test
This commit is contained in:
commit
76df1f7cd0
@ -60,7 +60,9 @@ public interface BusinessConsts {
|
||||
*/
|
||||
String DEFAULT_PASSWORD = "123456";
|
||||
|
||||
/**贵州装备智造学院默认导入学生用户密码*/
|
||||
/**
|
||||
* 贵州装备智造学院默认导入学生用户密码
|
||||
*/
|
||||
String GZB_DEFAULT_PASSWORD = "666666";
|
||||
|
||||
String SYSTEM_BIGSCREEN = "bigScreen";
|
||||
@ -95,6 +97,7 @@ public interface BusinessConsts {
|
||||
|
||||
/**
|
||||
* 缓存前缀
|
||||
*
|
||||
* @author sheng
|
||||
*/
|
||||
interface CachePrefix {
|
||||
@ -109,9 +112,13 @@ public interface BusinessConsts {
|
||||
*/
|
||||
interface WebSocketSubscribeTopic {
|
||||
String Common = "/topic/message";
|
||||
/** 综合演练房间 */
|
||||
/**
|
||||
* 综合演练房间
|
||||
*/
|
||||
String Room = "/queue/room/%s";
|
||||
/** 仿真 */
|
||||
/**
|
||||
* 仿真
|
||||
*/
|
||||
String Simulation = "/queue/simulation/%s";
|
||||
String Sandbox3D = "/queue/simulation/jl3d/%s";
|
||||
String TrainDrive3D = "/queue/simulation/drive/%s";
|
||||
@ -121,7 +128,9 @@ public interface BusinessConsts {
|
||||
}
|
||||
|
||||
|
||||
/** 设备类型 */
|
||||
/**
|
||||
* 设备类型
|
||||
*/
|
||||
interface DeviceType {
|
||||
String Link = "01";
|
||||
String Switch = "02";
|
||||
@ -131,11 +140,17 @@ public interface BusinessConsts {
|
||||
String StationStand = "06";
|
||||
}
|
||||
|
||||
/** 车站计数器类型 */
|
||||
/**
|
||||
* 车站计数器类型
|
||||
*/
|
||||
interface CounterType {
|
||||
/** 区故解 */
|
||||
/**
|
||||
* 区故解
|
||||
*/
|
||||
String type01 = "01";
|
||||
/** 总人解 */
|
||||
/**
|
||||
* 总人解
|
||||
*/
|
||||
String type02 = "02";
|
||||
}
|
||||
|
||||
@ -143,20 +158,33 @@ public interface BusinessConsts {
|
||||
|
||||
/**
|
||||
* 权限类型
|
||||
*
|
||||
* @author Jade
|
||||
*/
|
||||
interface Type {
|
||||
/** 教学 */
|
||||
/**
|
||||
* 教学
|
||||
*/
|
||||
String Type01 = "01";
|
||||
/** 考试 */
|
||||
/**
|
||||
* 考试
|
||||
*/
|
||||
String Type02 = "02";
|
||||
/** 仿真 */
|
||||
/**
|
||||
* 仿真
|
||||
*/
|
||||
String Type03 = "03";
|
||||
/** 大屏 */
|
||||
/**
|
||||
* 大屏
|
||||
*/
|
||||
String Type04 = "04";
|
||||
/** 琏计划 */
|
||||
/**
|
||||
* 琏计划
|
||||
*/
|
||||
String Type05 = "05";
|
||||
/** 三维 */
|
||||
/**
|
||||
* 三维
|
||||
*/
|
||||
String Type06 = "06";
|
||||
}
|
||||
|
||||
@ -164,17 +192,29 @@ public interface BusinessConsts {
|
||||
* 试用时间单位
|
||||
*/
|
||||
interface TimeUnit {
|
||||
/** 年 */
|
||||
/**
|
||||
* 年
|
||||
*/
|
||||
String TimeUnit01 = "01";
|
||||
/** 月 */
|
||||
/**
|
||||
* 月
|
||||
*/
|
||||
String TimeUnit02 = "02";
|
||||
/** 日 */
|
||||
/**
|
||||
* 日
|
||||
*/
|
||||
String TimeUnit03 = "03";
|
||||
/** 时 */
|
||||
/**
|
||||
* 时
|
||||
*/
|
||||
String TimeUnit04 = "04";
|
||||
/** 分(默认) */
|
||||
/**
|
||||
* 分(默认)
|
||||
*/
|
||||
String TimeUnit05 = "05";
|
||||
/** 秒 */
|
||||
/**
|
||||
* 秒
|
||||
*/
|
||||
String TimeUnit06 = "06";
|
||||
}
|
||||
|
||||
@ -182,15 +222,25 @@ public interface BusinessConsts {
|
||||
* 来源
|
||||
*/
|
||||
interface Source {
|
||||
/** 来自订单 */
|
||||
/**
|
||||
* 来自订单
|
||||
*/
|
||||
String Source01 = "01";
|
||||
/** 来自订单权限分发打包 */
|
||||
/**
|
||||
* 来自订单权限分发打包
|
||||
*/
|
||||
String Source02 = "02";
|
||||
/** 来自个人权限分发 */
|
||||
/**
|
||||
* 来自个人权限分发
|
||||
*/
|
||||
String Source03 = "03";
|
||||
/** 来自个人权限打包分发 */
|
||||
/**
|
||||
* 来自个人权限打包分发
|
||||
*/
|
||||
String Source04 = "04";
|
||||
/** 来自个人权限转赠 */
|
||||
/**
|
||||
* 来自个人权限转赠
|
||||
*/
|
||||
String Source05 = "05";
|
||||
}
|
||||
|
||||
@ -199,70 +249,109 @@ public interface BusinessConsts {
|
||||
interface Order {
|
||||
/**
|
||||
* 订单类型
|
||||
*
|
||||
* @author sheng
|
||||
*/
|
||||
interface Type {
|
||||
/** 个人 */
|
||||
/**
|
||||
* 个人
|
||||
*/
|
||||
String Type01 = "01";
|
||||
/** 企业合同 */
|
||||
/**
|
||||
* 企业合同
|
||||
*/
|
||||
String Type02 = "02";
|
||||
/** 合约赠送 */
|
||||
/**
|
||||
* 合约赠送
|
||||
*/
|
||||
String Type03 = "03";
|
||||
/** 内部分配 */
|
||||
/**
|
||||
* 内部分配
|
||||
*/
|
||||
String Type04 = "04";
|
||||
}
|
||||
|
||||
/**
|
||||
* 业务类型
|
||||
*
|
||||
* @author sheng
|
||||
*/
|
||||
interface BizType {
|
||||
/** 正常购买 */
|
||||
/**
|
||||
* 正常购买
|
||||
*/
|
||||
String Type01 = "01";
|
||||
/** 续费 */
|
||||
/**
|
||||
* 续费
|
||||
*/
|
||||
String Type02 = "02";
|
||||
/** 增加权限数量 */
|
||||
/**
|
||||
* 增加权限数量
|
||||
*/
|
||||
String Type03 = "03";
|
||||
/** 续费+增加权限数量 */
|
||||
/**
|
||||
* 续费+增加权限数量
|
||||
*/
|
||||
String Type04 = "04";
|
||||
}
|
||||
|
||||
/**
|
||||
* 支付类型
|
||||
*
|
||||
* @author sheng
|
||||
*/
|
||||
interface PayType {
|
||||
/** 合同线下支付 */
|
||||
/**
|
||||
* 合同线下支付
|
||||
*/
|
||||
String Type01 = "01";
|
||||
/** 微信支付 */
|
||||
/**
|
||||
* 微信支付
|
||||
*/
|
||||
String Type02 = "02";
|
||||
/** 支付宝支付 */
|
||||
/**
|
||||
* 支付宝支付
|
||||
*/
|
||||
String Type03 = "03";
|
||||
}
|
||||
|
||||
/**
|
||||
* 支付状态
|
||||
*
|
||||
* @author sheng
|
||||
*/
|
||||
interface PayStatus {
|
||||
/** 待支付 */
|
||||
/**
|
||||
* 待支付
|
||||
*/
|
||||
String Status01 = "01";
|
||||
/** 已支付 */
|
||||
/**
|
||||
* 已支付
|
||||
*/
|
||||
String Status02 = "02";
|
||||
/** 取消 */
|
||||
/**
|
||||
* 取消
|
||||
*/
|
||||
String Status03 = "03";
|
||||
}
|
||||
|
||||
/**
|
||||
* 订单状态
|
||||
*
|
||||
* @author sheng
|
||||
*/
|
||||
interface Status {
|
||||
/** 未完成 */
|
||||
/**
|
||||
* 未完成
|
||||
*/
|
||||
String Status01 = "01";
|
||||
/** 完成 */
|
||||
/**
|
||||
* 完成
|
||||
*/
|
||||
String Status02 = "02";
|
||||
/** 取消 */
|
||||
/**
|
||||
* 取消
|
||||
*/
|
||||
String Status03 = "03";
|
||||
}
|
||||
|
||||
@ -284,6 +373,7 @@ public interface BusinessConsts {
|
||||
|
||||
/**
|
||||
* 模式
|
||||
*
|
||||
* @author Jade
|
||||
*/
|
||||
interface Mode {
|
||||
@ -296,14 +386,20 @@ public interface BusinessConsts {
|
||||
*/
|
||||
String Mode05 = "05";
|
||||
}
|
||||
|
||||
/**
|
||||
* 实训状态类型
|
||||
*
|
||||
* @author Jade
|
||||
*/
|
||||
interface StatusType {
|
||||
/** 开始 */
|
||||
/**
|
||||
* 开始
|
||||
*/
|
||||
String Type01 = "01";
|
||||
/** 结束 */
|
||||
/**
|
||||
* 结束
|
||||
*/
|
||||
String Type02 = "02";
|
||||
}
|
||||
|
||||
@ -311,18 +407,33 @@ public interface BusinessConsts {
|
||||
* 实训生成类型
|
||||
*/
|
||||
interface GenerateType {
|
||||
/** 自动 */
|
||||
/**
|
||||
* 自动
|
||||
*/
|
||||
String GenerateType01 = "01";
|
||||
/** 人工 */
|
||||
/**
|
||||
* 人工
|
||||
*/
|
||||
String GenerateType02 = "02";
|
||||
}
|
||||
|
||||
enum Type {
|
||||
Section("区段实训"), Switch("道岔实训"), Signal("信号机实训"), Stand("站台实训"), Station("车站实训"), ControlConvertMenu("控制权实训"), TrainWindow("车次窗实训"), LimitControl("限速实训"), Driver("司机驾驶实训"), Train("列车实训");
|
||||
Section("区段实训"),
|
||||
Switch("道岔实训"),
|
||||
Signal("信号机实训"),
|
||||
Stand("站台实训"),
|
||||
Station("车站实训"),
|
||||
ControlConvertMenu("控制权实训"),
|
||||
TrainWindow("车次窗实训"),
|
||||
LimitControl("限速实训"),
|
||||
Driver("司机驾驶实训"),
|
||||
Train("列车实训");
|
||||
private String description;
|
||||
|
||||
Type(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
@ -332,6 +443,7 @@ public interface BusinessConsts {
|
||||
interface Exam {
|
||||
/**
|
||||
* 考试结果
|
||||
*
|
||||
* @author Jade
|
||||
*/
|
||||
interface Result {
|
||||
@ -353,7 +465,9 @@ public interface BusinessConsts {
|
||||
String Result04 = "04";
|
||||
}
|
||||
|
||||
/**考试试题作答结果/原因*/
|
||||
/**
|
||||
* 考试试题作答结果/原因
|
||||
*/
|
||||
interface QuestionCause {
|
||||
String INCORRECT = "操作错误";
|
||||
String OVERTIME = "操作超时";
|
||||
@ -384,6 +498,7 @@ public interface BusinessConsts {
|
||||
*/
|
||||
String Type03 = "03";
|
||||
}
|
||||
|
||||
/**
|
||||
* 运行方向类型
|
||||
*/
|
||||
@ -431,6 +546,7 @@ public interface BusinessConsts {
|
||||
prdType02("【ATS行调工作站实操】", "该课程基于国内知名信号厂商的真实ATS系统,利用虚拟现实、人工智能等成熟的互联网技术,并结合一线运营人员的宝贵经验,实现了对行调工作站的原理级仿真。");
|
||||
private String name;
|
||||
private String remarks;
|
||||
|
||||
PrdInfo(String name, String remarks) {
|
||||
this.name = name;
|
||||
this.remarks = remarks;
|
||||
@ -444,6 +560,7 @@ public interface BusinessConsts {
|
||||
return remarks;
|
||||
}
|
||||
}
|
||||
|
||||
interface Version {
|
||||
String originalVersion = "0.0";
|
||||
}
|
||||
@ -498,7 +615,9 @@ public interface BusinessConsts {
|
||||
* 类型
|
||||
*/
|
||||
interface Type {
|
||||
/** 实训生成任务 */
|
||||
/**
|
||||
* 实训生成任务
|
||||
*/
|
||||
String Type01 = "01";
|
||||
}
|
||||
|
||||
@ -506,15 +625,25 @@ public interface BusinessConsts {
|
||||
* 状态
|
||||
*/
|
||||
interface Status {
|
||||
/** 未开始 */
|
||||
/**
|
||||
* 未开始
|
||||
*/
|
||||
String Status01 = "01";
|
||||
/** 进行中 */
|
||||
/**
|
||||
* 进行中
|
||||
*/
|
||||
String Status02 = "02";
|
||||
/** 已完成 */
|
||||
/**
|
||||
* 已完成
|
||||
*/
|
||||
String Status03 = "03";
|
||||
/** 待执行 */
|
||||
/**
|
||||
* 待执行
|
||||
*/
|
||||
String Status04 = "04";
|
||||
/** 已取消 */
|
||||
/**
|
||||
* 已取消
|
||||
*/
|
||||
String Status05 = "05";
|
||||
}
|
||||
}
|
||||
@ -537,6 +666,7 @@ public interface BusinessConsts {
|
||||
*/
|
||||
String State03 = "03";
|
||||
}
|
||||
|
||||
/**
|
||||
* 房间状态
|
||||
*/
|
||||
@ -617,15 +747,25 @@ public interface BusinessConsts {
|
||||
*/
|
||||
enum TheoryType {
|
||||
|
||||
/** 单选题*/
|
||||
/**
|
||||
* 单选题
|
||||
*/
|
||||
select,
|
||||
/** 多选题*/
|
||||
/**
|
||||
* 多选题
|
||||
*/
|
||||
multi,
|
||||
/**判断题*/
|
||||
/**
|
||||
* 判断题
|
||||
*/
|
||||
judge,
|
||||
/**填空题*/
|
||||
/**
|
||||
* 填空题
|
||||
*/
|
||||
fill,
|
||||
/**问答*/
|
||||
/**
|
||||
* 问答
|
||||
*/
|
||||
answer
|
||||
}
|
||||
}
|
||||
|
@ -653,6 +653,8 @@ public class LessonService implements ILessonService {
|
||||
int orderNum = 1;
|
||||
Random random = new Random();
|
||||
for (BusinessConsts.Training.Type type : BusinessConsts.Training.Type.values()) {
|
||||
List<Training> trainings = iTrainingV1Service.queryTrainingsBy(mapVO.getId(), lesson.getPrdType(), type.name());
|
||||
if (CollectionUtils.isEmpty(trainings)) continue;
|
||||
//章节
|
||||
LsLessonChapter chapter = new LsLessonChapter();
|
||||
chapter.setLessonId(lesson.getId());
|
||||
@ -661,9 +663,7 @@ public class LessonService implements ILessonService {
|
||||
chapter.setName(type.getDescription());
|
||||
chapter.setRemarks(chapter.getName() + "章节");
|
||||
lessonChapterDAO.insert(chapter);
|
||||
List<Training> trainings = iTrainingV1Service.queryTrainingsBy(mapVO.getId(), lesson.getPrdType(), type.name());
|
||||
if (CollectionUtils.isEmpty(trainings)) continue;
|
||||
trainings.stream().collect(Collectors.groupingBy(t -> t.getOperateType())).forEach((s, ts) -> {
|
||||
trainings.stream().collect(Collectors.groupingBy(Training::getOperateType)).forEach((s, ts) -> {
|
||||
examTrainings.add(ts.get(random.nextInt(ts.size())));
|
||||
int i = 1;
|
||||
while (i < 3) {
|
||||
|
@ -97,7 +97,7 @@ public class SignalGeneratorNew implements GeneratorNew {
|
||||
if (route.isGuide()) { // 引导进路跳过
|
||||
continue;
|
||||
}
|
||||
trainingVOList.add(this.build(config, simulation, route, operateDefinitionVO));
|
||||
trainingVOList.add(this.build(config, simulation, signal, operateDefinitionVO));
|
||||
// 仿真重置
|
||||
simulation.reset();
|
||||
}
|
||||
@ -165,7 +165,7 @@ public class SignalGeneratorNew implements GeneratorNew {
|
||||
}
|
||||
this.deviceStatusModifyTool.openRouteDirect(simulation, route);
|
||||
this.deviceStatusModifyTool.closeSignalDirectly(route.getStart());
|
||||
trainingVOList.add(this.build(config, simulation, route, operateDefinitionVO));
|
||||
trainingVOList.add(this.build(config, simulation, signal, operateDefinitionVO));
|
||||
// 仿真重置
|
||||
simulation.reset();
|
||||
}
|
||||
@ -209,7 +209,7 @@ public class SignalGeneratorNew implements GeneratorNew {
|
||||
.collect(Collectors.toList());
|
||||
for (Route route : fltRouteList) {
|
||||
deviceStatusModifyTool.openRouteDirect(simulation, route);
|
||||
trainingVOList.add(this.build(config, simulation, route, operateDefinitionVO));
|
||||
trainingVOList.add(this.build(config, simulation, route.getStart(), operateDefinitionVO));
|
||||
// 仿真重置
|
||||
simulation.reset();
|
||||
}
|
||||
@ -248,7 +248,7 @@ public class SignalGeneratorNew implements GeneratorNew {
|
||||
} else {
|
||||
for (Route route : arcRouteList) {
|
||||
route.setCiControl(true);
|
||||
trainingVOList.add(this.build(config, simulation, route, operateDefinitionVO));
|
||||
trainingVOList.add(this.build(config, simulation, signal, operateDefinitionVO));
|
||||
// 仿真重置
|
||||
simulation.reset();
|
||||
}
|
||||
|
@ -94,6 +94,7 @@ tencent-cloud:
|
||||
logging:
|
||||
file:
|
||||
path: /logs/joylink/rtss
|
||||
max-size: 100MB
|
||||
level:
|
||||
club.joylink.rtss: DEBUG
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user