| | |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.time.LocalDate; |
| | | import java.util.ArrayList; |
| | | import java.util.List; |
| | | |
| | | import com.ruoyi.account.vo.*; |
| | |
| | | } |
| | | |
| | | @ResponseBody |
| | | @PostMapping("/getTopUsers") |
| | | public R<List<AppUser>> getTopUsers(@RequestBody AppUser appUser) { |
| | | List<Integer> vipIds = new ArrayList<>(); |
| | | vipIds.add(5); |
| | | vipIds.add(6); |
| | | vipIds.add(7); |
| | | List<AppUser> list = appUserService.lambdaQuery().in(AppUser::getVipId, vipIds).list(); |
| | | return R.ok(list); |
| | | |
| | | } |
| | | |
| | | @ResponseBody |
| | | @PostMapping("/getCouponCount") |
| | | public R<Long> getCouponCount(@RequestParam("userId")Long userId, @RequestParam("couponId") Integer couponId ){ |
| | | Long count = userCouponService.lambdaQuery().eq(UserCoupon::getAppUserId, userId).eq(UserCoupon::getCouponId, couponId).count(); |