liujie
2023-10-26 e030255c23c7ba3e2cbad1036a810d6d72fa864f
cloud-server-account/src/main/java/com/dsh/account/controller/ClassDetailsController.java
@@ -129,7 +129,6 @@
            e.printStackTrace();
            return ResultUtil.runErr();
        }
    }
    @ResponseBody
@@ -159,9 +158,9 @@
    @ApiOperation(value = "上课首页分配课时-课程列表", tags = {"APP-开始上课"})
    @ApiImplicitParams({
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9....."),
            @ApiImplicitParam(value = "分配给课包id", name = "packetId", required = true, dataType = "string"),
            @ApiImplicitParam(value = "分配给课包id", name = "packetId", required = true, dataType = "Long"),
    })
    public ResultUtil<Integer> weeksOfAddHours(Integer packetId){
    public ResultUtil<Integer> weeksOfAddHours(Long packetId){
        try {
            Integer appUserId = tokenUtil.getUserIdFormRedis();
            if(null == appUserId){
@@ -169,10 +168,12 @@
            }
            TAppGift one = appGiftService.getOne(new LambdaQueryWrapper<TAppGift>().eq(TAppGift::getUserId, appUserId));
            Boolean b= false;
            Integer i=0;
            if(one!=null && one.getNum()>0){
                 b =appGiftService.weeksOfAddHours(packetId,appUserId,one.getNum());
                 i=appGiftService.weeksOfAddHours(packetId,appUserId,one.getNum());
            }
            if(b){
            if(i==1){
                // 送完清0
                one.setNum(0);
                appGiftService.updateById(one);
@@ -591,16 +592,16 @@
            @ApiImplicitParam(value = "时间类型 0=全部 1=近一周 2=近一个月 3=近一年", name = "timeType", required = false, dataType = "int"),
            @ApiImplicitParam(value = "课程名称", name = "appointStatus", required = false, dataType = "string"),
    })
    public ResultUtil<List<RecordAppoint>> cgeClassAppointmentRecordList(Integer stuId, Integer appointStatus, Integer timeType, String search){
        try {
    public ResultUtil<List<RecordAppoint>> cgeClassAppointmentRecordList(Integer stuId, Integer appointStatus, Integer timeType, String search,Integer pageNum){
//        try {
            Integer appUserId = tokenUtil.getUserIdFormRedis();
            if(null == appUserId){
                return ResultUtil.tokenErr();
            }
            return ResultUtil.success(istuService.getAppointmentRecords(stuId,appUserId,appointStatus,timeType,search));
        }catch (Exception e){
            return ResultUtil.runErr();
        }
            return ResultUtil.success(istuService.getAppointmentRecords(stuId,appUserId,appointStatus,timeType,search,pageNum));
//        }catch (Exception e){
//            return ResultUtil.runErr();
//        }
    }