feat(study): 添加学生信息中的培训课程和考试分数字段

dev
zhaokai 2026-03-09 14:07:18 +08:00
parent de86566389
commit e0b811f04d
3 changed files with 30 additions and 1 deletions

View File

@ -6,6 +6,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.math.BigDecimal;
import java.time.LocalDateTime;
@ -212,6 +213,12 @@ public class StudentCO extends ClientObject {
@TableField(exist = false)
private String sex;
@ApiModelProperty(value = "培训课程名字集合")
@TableField(exist = false)
private String curriculumNameList;
@ApiModelProperty(value = "考试分数")
@TableField(exist = false)
private BigDecimal examScore;
//环境
@ApiModelProperty(value = "环境")

View File

@ -7,6 +7,8 @@ import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import java.math.BigDecimal;
/**
* web-infrastructure
*
@ -205,6 +207,12 @@ public class StudentDO extends BaseDO {
@ApiModelProperty(value = "性别")
@TableField(exist = false)
private String sex;
@ApiModelProperty(value = "培训课程名字集合")
@TableField(exist = false)
private String curriculumNameList;
@ApiModelProperty(value = "考试分数")
@TableField(exist = false)
private BigDecimal examScore;
}

View File

@ -371,10 +371,24 @@
(YEAR(NOW()) - SUBSTRING(FROM_BASE64(s.user_id_card), 7, 4)) ELSE NULL
END AS age,
cast(substring(FROM_BASE64(s.user_id_card), 7, 8) AS DATE) AS birthday
cast(substring(FROM_BASE64(s.user_id_card), 7, 8) AS DATE) AS birthday,
c.name as class_name,
c.start_time,
c.end_time,
c.valid_start_time,
c.valid_end_time,
c.teacher_name,
c.train_type,
c.train_type_name,
c.training_location,
GROUP_CONCAT(DISTINCT cc.curriculum_name) AS curriculumNameList,
ser.exam_score
from
student s
left join user u on u.phone = s.phone
left join class c on c.class_id = s.class_id
left join class_curriculum cc on cc.class_id = c.class_id
left join student_exam_record ser on ser.student_id = s.student_id and ser.class_id = c.class_id
<where>
s.student_id = #{studentId}
</where>