Ver Fonte

/student/schoolRollFurtherEducation/page 增加status字段
/student/baseStudentBehaviorManage/mobile-page 返回assessmentUserName等字段值
/student/classHonors" 新增班级荣誉代码接口

phoenix há 1 ano atrás
pai
commit
16511807fe

+ 101 - 0
src/main/java/com/xjrsoft/module/student/controller/ClassHonorsController.java

@@ -0,0 +1,101 @@
+package com.xjrsoft.module.student.controller;
+
+import cn.hutool.core.bean.BeanUtil;
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.xjrsoft.common.page.ConventPage;
+import com.xjrsoft.common.page.PageOutput;
+import com.xjrsoft.common.model.result.RT;
+import com.xjrsoft.common.utils.VoToColumnUtil;
+import com.xjrsoft.module.student.dto.AddClassHonorsDto;
+import com.xjrsoft.module.student.dto.UpdateClassHonorsDto;
+import cn.dev33.satoken.annotation.SaCheckPermission;
+import com.alibaba.excel.EasyExcel;
+import org.springframework.web.multipart.MultipartFile;
+import java.io.IOException;
+
+import com.xjrsoft.module.student.dto.ClassHonorsPageDto;
+import com.xjrsoft.module.student.entity.ClassHonors;
+import com.xjrsoft.module.student.service.IClassHonorsService;
+import com.xjrsoft.module.student.vo.ClassHonorsPageVo;
+
+import com.xjrsoft.module.student.vo.ClassHonorsVo;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import lombok.AllArgsConstructor;
+import org.springframework.web.bind.annotation.*;
+
+import javax.validation.Valid;
+import java.util.List;
+
+/**
+* @title: 班级荣誉
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@RestController
+@RequestMapping("/student" + "/classHonors")
+@Api(value = "/student"  + "/classHonors",tags = "班级荣誉代码")
+@AllArgsConstructor
+public class ClassHonorsController {
+
+
+    private final IClassHonorsService classHonorsService;
+
+    @GetMapping(value = "/page")
+    @ApiOperation(value="班级荣誉列表(分页)")
+    @SaCheckPermission("classhonors:detail")
+    public RT<PageOutput<ClassHonorsPageVo>> page(@Valid ClassHonorsPageDto dto){
+        IPage<ClassHonorsPageVo> page = classHonorsService.getPagePC(dto);
+        PageOutput<ClassHonorsPageVo> pageOutput = ConventPage.getPageOutput(page, ClassHonorsPageVo.class);
+        return RT.ok(pageOutput);
+    }
+
+    @GetMapping(value = "/info")
+    @ApiOperation(value="根据id查询班级荣誉信息")
+    @SaCheckPermission("classhonors:detail")
+    public RT<ClassHonorsVo> info(@RequestParam Long id){
+        ClassHonorsVo classHonorsVo = classHonorsService.getInfoById(id);
+        if (classHonorsVo == null) {
+           return RT.error("找不到此数据!");
+        }
+        return RT.ok(classHonorsVo);
+    }
+
+
+    @PostMapping
+    @ApiOperation(value = "新增班级荣誉")
+    @SaCheckPermission("classhonors:add")
+    public RT<Boolean> add(@Valid @RequestBody AddClassHonorsDto dto){
+        ClassHonors classHonors = BeanUtil.toBean(dto, ClassHonors.class);
+        boolean isSuccess = classHonorsService.save(classHonors);
+    return RT.ok(isSuccess);
+    }
+
+    @PutMapping
+    @ApiOperation(value = "修改班级荣誉")
+    @SaCheckPermission("classhonors:edit")
+    public RT<Boolean> update(@Valid @RequestBody UpdateClassHonorsDto dto){
+
+        ClassHonors classHonors = BeanUtil.toBean(dto, ClassHonors.class);
+        return RT.ok(classHonorsService.updateById(classHonors));
+
+    }
+
+    @DeleteMapping
+    @ApiOperation(value = "删除班级荣誉")
+    @SaCheckPermission("classhonors:delete")
+    public RT<Boolean> delete(@Valid @RequestBody List<Long> ids){
+        return RT.ok(classHonorsService.removeBatchByIds(ids));
+
+    }
+    @PostMapping("/import")
+    @ApiOperation(value = "导入")
+    public RT<Boolean> importData(@RequestParam MultipartFile file) throws IOException {
+        List<ClassHonorsPageVo> savedDataList = EasyExcel.read(file.getInputStream()).head(ClassHonorsPageVo.class).sheet().doReadSync();
+        Boolean result = classHonorsService.saveBatch(BeanUtil.copyToList(savedDataList, ClassHonors.class));
+        return RT.ok(result);
+    }
+
+}

+ 68 - 0
src/main/java/com/xjrsoft/module/student/dto/AddClassHonorsDto.java

@@ -0,0 +1,68 @@
+package com.xjrsoft.module.student.dto;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import java.io.Serializable;
+import com.fasterxml.jackson.annotation.JsonFormat;
+
+import java.time.LocalTime;
+import java.time.LocalDateTime;
+import java.math.BigDecimal;
+import java.util.List;
+import java.util.Date;
+
+
+
+/**
+* @title: 班级荣誉
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Data
+public class AddClassHonorsDto implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+    * 序号
+    */
+    @ApiModelProperty("序号")
+    private Integer sortCode;
+    /**
+    * 学期ID(base_semester)
+    */
+    @ApiModelProperty("学期ID(base_semester)")
+    private Long baseSemesterId;
+    /**
+    * 班级id
+    */
+    @ApiModelProperty("班级id")
+    private Long classId;
+    /**
+    * 荣誉级别(xjr_dictionary_item[honors_level])
+    */
+    @ApiModelProperty("荣誉级别(xjr_dictionary_item[honors_level])")
+    private String honorsLevel;
+    /**
+    * 荣誉等级(xjr_dictionary_item[honors_grade])
+    */
+    @ApiModelProperty("荣誉等级(xjr_dictionary_item[honors_grade])")
+    private String honorsGrade;
+    /**
+    * 荣誉名称
+    */
+    @ApiModelProperty("荣誉名称")
+    private String name;
+    /**
+    * 获奖日期
+    */
+    @ApiModelProperty("获奖日期")
+    private Date awardDate;
+    /**
+    * 附件文件id
+    */
+    @ApiModelProperty("附件文件id")
+    private Long fileId;
+
+}

