| | |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.dsh.course.entity.*; |
| | | import com.dsh.course.feignclient.account.AppUserClient; |
| | | import com.dsh.course.feignclient.account.StudentClient; |
| | | import com.dsh.course.feignclient.account.model.AppUser; |
| | | import com.dsh.course.feignclient.account.model.Student; |
| | | import com.dsh.course.feignclient.model.*; |
| | | import com.dsh.course.feignclient.other.StoreClient; |
| | | import com.dsh.course.feignclient.other.model.Store; |
| | |
| | | @Autowired |
| | | private TCourseService tcService; |
| | | |
| | | |
| | | @Resource |
| | | private StudentClient studentClient; |
| | | |
| | | @Autowired |
| | | private TCoursePackageTypeService coursePackageTypeService; |
| | |
| | | @ResponseBody |
| | | @PostMapping("/base/coursePack/queryPayment") |
| | | public List<StuCourseResp> getStuCoursePackagePayment(@RequestBody Integer stuId){ |
| | | Integer userIdFormRedis = null; |
| | | try { |
| | | userIdFormRedis = tokenUtil.getUserIdFormRedis(); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | List<StuCourseResp> resps = new ArrayList<>(); |
| | | Student student = studentClient.queryStudentById(stuId); |
| | | List<TCoursePackagePayment> byUserId = packagePaymentService.list(new QueryWrapper<TCoursePackagePayment>() |
| | | .eq("appUserId",userIdFormRedis) |
| | | .eq("appUserId",student.getAppUserId()) |
| | | .eq("studentId",stuId)); |
| | | |
| | | if (byUserId.size() > 0 ){ |