Browse Source

调整性别数据

dzx 1 year ago
parent
commit
708324587e

+ 3 - 1
src/main/java/com/xjrsoft/module/student/controller/StudentManagerController.java

@@ -81,7 +81,9 @@ public class StudentManagerController {
                         .leftJoin("base_grade a on a.id = t2.grade_id")
                         .leftJoin("base_major_set b on b.id = t2.major_set_id")
                         .leftJoin(BaseClass.class, BaseClass::getId, BaseStudentSchoolRoll::getClassId));
-
+        for (BaseStudentUserPageVo record : page.getRecords()) {
+            record.setGenderCn(GenderDictionaryEnum.getValue(record.getGender()));
+        }
         PageOutput<BaseStudentUserPageVo> pageOutput = ConventPage.getPageOutput(page, BaseStudentUserPageVo.class);
         return R.ok(pageOutput);
     }

+ 1 - 1
src/main/java/com/xjrsoft/module/student/entity/BaseStudentUser.java

@@ -64,7 +64,7 @@ public class BaseStudentUser implements Serializable {
      * 性别
      */
     @ApiModelProperty("性别")
-    private Integer gender;
+    private String gender;
     /**
      * 手机号
      */

+ 6 - 0
src/main/java/com/xjrsoft/module/student/vo/BaseStudentUserPageVo.java

@@ -47,6 +47,12 @@ public class BaseStudentUserPageVo {
      */
     @ApiModelProperty("性别")
     private String gender;
+
+    /**
+     * 性别中文
+     */
+    @ApiModelProperty("性别中文")
+    private String genderCn;
     /**
      * 证件号码
      */