+ 40 - 0
src/main/java/com/xjrsoft/module/student/dto/ClassHonorsPageDto.java

@@ -0,0 +1,40 @@
+package com.xjrsoft.module.student.dto;
+
+import com.xjrsoft.common.page.PageInput;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import java.util.Date;
+
+
+/**
+* @title: 班级荣誉分页查询入参
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Data
+@EqualsAndHashCode(callSuper = false)
+public class ClassHonorsPageDto extends PageInput {
+
+    /**
+     * 荣誉级别(xjr_dictionary_item[honors_level])
+     */
+    @ApiModelProperty("荣誉级别(xjr_dictionary_item[honors_level])")
+    private String honorsLevel;
+    /**
+     * 荣誉等级(xjr_dictionary_item[honors_grade])
+     */
+    @ApiModelProperty("荣誉等级(xjr_dictionary_item[honors_grade])")
+    private String honorsGrade;
+    /**
+     * 获奖日期
+     */
+    @ApiModelProperty("获奖日期")
+    private Date awardDate;
+    /**
+     * 荣誉名称
+     */
+    @ApiModelProperty("荣誉名称")
+    private String name;
+}

+ 32 - 0
src/main/java/com/xjrsoft/module/student/dto/UpdateClassHonorsDto.java

@@ -0,0 +1,32 @@
+package com.xjrsoft.module.student.dto;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import java.io.Serializable;
+
+import java.time.LocalTime;
+import java.time.LocalDateTime;
+import java.math.BigDecimal;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import java.util.List;
+import java.util.Date;
+
+
+
+/**
+* @title: 班级荣誉
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Data
+public class UpdateClassHonorsDto extends AddClassHonorsDto {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+    * 主键编号
+    */
+    @ApiModelProperty("主键编号")
+    private Long id;
+}

+ 118 - 0
src/main/java/com/xjrsoft/module/student/entity/ClassHonors.java

