nickchange
2023-11-09 c036557db88c6297b9a626a892dce35c14ab8ee5
cloud-server-account/src/main/java/com/dsh/account/controller/ClassDetailsController.java
@@ -263,6 +263,7 @@
                    vo.setStuWeight(sts.getWeight());
                    vo.setIsNot(sts.getIsDefault());
                    vo.setStuPhone(sts.getPhone());
                    vo.setSex(sts.getSex());
                    stuListVos.add(vo);
                });
            }
@@ -341,13 +342,27 @@
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9....."),
            @ApiImplicitParam(value = "学员id", name = "stuId", required = true, dataType = "int"),
    })
    public ResultUtil commitEditStu(StuEditInfoReq stu){
    public ResultUtil commitEditStu(StuDetailsReq stu){
        try {
            Integer userIdFormRedis = tokenUtil.getUserIdFormRedis();
            if(null == userIdFormRedis){
                return ResultUtil.tokenErr();
            }
            return ResultUtil.success(istuService.commitEditStudentInfo(stu,userIdFormRedis));
            SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
            TStudent tStudent = new TStudent();
            tStudent.setId(stu.getStuId());
            tStudent.setBirthday(format.parse(stu.getBirthday()));
            tStudent.setHeadImg(stu.getHeadImg());
            tStudent.setHeight(stu.getHeight());
            tStudent.setWeight(stu.getWeight());
            tStudent.setPhone(stu.getPhone());
            tStudent.setSex(stu.getSex());
            tStudent.setName(stu.getName());
            tStudent.setIdCard(stu.getIdCard());
          return  ResultUtil.success(istuService.updateById(tStudent));
//            return ResultUtil.success(istuService.commitEditStudentInfo(stu,userIdFormRedis));
        }catch (Exception e){
            return ResultUtil.runErr();
        }
@@ -546,6 +561,9 @@
    })
    public ResultUtil<List<StuMedalVo>> queryStuMedal( Integer stuId){
        try {
            Integer appUserId = tokenUtil.getUserIdFormRedis();
            if(null == appUserId){
                return ResultUtil.tokenErr();