xiaoCJ 9 months ago
parent 1675fbe6f4
commit ca73521faa

@ -44,7 +44,7 @@ public class CaseController {
@ApiOperation("案例题新增")
@PostMapping("insertCase")
public ResultEntity<HttpStatus> insertCase(@ApiParam("目前二级三级ID可以为空来源和题型要传,上架状态传true") @RequestBody SysCaseQuestion sysCaseQuestion) {
if (!("1").equals(sysCaseQuestion.getType())) {
if (("3").equals(sysCaseQuestion.getType())) {
return new ResultEntity<>(HttpStatus.BAD_REQUEST, "题型错误!");
}
if (StringUtils.isBlank(sysCaseQuestion.getOneId())) { //todo 目前二级三级ID可以为空
@ -67,17 +67,19 @@ public class CaseController {
String uuid = IdUtil.randomUUID();
sysCaseQuestion.setCaseId(uuid);
sysCaseQuestion.setCreateTime(new Date());
sysCaseQuestion.setUnmountStatus(false);
caseQuestionMapper.insert(sysCaseQuestion);
//新增绑定关系
SysTopicAndCourse sysTopicAndCourse = new SysTopicAndCourse();
sysTopicAndCourse.setId(IdUtil.randomUUID());
sysTopicAndCourse.setTopicType("1");
sysTopicAndCourse.setTopicId(uuid);
sysTopicAndCourse.setOneId(sysCaseQuestion.getOneId());
if (StringUtils.isNotBlank(sysCaseQuestion.getTwoId())) {
sysTopicAndCourse.setTwoId(sysCaseQuestion.getTwoId());
}
if (StringUtils.isNotBlank(sysCaseQuestion.getThree())) {
sysTopicAndCourse.setThreeId(sysCaseQuestion.getThree());
if (StringUtils.isNotBlank(sysCaseQuestion.getThreeId())) {
sysTopicAndCourse.setThreeId(sysCaseQuestion.getThreeId());
}
topicAndCourseMapper.insert(sysTopicAndCourse);
return new ResultEntity<>(HttpStatus.OK, "新增成功!");
@ -89,8 +91,8 @@ public class CaseController {
@PostMapping("selectCaseByConditions")
public ResultEntity<PageInfo<SysCaseQuestion>> selectCaseByConditions(@RequestParam Integer index,
@RequestParam Integer size,
@RequestParam String title,
@RequestParam String oneId) {
@RequestParam(required = false) String title,
@RequestParam(required = false) String oneId) {
PageHelper.startPage(index, size);
List<SysCaseQuestion> list = caseQuestionMapper.selectCaseByConditions(title, oneId);
PageInfo pageInfo = new PageInfo<SysCaseQuestion>(list);

@ -127,12 +127,15 @@ public class CourseConfigController {
@ApiOperation("课程配置/资源列表展示")
@PostMapping("selectResourceByIDAndSource")
public ResultEntity<PageInfo<SysResource>> selectResource(@ApiParam("课程ID") @RequestParam String oneID,
@ApiParam("章ID") @RequestParam String twoID,
@ApiParam("节ID") @RequestParam String threeID,
@ApiParam("章ID") @RequestParam(required = false) String twoID,
@ApiParam("节ID") @RequestParam(required = false) String threeID,
@RequestParam(required = false) String source, //子系统调用时传
@RequestParam Integer index,
@RequestParam Integer size) {
List<String> list = sysResourceAndCourseMapper.selectResourceId(oneID, twoID, threeID);
if (list == null || list.isEmpty()) {
return new ResultEntity<PageInfo<SysResource>>(new PageInfo<>());
}
SysResourceExample example = new SysResourceExample();
SysResourceExample.Criteria criteria = example.createCriteria();
criteria.andResourceIdIn(list);
@ -141,7 +144,7 @@ public class CourseConfigController {
List<String> sources = Arrays.asList(source, "内置");
criteria.andSourceIn(sources);
}
example.setOrderByClause("createTime ASC");
example.setOrderByClause("create_time ASC");
List<SysResource> sysResources = sysResourceMapper.selectByExample(example);
PageInfo pageInfo = PageUtil.pageHelper(sysResources, index, size);
return new ResultEntity<PageInfo<SysResource>>(pageInfo);

@ -12,17 +12,24 @@ import com.sztzjy.resource_center.entity.dto.SysObjectiveQuestionsDto;
import com.sztzjy.resource_center.mapper.SysObjectiveQuestionsMapper;
import com.sztzjy.resource_center.mapper.SysTopicAndCourseMapper;
import com.sztzjy.resource_center.util.ResultEntity;
import com.sztzjy.resource_center.util.file.IFileUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.apache.commons.lang3.StringUtils;
import org.apache.poi.openxml4j.exceptions.InvalidFormatException;
import org.apache.poi.ss.usermodel.*;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.http.HttpStatus;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import java.util.Date;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.math.BigDecimal;
import java.util.*;
/**
* @Author xcj
@ -37,6 +44,10 @@ public class TopicResourceController {
private SysObjectiveQuestionsMapper sysObjectiveQuestionMapper;
@Autowired
private SysTopicAndCourseMapper sysTopicAndCourseMapper;
@Autowired
IFileUtil fileUtil;
@Value("${file.path}")
private String filePath;
@ApiOperation("新增单个试题") //新增 题干不允许重复
@PostMapping("addTopic")
@ -75,6 +86,7 @@ public class TopicResourceController {
String uuid = IdUtil.randomUUID();
objectiveQuestion.setObjectiveId(uuid);
objectiveQuestion.setCreateTime(new Date());
objectiveQuestion.setIsDelete(false);
sysObjectiveQuestionMapper.insert(objectiveQuestion);
//新增题库关系表
@ -93,14 +105,19 @@ public class TopicResourceController {
return new ResultEntity<>(HttpStatus.OK, "新增题目成功!");
}
@ApiOperation("本地excel导入试题") //todo 模板暂定,可以复用皖西的导入
@AnonymousAccess
@ApiOperation("本地excel导入试题")
@PostMapping("importTopicByLocal")
private ResultEntity importTopicByLocal() {
return null;
private ResultEntity<HttpStatus> importTopicByLocal(@RequestParam MultipartFile file,
@RequestParam String source) throws IOException, InvalidFormatException {
if (file == null) {
return new ResultEntity<>(HttpStatus.BAD_REQUEST, "导入文件不能为空");
}
return insertObjectiveByExcel(file, source);
}
@ApiOperation("批量导入") //理解为批量添加已有资源的绑定关系
@ApiOperation("资源中心批量导入") //理解为批量添加已有资源的绑定关系
@PostMapping("importTopic")
private ResultEntity<String> importTopic(@RequestBody List<SysTopicAndCourse> list) {
for (SysTopicAndCourse sysTopicAndCourse : list) {
@ -123,15 +140,24 @@ public class TopicResourceController {
return new ResultEntity<>(HttpStatus.OK, "添加成功!");
}
//客观题导入模板下载
@GetMapping("downloadResource")
@ApiOperation("客观题导入模板下载")
@AnonymousAccess
public void downloadResource(HttpServletResponse response) {
fileUtil.download(response, "客观题导入模板.xlsx", filePath);
}
@AnonymousAccess
@ApiOperation("条件查询")
@PostMapping("selectTopicByConditions") //todo 关于老师删除的题库如何查询
private ResultEntity<PageInfo<SysObjectiveQuestionsDto>> selectTopicByConditions(@RequestParam Integer index,
@RequestParam Integer size,
@RequestParam(required = false) String oneID,
@RequestParam (required = false)String twoID,
@RequestParam (required = false)String threeID,
@ApiParam("题干") @RequestParam (required = false)String content) {
@RequestParam(required = false) String twoID,
@RequestParam(required = false) String threeID,
@ApiParam("题干") @RequestParam(required = false) String content) {
PageHelper.startPage(index, size);
List<SysObjectiveQuestionsDto> list = sysObjectiveQuestionMapper.selectTopicByConditions(oneID, twoID, threeID, content);
PageInfo<SysObjectiveQuestionsDto> pageInfo = new PageInfo(list);
@ -143,7 +169,7 @@ public class TopicResourceController {
@ApiOperation("编辑")
@PostMapping("updateTopic")
private ResultEntity<String> updateTopic(@ApiParam("修改绑定关系需要传topicAndCourseId") @RequestParam SysObjectiveQuestionsDto dto) {
if (dto.getInputType().equals("0")) { //老师新增的不能编辑
if (!dto.getSource().equals("管理员")) { //老师新增的不能编辑
SysTopicAndCourseExample example = new SysTopicAndCourseExample();
example.createCriteria().andTopicIdEqualTo(dto.getObjectiveId());
List<SysTopicAndCourse> sysTopicAndCourses = sysTopicAndCourseMapper.selectByExample(example);
@ -184,4 +210,82 @@ public class TopicResourceController {
sysObjectiveQuestionMapper.deleteByPrimaryKey(id);
return new ResultEntity<>(HttpStatus.OK, "成功删除!");
}
//如果是内置增加 则需要提供课程和章节信息
//如果是老师增加 则只需要提供课程信息
public ResultEntity<HttpStatus> insertObjectiveByExcel(MultipartFile file, String source) throws IOException, InvalidFormatException {
List<SysObjectiveQuestions> objectiveQuestionList = new ArrayList<>();
Workbook workbook = WorkbookFactory.create(file.getInputStream());
Sheet sheet = workbook.getSheetAt(0);
// 迭代每一行
Iterator<Row> iterator = sheet.iterator();
iterator.next();
while (iterator.hasNext()) {
Row row = iterator.next();
/*解析列下标从0开始*/
Cell cell0 = row.getCell(0);
Cell cell1 = row.getCell(1);
Cell cell2 = row.getCell(2);
Cell cell3 = row.getCell(3);
Cell cell4 = row.getCell(4);
Cell cell5 = row.getCell(5);
Cell cell6 = row.getCell(6);
Cell cell7 = row.getCell(7);
Cell cell8 = row.getCell(8);
Cell cell9 = row.getCell(9);
//判断题的BCDE选项和解析可能为空
if (cell0 == null || cell1 == null || cell2 == null || cell6 == null || cell7 == null || cell9 == null) {
return new ResultEntity<>(HttpStatus.BAD_REQUEST, "必填项不能为空");
}
String content = this.getCellValue(cell0);//题干
String a = this.getCellValue(cell1); //选项A
String b = this.getCellValue(cell2);//选项B
String type = this.getCellValue(cell6);//题型
String answer = this.getCellValue(cell7);//答案
String score = this.getCellValue(cell9);//分值
String c = cell3 != null ? this.getCellValue(cell3) : null;
String d = cell4 != null ? this.getCellValue(cell4) : null;
String e = cell5 != null ? this.getCellValue(cell5) : null;
String analyze = cell8 != null ? this.getCellValue(cell8) : null;
SysObjectiveQuestions obj = new SysObjectiveQuestions();
obj.setObjectiveId(String.valueOf(UUID.randomUUID()));
obj.setContent(content);
obj.setType(type);
obj.setSource(source);
obj.setQuestionA(a);
obj.setQuestionB(b);
obj.setQuestionC(c);
obj.setQuestionD(d);
obj.setQuestionE(e);
obj.setAnswer(answer);
obj.setAnalysis(analyze);
obj.setScore(BigDecimal.valueOf(Integer.parseInt(score)));
obj.setCreateTime(new Date());
obj.setIsDelete(false);
objectiveQuestionList.add(obj);
}
int result = sysObjectiveQuestionMapper.insertBatch(objectiveQuestionList);
if (result > 0) {
return new ResultEntity<>(HttpStatus.OK, "批量导入成功!");
} else {
return new ResultEntity<>(HttpStatus.INTERNAL_SERVER_ERROR, "批量导入失败,请联系管理员!");
}
}
public String getCellValue(Cell cell) {
if (cell.getCellType() == Cell.CELL_TYPE_BOOLEAN) {
return String.valueOf(cell.getBooleanCellValue());
} else if (cell.getCellType() == Cell.CELL_TYPE_NUMERIC) {
Double d = cell.getNumericCellValue();
return String.valueOf(d.intValue());
}
return String.valueOf(cell.getStringCellValue());
}
}

@ -16,7 +16,7 @@ public class SysCaseQuestion {
@ApiModelProperty("题目标题")
private String title;
@ApiModelProperty("数据集地址 /用,隔开")
@ApiModelProperty("数据集地址 ,隔开")
private String resourceData;
@ApiModelProperty("来源 schoolid/内置")
@ -28,11 +28,17 @@ public class SysCaseQuestion {
@ApiModelProperty("一级目录ID")
private String oneId;
private String oneName;
@ApiModelProperty("二级目录ID")
private String twoId;
private String twoName;
@ApiModelProperty("三级目录ID")
private String three;
private String threeId;
private String threeName;
@ApiModelProperty("上下架状态")
private Boolean unmountStatus;
@ -94,6 +100,14 @@ public class SysCaseQuestion {
this.oneId = oneId == null ? null : oneId.trim();
}
public String getOneName() {
return oneName;
}
public void setOneName(String oneName) {
this.oneName = oneName == null ? null : oneName.trim();
}
public String getTwoId() {
return twoId;
}
@ -102,12 +116,28 @@ public class SysCaseQuestion {
this.twoId = twoId == null ? null : twoId.trim();
}
public String getThree() {
return three;
public String getTwoName() {
return twoName;
}
public void setTwoName(String twoName) {
this.twoName = twoName == null ? null : twoName.trim();
}
public String getThreeId() {
return threeId;
}
public void setThreeId(String threeId) {
this.threeId = threeId == null ? null : threeId.trim();
}
public String getThreeName() {
return threeName;
}
public void setThree(String three) {
this.three = three == null ? null : three.trim();
public void setThreeName(String threeName) {
this.threeName = threeName == null ? null : threeName.trim();
}
public Boolean getUnmountStatus() {

@ -525,6 +525,76 @@ public class SysCaseQuestionExample {
return (Criteria) this;
}
public Criteria andOneNameIsNull() {
addCriterion("one_name is null");
return (Criteria) this;
}
public Criteria andOneNameIsNotNull() {
addCriterion("one_name is not null");
return (Criteria) this;
}
public Criteria andOneNameEqualTo(String value) {
addCriterion("one_name =", value, "oneName");
return (Criteria) this;
}
public Criteria andOneNameNotEqualTo(String value) {
addCriterion("one_name <>", value, "oneName");
return (Criteria) this;
}
public Criteria andOneNameGreaterThan(String value) {
addCriterion("one_name >", value, "oneName");
return (Criteria) this;
}
public Criteria andOneNameGreaterThanOrEqualTo(String value) {
addCriterion("one_name >=", value, "oneName");
return (Criteria) this;
}
public Criteria andOneNameLessThan(String value) {
addCriterion("one_name <", value, "oneName");
return (Criteria) this;
}
public Criteria andOneNameLessThanOrEqualTo(String value) {
addCriterion("one_name <=", value, "oneName");
return (Criteria) this;
}
public Criteria andOneNameLike(String value) {
addCriterion("one_name like", value, "oneName");
return (Criteria) this;
}
public Criteria andOneNameNotLike(String value) {
addCriterion("one_name not like", value, "oneName");
return (Criteria) this;
}
public Criteria andOneNameIn(List<String> values) {
addCriterion("one_name in", values, "oneName");
return (Criteria) this;
}
public Criteria andOneNameNotIn(List<String> values) {
addCriterion("one_name not in", values, "oneName");
return (Criteria) this;
}
public Criteria andOneNameBetween(String value1, String value2) {
addCriterion("one_name between", value1, value2, "oneName");
return (Criteria) this;
}
public Criteria andOneNameNotBetween(String value1, String value2) {
addCriterion("one_name not between", value1, value2, "oneName");
return (Criteria) this;
}
public Criteria andTwoIdIsNull() {
addCriterion("two_id is null");
return (Criteria) this;
@ -595,73 +665,213 @@ public class SysCaseQuestionExample {
return (Criteria) this;
}
public Criteria andThreeIsNull() {
addCriterion("three is null");
public Criteria andTwoNameIsNull() {
addCriterion("two_name is null");
return (Criteria) this;
}
public Criteria andTwoNameIsNotNull() {
addCriterion("two_name is not null");
return (Criteria) this;
}
public Criteria andTwoNameEqualTo(String value) {
addCriterion("two_name =", value, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameNotEqualTo(String value) {
addCriterion("two_name <>", value, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameGreaterThan(String value) {
addCriterion("two_name >", value, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameGreaterThanOrEqualTo(String value) {
addCriterion("two_name >=", value, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameLessThan(String value) {
addCriterion("two_name <", value, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameLessThanOrEqualTo(String value) {
addCriterion("two_name <=", value, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameLike(String value) {
addCriterion("two_name like", value, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameNotLike(String value) {
addCriterion("two_name not like", value, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameIn(List<String> values) {
addCriterion("two_name in", values, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameNotIn(List<String> values) {
addCriterion("two_name not in", values, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameBetween(String value1, String value2) {
addCriterion("two_name between", value1, value2, "twoName");
return (Criteria) this;
}
public Criteria andTwoNameNotBetween(String value1, String value2) {
addCriterion("two_name not between", value1, value2, "twoName");
return (Criteria) this;
}
public Criteria andThreeIdIsNull() {
addCriterion("three_id is null");
return (Criteria) this;
}
public Criteria andThreeIdIsNotNull() {
addCriterion("three_id is not null");
return (Criteria) this;
}
public Criteria andThreeIdEqualTo(String value) {
addCriterion("three_id =", value, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdNotEqualTo(String value) {
addCriterion("three_id <>", value, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdGreaterThan(String value) {
addCriterion("three_id >", value, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdGreaterThanOrEqualTo(String value) {
addCriterion("three_id >=", value, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdLessThan(String value) {
addCriterion("three_id <", value, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdLessThanOrEqualTo(String value) {
addCriterion("three_id <=", value, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdLike(String value) {
addCriterion("three_id like", value, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdNotLike(String value) {
addCriterion("three_id not like", value, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdIn(List<String> values) {
addCriterion("three_id in", values, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdNotIn(List<String> values) {
addCriterion("three_id not in", values, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdBetween(String value1, String value2) {
addCriterion("three_id between", value1, value2, "threeId");
return (Criteria) this;
}
public Criteria andThreeIdNotBetween(String value1, String value2) {
addCriterion("three_id not between", value1, value2, "threeId");
return (Criteria) this;
}
public Criteria andThreeNameIsNull() {
addCriterion("three_name is null");
return (Criteria) this;
}
public Criteria andThreeIsNotNull() {
addCriterion("three is not null");
public Criteria andThreeNameIsNotNull() {
addCriterion("three_name is not null");
return (Criteria) this;
}
public Criteria andThreeEqualTo(String value) {
addCriterion("three =", value, "three");
public Criteria andThreeNameEqualTo(String value) {
addCriterion("three_name =", value, "threeName");
return (Criteria) this;
}
public Criteria andThreeNotEqualTo(String value) {
addCriterion("three <>", value, "three");
public Criteria andThreeNameNotEqualTo(String value) {
addCriterion("three_name <>", value, "threeName");
return (Criteria) this;
}
public Criteria andThreeGreaterThan(String value) {
addCriterion("three >", value, "three");
public Criteria andThreeNameGreaterThan(String value) {
addCriterion("three_name >", value, "threeName");
return (Criteria) this;
}
public Criteria andThreeGreaterThanOrEqualTo(String value) {
addCriterion("three >=", value, "three");
public Criteria andThreeNameGreaterThanOrEqualTo(String value) {
addCriterion("three_name >=", value, "threeName");
return (Criteria) this;
}
public Criteria andThreeLessThan(String value) {
addCriterion("three <", value, "three");
public Criteria andThreeNameLessThan(String value) {
addCriterion("three_name <", value, "threeName");
return (Criteria) this;
}
public Criteria andThreeLessThanOrEqualTo(String value) {
addCriterion("three <=", value, "three");
public Criteria andThreeNameLessThanOrEqualTo(String value) {
addCriterion("three_name <=", value, "threeName");
return (Criteria) this;
}
public Criteria andThreeLike(String value) {
addCriterion("three like", value, "three");
public Criteria andThreeNameLike(String value) {
addCriterion("three_name like", value, "threeName");
return (Criteria) this;
}
public Criteria andThreeNotLike(String value) {
addCriterion("three not like", value, "three");
public Criteria andThreeNameNotLike(String value) {
addCriterion("three_name not like", value, "threeName");
return (Criteria) this;
}
public Criteria andThreeIn(List<String> values) {
addCriterion("three in", values, "three");
public Criteria andThreeNameIn(List<String> values) {
addCriterion("three_name in", values, "threeName");
return (Criteria) this;
}
public Criteria andThreeNotIn(List<String> values) {
addCriterion("three not in", values, "three");
public Criteria andThreeNameNotIn(List<String> values) {
addCriterion("three_name not in", values, "threeName");
return (Criteria) this;
}
public Criteria andThreeBetween(String value1, String value2) {
addCriterion("three between", value1, value2, "three");
public Criteria andThreeNameBetween(String value1, String value2) {
addCriterion("three_name between", value1, value2, "threeName");
return (Criteria) this;
}
public Criteria andThreeNotBetween(String value1, String value2) {
addCriterion("three not between", value1, value2, "three");
public Criteria andThreeNameNotBetween(String value1, String value2) {
addCriterion("three_name not between", value1, value2, "threeName");
return (Criteria) this;
}

@ -8,32 +8,14 @@ import io.swagger.annotations.ApiModelProperty;
*
*
* @author xcj
* sys_objective_question
* sys_objective_questions
*/
public class SysObjectiveQuestions {
@ApiModelProperty("客观题ID")
private String objectiveId;
@ApiModelProperty("课程ID")
private String courseId;
@ApiModelProperty("课程名称")
private String courseName;
@ApiModelProperty("章节ID")
private String chapterId;
@ApiModelProperty("章节名称")
private String chapterName;
@ApiModelProperty("内置,新增 0为老师导入 1为内置")
private String inputType;
@ApiModelProperty("题目类型 0单选 1多选 2判断")
private String type;
@ApiModelProperty("分数")
private BigDecimal score;
@ApiModelProperty("schoolid/内置")
private String source;
@ApiModelProperty("题目内容")
private String content;
@ -53,48 +35,26 @@ public class SysObjectiveQuestions {
@ApiModelProperty("选项e")
private String questionE;
@ApiModelProperty("分数")
private BigDecimal score;
@ApiModelProperty("答案")
private String answer;
@ApiModelProperty("答案解析")
private String analysis;
@ApiModelProperty("学校Id")
private String schoolId;
@ApiModelProperty("题目类型 0单选 1多选 2判断")
private String type;
@ApiModelProperty("创建时间")
private Date createTime;
@ApiModelProperty("修改时间")
private String updateTime;
private Date updateTime;
@ApiModelProperty("是否删除")
private Boolean isDelete;
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public String getUpdateTime() {
return updateTime;
}
public void setUpdateTime(String updateTime) {
this.updateTime = updateTime;
}
public Boolean getDelete() {
return isDelete;
}
public void setDelete(Boolean delete) {
isDelete = delete;
}
public String getObjectiveId() {
return objectiveId;
}
@ -103,60 +63,12 @@ public class SysObjectiveQuestions {
this.objectiveId = objectiveId == null ? null : objectiveId.trim();
}
public String getCourseId() {
return courseId;
}
public void setCourseId(String courseId) {
this.courseId = courseId == null ? null : courseId.trim();
}
public String getCourseName() {
return courseName;
}
public void setCourseName(String courseName) {
this.courseName = courseName == null ? null : courseName.trim();
}
public String getChapterId() {
return chapterId;
}
public void setChapterId(String chapterId) {
this.chapterId = chapterId == null ? null : chapterId.trim();
}
public String getChapterName() {
return chapterName;
public String getSource() {
return source;
}
public void setChapterName(String chapterName) {
this.chapterName = chapterName == null ? null : chapterName.trim();
}
public String getInputType() {
return inputType;
}
public void setInputType(String inputType) {
this.inputType = inputType == null ? null : inputType.trim();
}
public String getType() {
return type;
}
public void setType(String type) {
this.type = type == null ? null : type.trim();
}
public BigDecimal getScore() {
return score;
}
public void setScore(BigDecimal score) {
this.score = score;
public void setSource(String source) {
this.source = source == null ? null : source.trim();
}
public String getContent() {
@ -207,6 +119,14 @@ public class SysObjectiveQuestions {
this.questionE = questionE == null ? null : questionE.trim();
}
public BigDecimal getScore() {
return score;
}
public void setScore(BigDecimal score) {
this.score = score;
}
public String getAnswer() {
return answer;
}
@ -223,11 +143,35 @@ public class SysObjectiveQuestions {
this.analysis = analysis == null ? null : analysis.trim();
}
public String getSchoolId() {
return schoolId;
public String getType() {
return type;
}
public void setType(String type) {
this.type = type == null ? null : type.trim();
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public Date getUpdateTime() {
return updateTime;
}
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
public Boolean getIsDelete() {
return isDelete;
}
public void setSchoolId(String schoolId) {
this.schoolId = schoolId == null ? null : schoolId.trim();
public void setIsDelete(Boolean isDelete) {
this.isDelete = isDelete;
}
}

@ -2,6 +2,7 @@ package com.sztzjy.resource_center.entity;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
public class SysObjectiveQuestionsExample {
@ -175,483 +176,73 @@ public class SysObjectiveQuestionsExample {
return (Criteria) this;
}
public Criteria andCourseIdIsNull() {
addCriterion("course_id is null");
public Criteria andSourceIsNull() {
addCriterion("source is null");
return (Criteria) this;
}
public Criteria andCourseIdIsNotNull() {
addCriterion("course_id is not null");
public Criteria andSourceIsNotNull() {
addCriterion("source is not null");
return (Criteria) this;
}
public Criteria andCourseIdEqualTo(String value) {
addCriterion("course_id =", value, "courseId");
public Criteria andSourceEqualTo(String value) {
addCriterion("source =", value, "source");
return (Criteria) this;
}
public Criteria andCourseIdNotEqualTo(String value) {
addCriterion("course_id <>", value, "courseId");
public Criteria andSourceNotEqualTo(String value) {
addCriterion("source <>", value, "source");
return (Criteria) this;
}
public Criteria andCourseIdGreaterThan(String value) {
addCriterion("course_id >", value, "courseId");
public Criteria andSourceGreaterThan(String value) {
addCriterion("source >", value, "source");
return (Criteria) this;
}
public Criteria andCourseIdGreaterThanOrEqualTo(String value) {
addCriterion("course_id >=", value, "courseId");
public Criteria andSourceGreaterThanOrEqualTo(String value) {
addCriterion("source >=", value, "source");
return (Criteria) this;
}
public Criteria andCourseIdLessThan(String value) {
addCriterion("course_id <", value, "courseId");
public Criteria andSourceLessThan(String value) {
addCriterion("source <", value, "source");
return (Criteria) this;
}
public Criteria andCourseIdLessThanOrEqualTo(String value) {
addCriterion("course_id <=", value, "courseId");
public Criteria andSourceLessThanOrEqualTo(String value) {
addCriterion("source <=", value, "source");
return (Criteria) this;
}
public Criteria andCourseIdLike(String value) {
addCriterion("course_id like", value, "courseId");
public Criteria andSourceLike(String value) {
addCriterion("source like", value, "source");
return (Criteria) this;
}
public Criteria andCourseIdNotLike(String value) {
addCriterion("course_id not like", value, "courseId");
public Criteria andSourceNotLike(String value) {
addCriterion("source not like", value, "source");
return (Criteria) this;
}
public Criteria andCourseIdIn(List<String> values) {
addCriterion("course_id in", values, "courseId");
public Criteria andSourceIn(List<String> values) {
addCriterion("source in", values, "source");
return (Criteria) this;
}
public Criteria andCourseIdNotIn(List<String> values) {
addCriterion("course_id not in", values, "courseId");
public Criteria andSourceNotIn(List<String> values) {
addCriterion("source not in", values, "source");
return (Criteria) this;
}
public Criteria andCourseIdBetween(String value1, String value2) {
addCriterion("course_id between", value1, value2, "courseId");
public Criteria andSourceBetween(String value1, String value2) {
addCriterion("source between", value1, value2, "source");
return (Criteria) this;
}
public Criteria andCourseIdNotBetween(String value1, String value2) {
addCriterion("course_id not between", value1, value2, "courseId");
return (Criteria) this;
}
public Criteria andCourseNameIsNull() {
addCriterion("course_name is null");
return (Criteria) this;
}
public Criteria andCourseNameIsNotNull() {
addCriterion("course_name is not null");
return (Criteria) this;
}
public Criteria andCourseNameEqualTo(String value) {
addCriterion("course_name =", value, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameNotEqualTo(String value) {
addCriterion("course_name <>", value, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameGreaterThan(String value) {
addCriterion("course_name >", value, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameGreaterThanOrEqualTo(String value) {
addCriterion("course_name >=", value, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameLessThan(String value) {
addCriterion("course_name <", value, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameLessThanOrEqualTo(String value) {
addCriterion("course_name <=", value, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameLike(String value) {
addCriterion("course_name like", value, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameNotLike(String value) {
addCriterion("course_name not like", value, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameIn(List<String> values) {
addCriterion("course_name in", values, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameNotIn(List<String> values) {
addCriterion("course_name not in", values, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameBetween(String value1, String value2) {
addCriterion("course_name between", value1, value2, "courseName");
return (Criteria) this;
}
public Criteria andCourseNameNotBetween(String value1, String value2) {
addCriterion("course_name not between", value1, value2, "courseName");
return (Criteria) this;
}
public Criteria andChapterIdIsNull() {
addCriterion("chapter_id is null");
return (Criteria) this;
}
public Criteria andChapterIdIsNotNull() {
addCriterion("chapter_id is not null");
return (Criteria) this;
}
public Criteria andChapterIdEqualTo(String value) {
addCriterion("chapter_id =", value, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdNotEqualTo(String value) {
addCriterion("chapter_id <>", value, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdGreaterThan(String value) {
addCriterion("chapter_id >", value, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdGreaterThanOrEqualTo(String value) {
addCriterion("chapter_id >=", value, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdLessThan(String value) {
addCriterion("chapter_id <", value, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdLessThanOrEqualTo(String value) {
addCriterion("chapter_id <=", value, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdLike(String value) {
addCriterion("chapter_id like", value, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdNotLike(String value) {
addCriterion("chapter_id not like", value, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdIn(List<String> values) {
addCriterion("chapter_id in", values, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdNotIn(List<String> values) {
addCriterion("chapter_id not in", values, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdBetween(String value1, String value2) {
addCriterion("chapter_id between", value1, value2, "chapterId");
return (Criteria) this;
}
public Criteria andChapterIdNotBetween(String value1, String value2) {
addCriterion("chapter_id not between", value1, value2, "chapterId");
return (Criteria) this;
}
public Criteria andChapterNameIsNull() {
addCriterion("chapter_name is null");
return (Criteria) this;
}
public Criteria andChapterNameIsNotNull() {
addCriterion("chapter_name is not null");
return (Criteria) this;
}
public Criteria andChapterNameEqualTo(String value) {
addCriterion("chapter_name =", value, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameNotEqualTo(String value) {
addCriterion("chapter_name <>", value, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameGreaterThan(String value) {
addCriterion("chapter_name >", value, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameGreaterThanOrEqualTo(String value) {
addCriterion("chapter_name >=", value, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameLessThan(String value) {
addCriterion("chapter_name <", value, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameLessThanOrEqualTo(String value) {
addCriterion("chapter_name <=", value, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameLike(String value) {
addCriterion("chapter_name like", value, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameNotLike(String value) {
addCriterion("chapter_name not like", value, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameIn(List<String> values) {
addCriterion("chapter_name in", values, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameNotIn(List<String> values) {
addCriterion("chapter_name not in", values, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameBetween(String value1, String value2) {
addCriterion("chapter_name between", value1, value2, "chapterName");
return (Criteria) this;
}
public Criteria andChapterNameNotBetween(String value1, String value2) {
addCriterion("chapter_name not between", value1, value2, "chapterName");
return (Criteria) this;
}
public Criteria andInputTypeIsNull() {
addCriterion("input_type is null");
return (Criteria) this;
}
public Criteria andInputTypeIsNotNull() {
addCriterion("input_type is not null");
return (Criteria) this;
}
public Criteria andInputTypeEqualTo(String value) {
addCriterion("input_type =", value, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeNotEqualTo(String value) {
addCriterion("input_type <>", value, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeGreaterThan(String value) {
addCriterion("input_type >", value, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeGreaterThanOrEqualTo(String value) {
addCriterion("input_type >=", value, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeLessThan(String value) {
addCriterion("input_type <", value, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeLessThanOrEqualTo(String value) {
addCriterion("input_type <=", value, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeLike(String value) {
addCriterion("input_type like", value, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeNotLike(String value) {
addCriterion("input_type not like", value, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeIn(List<String> values) {
addCriterion("input_type in", values, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeNotIn(List<String> values) {
addCriterion("input_type not in", values, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeBetween(String value1, String value2) {
addCriterion("input_type between", value1, value2, "inputType");
return (Criteria) this;
}
public Criteria andInputTypeNotBetween(String value1, String value2) {
addCriterion("input_type not between", value1, value2, "inputType");
return (Criteria) this;
}
public Criteria andTypeIsNull() {
addCriterion("type is null");
return (Criteria) this;
}
public Criteria andTypeIsNotNull() {
addCriterion("type is not null");
return (Criteria) this;
}
public Criteria andTypeEqualTo(String value) {
addCriterion("type =", value, "type");
return (Criteria) this;
}
public Criteria andTypeNotEqualTo(String value) {
addCriterion("type <>", value, "type");
return (Criteria) this;
}
public Criteria andTypeGreaterThan(String value) {
addCriterion("type >", value, "type");
return (Criteria) this;
}
public Criteria andTypeGreaterThanOrEqualTo(String value) {
addCriterion("type >=", value, "type");
return (Criteria) this;
}
public Criteria andTypeLessThan(String value) {
addCriterion("type <", value, "type");
return (Criteria) this;
}
public Criteria andTypeLessThanOrEqualTo(String value) {
addCriterion("type <=", value, "type");
return (Criteria) this;
}
public Criteria andTypeLike(String value) {
addCriterion("type like", value, "type");
return (Criteria) this;
}
public Criteria andTypeNotLike(String value) {
addCriterion("type not like", value, "type");
return (Criteria) this;
}
public Criteria andTypeIn(List<String> values) {
addCriterion("type in", values, "type");
return (Criteria) this;
}
public Criteria andTypeNotIn(List<String> values) {
addCriterion("type not in", values, "type");
return (Criteria) this;
}
public Criteria andTypeBetween(String value1, String value2) {
addCriterion("type between", value1, value2, "type");
return (Criteria) this;
}
public Criteria andTypeNotBetween(String value1, String value2) {
addCriterion("type not between", value1, value2, "type");
return (Criteria) this;
}
public Criteria andScoreIsNull() {
addCriterion("score is null");
return (Criteria) this;
}
public Criteria andScoreIsNotNull() {
addCriterion("score is not null");
return (Criteria) this;
}
public Criteria andScoreEqualTo(BigDecimal value) {
addCriterion("score =", value, "score");
return (Criteria) this;
}
public Criteria andScoreNotEqualTo(BigDecimal value) {
addCriterion("score <>", value, "score");
return (Criteria) this;
}
public Criteria andScoreGreaterThan(BigDecimal value) {
addCriterion("score >", value, "score");
return (Criteria) this;
}
public Criteria andScoreGreaterThanOrEqualTo(BigDecimal value) {
addCriterion("score >=", value, "score");
return (Criteria) this;
}
public Criteria andScoreLessThan(BigDecimal value) {
addCriterion("score <", value, "score");
return (Criteria) this;
}
public Criteria andScoreLessThanOrEqualTo(BigDecimal value) {
addCriterion("score <=", value, "score");
return (Criteria) this;
}
public Criteria andScoreIn(List<BigDecimal> values) {
addCriterion("score in", values, "score");
return (Criteria) this;
}
public Criteria andScoreNotIn(List<BigDecimal> values) {
addCriterion("score not in", values, "score");
return (Criteria) this;
}
public Criteria andScoreBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("score between", value1, value2, "score");
return (Criteria) this;
}
public Criteria andScoreNotBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("score not between", value1, value2, "score");
public Criteria andSourceNotBetween(String value1, String value2) {
addCriterion("source not between", value1, value2, "source");
return (Criteria) this;
}
@ -1075,6 +666,66 @@ public class SysObjectiveQuestionsExample {
return (Criteria) this;
}
public Criteria andScoreIsNull() {
addCriterion("score is null");
return (Criteria) this;
}
public Criteria andScoreIsNotNull() {
addCriterion("score is not null");
return (Criteria) this;
}
public Criteria andScoreEqualTo(BigDecimal value) {
addCriterion("score =", value, "score");
return (Criteria) this;
}
public Criteria andScoreNotEqualTo(BigDecimal value) {
addCriterion("score <>", value, "score");
return (Criteria) this;
}
public Criteria andScoreGreaterThan(BigDecimal value) {
addCriterion("score >", value, "score");
return (Criteria) this;
}
public Criteria andScoreGreaterThanOrEqualTo(BigDecimal value) {
addCriterion("score >=", value, "score");
return (Criteria) this;
}
public Criteria andScoreLessThan(BigDecimal value) {
addCriterion("score <", value, "score");
return (Criteria) this;
}
public Criteria andScoreLessThanOrEqualTo(BigDecimal value) {
addCriterion("score <=", value, "score");
return (Criteria) this;
}
public Criteria andScoreIn(List<BigDecimal> values) {
addCriterion("score in", values, "score");
return (Criteria) this;
}
public Criteria andScoreNotIn(List<BigDecimal> values) {
addCriterion("score not in", values, "score");
return (Criteria) this;
}
public Criteria andScoreBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("score between", value1, value2, "score");
return (Criteria) this;
}
public Criteria andScoreNotBetween(BigDecimal value1, BigDecimal value2) {
addCriterion("score not between", value1, value2, "score");
return (Criteria) this;
}
public Criteria andAnswerIsNull() {
addCriterion("answer is null");
return (Criteria) this;
@ -1215,73 +866,253 @@ public class SysObjectiveQuestionsExample {
return (Criteria) this;
}
public Criteria andSchoolIdIsNull() {
addCriterion("school_id is null");
public Criteria andTypeIsNull() {
addCriterion("type is null");
return (Criteria) this;
}
public Criteria andTypeIsNotNull() {
addCriterion("type is not null");
return (Criteria) this;
}
public Criteria andTypeEqualTo(String value) {
addCriterion("type =", value, "type");
return (Criteria) this;
}
public Criteria andTypeNotEqualTo(String value) {
addCriterion("type <>", value, "type");
return (Criteria) this;
}
public Criteria andTypeGreaterThan(String value) {
addCriterion("type >", value, "type");
return (Criteria) this;
}
public Criteria andTypeGreaterThanOrEqualTo(String value) {
addCriterion("type >=", value, "type");
return (Criteria) this;
}
public Criteria andTypeLessThan(String value) {
addCriterion("type <", value, "type");
return (Criteria) this;
}
public Criteria andTypeLessThanOrEqualTo(String value) {
addCriterion("type <=", value, "type");
return (Criteria) this;
}
public Criteria andTypeLike(String value) {
addCriterion("type like", value, "type");
return (Criteria) this;
}
public Criteria andTypeNotLike(String value) {
addCriterion("type not like", value, "type");
return (Criteria) this;
}
public Criteria andTypeIn(List<String> values) {
addCriterion("type in", values, "type");
return (Criteria) this;
}
public Criteria andTypeNotIn(List<String> values) {
addCriterion("type not in", values, "type");
return (Criteria) this;
}
public Criteria andTypeBetween(String value1, String value2) {
addCriterion("type between", value1, value2, "type");
return (Criteria) this;
}
public Criteria andTypeNotBetween(String value1, String value2) {
addCriterion("type not between", value1, value2, "type");
return (Criteria) this;
}
public Criteria andCreateTimeIsNull() {
addCriterion("create_time is null");
return (Criteria) this;
}
public Criteria andCreateTimeIsNotNull() {
addCriterion("create_time is not null");
return (Criteria) this;
}
public Criteria andCreateTimeEqualTo(Date value) {
addCriterion("create_time =", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotEqualTo(Date value) {
addCriterion("create_time <>", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeGreaterThan(Date value) {
addCriterion("create_time >", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) {
addCriterion("create_time >=", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeLessThan(Date value) {
addCriterion("create_time <", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeLessThanOrEqualTo(Date value) {
addCriterion("create_time <=", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeIn(List<Date> values) {
addCriterion("create_time in", values, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotIn(List<Date> values) {
addCriterion("create_time not in", values, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeBetween(Date value1, Date value2) {
addCriterion("create_time between", value1, value2, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotBetween(Date value1, Date value2) {
addCriterion("create_time not between", value1, value2, "createTime");
return (Criteria) this;
}
public Criteria andUpdateTimeIsNull() {
addCriterion("update_time is null");
return (Criteria) this;
}
public Criteria andUpdateTimeIsNotNull() {
addCriterion("update_time is not null");
return (Criteria) this;
}
public Criteria andUpdateTimeEqualTo(Date value) {
addCriterion("update_time =", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeNotEqualTo(Date value) {
addCriterion("update_time <>", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeGreaterThan(Date value) {
addCriterion("update_time >", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) {
addCriterion("update_time >=", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeLessThan(Date value) {
addCriterion("update_time <", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeLessThanOrEqualTo(Date value) {
addCriterion("update_time <=", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeIn(List<Date> values) {
addCriterion("update_time in", values, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeNotIn(List<Date> values) {
addCriterion("update_time not in", values, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeBetween(Date value1, Date value2) {
addCriterion("update_time between", value1, value2, "updateTime");
return (Criteria) this;
}
public Criteria andSchoolIdIsNotNull() {
addCriterion("school_id is not null");
public Criteria andUpdateTimeNotBetween(Date value1, Date value2) {
addCriterion("update_time not between", value1, value2, "updateTime");
return (Criteria) this;
}
public Criteria andSchoolIdEqualTo(String value) {
addCriterion("school_id =", value, "schoolId");
public Criteria andIsDeleteIsNull() {
addCriterion("is_delete is null");
return (Criteria) this;
}
public Criteria andSchoolIdNotEqualTo(String value) {
addCriterion("school_id <>", value, "schoolId");
public Criteria andIsDeleteIsNotNull() {
addCriterion("is_delete is not null");
return (Criteria) this;
}
public Criteria andSchoolIdGreaterThan(String value) {
addCriterion("school_id >", value, "schoolId");
public Criteria andIsDeleteEqualTo(Boolean value) {
addCriterion("is_delete =", value, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdGreaterThanOrEqualTo(String value) {
addCriterion("school_id >=", value, "schoolId");
public Criteria andIsDeleteNotEqualTo(Boolean value) {
addCriterion("is_delete <>", value, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdLessThan(String value) {
addCriterion("school_id <", value, "schoolId");
public Criteria andIsDeleteGreaterThan(Boolean value) {
addCriterion("is_delete >", value, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdLessThanOrEqualTo(String value) {
addCriterion("school_id <=", value, "schoolId");
public Criteria andIsDeleteGreaterThanOrEqualTo(Boolean value) {
addCriterion("is_delete >=", value, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdLike(String value) {
addCriterion("school_id like", value, "schoolId");
public Criteria andIsDeleteLessThan(Boolean value) {
addCriterion("is_delete <", value, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdNotLike(String value) {
addCriterion("school_id not like", value, "schoolId");
public Criteria andIsDeleteLessThanOrEqualTo(Boolean value) {
addCriterion("is_delete <=", value, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdIn(List<String> values) {
addCriterion("school_id in", values, "schoolId");
public Criteria andIsDeleteIn(List<Boolean> values) {
addCriterion("is_delete in", values, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdNotIn(List<String> values) {
addCriterion("school_id not in", values, "schoolId");
public Criteria andIsDeleteNotIn(List<Boolean> values) {
addCriterion("is_delete not in", values, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdBetween(String value1, String value2) {
addCriterion("school_id between", value1, value2, "schoolId");
public Criteria andIsDeleteBetween(Boolean value1, Boolean value2) {
addCriterion("is_delete between", value1, value2, "isDelete");
return (Criteria) this;
}
public Criteria andSchoolIdNotBetween(String value1, String value2) {
addCriterion("school_id not between", value1, value2, "schoolId");
public Criteria andIsDeleteNotBetween(Boolean value1, Boolean value2) {
addCriterion("is_delete not between", value1, value2, "isDelete");
return (Criteria) this;
}
}

@ -2,12 +2,11 @@ package com.sztzjy.resource_center.mapper;
import com.sztzjy.resource_center.entity.SysObjectiveQuestions;
import com.sztzjy.resource_center.entity.SysObjectiveQuestionsExample;
import java.util.List;
import com.sztzjy.resource_center.entity.dto.SysObjectiveQuestionsDto;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;
@Mapper
public interface SysObjectiveQuestionsMapper {
long countByExample(SysObjectiveQuestionsExample example);
@ -32,8 +31,10 @@ public interface SysObjectiveQuestionsMapper {
int updateByPrimaryKey(SysObjectiveQuestions record);
List<SysObjectiveQuestionsDto> selectTopicByConditions(@Param("oneID") String oneID,
List<SysObjectiveQuestionsDto> selectTopicByConditions(@Param("oneID")String oneID,
@Param("twoID") String twoID,
@Param("threeID") String threeID,
@Param("content") String content);
int insertBatch(@Param("objectiveQuestionList") List<SysObjectiveQuestions> objectiveQuestionList);
}

@ -34,8 +34,8 @@ public interface SysResourceAndCourseMapper {
void batchDeleteByIds(@Param("idList") List<String> idList);
@Select("SELECT resource_id FROM sys_resource_and_course where one_id = #{oneId} and two_id = #{twoID} and three_id = #{threeID}")
List<String> selectResourceId(@Param("oneId") String oneID,
// @Select("SELECT resource_id FROM sys_resource_and_course where one_id = #{oneId} and two_id = #{twoID} and three_id = #{threeID}")
List<String> selectResourceId(@Param("oneID") String oneID,
@Param("twoID") String twoID,
@Param("threeID") String threeID);

@ -11,7 +11,7 @@ spring:
# 文件存储
file:
type: local
# path: /usr/local/tianzeProject/resource_center/uploadFile
# path: /usr/local/tianzeProject/resourceCenter/uploadFile
path: D:/home
timer:
enable: false

@ -44,9 +44,9 @@
<!-- <table tableName="sys_case_question_steps" domainObjectName="SysCaseQuestionStep" />-->
<!-- <table tableName="sys_model" domainObjectName="SysModel" />-->
<!-- <table tableName="sys_model_question" domainObjectName="SysModelQuestion" />-->
<!-- <table tableName="sys_objective_question" domainObjectName="SysObjectiveQuestions" />-->
<table tableName="sys_objective_questions" domainObjectName="SysObjectiveQuestions" />
<!-- <table tableName="sys_one_catalog" domainObjectName="SysOneCatalog" />-->
<table tableName="sys_resource" domainObjectName="SysResource" />
<!-- <table tableName="sys_resource" domainObjectName="SysResource" />-->
<!-- <table tableName="sys_resource_and_course" domainObjectName="SysResourceAndCourse" />-->
<!-- <table tableName="sys_resource_data" domainObjectName="SysResourceData" />-->
<!-- <table tableName="sys_school" domainObjectName="SysSchool" />-->

@ -1,397 +1,444 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.sztzjy.resource_center.mapper.SysCaseQuestionMapper">
<resultMap id="BaseResultMap" type="com.sztzjy.resource_center.entity.SysCaseQuestion">
<id column="case_id" jdbcType="VARCHAR" property="caseId"/>
<result column="title" jdbcType="VARCHAR" property="title"/>
<result column="resource_data" jdbcType="VARCHAR" property="resourceData"/>
<result column="source" jdbcType="VARCHAR" property="source"/>
<result column="type" jdbcType="VARCHAR" property="type"/>
<result column="one_id" jdbcType="VARCHAR" property="oneId"/>
<result column="two_id" jdbcType="VARCHAR" property="twoId"/>
<result column="three" jdbcType="VARCHAR" property="three"/>
<result column="unmount_status" jdbcType="BIT" property="unmountStatus"/>
<result column="create_time" jdbcType="TIMESTAMP" property="createTime"/>
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime"/>
</resultMap>
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.sztzjy.resource_center.entity.SysCaseQuestion">
<result column="content" jdbcType="LONGVARCHAR" property="content"/>
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="("
separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
<resultMap id="BaseResultMap" type="com.sztzjy.resource_center.entity.SysCaseQuestion">
<id column="case_id" jdbcType="VARCHAR" property="caseId" />
<result column="title" jdbcType="VARCHAR" property="title" />
<result column="resource_data" jdbcType="VARCHAR" property="resourceData" />
<result column="source" jdbcType="VARCHAR" property="source" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="one_id" jdbcType="VARCHAR" property="oneId" />
<result column="one_name" jdbcType="VARCHAR" property="oneName" />
<result column="two_id" jdbcType="VARCHAR" property="twoId" />
<result column="two_name" jdbcType="VARCHAR" property="twoName" />
<result column="three_id" jdbcType="VARCHAR" property="threeId" />
<result column="three_name" jdbcType="VARCHAR" property="threeName" />
<result column="unmount_status" jdbcType="BIT" property="unmountStatus" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
</resultMap>
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.sztzjy.resource_center.entity.SysCaseQuestion">
<result column="content" jdbcType="LONGVARCHAR" property="content" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="("
separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
case_id
, title, resource_data, source, type, one_id, two_id, three, unmount_status,
create_time, update_time
</sql>
<sql id="Blob_Column_List">
content
</sql>
<select id="selectByExampleWithBLOBs" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestionExample"
resultMap="ResultMapWithBLOBs">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List"/>
,
<include refid="Blob_Column_List"/>
from sys_case_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause"/>
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByExample" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestionExample"
resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List"/>
from sys_case_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause"/>
</trim>
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="ResultMapWithBLOBs">
select
<include refid="Base_Column_List"/>
,
<include refid="Blob_Column_List"/>
from sys_case_questions
where case_id = #{caseId,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete
from sys_case_questions
where case_id = #{caseId,jdbcType=VARCHAR}
</delete>
<delete id="deleteByExample" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestionExample">
delete from sys_case_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause"/>
</if>
</delete>
<insert id="insert" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
insert into sys_case_questions (case_id, title, resource_data,
source, type, one_id,
two_id, three, unmount_status,
create_time, update_time, content)
values (#{caseId,jdbcType=VARCHAR}, #{title,jdbcType=VARCHAR}, #{resourceData,jdbcType=VARCHAR},
#{source,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{oneId,jdbcType=VARCHAR},
#{twoId,jdbcType=VARCHAR}, #{three,jdbcType=VARCHAR}, #{unmountStatus,jdbcType=BIT},
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{content,jdbcType=LONGVARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
insert into sys_case_questions
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="caseId != null">
case_id,
</if>
<if test="title != null">
title,
</if>
<if test="resourceData != null">
resource_data,
</if>
<if test="source != null">
source,
</if>
<if test="type != null">
type,
</if>
<if test="oneId != null">
one_id,
</if>
<if test="twoId != null">
two_id,
</if>
<if test="three != null">
three,
</if>
<if test="unmountStatus != null">
unmount_status,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="content != null">
content,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="caseId != null">
#{caseId,jdbcType=VARCHAR},
</if>
<if test="title != null">
#{title,jdbcType=VARCHAR},
</if>
<if test="resourceData != null">
#{resourceData,jdbcType=VARCHAR},
</if>
<if test="source != null">
#{source,jdbcType=VARCHAR},
</if>
<if test="type != null">
#{type,jdbcType=VARCHAR},
</if>
<if test="oneId != null">
#{oneId,jdbcType=VARCHAR},
</if>
<if test="twoId != null">
#{twoId,jdbcType=VARCHAR},
</if>
<if test="three != null">
#{three,jdbcType=VARCHAR},
</if>
<if test="unmountStatus != null">
#{unmountStatus,jdbcType=BIT},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="content != null">
#{content,jdbcType=LONGVARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestionExample"
resultType="java.lang.Long">
select count(*) from sys_case_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause"/>
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update sys_case_questions
<set>
<if test="record.caseId != null">
case_id = #{record.caseId,jdbcType=VARCHAR},
</if>
<if test="record.title != null">
title = #{record.title,jdbcType=VARCHAR},
</if>
<if test="record.resourceData != null">
resource_data = #{record.resourceData,jdbcType=VARCHAR},
</if>
<if test="record.source != null">
source = #{record.source,jdbcType=VARCHAR},
</if>
<if test="record.type != null">
type = #{record.type,jdbcType=VARCHAR},
</if>
<if test="record.oneId != null">
one_id = #{record.oneId,jdbcType=VARCHAR},
</if>
<if test="record.twoId != null">
two_id = #{record.twoId,jdbcType=VARCHAR},
</if>
<if test="record.three != null">
three = #{record.three,jdbcType=VARCHAR},
</if>
<if test="record.unmountStatus != null">
unmount_status = #{record.unmountStatus,jdbcType=BIT},
</if>
<if test="record.createTime != null">
create_time = #{record.createTime,jdbcType=TIMESTAMP},
</if>
<if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if>
<if test="record.content != null">
content = #{record.content,jdbcType=LONGVARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause"/>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</update>
<update id="updateByExampleWithBLOBs" parameterType="map">
update sys_case_questions
set case_id = #{record.caseId,jdbcType=VARCHAR},
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
case_id, title, resource_data, source, type, one_id, one_name, two_id, two_name,
three_id, three_name, unmount_status, create_time, update_time
</sql>
<sql id="Blob_Column_List">
content
</sql>
<select id="selectByExampleWithBLOBs" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestionExample" resultMap="ResultMapWithBLOBs">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
,
<include refid="Blob_Column_List" />
from sys_case_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByExample" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestionExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from sys_case_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="ResultMapWithBLOBs">
select
<include refid="Base_Column_List" />
,
<include refid="Blob_Column_List" />
from sys_case_questions
where case_id = #{caseId,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from sys_case_questions
where case_id = #{caseId,jdbcType=VARCHAR}
</delete>
<delete id="deleteByExample" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestionExample">
delete from sys_case_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
insert into sys_case_questions (case_id, title, resource_data,
source, type, one_id,
one_name, two_id, two_name,
three_id, three_name, unmount_status,
create_time, update_time, content
)
values (#{caseId,jdbcType=VARCHAR}, #{title,jdbcType=VARCHAR}, #{resourceData,jdbcType=VARCHAR},
#{source,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{oneId,jdbcType=VARCHAR},
#{oneName,jdbcType=VARCHAR}, #{twoId,jdbcType=VARCHAR}, #{twoName,jdbcType=VARCHAR},
#{threeId,jdbcType=VARCHAR}, #{threeName,jdbcType=VARCHAR}, #{unmountStatus,jdbcType=BIT},
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{content,jdbcType=LONGVARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
insert into sys_case_questions
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="caseId != null">
case_id,
</if>
<if test="title != null">
title,
</if>
<if test="resourceData != null">
resource_data,
</if>
<if test="source != null">
source,
</if>
<if test="type != null">
type,
</if>
<if test="oneId != null">
one_id,
</if>
<if test="oneName != null">
one_name,
</if>
<if test="twoId != null">
two_id,
</if>
<if test="twoName != null">
two_name,
</if>
<if test="threeId != null">
three_id,
</if>
<if test="threeName != null">
three_name,
</if>
<if test="unmountStatus != null">
unmount_status,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="content != null">
content,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="caseId != null">
#{caseId,jdbcType=VARCHAR},
</if>
<if test="title != null">
#{title,jdbcType=VARCHAR},
</if>
<if test="resourceData != null">
#{resourceData,jdbcType=VARCHAR},
</if>
<if test="source != null">
#{source,jdbcType=VARCHAR},
</if>
<if test="type != null">
#{type,jdbcType=VARCHAR},
</if>
<if test="oneId != null">
#{oneId,jdbcType=VARCHAR},
</if>
<if test="oneName != null">
#{oneName,jdbcType=VARCHAR},
</if>
<if test="twoId != null">
#{twoId,jdbcType=VARCHAR},
</if>
<if test="twoName != null">
#{twoName,jdbcType=VARCHAR},
</if>
<if test="threeId != null">
#{threeId,jdbcType=VARCHAR},
</if>
<if test="threeName != null">
#{threeName,jdbcType=VARCHAR},
</if>
<if test="unmountStatus != null">
#{unmountStatus,jdbcType=BIT},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="content != null">
#{content,jdbcType=LONGVARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestionExample" resultType="java.lang.Long">
select count(*) from sys_case_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update sys_case_questions
<set>
<if test="record.caseId != null">
case_id = #{record.caseId,jdbcType=VARCHAR},
</if>
<if test="record.title != null">
title = #{record.title,jdbcType=VARCHAR},
</if>
<if test="record.resourceData != null">
resource_data = #{record.resourceData,jdbcType=VARCHAR},
</if>
<if test="record.source != null">
source = #{record.source,jdbcType=VARCHAR},
</if>
<if test="record.type != null">
type = #{record.type,jdbcType=VARCHAR},
</if>
<if test="record.oneId != null">
one_id = #{record.oneId,jdbcType=VARCHAR},
</if>
<if test="record.oneName != null">
one_name = #{record.oneName,jdbcType=VARCHAR},
</if>
<if test="record.twoId != null">
two_id = #{record.twoId,jdbcType=VARCHAR},
three = #{record.three,jdbcType=VARCHAR},
</if>
<if test="record.twoName != null">
two_name = #{record.twoName,jdbcType=VARCHAR},
</if>
<if test="record.threeId != null">
three_id = #{record.threeId,jdbcType=VARCHAR},
</if>
<if test="record.threeName != null">
three_name = #{record.threeName,jdbcType=VARCHAR},
</if>
<if test="record.unmountStatus != null">
unmount_status = #{record.unmountStatus,jdbcType=BIT},
</if>
<if test="record.createTime != null">
create_time = #{record.createTime,jdbcType=TIMESTAMP},
</if>
<if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
content = #{record.content,jdbcType=LONGVARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause"/>
</if>
</update>
<update id="updateByExample" parameterType="map">
update sys_case_questions
set case_id = #{record.caseId,jdbcType=VARCHAR},
title = #{record.title,jdbcType=VARCHAR},
resource_data = #{record.resourceData,jdbcType=VARCHAR},
source = #{record.source,jdbcType=VARCHAR},
type = #{record.type,jdbcType=VARCHAR},
one_id = #{record.oneId,jdbcType=VARCHAR},
two_id = #{record.twoId,jdbcType=VARCHAR},
three = #{record.three,jdbcType=VARCHAR},
unmount_status = #{record.unmountStatus,jdbcType=BIT},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_time = #{record.updateTime,jdbcType=TIMESTAMP}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause"/>
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
update sys_case_questions
<set>
<if test="title != null">
title = #{title,jdbcType=VARCHAR},
</if>
<if test="resourceData != null">
resource_data = #{resourceData,jdbcType=VARCHAR},
</if>
<if test="source != null">
source = #{source,jdbcType=VARCHAR},
</if>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="oneId != null">
one_id = #{oneId,jdbcType=VARCHAR},
</if>
<if test="twoId != null">
two_id = #{twoId,jdbcType=VARCHAR},
</if>
<if test="three != null">
three = #{three,jdbcType=VARCHAR},
</if>
<if test="unmountStatus != null">
unmount_status = #{unmountStatus,jdbcType=BIT},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="content != null">
content = #{content,jdbcType=LONGVARCHAR},
</if>
</set>
where case_id = #{caseId,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKeyWithBLOBs" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
update sys_case_questions
set title = #{title,jdbcType=VARCHAR},
resource_data = #{resourceData,jdbcType=VARCHAR},
source = #{source,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
one_id = #{oneId,jdbcType=VARCHAR},
two_id = #{twoId,jdbcType=VARCHAR},
three = #{three,jdbcType=VARCHAR},
unmount_status = #{unmountStatus,jdbcType=BIT},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP},
content = #{content,jdbcType=LONGVARCHAR}
where case_id = #{caseId,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
update sys_case_questions
set title = #{title,jdbcType=VARCHAR},
resource_data = #{resourceData,jdbcType=VARCHAR},
source = #{source,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
one_id = #{oneId,jdbcType=VARCHAR},
two_id = #{twoId,jdbcType=VARCHAR},
three = #{three,jdbcType=VARCHAR},
unmount_status = #{unmountStatus,jdbcType=BIT},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP}
where case_id = #{caseId,jdbcType=VARCHAR}
</update>
<!--条件查询-->
<select id="selectCaseByConditions" parameterType="java.lang.String" resultMap="BaseResultMap">
select * from sys_case_question s
<where>
<if test="oneId != null and oneId != ''">
s.one_id = #{oneId}
</if>
<if test="title != null and title != ''">
and s.title = #{title}
</if>
and s.unmount_status is false
</where>
</select>
</if>
<if test="record.content != null">
content = #{record.content,jdbcType=LONGVARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExampleWithBLOBs" parameterType="map">
update sys_case_questions
set case_id = #{record.caseId,jdbcType=VARCHAR},
title = #{record.title,jdbcType=VARCHAR},
resource_data = #{record.resourceData,jdbcType=VARCHAR},
source = #{record.source,jdbcType=VARCHAR},
type = #{record.type,jdbcType=VARCHAR},
one_id = #{record.oneId,jdbcType=VARCHAR},
one_name = #{record.oneName,jdbcType=VARCHAR},
two_id = #{record.twoId,jdbcType=VARCHAR},
two_name = #{record.twoName,jdbcType=VARCHAR},
three_id = #{record.threeId,jdbcType=VARCHAR},
three_name = #{record.threeName,jdbcType=VARCHAR},
unmount_status = #{record.unmountStatus,jdbcType=BIT},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
content = #{record.content,jdbcType=LONGVARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update sys_case_questions
set case_id = #{record.caseId,jdbcType=VARCHAR},
title = #{record.title,jdbcType=VARCHAR},
resource_data = #{record.resourceData,jdbcType=VARCHAR},
source = #{record.source,jdbcType=VARCHAR},
type = #{record.type,jdbcType=VARCHAR},
one_id = #{record.oneId,jdbcType=VARCHAR},
one_name = #{record.oneName,jdbcType=VARCHAR},
two_id = #{record.twoId,jdbcType=VARCHAR},
two_name = #{record.twoName,jdbcType=VARCHAR},
three_id = #{record.threeId,jdbcType=VARCHAR},
three_name = #{record.threeName,jdbcType=VARCHAR},
unmount_status = #{record.unmountStatus,jdbcType=BIT},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_time = #{record.updateTime,jdbcType=TIMESTAMP}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
update sys_case_questions
<set>
<if test="title != null">
title = #{title,jdbcType=VARCHAR},
</if>
<if test="resourceData != null">
resource_data = #{resourceData,jdbcType=VARCHAR},
</if>
<if test="source != null">
source = #{source,jdbcType=VARCHAR},
</if>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="oneId != null">
one_id = #{oneId,jdbcType=VARCHAR},
</if>
<if test="oneName != null">
one_name = #{oneName,jdbcType=VARCHAR},
</if>
<if test="twoId != null">
two_id = #{twoId,jdbcType=VARCHAR},
</if>
<if test="twoName != null">
two_name = #{twoName,jdbcType=VARCHAR},
</if>
<if test="threeId != null">
three_id = #{threeId,jdbcType=VARCHAR},
</if>
<if test="threeName != null">
three_name = #{threeName,jdbcType=VARCHAR},
</if>
<if test="unmountStatus != null">
unmount_status = #{unmountStatus,jdbcType=BIT},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="content != null">
content = #{content,jdbcType=LONGVARCHAR},
</if>
</set>
where case_id = #{caseId,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKeyWithBLOBs" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
update sys_case_questions
set title = #{title,jdbcType=VARCHAR},
resource_data = #{resourceData,jdbcType=VARCHAR},
source = #{source,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
one_id = #{oneId,jdbcType=VARCHAR},
one_name = #{oneName,jdbcType=VARCHAR},
two_id = #{twoId,jdbcType=VARCHAR},
two_name = #{twoName,jdbcType=VARCHAR},
three_id = #{threeId,jdbcType=VARCHAR},
three_name = #{threeName,jdbcType=VARCHAR},
unmount_status = #{unmountStatus,jdbcType=BIT},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP},
content = #{content,jdbcType=LONGVARCHAR}
where case_id = #{caseId,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sztzjy.resource_center.entity.SysCaseQuestion">
update sys_case_questions
set title = #{title,jdbcType=VARCHAR},
resource_data = #{resourceData,jdbcType=VARCHAR},
source = #{source,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
one_id = #{oneId,jdbcType=VARCHAR},
one_name = #{oneName,jdbcType=VARCHAR},
two_id = #{twoId,jdbcType=VARCHAR},
two_name = #{twoName,jdbcType=VARCHAR},
three_id = #{threeId,jdbcType=VARCHAR},
three_name = #{threeName,jdbcType=VARCHAR},
unmount_status = #{unmountStatus,jdbcType=BIT},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP}
where case_id = #{caseId,jdbcType=VARCHAR}
</update>
<!--条件查询-->
<select id="selectCaseByConditions" parameterType="java.lang.String" resultMap="BaseResultMap">
select * from sys_case_questions s
<where>
<if test="oneId != null and oneId != ''">
s.one_id = #{oneId}
</if>
<if test="title != null and title != ''">
and s.title = #{title}
</if>
and s.unmount_status is false
</where>
</select>
</mapper>

@ -16,7 +16,7 @@
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="is_delete" jdbcType="TINYINT" property="isDelete" />
<result column="is_delete" jdbcType="BIT" property="isDelete" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
@ -86,7 +86,7 @@
distinct
</if>
<include refid="Base_Column_List" />
from sys_objective_question
from sys_objective_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
@ -97,21 +97,21 @@
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from sys_objective_question
from sys_objective_questions
where objective_id = #{objectiveId,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from sys_objective_question
delete from sys_objective_questions
where objective_id = #{objectiveId,jdbcType=VARCHAR}
</delete>
<delete id="deleteByExample" parameterType="com.sztzjy.resource_center.entity.SysObjectiveQuestionsExample">
delete from sys_objective_question
delete from sys_objective_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.sztzjy.resource_center.entity.SysObjectiveQuestions">
insert into sys_objective_question (objective_id, source, content,
insert into sys_objective_questions (objective_id, source, content,
question_a, question_b, question_c,
question_d, question_e, score,
answer, analysis, type,
@ -121,11 +121,11 @@
#{questionA,jdbcType=VARCHAR}, #{questionB,jdbcType=VARCHAR}, #{questionC,jdbcType=VARCHAR},
#{questionD,jdbcType=VARCHAR}, #{questionE,jdbcType=VARCHAR}, #{score,jdbcType=DECIMAL},
#{answer,jdbcType=VARCHAR}, #{analysis,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR},
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{isDelete,jdbcType=TINYINT}
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{isDelete,jdbcType=BIT}
)
</insert>
<insert id="insertSelective" parameterType="com.sztzjy.resource_center.entity.SysObjectiveQuestions">
insert into sys_objective_question
insert into sys_objective_questions
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="objectiveId != null">
objective_id,
@ -217,18 +217,18 @@
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="isDelete != null">
#{isDelete,jdbcType=TINYINT},
#{isDelete,jdbcType=BIT},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.sztzjy.resource_center.entity.SysObjectiveQuestionsExample" resultType="java.lang.Long">
select count(*) from sys_objective_question
select count(*) from sys_objective_questions
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update sys_objective_question
update sys_objective_questions
<set>
<if test="record.objectiveId != null">
objective_id = #{record.objectiveId,jdbcType=VARCHAR},
@ -273,7 +273,7 @@
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if>
<if test="record.isDelete != null">
is_delete = #{record.isDelete,jdbcType=TINYINT},
is_delete = #{record.isDelete,jdbcType=BIT},
</if>
</set>
<if test="_parameter != null">
@ -281,7 +281,7 @@
</if>
</update>
<update id="updateByExample" parameterType="map">
update sys_objective_question
update sys_objective_questions
set objective_id = #{record.objectiveId,jdbcType=VARCHAR},
source = #{record.source,jdbcType=VARCHAR},
content = #{record.content,jdbcType=VARCHAR},
@ -296,13 +296,13 @@
type = #{record.type,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
is_delete = #{record.isDelete,jdbcType=TINYINT}
is_delete = #{record.isDelete,jdbcType=BIT}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.sztzjy.resource_center.entity.SysObjectiveQuestions">
update sys_objective_question
update sys_objective_questions
<set>
<if test="source != null">
source = #{source,jdbcType=VARCHAR},
@ -344,13 +344,13 @@
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="isDelete != null">
is_delete = #{isDelete,jdbcType=TINYINT},
is_delete = #{isDelete,jdbcType=BIT},
</if>
</set>
where objective_id = #{objectiveId,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sztzjy.resource_center.entity.SysObjectiveQuestions">
update sys_objective_question
update sys_objective_questions
set source = #{source,jdbcType=VARCHAR},
content = #{content,jdbcType=VARCHAR},
question_a = #{questionA,jdbcType=VARCHAR},
@ -364,7 +364,7 @@
type = #{type,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_time = #{updateTime,jdbcType=TIMESTAMP},
is_delete = #{isDelete,jdbcType=TINYINT}
is_delete = #{isDelete,jdbcType=BIT}
where objective_id = #{objectiveId,jdbcType=VARCHAR}
</update>
@ -408,7 +408,18 @@
<if test="content != null and content != ''">
and sb.content = #{content}
</if>
</where>
</where>>
order by sb.create_time
</select>
<insert id="insertBatch" parameterType="java.util.List">
INSERT INTO sys_objective_questions (
objective_id, source, content, question_a, question_b, question_c, question_d, question_e, score, answer, analysis, type, create_time, update_time, is_delete
) VALUES
<foreach collection="objectiveQuestionList" item="item" index="index" separator=",">
(
#{item.objectiveId}, #{item.source}, #{item.content}, #{item.questionA}, #{item.questionB}, #{item.questionC}, #{item.questionD}, #{item.questionE}, #{item.score}, #{item.answer}, #{item.analysis}, #{item.type}, #{item.createTime}, #{item.updateTime}, #{item.isDelete}
)
</foreach>
</insert>
</mapper>

@ -239,4 +239,19 @@
</foreach>
</insert>
<select id="selectResourceId" parameterType="java.lang.String" resultType="java.lang.String">
SELECT resource_id FROM sys_resource_and_course
<where>
<if test="oneID != null and oneID !=''">
one_id = #{oneID}
</if>
<if test="twoID != null and twoID !=''">
and two_id = #{twoID}
</if>
<if test="threeID != null and threeID !=''">
and three_id = #{threeID}
</if>
</where>
</select>
</mapper>

@ -354,10 +354,9 @@
<select id="selectResource" parameterType="java.lang.String" resultMap="BaseResultMap">
SELECT *
FROM sys_resource
join
<where>
<if test="oneId != null and oneId != ''">
ont_tag = #{oneId}
one_tag = #{oneId}
</if>
<if test="twoId != null and twoId != ''">
and two_tag = #{twoId}

Loading…
Cancel
Save