@@ -0,0 +1,118 @@
+package com.xjrsoft.module.student.entity;
+
+import com.baomidou.mybatisplus.annotation.FieldFill;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.github.yulichang.annotation.EntityMapping;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import java.io.Serializable;
+import java.time.LocalTime;
+import java.time.LocalDateTime;
+import java.math.BigDecimal;
+import java.util.List;
+import java.util.Date;
+
+
+/**
+* @title: 班级荣誉
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Data
+@TableName("class_honors")
+@ApiModel(value = "class_honors", description = "班级荣誉")
+public class ClassHonors implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+    * 主键编号
+    */
+    @ApiModelProperty("主键编号")
+    @TableId
+    private Long id;
+    /**
+    * 创建人
+    */
+    @ApiModelProperty("创建人")
+    @TableField(fill = FieldFill.INSERT)
+    private Long createUserId;
+    /**
+    * 创建时间
+    */
+    @ApiModelProperty("创建时间")
+    @TableField(fill = FieldFill.INSERT)
+    private Date createDate;
+    /**
+    * 修改人
+    */
+    @ApiModelProperty("修改人")
+    @TableField(fill = FieldFill.UPDATE)
+    private Long modifyUserId;
+    /**
+    * 修改时间
+    */
+    @ApiModelProperty("修改时间")
+    @TableField(fill = FieldFill.UPDATE)
+    private Date modifyDate;
+    /**
+    * 删除标记
+    */
+    @ApiModelProperty("删除标记")
+    @TableField(fill = FieldFill.INSERT)
+    @TableLogic
+    private Integer deleteMark;
+    /**
+    * 有效标志
+    */
+    @ApiModelProperty("有效标志")
+    @TableField(fill = FieldFill.INSERT)
+    private Integer enabledMark;
+    /**
+    * 序号
+    */
+    @ApiModelProperty("序号")
+    private Integer sortCode;
+    /**
+    * 学期ID(base_semester)
+    */
+    @ApiModelProperty("学期ID(base_semester)")
+    private Long baseSemesterId;
+    /**
+    * 班级id
+    */
+    @ApiModelProperty("班级id")
+    private Long classId;
+    /**
+    * 荣誉级别(xjr_dictionary_item[honors_level])
+    */
+    @ApiModelProperty("荣誉级别(xjr_dictionary_item[honors_level])")
+    private String honorsLevel;
+    /**
+    * 荣誉等级(xjr_dictionary_item[honors_grade])
+    */
+    @ApiModelProperty("荣誉等级(xjr_dictionary_item[honors_grade])")
+    private String honorsGrade;
+    /**
+    * 荣誉名称
+    */
+    @ApiModelProperty("荣誉名称")
+    private String name;
+    /**
+    * 获奖日期
+    */
+    @ApiModelProperty("获奖日期")
+    private Date awardDate;
+    /**
+    * 附件文件id
+    */
+    @ApiModelProperty("附件文件id")
+    private Long fileId;
+
+
+}

+ 38 - 0
src/main/java/com/xjrsoft/module/student/mapper/ClassHonorsMapper.java

@@ -0,0 +1,38 @@
+package com.xjrsoft.module.student.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.github.yulichang.base.MPJBaseMapper;
+import com.xjrsoft.module.student.dto.BaseStudentPunishmentInfoPageDto;
+import com.xjrsoft.module.student.dto.ClassHonorsPageDto;
+import com.xjrsoft.module.student.entity.ClassHonors;
+import com.xjrsoft.module.student.vo.BaseStudentPunishmentInfoPageVo;
+import com.xjrsoft.module.student.vo.ClassHonorsPageVo;
+import com.xjrsoft.module.student.vo.ClassHonorsVo;
+import org.apache.ibatis.annotations.Mapper;
+
+/**
+* @title: 班级荣誉
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Mapper
+public interface ClassHonorsMapper extends MPJBaseMapper<ClassHonors> {
+
+    /**
+     * 班级荣誉列表(分页)PC端
+     * @param dto
+     * @return
+     */
+    IPage<ClassHonorsPageVo> getPagePC(IPage<ClassHonorsPageDto> page, ClassHonorsPageDto dto);
+
+    /**
+     * 根据id查询班级荣誉信息
+     * @param id
+     * @return
+     */
+    ClassHonorsVo getInfoById(Long id);
+
+}

