Browse Source

学生导入性别bug

zhaoy 6 years ago
parent
commit
3c8612f962

+ 2 - 2
applications/school/school-server/src/main/java/com/usoftchina/smartschool/school/basic/service/impl/StudentServiceImpl.java

@@ -197,9 +197,9 @@ public class StudentServiceImpl implements StudentService{
                 json = JSONObject.parseObject(main.getDd_maindata());
                 json = JSONObject.parseObject(main.getDd_maindata());
                 if (null != json) {
                 if (null != json) {
                     if ("男".equals(json.get("stu_sex"))) {
                     if ("男".equals(json.get("stu_sex"))) {
-                        json.put("stu_sex", 1);
+                        json.put("stu_sex", 0);
                     }else if ("女".equals(json.get("stu_sex"))) {
                     }else if ("女".equals(json.get("stu_sex"))) {
-                        json.put("stu_sex", 2);
+                        json.put("stu_sex", 1);
                     }else if(!"男".equals(json.get("stu_sex")) && !"女".equals(json.get("stu_sex"))){
                     }else if(!"男".equals(json.get("stu_sex")) && !"女".equals(json.get("stu_sex"))){
                         throw new BizException(BizExceptionCode.ILLEGAL_Gender);
                         throw new BizException(BizExceptionCode.ILLEGAL_Gender);
                     }
                     }