|
|
@ -71,8 +71,7 @@ public class CaseApi {
|
|
|
|
sysTopicAndCourse.setId(IdUtil.randomUUID());
|
|
|
|
sysTopicAndCourse.setId(IdUtil.randomUUID());
|
|
|
|
sysTopicAndCourse.setTopicType("1");
|
|
|
|
sysTopicAndCourse.setTopicType("1");
|
|
|
|
sysTopicAndCourse.setTopicId(uuid);
|
|
|
|
sysTopicAndCourse.setTopicId(uuid);
|
|
|
|
SysOneCatalog sysOneCatalogs = getSysOneCatalogs(sysCaseQuestion.getOneName());
|
|
|
|
String oneId = sysOneCatalogs1.getOneId();
|
|
|
|
String oneId = sysOneCatalogs.getOneId();
|
|
|
|
|
|
|
|
sysTopicAndCourse.setOneId(oneId);
|
|
|
|
sysTopicAndCourse.setOneId(oneId);
|
|
|
|
sysTopicAndCourse.setOneName(sysCaseQuestion.getOneName());
|
|
|
|
sysTopicAndCourse.setOneName(sysCaseQuestion.getOneName());
|
|
|
|
if (StringUtils.isNotBlank(sysCaseQuestion.getTwoId())) {
|
|
|
|
if (StringUtils.isNotBlank(sysCaseQuestion.getTwoId())) {
|
|
|
@ -98,7 +97,7 @@ public class CaseApi {
|
|
|
|
@AnonymousAccess
|
|
|
|
@AnonymousAccess
|
|
|
|
@ApiOperation("案例题页面查询")
|
|
|
|
@ApiOperation("案例题页面查询")
|
|
|
|
@PostMapping("selectCaseList")
|
|
|
|
@PostMapping("selectCaseList")
|
|
|
|
public PageInfo<SysCaseQuestion> selectCaseByConditions(@RequestParam Integer index,
|
|
|
|
public PageInfo<SysCaseQuestion> selectCaseList(@RequestParam Integer index,
|
|
|
|
@RequestParam Integer size,
|
|
|
|
@RequestParam Integer size,
|
|
|
|
@RequestParam(required = false) String keyword,
|
|
|
|
@RequestParam(required = false) String keyword,
|
|
|
|
@RequestParam(required = false) String systemOwner,
|
|
|
|
@RequestParam(required = false) String systemOwner,
|
|
|
@ -114,9 +113,21 @@ public class CaseApi {
|
|
|
|
@AnonymousAccess
|
|
|
|
@AnonymousAccess
|
|
|
|
@ApiOperation("案例题详细内容展示")
|
|
|
|
@ApiOperation("案例题详细内容展示")
|
|
|
|
@PostMapping("selectCaseDetails")
|
|
|
|
@PostMapping("selectCaseDetails")
|
|
|
|
public SysCaseQuestion selectCaseByConditionsByID(@RequestParam String caseId) {
|
|
|
|
public SysCaseQuestion selectCaseByConditionsByID(@RequestParam String caseId,
|
|
|
|
return caseQuestionMapper.selectByPrimaryKey(caseId);
|
|
|
|
@RequestParam String oneId) {
|
|
|
|
|
|
|
|
SysTopicAndCourseExample example = new SysTopicAndCourseExample();
|
|
|
|
|
|
|
|
example.createCriteria().andOneIdEqualTo(oneId).andTopicIdEqualTo(caseId);
|
|
|
|
|
|
|
|
List<SysTopicAndCourse> sysTopicAndCourses = topicAndCourseMapper.selectByExample(example);
|
|
|
|
|
|
|
|
if (sysTopicAndCourses != null && !sysTopicAndCourses.isEmpty()) {
|
|
|
|
|
|
|
|
SysTopicAndCourse sysTopicAndCourse = sysTopicAndCourses.get(0);
|
|
|
|
|
|
|
|
SysCaseQuestion sysCaseQuestion = caseQuestionMapper.selectByPrimaryKey(caseId);
|
|
|
|
|
|
|
|
sysCaseQuestion.setTwoId(sysTopicAndCourse.getTwoId());
|
|
|
|
|
|
|
|
sysCaseQuestion.setTwoName(sysTopicAndCourse.getTwoName());
|
|
|
|
|
|
|
|
sysCaseQuestion.setThreeId(sysTopicAndCourse.getThreeId());
|
|
|
|
|
|
|
|
sysCaseQuestion.setThreeName(sysTopicAndCourse.getThreeName());
|
|
|
|
|
|
|
|
return sysCaseQuestion;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return null;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|