+ 44 - 0
src/main/java/com/xjrsoft/module/student/service/IClassHonorsService.java

@@ -0,0 +1,44 @@
+package com.xjrsoft.module.student.service;
+
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.github.yulichang.base.MPJBaseService;
+import com.xjrsoft.module.student.dto.ClassHonorsPageDto;
+import com.xjrsoft.module.student.entity.ClassHonors;
+import com.xjrsoft.module.student.vo.ClassHonorsPageVo;
+import com.xjrsoft.module.student.vo.ClassHonorsSemesterClassTreeVo;
+import com.xjrsoft.module.student.vo.ClassHonorsVo;
+import lombok.Data;
+import java.util.List;
+
+/**
+* @title: 班级荣誉
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+
+public interface IClassHonorsService extends MPJBaseService<ClassHonors> {
+
+    /**
+     * 班级荣誉列表(分页)PC端
+     * @param dto
+     * @return
+     */
+    IPage<ClassHonorsPageVo> getPagePC(ClassHonorsPageDto dto);
+
+    /**
+     * 根据id查询班级荣誉信息
+     * @param id
+     * @return
+     */
+    ClassHonorsVo getInfoById(Long id);
+
+    /**
+     * 将所有班级荣誉的学期和班级构成树
+     * @return
+     */
+    List<ClassHonorsSemesterClassTreeVo> getSemesterClassTree();
+
+
+}

+ 101 - 0
src/main/java/com/xjrsoft/module/student/service/impl/ClassHonorsServiceImpl.java

@@ -0,0 +1,101 @@
+package com.xjrsoft.module.student.service.impl;
+
+import cn.hutool.core.util.ObjectUtil;
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.core.toolkit.StringUtils;
+import com.baomidou.mybatisplus.core.toolkit.Wrappers;
+import com.github.yulichang.base.MPJBaseServiceImpl;
+import com.github.yulichang.wrapper.MPJLambdaWrapper;
+import com.xjrsoft.common.exception.MyException;
+import com.xjrsoft.common.page.ConventPage;
+import com.xjrsoft.common.utils.VoToColumnUtil;
+import com.xjrsoft.module.base.service.IBaseSemesterService;
+import com.xjrsoft.module.student.dto.ClassHonorsPageDto;
+import com.xjrsoft.module.student.entity.BaseStudentAssessmentCategory;
+import com.xjrsoft.module.student.entity.BaseStudentBehaviorProject;
+import com.xjrsoft.module.student.entity.ClassHonors;
+import com.xjrsoft.module.student.mapper.ClassHonorsMapper;
+import com.xjrsoft.module.student.service.IClassHonorsService;
+import com.xjrsoft.module.student.vo.*;
+import com.xjrsoft.module.system.entity.DictionaryDetail;
+import com.xjrsoft.module.system.entity.File;
+import com.xjrsoft.module.system.service.IFileService;
+import lombok.AllArgsConstructor;
+import org.springframework.stereotype.Service;
+
+import java.util.ArrayList;
+import java.util.List;
+
+
+/**
+* @title: 班级荣誉
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Service
+@AllArgsConstructor
+public class ClassHonorsServiceImpl extends MPJBaseServiceImpl<ClassHonorsMapper, ClassHonors> implements IClassHonorsService {
+
+
+    private final ClassHonorsMapper classHonorsMapper;
+    private final IFileService fileService;
+    /**
+     * 班级荣誉列表(分页)PC端
+     * @param dto
+     * @return
+     */
+    @Override
+    public IPage<ClassHonorsPageVo> getPagePC(ClassHonorsPageDto dto) {
+        return classHonorsMapper.getPagePC(ConventPage.getPage(dto),dto);
+    }
+
+    /**
+     * 根据id查询班级荣誉信息
+     * @param id
+     * @return
+     */
+    @Override
+    public ClassHonorsVo getInfoById(Long id) {
+        ClassHonorsVo classHonorsVo = classHonorsMapper.getInfoById(id);
+        if(ObjectUtil.isNull(classHonorsVo)){
+            throw new MyException("该数据不存在");
+        }
+
+        // 添加文件列表
+        classHonorsVo.setFileList(fileService.list(Wrappers.<File>query().lambda().eq(File::getFolderId, classHonorsVo.getFileId())));
+        return classHonorsVo;
+    }
+
+    @Override
+    public List<ClassHonorsSemesterClassTreeVo> getSemesterClassTree() {
+        List<ClassHonorsSemesterClassTreeVo> treeVoList = new ArrayList<>();
+
+        //获取所有的学期id
+        LambdaQueryWrapper<ClassHonors> queryWrapper1 = new LambdaQueryWrapper<>();
+        queryWrapper1
+                .select(ClassHonors::getBaseSemesterId)
+                .groupBy(ClassHonors::getBaseSemesterId)
+                .orderByDesc(ClassHonors::getId);
+        List<ClassHonors> classHonorsList = this.list(queryWrapper1);
+        List<Long> semesterIds = new ArrayList<>();
+        for (ClassHonors c : classHonorsList){
+            semesterIds.add(c.getBaseSemesterId());
+        }
+
+        //获取所有的班级id
+        LambdaQueryWrapper<ClassHonors> queryWrapper = new LambdaQueryWrapper<>();
+        queryWrapper
+                .select(ClassHonors::getBaseSemesterId)
+                .groupBy(ClassHonors::getBaseSemesterId)
+                .orderByDesc(ClassHonors::getId);
+        List<ClassHonors> classHonorsList_all = this.list(queryWrapper);
+        List<Long> classIds = new ArrayList<>();
+        for (ClassHonors c : classHonorsList){
+            semesterIds.add(c.getBaseSemesterId());
+        }
+
+        return null;
+    }
+}

