diff --git a/src/main/java/com/sztzjy/resource_center/controller/CourseConfigController.java b/src/main/java/com/sztzjy/resource_center/controller/CourseConfigController.java index 0554a35..9394add 100644 --- a/src/main/java/com/sztzjy/resource_center/controller/CourseConfigController.java +++ b/src/main/java/com/sztzjy/resource_center/controller/CourseConfigController.java @@ -1,16 +1,15 @@ package com.sztzjy.resource_center.controller; import cn.hutool.core.util.IdUtil; +import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageInfo; import com.sztzjy.resource_center.annotation.AnonymousAccess; import com.sztzjy.resource_center.entity.SysResource; import com.sztzjy.resource_center.entity.SysResourceAndCourse; import com.sztzjy.resource_center.entity.SysResourceAndCourseExample; -import com.sztzjy.resource_center.entity.SysResourceExample; import com.sztzjy.resource_center.entity.dto.SysResourceDto; import com.sztzjy.resource_center.mapper.SysResourceAndCourseMapper; import com.sztzjy.resource_center.mapper.SysResourceMapper; -import com.sztzjy.resource_center.util.PageUtil; import com.sztzjy.resource_center.util.ResultEntity; import com.sztzjy.resource_center.util.file.IFileUtil; import io.swagger.annotations.Api; @@ -22,7 +21,6 @@ import org.springframework.http.HttpStatus; import org.springframework.web.bind.annotation.*; import org.springframework.web.multipart.MultipartFile; -import java.util.Arrays; import java.util.Date; import java.util.List; @@ -76,12 +74,6 @@ public class CourseConfigController { String uuid = IdUtil.randomUUID(); sysResource.setResourceId(uuid); sysResource.setPictureUrl(pictureName); - sysResource.setOneTag(dto.getOneId()); - sysResource.setOneName(dto.getOneName()); - sysResource.setTwoTag(dto.getTwoId()); - sysResource.setTwoName(dto.getTwoName()); - sysResource.setThreeTag(dto.getThreeId()); - sysResource.setThreeName(dto.getThreeName()); sysResource.setUrl(url); sysResource.setSource(dto.getSource()); //管理员或者 xx学校 sysResource.setResourceName(dto.getResourceName()); @@ -95,6 +87,9 @@ public class CourseConfigController { sysResourceAndCourse.setOneId(dto.getOneId()); sysResourceAndCourse.setTwoId(dto.getTwoId()); sysResourceAndCourse.setThreeId(dto.getThreeId()); + sysResourceAndCourse.setOneName(dto.getOneName()); + sysResourceAndCourse.setTwoName(dto.getTwoName()); + sysResourceAndCourse.setThreeName(dto.getThreeName()); sysResourceAndCourse.setResourceId(uuid); //资源ID sysResourceAndCourseMapper.insert(sysResourceAndCourse); return new ResultEntity<>(HttpStatus.OK, "上传成功!"); @@ -124,30 +119,18 @@ public class CourseConfigController { @AnonymousAccess - @ApiOperation("课程配置/资源列表展示") + @ApiOperation("课程配置/资源列表展示,无重复") @PostMapping("selectResourceByIDAndSource") - public ResultEntity> selectResource(@ApiParam("课程ID") @RequestParam String oneID, - @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 list = sysResourceAndCourseMapper.selectResourceId(oneID, twoID, threeID); - if (list == null || list.isEmpty()) { - return new ResultEntity>(new PageInfo<>()); - } - SysResourceExample example = new SysResourceExample(); - SysResourceExample.Criteria criteria = example.createCriteria(); - criteria.andResourceIdIn(list); - //不为空子系统调用 - if (StringUtils.isNotBlank(source)) { - List sources = Arrays.asList(source, "内置"); - criteria.andSourceIn(sources); - } - example.setOrderByClause("create_time ASC"); - List sysResources = sysResourceMapper.selectByExample(example); - PageInfo pageInfo = PageUtil.pageHelper(sysResources, index, size); - return new ResultEntity>(pageInfo); + public ResultEntity> selectResource(@ApiParam("课程ID") @RequestParam String oneID, + @ApiParam("章ID") @RequestParam String twoID, + @ApiParam("节ID") @RequestParam String threeID, + @RequestParam(required = false) String source, //子系统调用时传 + @RequestParam Integer index, + @RequestParam Integer size) { + PageHelper.startPage(index, size); + List sysResourceDtos = sysResourceMapper.selectResource(oneID, twoID, threeID); + PageInfo pageInfo = new PageInfo(sysResourceDtos); + return new ResultEntity>(pageInfo); } diff --git a/src/main/java/com/sztzjy/resource_center/controller/LearningResourceController.java b/src/main/java/com/sztzjy/resource_center/controller/LearningResourceController.java index ded7ff0..a73c42f 100644 --- a/src/main/java/com/sztzjy/resource_center/controller/LearningResourceController.java +++ b/src/main/java/com/sztzjy/resource_center/controller/LearningResourceController.java @@ -4,6 +4,7 @@ import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageInfo; import com.sztzjy.resource_center.annotation.AnonymousAccess; import com.sztzjy.resource_center.entity.SysResource; +import com.sztzjy.resource_center.entity.dto.SysResourceDto; import com.sztzjy.resource_center.mapper.SysResourceMapper; import com.sztzjy.resource_center.util.ResultEntity; import io.swagger.annotations.Api; @@ -36,21 +37,23 @@ public class LearningResourceController { private String filePath; + @AnonymousAccess - @ApiOperation("学习资源/资源列表展示") - @PostMapping("selectResource") - public ResultEntity> selectResource(@ApiParam("课程ID") @RequestParam(required = false) String oneID, - @ApiParam("章ID") @RequestParam(required = false) String twoID, - @ApiParam("节ID") @RequestParam(required = false) String threeID, - @ApiParam("资源名称") @RequestParam(required = false) String resourceName, - @RequestParam Integer index, - @RequestParam Integer size) { + @ApiOperation("学习资源/资源列表展示/有重复数据") + @PostMapping("selectResourceByRepeat") + public ResultEntity> selectResourceByRepeat(@ApiParam("课程ID") @RequestParam(required = false) String oneID, + @ApiParam("章ID") @RequestParam(required = false) String twoID, + @ApiParam("节ID") @RequestParam(required = false) String threeID, + @ApiParam("资源名称") @RequestParam(required = false) String resourceName, + @RequestParam Integer index, + @RequestParam Integer size) { PageHelper.startPage(index, size); - List sysResourceDtos = sysResourceMapper.selectResource(oneID, twoID, threeID, resourceName); - PageInfo pageInfo = new PageInfo(sysResourceDtos); - return new ResultEntity>(pageInfo); + List sysResourceDtos = sysResourceMapper.selectResourceByRepeat(oneID, twoID, threeID, resourceName); + PageInfo pageInfo = new PageInfo(sysResourceDtos); + return new ResultEntity>(pageInfo); } + @AnonymousAccess @ApiOperation("学习资源/删除") //同步过来的不做删除 @PostMapping("deleteResource") diff --git a/src/main/java/com/sztzjy/resource_center/controller/TopicResourceController.java b/src/main/java/com/sztzjy/resource_center/controller/TopicResourceController.java index 78c8cb0..a477257 100644 --- a/src/main/java/com/sztzjy/resource_center/controller/TopicResourceController.java +++ b/src/main/java/com/sztzjy/resource_center/controller/TopicResourceController.java @@ -49,6 +49,8 @@ public class TopicResourceController { @Value("${file.path}") private String filePath; + + @AnonymousAccess @ApiOperation("新增单个试题") //新增 题干不允许重复 @PostMapping("addTopic") private ResultEntity addTopic(@RequestBody SysObjectiveQuestionsDto objectiveQuestion) { @@ -97,11 +99,11 @@ public class TopicResourceController { sysTopicAndCourse.setOneId(objectiveQuestion.getOneID()); sysTopicAndCourse.setOneName(objectiveQuestion.getOneName()); if (StringUtils.isNotBlank(objectiveQuestion.getTwoID())) { - sysTopicAndCourse.setTwoId(sysTopicAndCourse.getTwoId()); + sysTopicAndCourse.setTwoId(objectiveQuestion.getTwoID()); sysTopicAndCourse.setTwoName(objectiveQuestion.getTwoName()); } if (StringUtils.isNotBlank(objectiveQuestion.getThreeID())) { - sysTopicAndCourse.setThreeId(sysTopicAndCourse.getThreeId()); + sysTopicAndCourse.setThreeId(objectiveQuestion.getThreeID()); sysTopicAndCourse.setThreeName(objectiveQuestion.getThreeName()); } sysTopicAndCourseMapper.insert(sysTopicAndCourse); @@ -153,26 +155,69 @@ public class TopicResourceController { @AnonymousAccess - @ApiOperation("条件查询") + @ApiOperation("条件查询/不重复") @PostMapping("selectTopicByConditions") //todo 关于老师删除的题库如何查询 private ResultEntity> selectTopicByConditions(@RequestParam Integer index, @RequestParam Integer size, - @RequestParam(required = false) String oneID, - @RequestParam(required = false) String twoID, - @RequestParam(required = false) String threeID, + @RequestParam String oneID, + @RequestParam String twoID, + @RequestParam String threeID, @RequestParam(required = false) String type, @ApiParam("题干") @RequestParam(required = false) String content) { PageHelper.startPage(index, size); - List list = sysObjectiveQuestionMapper.selectTopicByConditions(oneID, twoID, threeID, type,content); + List list = sysObjectiveQuestionMapper.selectTopicByConditions(oneID, twoID, threeID, type, content); PageInfo pageInfo = new PageInfo(list); return new ResultEntity>(pageInfo); } + + @AnonymousAccess + @ApiOperation("课程配置/题目条件查询") + @PostMapping("getTopicByConfig") //todo 关于老师删除的题库如何查询 + private ResultEntity> getTopicByConfig(@RequestParam Integer index, + @RequestParam Integer size, + @RequestParam(required = false) String oneID, + @RequestParam(required = false) String twoID, + @RequestParam(required = false) String threeID, + @RequestParam(required = false) String type, + @ApiParam("题干") @RequestParam(required = false) String content) { + PageHelper.startPage(index, size); + List list = sysObjectiveQuestionMapper.getTopicByConfig(oneID, twoID, threeID, type, content); + PageInfo pageInfo = new PageInfo(list); + return new ResultEntity>(pageInfo); +// SysTopicAndCourseExample example = new SysTopicAndCourseExample(); +// SysTopicAndCourseExample.Criteria criteria = example.createCriteria(); +// if (StringUtils.isNotBlank(oneID)) { +// criteria.andOneIdEqualTo(oneID); +// } +// if (StringUtils.isNotBlank(twoID)) { +// criteria.andTwoIdEqualTo(twoID); +// } +// if (StringUtils.isNotBlank(threeID)) { +// criteria.andThreeIdEqualTo(threeID); +// } +// List sysTopicAndCourses = sysTopicAndCourseMapper.selectByExample(example); +// List collect = sysTopicAndCourses.stream().map(SysTopicAndCourse::getTopicId).collect(Collectors.toList()); +// SysObjectiveQuestionsExample example1 = new SysObjectiveQuestionsExample(); +// SysObjectiveQuestionsExample.Criteria criteria1 = example1.createCriteria(); +// if (StringUtils.isNotBlank(type)) { +// criteria1.andTypeEqualTo(type); +// } +// if (StringUtils.isNotBlank(content)) { +// criteria1.andContentLike(content); +// } +// criteria1.andObjectiveIdIn(collect); +// List sysObjectiveQuestions = sysObjectiveQuestionMapper.selectByExample(example1); +// PageInfo pageInfo = PageUtil.pageHelper(sysObjectiveQuestions, index, size); +// return new ResultEntity>(pageInfo); + } + + //老师新增的题目正在使用的话资源中心只能查看,不能编辑和删除, // 如果老师自己删除了这个题目,资源中心题库管理也可以编辑和删除。如果题目正在被使用,则删除的时候提示:题目被xx课程xx章节使用,不能删除。 @ApiOperation("编辑") @PostMapping("updateTopic") - private ResultEntity updateTopic(@ApiParam("修改绑定关系需要传topicAndCourseId") @RequestParam SysObjectiveQuestionsDto dto) { + private ResultEntity updateTopic(@ApiParam("修改绑定关系需要传topicAndCourseId") @RequestBody SysObjectiveQuestionsDto dto) { if (!dto.getSource().equals("管理员")) { //老师新增的不能编辑 SysTopicAndCourseExample example = new SysTopicAndCourseExample(); example.createCriteria().andTopicIdEqualTo(dto.getObjectiveId()); @@ -194,12 +239,25 @@ public class TopicResourceController { return new ResultEntity<>(HttpStatus.BAD_REQUEST, "编辑完成!"); } - + @AnonymousAccess @ApiOperation("删除题目绑定关系") @PostMapping("deleteTopicBinding") - private ResultEntity deleteTopicBinding(@RequestParam String id) { + private ResultEntity deleteTopicBinding(@RequestParam String id, + @RequestParam(required = false) String oneId, + @RequestParam(required = false) String twoId, + @RequestParam(required = false) String threeId) { SysTopicAndCourseExample example = new SysTopicAndCourseExample(); - example.createCriteria().andTopicTypeEqualTo(id); + SysTopicAndCourseExample.Criteria criteria = example.createCriteria(); + if (StringUtils.isNotBlank(oneId)) { + criteria.andOneIdEqualTo(oneId); + } + if (StringUtils.isNotBlank(twoId)) { + criteria.andTwoIdEqualTo(twoId); + } + if (StringUtils.isNotBlank(threeId)) { + criteria.andThreeIdEqualTo(threeId); + } + criteria.andTopicIdEqualTo(id); sysTopicAndCourseMapper.deleteByExample(example); return new ResultEntity<>(HttpStatus.OK, "成功删除绑定关系!"); } diff --git a/src/main/java/com/sztzjy/resource_center/entity/SysResourceAndCourse.java b/src/main/java/com/sztzjy/resource_center/entity/SysResourceAndCourse.java index 57bd452..37a1bc7 100644 --- a/src/main/java/com/sztzjy/resource_center/entity/SysResourceAndCourse.java +++ b/src/main/java/com/sztzjy/resource_center/entity/SysResourceAndCourse.java @@ -21,6 +21,12 @@ public class SysResourceAndCourse { @ApiModelProperty("三级目录ID/节ID") private String threeId; + private String oneName; + + private String twoName; + + private String threeName; + public String getId() { return id; } @@ -60,4 +66,28 @@ public class SysResourceAndCourse { public void setThreeId(String threeId) { this.threeId = threeId == null ? null : threeId.trim(); } + + public String getOneName() { + return oneName; + } + + public void setOneName(String oneName) { + this.oneName = oneName == null ? null : oneName.trim(); + } + + public String getTwoName() { + return twoName; + } + + public void setTwoName(String twoName) { + this.twoName = twoName == null ? null : twoName.trim(); + } + + public String getThreeName() { + return threeName; + } + + public void setThreeName(String threeName) { + this.threeName = threeName == null ? null : threeName.trim(); + } } \ No newline at end of file diff --git a/src/main/java/com/sztzjy/resource_center/entity/SysResourceAndCourseExample.java b/src/main/java/com/sztzjy/resource_center/entity/SysResourceAndCourseExample.java index 0097654..51d8d25 100644 --- a/src/main/java/com/sztzjy/resource_center/entity/SysResourceAndCourseExample.java +++ b/src/main/java/com/sztzjy/resource_center/entity/SysResourceAndCourseExample.java @@ -453,6 +453,216 @@ public class SysResourceAndCourseExample { addCriterion("three_id not between", value1, value2, "threeId"); 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 values) { + addCriterion("one_name in", values, "oneName"); + return (Criteria) this; + } + + public Criteria andOneNameNotIn(List 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 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 values) { + addCriterion("two_name in", values, "twoName"); + return (Criteria) this; + } + + public Criteria andTwoNameNotIn(List 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 andThreeNameIsNull() { + addCriterion("three_name is null"); + return (Criteria) this; + } + + public Criteria andThreeNameIsNotNull() { + addCriterion("three_name is not null"); + return (Criteria) this; + } + + public Criteria andThreeNameEqualTo(String value) { + addCriterion("three_name =", value, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameNotEqualTo(String value) { + addCriterion("three_name <>", value, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameGreaterThan(String value) { + addCriterion("three_name >", value, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameGreaterThanOrEqualTo(String value) { + addCriterion("three_name >=", value, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameLessThan(String value) { + addCriterion("three_name <", value, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameLessThanOrEqualTo(String value) { + addCriterion("three_name <=", value, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameLike(String value) { + addCriterion("three_name like", value, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameNotLike(String value) { + addCriterion("three_name not like", value, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameIn(List values) { + addCriterion("three_name in", values, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameNotIn(List values) { + addCriterion("three_name not in", values, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameBetween(String value1, String value2) { + addCriterion("three_name between", value1, value2, "threeName"); + return (Criteria) this; + } + + public Criteria andThreeNameNotBetween(String value1, String value2) { + addCriterion("three_name not between", value1, value2, "threeName"); + return (Criteria) this; + } } public static class Criteria extends GeneratedCriteria { diff --git a/src/main/java/com/sztzjy/resource_center/entity/dto/SysObjectiveQuestionsDto.java b/src/main/java/com/sztzjy/resource_center/entity/dto/SysObjectiveQuestionsDto.java index 84bd77d..af95cfc 100644 --- a/src/main/java/com/sztzjy/resource_center/entity/dto/SysObjectiveQuestionsDto.java +++ b/src/main/java/com/sztzjy/resource_center/entity/dto/SysObjectiveQuestionsDto.java @@ -2,8 +2,6 @@ package com.sztzjy.resource_center.entity.dto; import com.sztzjy.resource_center.entity.SysObjectiveQuestions; import lombok.Data; -import lombok.EqualsAndHashCode; -import lombok.ToString; /** * @Author xcj diff --git a/src/main/java/com/sztzjy/resource_center/mapper/SysObjectiveQuestionsMapper.java b/src/main/java/com/sztzjy/resource_center/mapper/SysObjectiveQuestionsMapper.java index 41c8f24..b5f2d73 100644 --- a/src/main/java/com/sztzjy/resource_center/mapper/SysObjectiveQuestionsMapper.java +++ b/src/main/java/com/sztzjy/resource_center/mapper/SysObjectiveQuestionsMapper.java @@ -38,4 +38,10 @@ public interface SysObjectiveQuestionsMapper { @Param("content") String content); int insertBatch(@Param("objectiveQuestionList") List objectiveQuestionList); + + List getTopicByConfig(@Param("oneID")String oneID, + @Param("twoID") String twoID, + @Param("threeID") String threeID, + @Param("type")String type, + @Param("content") String content); } \ No newline at end of file diff --git a/src/main/java/com/sztzjy/resource_center/mapper/SysResourceAndCourseMapper.java b/src/main/java/com/sztzjy/resource_center/mapper/SysResourceAndCourseMapper.java index 3c189cb..8423a8a 100644 --- a/src/main/java/com/sztzjy/resource_center/mapper/SysResourceAndCourseMapper.java +++ b/src/main/java/com/sztzjy/resource_center/mapper/SysResourceAndCourseMapper.java @@ -2,12 +2,10 @@ package com.sztzjy.resource_center.mapper; import com.sztzjy.resource_center.entity.SysResourceAndCourse; import com.sztzjy.resource_center.entity.SysResourceAndCourseExample; -import org.apache.ibatis.annotations.Mapper; -import org.apache.ibatis.annotations.Param; -import org.apache.ibatis.annotations.Select; - import java.util.List; +import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; @Mapper public interface SysResourceAndCourseMapper { long countByExample(SysResourceAndCourseExample example); @@ -34,10 +32,10 @@ public interface SysResourceAndCourseMapper { void batchDeleteByIds(@Param("idList") List idList); -// @Select("SELECT resource_id FROM sys_resource_and_course where one_id = #{oneId} and two_id = #{twoID} and three_id = #{threeID}") List selectResourceId(@Param("oneID") String oneID, @Param("twoID") String twoID, @Param("threeID") String threeID); void batchInsert(@Param("resourceAndCourses") List resourceAndCourses); + } \ No newline at end of file diff --git a/src/main/java/com/sztzjy/resource_center/mapper/SysResourceMapper.java b/src/main/java/com/sztzjy/resource_center/mapper/SysResourceMapper.java index 1103cb7..608fa72 100644 --- a/src/main/java/com/sztzjy/resource_center/mapper/SysResourceMapper.java +++ b/src/main/java/com/sztzjy/resource_center/mapper/SysResourceMapper.java @@ -2,10 +2,13 @@ package com.sztzjy.resource_center.mapper; import com.sztzjy.resource_center.entity.SysResource; import com.sztzjy.resource_center.entity.SysResourceExample; + import java.util.List; +import com.sztzjy.resource_center.entity.dto.SysResourceDto; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; + @Mapper public interface SysResourceMapper { long countByExample(SysResourceExample example); @@ -31,8 +34,13 @@ public interface SysResourceMapper { int updateByPrimaryKey(SysResource record); - List selectResource(@Param("oneId") String oneId, - @Param("twoId") String twoId, - @Param("threeId") String threeId, - @Param("resourceName") String resourceName); + List selectResource(@Param("oneId") String oneId, + @Param("twoId") String twoId, + @Param("threeId") String threeId); + + List selectResourceByRepeat(@Param("oneId") String oneId, + @Param("twoId") String twoId, + @Param("threeId") String threeId, + @Param("resourceName") String resourceName); + } \ No newline at end of file diff --git a/src/main/resources/generatorConfig.xml b/src/main/resources/generatorConfig.xml index 9c7e753..83e804b 100644 --- a/src/main/resources/generatorConfig.xml +++ b/src/main/resources/generatorConfig.xml @@ -47,7 +47,7 @@ - + @@ -56,8 +56,8 @@ -
-
+ + diff --git a/src/main/resources/mapper/SysObjectiveQuestionsMapper.xml b/src/main/resources/mapper/SysObjectiveQuestionsMapper.xml index e92d3f2..504cd24 100644 --- a/src/main/resources/mapper/SysObjectiveQuestionsMapper.xml +++ b/src/main/resources/mapper/SysObjectiveQuestionsMapper.xml @@ -1,431 +1,466 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - + + + + + + + + + + + + + + + + + + + + + + + + + + and ${criterion.condition} + + + and ${criterion.condition} #{criterion.value} + + + and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} + + + and ${criterion.condition} + + #{listItem} + + + + + + - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - + + + + + + + + + + + and ${criterion.condition} + + + and ${criterion.condition} #{criterion.value} + + + and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} + + + and ${criterion.condition} + + #{listItem} + + + + + + - - - - - - - objective_id, source, content, question_a, question_b, question_c, question_d, question_e, + + + + objective_id + , source, content, question_a, question_b, question_c, question_d, question_e, score, answer, analysis, type, create_time, update_time, is_delete - - - - - delete from sys_objective_questions - where objective_id = #{objectiveId,jdbcType=VARCHAR} - - - delete from sys_objective_questions - - - - - - 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 (#{objectiveId,jdbcType=VARCHAR}, #{source,jdbcType=VARCHAR}, #{content,jdbcType=VARCHAR}, - #{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=BIT} - ) - - - 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, - - - - - #{objectiveId,jdbcType=VARCHAR}, - - - #{source,jdbcType=VARCHAR}, - - - #{content,jdbcType=VARCHAR}, - - - #{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=BIT}, - - - - - - update sys_objective_questions - - - objective_id = #{record.objectiveId,jdbcType=VARCHAR}, - - + + + + + delete + from sys_objective_questions + where objective_id = #{objectiveId,jdbcType=VARCHAR} + + + delete from sys_objective_questions + + + + + + 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 (#{objectiveId,jdbcType=VARCHAR}, #{source,jdbcType=VARCHAR}, #{content,jdbcType=VARCHAR}, + #{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=BIT}) + + + 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, + + + + + #{objectiveId,jdbcType=VARCHAR}, + + + #{source,jdbcType=VARCHAR}, + + + #{content,jdbcType=VARCHAR}, + + + #{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=BIT}, + + + + + + update sys_objective_questions + + + objective_id = #{record.objectiveId,jdbcType=VARCHAR}, + + + source = #{record.source,jdbcType=VARCHAR}, + + + content = #{record.content,jdbcType=VARCHAR}, + + + question_a = #{record.questionA,jdbcType=VARCHAR}, + + + question_b = #{record.questionB,jdbcType=VARCHAR}, + + + question_c = #{record.questionC,jdbcType=VARCHAR}, + + + question_d = #{record.questionD,jdbcType=VARCHAR}, + + + question_e = #{record.questionE,jdbcType=VARCHAR}, + + + score = #{record.score,jdbcType=DECIMAL}, + + + answer = #{record.answer,jdbcType=VARCHAR}, + + + analysis = #{record.analysis,jdbcType=VARCHAR}, + + + type = #{record.type,jdbcType=VARCHAR}, + + + create_time = #{record.createTime,jdbcType=TIMESTAMP}, + + + update_time = #{record.updateTime,jdbcType=TIMESTAMP}, + + + is_delete = #{record.isDelete,jdbcType=BIT}, + + + + + + + + update sys_objective_questions + set objective_id = #{record.objectiveId,jdbcType=VARCHAR}, source = #{record.source,jdbcType=VARCHAR}, - - content = #{record.content,jdbcType=VARCHAR}, - - question_a = #{record.questionA,jdbcType=VARCHAR}, - - question_b = #{record.questionB,jdbcType=VARCHAR}, - - question_c = #{record.questionC,jdbcType=VARCHAR}, - - question_d = #{record.questionD,jdbcType=VARCHAR}, - - question_e = #{record.questionE,jdbcType=VARCHAR}, - - score = #{record.score,jdbcType=DECIMAL}, - - answer = #{record.answer,jdbcType=VARCHAR}, - - analysis = #{record.analysis,jdbcType=VARCHAR}, - - type = #{record.type,jdbcType=VARCHAR}, - - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - - update_time = #{record.updateTime,jdbcType=TIMESTAMP}, - - - is_delete = #{record.isDelete,jdbcType=BIT}, - - - - - - - - update sys_objective_questions - set objective_id = #{record.objectiveId,jdbcType=VARCHAR}, - source = #{record.source,jdbcType=VARCHAR}, - content = #{record.content,jdbcType=VARCHAR}, - question_a = #{record.questionA,jdbcType=VARCHAR}, - question_b = #{record.questionB,jdbcType=VARCHAR}, - question_c = #{record.questionC,jdbcType=VARCHAR}, - question_d = #{record.questionD,jdbcType=VARCHAR}, - question_e = #{record.questionE,jdbcType=VARCHAR}, - score = #{record.score,jdbcType=DECIMAL}, - answer = #{record.answer,jdbcType=VARCHAR}, - analysis = #{record.analysis,jdbcType=VARCHAR}, - type = #{record.type,jdbcType=VARCHAR}, - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - update_time = #{record.updateTime,jdbcType=TIMESTAMP}, - is_delete = #{record.isDelete,jdbcType=BIT} - - - - - - update sys_objective_questions - - - source = #{source,jdbcType=VARCHAR}, - - - content = #{content,jdbcType=VARCHAR}, - - - question_a = #{questionA,jdbcType=VARCHAR}, - - - question_b = #{questionB,jdbcType=VARCHAR}, - - - question_c = #{questionC,jdbcType=VARCHAR}, - - - question_d = #{questionD,jdbcType=VARCHAR}, - - - question_e = #{questionE,jdbcType=VARCHAR}, - - - score = #{score,jdbcType=DECIMAL}, - - - answer = #{answer,jdbcType=VARCHAR}, - - - analysis = #{analysis,jdbcType=VARCHAR}, - - - type = #{type,jdbcType=VARCHAR}, - - - create_time = #{createTime,jdbcType=TIMESTAMP}, - - - update_time = #{updateTime,jdbcType=TIMESTAMP}, - - - is_delete = #{isDelete,jdbcType=BIT}, - - - where objective_id = #{objectiveId,jdbcType=VARCHAR} - - - update sys_objective_questions - set source = #{source,jdbcType=VARCHAR}, - content = #{content,jdbcType=VARCHAR}, - question_a = #{questionA,jdbcType=VARCHAR}, - question_b = #{questionB,jdbcType=VARCHAR}, - question_c = #{questionC,jdbcType=VARCHAR}, - question_d = #{questionD,jdbcType=VARCHAR}, - question_e = #{questionE,jdbcType=VARCHAR}, - score = #{score,jdbcType=DECIMAL}, - answer = #{answer,jdbcType=VARCHAR}, - analysis = #{analysis,jdbcType=VARCHAR}, - type = #{type,jdbcType=VARCHAR}, - create_time = #{createTime,jdbcType=TIMESTAMP}, - update_time = #{updateTime,jdbcType=TIMESTAMP}, - is_delete = #{isDelete,jdbcType=BIT} - where objective_id = #{objectiveId,jdbcType=VARCHAR} - + is_delete = #{record.isDelete,jdbcType=BIT} + + + + + + update sys_objective_questions + + + source = #{source,jdbcType=VARCHAR}, + + + content = #{content,jdbcType=VARCHAR}, + + + question_a = #{questionA,jdbcType=VARCHAR}, + + + question_b = #{questionB,jdbcType=VARCHAR}, + + + question_c = #{questionC,jdbcType=VARCHAR}, + + + question_d = #{questionD,jdbcType=VARCHAR}, + + + question_e = #{questionE,jdbcType=VARCHAR}, + + + score = #{score,jdbcType=DECIMAL}, + + + answer = #{answer,jdbcType=VARCHAR}, + + + analysis = #{analysis,jdbcType=VARCHAR}, + + + type = #{type,jdbcType=VARCHAR}, + + + create_time = #{createTime,jdbcType=TIMESTAMP}, + + + update_time = #{updateTime,jdbcType=TIMESTAMP}, + + + is_delete = #{isDelete,jdbcType=BIT}, + + + where objective_id = #{objectiveId,jdbcType=VARCHAR} + + + update sys_objective_questions + set source = #{source,jdbcType=VARCHAR}, + content = #{content,jdbcType=VARCHAR}, + question_a = #{questionA,jdbcType=VARCHAR}, + question_b = #{questionB,jdbcType=VARCHAR}, + question_c = #{questionC,jdbcType=VARCHAR}, + question_d = #{questionD,jdbcType=VARCHAR}, + question_e = #{questionE,jdbcType=VARCHAR}, + score = #{score,jdbcType=DECIMAL}, + answer = #{answer,jdbcType=VARCHAR}, + analysis = #{analysis,jdbcType=VARCHAR}, + type = #{type,jdbcType=VARCHAR}, + create_time = #{createTime,jdbcType=TIMESTAMP}, + update_time = #{updateTime,jdbcType=TIMESTAMP}, + is_delete = #{isDelete,jdbcType=BIT} + where objective_id = #{objectiveId,jdbcType=VARCHAR} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - + + - - - - 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 - - ( - #{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} - ) - - + + 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 + + ( + #{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} + ) + + \ No newline at end of file diff --git a/src/main/resources/mapper/SysResourceAndCourseMapper.xml b/src/main/resources/mapper/SysResourceAndCourseMapper.xml index 092dc16..35f00a7 100644 --- a/src/main/resources/mapper/SysResourceAndCourseMapper.xml +++ b/src/main/resources/mapper/SysResourceAndCourseMapper.xml @@ -7,6 +7,9 @@ + + + @@ -70,7 +73,7 @@ id - , resource_id, one_id, two_id, three_id + , resource_id, one_id, two_id, three_id, one_name, two_name, three_name three_id = #{record.threeId,jdbcType=VARCHAR}, + + one_name = #{record.oneName,jdbcType=VARCHAR}, + + + two_name = #{record.twoName,jdbcType=VARCHAR}, + + + three_name = #{record.threeName,jdbcType=VARCHAR}, + @@ -183,7 +215,10 @@ resource_id = #{record.resourceId,jdbcType=VARCHAR}, one_id = #{record.oneId,jdbcType=VARCHAR}, two_id = #{record.twoId,jdbcType=VARCHAR}, - three_id = #{record.threeId,jdbcType=VARCHAR} + three_id = #{record.threeId,jdbcType=VARCHAR}, + one_name = #{record.oneName,jdbcType=VARCHAR}, + two_name = #{record.twoName,jdbcType=VARCHAR}, + three_name = #{record.threeName,jdbcType=VARCHAR} @@ -203,6 +238,15 @@ three_id = #{threeId,jdbcType=VARCHAR}, + + one_name = #{oneName,jdbcType=VARCHAR}, + + + two_name = #{twoName,jdbcType=VARCHAR}, + + + three_name = #{threeName,jdbcType=VARCHAR}, + where id = #{id,jdbcType=VARCHAR} @@ -211,7 +255,10 @@ set resource_id = #{resourceId,jdbcType=VARCHAR}, one_id = #{oneId,jdbcType=VARCHAR}, two_id = #{twoId,jdbcType=VARCHAR}, - three_id = #{threeId,jdbcType=VARCHAR} + three_id = #{threeId,jdbcType=VARCHAR}, + one_name = #{oneName,jdbcType=VARCHAR}, + two_name = #{twoName,jdbcType=VARCHAR}, + three_name = #{threeName,jdbcType=VARCHAR} where id = #{id,jdbcType=VARCHAR} @@ -239,19 +286,4 @@ - - \ No newline at end of file diff --git a/src/main/resources/mapper/SysResourceMapper.xml b/src/main/resources/mapper/SysResourceMapper.xml index e49aeeb..7286adf 100644 --- a/src/main/resources/mapper/SysResourceMapper.xml +++ b/src/main/resources/mapper/SysResourceMapper.xml @@ -1,373 +1,415 @@ - - - - - - - - - - - - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - + + + + + + + + + + + + + + + + + + + + + + + + + and ${criterion.condition} + + + and ${criterion.condition} #{criterion.value} + + + and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} + + + and ${criterion.condition} + + #{listItem} + + + + + + - - - - - - - - - - - - - - and ${criterion.condition} - - - and ${criterion.condition} #{criterion.value} - - - and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} - - - and ${criterion.condition} - - #{listItem} - - - + + + + + + + + + + + and ${criterion.condition} + + + and ${criterion.condition} #{criterion.value} + + + and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} + + + and ${criterion.condition} + + #{listItem} + + + + + + - - - - - - - resource_id, resource_name, url, picture_url, resource_type, source, one_tag, one_name, + + + + resource_id + , resource_name, url, picture_url, resource_type, source, one_tag, one_name, two_tag, two_name, three_tag, three_name, status, create_time - - - - - delete from sys_resource - where resource_id = #{resourceId,jdbcType=VARCHAR} - - - delete from sys_resource - - - - - - insert into sys_resource (resource_id, resource_name, url, - picture_url, resource_type, source, - one_tag, one_name, two_tag, - two_name, three_tag, three_name, - status, create_time) - values (#{resourceId,jdbcType=VARCHAR}, #{resourceName,jdbcType=VARCHAR}, #{url,jdbcType=VARCHAR}, - #{pictureUrl,jdbcType=VARCHAR}, #{resourceType,jdbcType=VARCHAR}, #{source,jdbcType=VARCHAR}, - #{oneTag,jdbcType=VARCHAR}, #{oneName,jdbcType=VARCHAR}, #{twoTag,jdbcType=VARCHAR}, - #{twoName,jdbcType=VARCHAR}, #{threeTag,jdbcType=VARCHAR}, #{threeName,jdbcType=VARCHAR}, - #{status,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}) - - - insert into sys_resource - - - resource_id, - - - resource_name, - - - url, - - - picture_url, - - - resource_type, - - - source, - - - one_tag, - - - one_name, - - - two_tag, - - - two_name, - - - three_tag, - - - three_name, - - - status, - - - create_time, - - - - - #{resourceId,jdbcType=VARCHAR}, - - - #{resourceName,jdbcType=VARCHAR}, - - - #{url,jdbcType=VARCHAR}, - - - #{pictureUrl,jdbcType=VARCHAR}, - - - #{resourceType,jdbcType=VARCHAR}, - - - #{source,jdbcType=VARCHAR}, - - - #{oneTag,jdbcType=VARCHAR}, - - - #{oneName,jdbcType=VARCHAR}, - - - #{twoTag,jdbcType=VARCHAR}, - - - #{twoName,jdbcType=VARCHAR}, - - - #{threeTag,jdbcType=VARCHAR}, - - - #{threeName,jdbcType=VARCHAR}, - - - #{status,jdbcType=INTEGER}, - - - #{createTime,jdbcType=TIMESTAMP}, - - - - - - update sys_resource - - - resource_id = #{record.resourceId,jdbcType=VARCHAR}, - - + + + + + delete + from sys_resource + where resource_id = #{resourceId,jdbcType=VARCHAR} + + + delete from sys_resource + + + + + + insert into sys_resource (resource_id, resource_name, url, + picture_url, resource_type, source, + one_tag, one_name, two_tag, + two_name, three_tag, three_name, + status, create_time) + values (#{resourceId,jdbcType=VARCHAR}, #{resourceName,jdbcType=VARCHAR}, #{url,jdbcType=VARCHAR}, + #{pictureUrl,jdbcType=VARCHAR}, #{resourceType,jdbcType=VARCHAR}, #{source,jdbcType=VARCHAR}, + #{oneTag,jdbcType=VARCHAR}, #{oneName,jdbcType=VARCHAR}, #{twoTag,jdbcType=VARCHAR}, + #{twoName,jdbcType=VARCHAR}, #{threeTag,jdbcType=VARCHAR}, #{threeName,jdbcType=VARCHAR}, + #{status,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}) + + + insert into sys_resource + + + resource_id, + + + resource_name, + + + url, + + + picture_url, + + + resource_type, + + + source, + + + one_tag, + + + one_name, + + + two_tag, + + + two_name, + + + three_tag, + + + three_name, + + + status, + + + create_time, + + + + + #{resourceId,jdbcType=VARCHAR}, + + + #{resourceName,jdbcType=VARCHAR}, + + + #{url,jdbcType=VARCHAR}, + + + #{pictureUrl,jdbcType=VARCHAR}, + + + #{resourceType,jdbcType=VARCHAR}, + + + #{source,jdbcType=VARCHAR}, + + + #{oneTag,jdbcType=VARCHAR}, + + + #{oneName,jdbcType=VARCHAR}, + + + #{twoTag,jdbcType=VARCHAR}, + + + #{twoName,jdbcType=VARCHAR}, + + + #{threeTag,jdbcType=VARCHAR}, + + + #{threeName,jdbcType=VARCHAR}, + + + #{status,jdbcType=INTEGER}, + + + #{createTime,jdbcType=TIMESTAMP}, + + + + + + update sys_resource + + + resource_id = #{record.resourceId,jdbcType=VARCHAR}, + + + resource_name = #{record.resourceName,jdbcType=VARCHAR}, + + + url = #{record.url,jdbcType=VARCHAR}, + + + picture_url = #{record.pictureUrl,jdbcType=VARCHAR}, + + + resource_type = #{record.resourceType,jdbcType=VARCHAR}, + + + source = #{record.source,jdbcType=VARCHAR}, + + + one_tag = #{record.oneTag,jdbcType=VARCHAR}, + + + one_name = #{record.oneName,jdbcType=VARCHAR}, + + + two_tag = #{record.twoTag,jdbcType=VARCHAR}, + + + two_name = #{record.twoName,jdbcType=VARCHAR}, + + + three_tag = #{record.threeTag,jdbcType=VARCHAR}, + + + three_name = #{record.threeName,jdbcType=VARCHAR}, + + + status = #{record.status,jdbcType=INTEGER}, + + + create_time = #{record.createTime,jdbcType=TIMESTAMP}, + + + + + + + + update sys_resource + set resource_id = #{record.resourceId,jdbcType=VARCHAR}, resource_name = #{record.resourceName,jdbcType=VARCHAR}, - - url = #{record.url,jdbcType=VARCHAR}, - - picture_url = #{record.pictureUrl,jdbcType=VARCHAR}, - - resource_type = #{record.resourceType,jdbcType=VARCHAR}, - - source = #{record.source,jdbcType=VARCHAR}, - - one_tag = #{record.oneTag,jdbcType=VARCHAR}, - - one_name = #{record.oneName,jdbcType=VARCHAR}, - - two_tag = #{record.twoTag,jdbcType=VARCHAR}, - - two_name = #{record.twoName,jdbcType=VARCHAR}, - - three_tag = #{record.threeTag,jdbcType=VARCHAR}, - - three_name = #{record.threeName,jdbcType=VARCHAR}, - - status = #{record.status,jdbcType=INTEGER}, - - - create_time = #{record.createTime,jdbcType=TIMESTAMP}, - - - - - - - - update sys_resource - set resource_id = #{record.resourceId,jdbcType=VARCHAR}, - resource_name = #{record.resourceName,jdbcType=VARCHAR}, - url = #{record.url,jdbcType=VARCHAR}, - picture_url = #{record.pictureUrl,jdbcType=VARCHAR}, - resource_type = #{record.resourceType,jdbcType=VARCHAR}, - source = #{record.source,jdbcType=VARCHAR}, - one_tag = #{record.oneTag,jdbcType=VARCHAR}, - one_name = #{record.oneName,jdbcType=VARCHAR}, - two_tag = #{record.twoTag,jdbcType=VARCHAR}, - two_name = #{record.twoName,jdbcType=VARCHAR}, - three_tag = #{record.threeTag,jdbcType=VARCHAR}, - three_name = #{record.threeName,jdbcType=VARCHAR}, - status = #{record.status,jdbcType=INTEGER}, - create_time = #{record.createTime,jdbcType=TIMESTAMP} - - - - - - update sys_resource - - - resource_name = #{resourceName,jdbcType=VARCHAR}, - - - url = #{url,jdbcType=VARCHAR}, - - - picture_url = #{pictureUrl,jdbcType=VARCHAR}, - - - resource_type = #{resourceType,jdbcType=VARCHAR}, - - - source = #{source,jdbcType=VARCHAR}, - - - one_tag = #{oneTag,jdbcType=VARCHAR}, - - - one_name = #{oneName,jdbcType=VARCHAR}, - - - two_tag = #{twoTag,jdbcType=VARCHAR}, - - - two_name = #{twoName,jdbcType=VARCHAR}, - - - three_tag = #{threeTag,jdbcType=VARCHAR}, - - - three_name = #{threeName,jdbcType=VARCHAR}, - - - status = #{status,jdbcType=INTEGER}, - - - create_time = #{createTime,jdbcType=TIMESTAMP}, - - - where resource_id = #{resourceId,jdbcType=VARCHAR} - - - update sys_resource - set resource_name = #{resourceName,jdbcType=VARCHAR}, - url = #{url,jdbcType=VARCHAR}, - picture_url = #{pictureUrl,jdbcType=VARCHAR}, - resource_type = #{resourceType,jdbcType=VARCHAR}, - source = #{source,jdbcType=VARCHAR}, - one_tag = #{oneTag,jdbcType=VARCHAR}, - one_name = #{oneName,jdbcType=VARCHAR}, - two_tag = #{twoTag,jdbcType=VARCHAR}, - two_name = #{twoName,jdbcType=VARCHAR}, - three_tag = #{threeTag,jdbcType=VARCHAR}, - three_name = #{threeName,jdbcType=VARCHAR}, - status = #{status,jdbcType=INTEGER}, - create_time = #{createTime,jdbcType=TIMESTAMP} - where resource_id = #{resourceId,jdbcType=VARCHAR} - + create_time = #{record.createTime,jdbcType=TIMESTAMP} + + + + + + update sys_resource + + + resource_name = #{resourceName,jdbcType=VARCHAR}, + + + url = #{url,jdbcType=VARCHAR}, + + + picture_url = #{pictureUrl,jdbcType=VARCHAR}, + + + resource_type = #{resourceType,jdbcType=VARCHAR}, + + + source = #{source,jdbcType=VARCHAR}, + + + one_tag = #{oneTag,jdbcType=VARCHAR}, + + + one_name = #{oneName,jdbcType=VARCHAR}, + + + two_tag = #{twoTag,jdbcType=VARCHAR}, + + + two_name = #{twoName,jdbcType=VARCHAR}, + + + three_tag = #{threeTag,jdbcType=VARCHAR}, + + + three_name = #{threeName,jdbcType=VARCHAR}, + + + status = #{status,jdbcType=INTEGER}, + + + create_time = #{createTime,jdbcType=TIMESTAMP}, + + + where resource_id = #{resourceId,jdbcType=VARCHAR} + + + update sys_resource + set resource_name = #{resourceName,jdbcType=VARCHAR}, + url = #{url,jdbcType=VARCHAR}, + picture_url = #{pictureUrl,jdbcType=VARCHAR}, + resource_type = #{resourceType,jdbcType=VARCHAR}, + source = #{source,jdbcType=VARCHAR}, + one_tag = #{oneTag,jdbcType=VARCHAR}, + one_name = #{oneName,jdbcType=VARCHAR}, + two_tag = #{twoTag,jdbcType=VARCHAR}, + two_name = #{twoName,jdbcType=VARCHAR}, + three_tag = #{threeTag,jdbcType=VARCHAR}, + three_name = #{threeName,jdbcType=VARCHAR}, + status = #{status,jdbcType=INTEGER}, + create_time = #{createTime,jdbcType=TIMESTAMP} + where resource_id = #{resourceId,jdbcType=VARCHAR} + + + + + + + + + + + + + + + + + + + + + - + + \ No newline at end of file