| | |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
| | | import com.baomidou.mybatisplus.extension.api.R; |
| | | import com.dsh.account.dto.BindDto; |
| | | import com.dsh.account.dto.IntroduceUserQuery; |
| | | import com.dsh.account.dto.SelectDto; |
| | | import com.dsh.account.dto.UpdateInfoDto; |
| | | import com.dsh.account.dto.*; |
| | | import com.dsh.account.entity.*; |
| | | import com.dsh.account.feignclient.other.VipClient; |
| | | import com.dsh.account.model.AddAppUserVo; |
| | |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiImplicitParams; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.checkerframework.checker.guieffect.qual.UI; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PathVariable; |
| | |
| | | |
| | | @Autowired |
| | | private TAppGiftService appGiftService; |
| | | |
| | | @Autowired |
| | | private UserIntegralChangesService userIntegralChangesService; |
| | | |
| | | /** |
| | | * 根据介绍有礼id查询当前活动参与次数 |
| | |
| | | return ResultUtil.runErr(); |
| | | } |
| | | } |
| | | |
| | | @ResponseBody |
| | | @PostMapping("/api/appUser/vipPayment") |
| | | @ApiOperation(value = "页面数据展示", tags = {"APP-成为会员"}) |
| | |
| | | // e.printStackTrace(); |
| | | // } |
| | | // } |
| | | |
| | | /** |
| | | * 购买年度会员支付微信回调 |
| | | * |
| | |
| | | return null; |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 根据用户id获取用户信息 |
| | | * |
| | |
| | | return appUserService.listByIds(appUserIdList); |
| | | } |
| | | |
| | | @Autowired |
| | | private UserIntegralChangesService userIntegralChangesService; |
| | | |
| | | /** |
| | | * 修改用户信息 |
| | |
| | | } |
| | | } |
| | | |
| | | @PostMapping("/base/appUser/updateIntegral") |
| | | public Boolean updateIntegral(@RequestBody UpdateIntegral updateIntegral) { |
| | | TAppUser appUser = appUserService.getById(updateIntegral.getId()); |
| | | Integer integral = appUser.getIntegral(); |
| | | switch (updateIntegral.getChangeType()) { |
| | | case 1: |
| | | integral = integral + updateIntegral.getIntegral(); |
| | | break; |
| | | case 2: |
| | | integral = integral - updateIntegral.getIntegral(); |
| | | break; |
| | | } |
| | | appUser.setIntegral(integral); |
| | | appUserService.updateById(appUser); |
| | | UserIntegralChanges userIntegralChanges = new UserIntegralChanges(); |
| | | userIntegralChanges.setAppUserId(updateIntegral.getId()); |
| | | userIntegralChanges.setType(1); |
| | | userIntegralChanges.setOldIntegral(appUser.getIntegral()); |
| | | userIntegralChanges.setNewIntegral(integral); |
| | | userIntegralChanges.setRemark(updateIntegral.getRemark()); |
| | | userIntegralChanges.setInsertTime(new Date()); |
| | | userIntegralChanges.setCategory(updateIntegral.getChangeType()); |
| | | userIntegralChangesService.save(userIntegralChanges); |
| | | return true; |
| | | } |
| | | |
| | | @PostMapping("/base/appUser/queryById") |
| | | public TAppUser queryById(@RequestBody Integer appUserId) { |
| | | try { |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * 根据城市code获取用户的id集合 |
| | | * |
| | | * @param cityCode 城市code |
| | | * @return |
| | | */ |
| | |
| | | |
| | | /** |
| | | * 根据省市名称所有用户 |
| | | * |
| | | * @param appUserIdsByCityName |
| | | * @return |
| | | */ |