+ 68 - 0
src/main/java/com/xjrsoft/module/student/vo/ClassHonorsPageVo.java

@@ -0,0 +1,68 @@
+package com.xjrsoft.module.student.vo;
+
+import com.alibaba.excel.annotation.ExcelProperty;
+import com.alibaba.excel.annotation.ExcelIgnore;
+import com.alibaba.excel.annotation.write.style.ContentStyle;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import com.xjrsoft.common.annotation.Trans;
+import com.xjrsoft.common.enums.TransType;
+import java.time.LocalTime;
+import java.time.LocalDateTime;
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+* @title: 班级荣誉分页列表出参
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Data
+public class ClassHonorsPageVo {
+
+    /**
+     * 主键编号
+     */
+    @ContentStyle(dataFormat = 49)
+    @ExcelProperty("主键编号")
+    @ApiModelProperty("主键编号")
+    private String id;
+    /**
+     * 序号
+     */
+    @ContentStyle(dataFormat = 49)
+    @ExcelProperty("序号")
+    @ApiModelProperty("序号")
+    private Integer sortCode;
+    /**
+     * 荣誉级别中文(xjr_dictionary_item[honors_level])
+     */
+    @ContentStyle(dataFormat = 49)
+    @ExcelProperty("荣誉级别中文(xjr_dictionary_item[honors_level])")
+    @ApiModelProperty("荣誉级别中文(xjr_dictionary_item[honors_level])")
+    private String honorsLevelCN;
+    /**
+     * 荣誉等级中文(xjr_dictionary_item[honors_grade])
+     */
+    @ContentStyle(dataFormat = 49)
+    @ExcelProperty("荣誉等级中文(xjr_dictionary_item[honors_grade])")
+    @ApiModelProperty("荣誉等级中文(xjr_dictionary_item[honors_grade])")
+    private String honorsGradeCN;
+    /**
+     * 荣誉名称
+     */
+    @ContentStyle(dataFormat = 49)
+    @ExcelProperty("荣誉名称")
+    @ApiModelProperty("荣誉名称")
+    private String name;
+    /**
+     * 获奖日期
+     */
+    @ContentStyle(dataFormat = 49)
+    @ExcelProperty("获奖日期")
+    @ApiModelProperty("获奖日期")
+    private Date awardDate;
+}

+ 33 - 0
src/main/java/com/xjrsoft/module/student/vo/ClassHonorsSemesterClassTreeVo.java

