| | |
| | | public Result updateStudent(String studentId, String name,String password, String studentNo, boolean sex, String phoneNo) { |
| | | //根据学学员ID,获取用户信息 |
| | | StuStudent stu = this.read(StuStudent.class, studentId); |
| | | |
| | | if (!stu.getStudentNo().equals(studentNo) && dao.exists(studentNo,ClientUtils.getOrgId())) { |
| | | return new Result(false, "学号已存在"); |
| | | if(stu.getStudentNo() != null){ |
| | | if (!stu.getStudentNo().equals(studentNo) && dao.exists(studentNo,ClientUtils.getOrgId())) { |
| | | return new Result(false, "学号已存在"); |
| | | } |
| | | } |
| | | |
| | | stu.setName(name); |
| | | stu.setSex(sex); |
| | | stu.setStudentNo(studentNo); |