luodangjia
2025-02-06 4ea15c3e2a3f0434df79a1b49fe4e90f7337b025
ruoyi-service/ruoyi-account/src/main/java/com/ruoyi/account/service/impl/UserPointServiceImpl.java
@@ -93,6 +93,11 @@
        if (CollectionUtil.isNotEmpty(page.getRecords())) {
            List<UserPointDetailVO> collect = page.getRecords().stream().map(p -> {
                UserPointDetailVO userPointDetailVO = new UserPointDetailVO();
                if (p.getType() != null && (p.getType().equals(12) || p.getType().equals(13))){
                    Long appUserId = p.getObjectId();
                    AppUser appUser = appUserService.getById(appUserId);
                    userPointDetailVO.setName(appUser.getName());
                }
                userPointDetailVO.setType(p.getType());
                userPointDetailVO.setVariablePoint(p.getVariablePoint());
                String format = p.getCreateTime().format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"));
@@ -170,6 +175,7 @@
            userPoint.setBalance(appUserForPhoe.getLavePoint());
            userPoint.setCreateTime(LocalDateTime.now());
            userPoint.setAppUserId(appUserForPhoe.getId());
            userPoint.setObjectId(userid);
            userPointService.save(userPoint);
        }
@@ -187,6 +193,7 @@
            userPoint.setBalance(appUser.getLavePoint());
            userPoint.setCreateTime(LocalDateTime.now());
            userPoint.setAppUserId(appUser.getId());
            userPoint.setObjectId(appUserForPhoe.getId());
            userPointService.save(userPoint);
        }
        return R.ok();