@@ -0,0 +1,33 @@
+package com.xjrsoft.module.student.vo;
+
+import com.xjrsoft.common.model.tree.ITreeNode;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.io.Serializable;
+import java.util.List;
+
+/**
+* @title: 班级荣誉分页列表学期班级树出参
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Data
+public class ClassHonorsSemesterClassTreeVo implements ITreeNode<ClassHonorsSemesterClassTreeVo,Long>, Serializable {
+
+    private static final long serialVersionUID = 1L;
+    /**
+     * 班级id
+     */
+    @ApiModelProperty("班级id")
+    private Long id;
+
+    @ApiModelProperty("名字")
+    private String name;
+
+    @ApiModelProperty("父级id-学期id")
+    private Long parentId;
+
+    private List<ClassHonorsSemesterClassTreeVo> children;
+}

+ 92 - 0
src/main/java/com/xjrsoft/module/student/vo/ClassHonorsVo.java

@@ -0,0 +1,92 @@
+package com.xjrsoft.module.student.vo;
+
+import com.xjrsoft.module.system.entity.File;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.time.LocalTime;
+import java.time.LocalDateTime;
+import java.math.BigDecimal;
+import java.util.List;
+import java.util.Date;
+
+/**
+* @title: 班级荣誉表单出参
+* @Author szs
+* @Date: 2023-12-06
+* @Version 1.0
+*/
+@Data
+public class ClassHonorsVo {
+
+    /**
+    * 主键编号
+    */
+    @ApiModelProperty("主键编号")
+    private Long id;
+    /**
+    * 序号
+    */
+    @ApiModelProperty("序号")
+    private Integer sortCode;
+    /**
+    * 学期ID(base_semester)
+    */
+    @ApiModelProperty("学期ID(base_semester)")
+    private Long baseSemesterId;
+    /**
+     * 学期ID中文(base_semester)
+     */
+    @ApiModelProperty("学期ID中文(base_semester)")
+    private Long baseSemesterIdCN;
+    /**
+    * 班级id
+    */
+    @ApiModelProperty("班级id")
+    private Long classId;
+    /**
+     * 班级id中文
+     */
+    @ApiModelProperty("班级id中文")
+    private Long classIdCN;
+    /**
+    * 荣誉级别(xjr_dictionary_item[honors_level])
+    */
+    @ApiModelProperty("荣誉级别(xjr_dictionary_item[honors_level])")
+    private String honorsLevel;
+    /**
+     * 荣誉级别中文(xjr_dictionary_item[honors_level])
+     */
+    @ApiModelProperty("荣誉级别中文(xjr_dictionary_item[honors_level])")
+    private String honorsLevelCN;
+    /**
+    * 荣誉等级(xjr_dictionary_item[honors_grade])
+    */
+    @ApiModelProperty("荣誉等级(xjr_dictionary_item[honors_grade])")
+    private String honorsGrade;
+    /**
+     * 荣誉等级中文(xjr_dictionary_item[honors_grade])
+     */
+    @ApiModelProperty("荣誉等级中文(xjr_dictionary_item[honors_grade])")
+    private String honorsGradeCN;
+    /**
+    * 荣誉名称
+    */
+    @ApiModelProperty("荣誉名称")
+    private String name;
+    /**
+    * 获奖日期
+    */
+    @ApiModelProperty("获奖日期")
+    private Date awardDate;
+    /**
+    * 附件文件id
+    */
+    @ApiModelProperty("附件文件id")
+    private Long fileId;
+    /**
+     * 该处分信息下的文件集合
+     */
+    @ApiModelProperty("文件集合")
+    private List<File> fileList;
+}

+ 6 - 1
src/main/resources/mapper/student/BaseStudentBehaviorManageMapper.xml

@@ -67,7 +67,12 @@
 
     <select id="getMobilePage" parameterType="com.xjrsoft.module.student.dto.BaseStudentBehaviorManageMobilePageDto" resultType="com.xjrsoft.module.student.vo.BaseStudentBehaviorManageMobilePageVo">
         SELECT t1.sort_code,t1.name,t1.class_name,t.assessment_date,
-        t3.name AS categoryName,t4.name AS projectName,t.score,t4.score_type  FROM base_student_behavior_manage t
+        t3.name AS categoryName,t4.name AS projectName,t.score,t4.score_type,
+        t2.name AS assessmentUserName,
+        t.assessment_address,
+        t3.name AS behaviorCategoryName,
+        t4.name AS behaviorProjectName
+        FROM base_student_behavior_manage t
         INNER JOIN base_student_behavior_student_relation t1 ON t1.base_student_behavior_manage_id = t.id
         <if test="dto.studentName != null and dto.studentName != ''">
             and t1.name like concat('%',#{dto.studentName},'%')

+ 50 - 0
src/main/resources/mapper/student/ClassHonorsMapper.xml

@@ -0,0 +1,50 @@
+<?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.xjrsoft.module.student.mapper.ClassHonorsMapper">
+    <select id="getPagePC" parameterType="com.xjrsoft.module.student.dto.ClassHonorsPageDto" resultType="com.xjrsoft.module.student.vo.ClassHonorsPageVo">
+        SELECT
+            t.id,
+            t.sort_code,
+            t1.name AS honorsLevelCN,
+            t2.name AS honorsGradeCN,
+            t.name,
+            t.award_date
+        FROM class_honors t
+            LEFT JOIN xjr_dictionary_detail t1 ON t1.code = t.honors_level
+            LEFT JOIN xjr_dictionary_detail t2 ON t2.code = t.honors_grade
+        WHERE
+            t.delete_mark = 0
+            <if test="dto.honorsLevel != null and dto.honorsLevel != ''">
+                and t.honors_level = #{dto.honorsLevel}
+            </if>
+            <if test="dto.honorsGrade != null and dto.honorsGrade != ''">
+                and t.honors_grade = #{dto.honorsGrade}
+            </if>
+            <if test="dto.awardDate != null and dto.awardDate != ''">
+                and t.award_date = #{dto.awardDate}
+            </if>
+            <if test="dto.name != null and dto.name != ''">
+                and t.name like concat('%',#{dto.name},'%')
+            </if>
+        ORDER BY
+            t.id DESC;
+    </select>
+    <select id="getInfoById"
+            resultType="com.xjrsoft.module.student.vo.ClassHonorsVo">
+        SELECT
+            t.*,
+            t1.name AS honorsLevelCN,
+            t2.name AS honorsGradeCN,
+            t3.name AS baseSemesterIdCN,
+            t4.name AS classIdCN,
+        FROM class_honors t
+            LEFT JOIN xjr_dictionary_detail t1 ON t1.code = t.honors_level
+            LEFT JOIN xjr_dictionary_detail t2 ON t2.code = t.honors_grade
+            LEFT JOIN base_semester t3 ON t3.id = t.base_semester_id
+            LEFT JOIN base_class t4 ON t4.id = t.class_id
+        WHERE
+            t.id = #{id} AND t.delete_mark = 0;
+    </select>
+</mapper>

+ 30 - 0
src/test/java/com/xjrsoft/xjrsoftboot/FreeMarkerGeneratorTest.java

@@ -921,4 +921,34 @@ public class FreeMarkerGeneratorTest {
         apiGeneratorService.generateCodes(params);
     }
 
+    /**
+     * 班级荣誉
+     *
+     */
+    @Test
+    public void gcClassHonors() throws IOException {
+        List<TableConfig> tableConfigs = new ArrayList<>();
+        TableConfig mainTable = new TableConfig();
+        mainTable.setTableName("class_honors");//init_sql中的表名
+        mainTable.setIsMain(true);//是否是主表,一般默认为true
+        mainTable.setPkField(GlobalConstant.DEFAULT_PK);//设置主键
+        mainTable.setPkType(GlobalConstant.DEFAULT_PK_TYPE);//设置主键类型
+        tableConfigs.add(mainTable);
+
+
+        ApiGenerateCodesDto params = new ApiGenerateCodesDto();
+        params.setAuthor("szs");//作者名称
+        params.setPackageName("student");//包名
+        params.setTableConfigs(tableConfigs);
+        params.setPage(true);//是否生成分页接口
+        params.setImport(true);//是否生成导入接口
+        params.setExport(false);//是否生成导出接口
+        params.setOutMainDir(true);//是否生成在主目录,前期测试可设置成false
+        params.setDs(ds);
+
+
+        IApiGeneratorService apiGeneratorService = new ApiGeneratorServiceImpl();
+
+        apiGeneratorService.generateCodes(params);
+    }
 }