提交 02850558 authored 作者: 窦馨雨's avatar 窦馨雨

合并分支 'dxy' 到 'qa'

CP计划小程序改造,改造登录放行 查看合并请求 !63
package com.wangxiaolu.promotion.controller.user.tem; package com.wangxiaolu.promotion.controller.user.tem;
import com.wangxiaolu.promotion.common.redis.RedisKeys;
import com.wangxiaolu.promotion.common.redis.service.RedisCache; import com.wangxiaolu.promotion.common.redis.service.RedisCache;
import com.wangxiaolu.promotion.common.util.DataUtils; import com.wangxiaolu.promotion.common.util.DataUtils;
import com.wangxiaolu.promotion.common.util.EnvUtil; import com.wangxiaolu.promotion.common.util.EnvUtil;
...@@ -11,7 +10,6 @@ import com.wangxiaolu.promotion.result.basedata.R; ...@@ -11,7 +10,6 @@ import com.wangxiaolu.promotion.result.basedata.R;
import com.wangxiaolu.promotion.result.basedata.RCode; import com.wangxiaolu.promotion.result.basedata.RCode;
import com.wangxiaolu.promotion.service.wechat.WeChatUserCoreService; import com.wangxiaolu.promotion.service.wechat.WeChatUserCoreService;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated; import org.springframework.validation.annotation.Validated;
...@@ -58,7 +56,8 @@ public class TemporaryInfoCoreController { ...@@ -58,7 +56,8 @@ public class TemporaryInfoCoreController {
// if (envUtil.isLive()) { // if (envUtil.isLive()) {
// String redisKey = RedisKeys.UserKeys.PHONE_VER_CODE.getKey() + wxTemporaryEnrollVo.getPhone(); // String redisKey = RedisKeys.UserKeys.PHONE_VER_CODE.getKey() + wxTemporaryEnrollVo.getPhone();
// String phoneCodeOld = redisCache.get(redisKey); // String phoneCodeOld = redisCache.get(redisKey);
// if (StringUtils.isBlank(phoneCodeOld) || !phoneCodeOld.equals(wxTemporaryEnrollVo.getPhoneCode())) { // if (StringUtils.isBlan
// k(phoneCodeOld) || !phoneCodeOld.equals(wxTemporaryEnrollVo.getPhoneCode())) {
// throw new ParamException(RCode.TENCENT_SMS_PHONE_CODE_ERROR, null); // throw new ParamException(RCode.TENCENT_SMS_PHONE_CODE_ERROR, null);
// } // }
// redisCache.removeKey(redisKey); // redisCache.removeKey(redisKey);
......
...@@ -72,12 +72,12 @@ public class TemporaryInfoQueryController { ...@@ -72,12 +72,12 @@ public class TemporaryInfoQueryController {
/** /**
* 注册时获取门店列表 * 注册时获取门店列表
* @param temporaryRegisterVo 临时注册信息 * @param planMonth 计划月份
* @return 门店列表 * @return 门店列表
*/ */
@PostMapping("/temporary/findStoreList") @GetMapping("/temporary/findStoreList")
public R findStoreList(@RequestBody TemporaryRegisterVo temporaryRegisterVo) { public R findStoreList(@RequestParam("planMonth") String planMonth) {
return R.success(weChatUserQueryService.findStoreList(temporaryRegisterVo)); return R.success(weChatUserQueryService.findStoreList(planMonth));
} }
private void phontAndOpenIdVerify(WxTemporaryLoginVo wxTemporaryLoginVo) { private void phontAndOpenIdVerify(WxTemporaryLoginVo wxTemporaryLoginVo) {
......
...@@ -42,9 +42,9 @@ public interface ActivityPlanInfoDao { ...@@ -42,9 +42,9 @@ public interface ActivityPlanInfoDao {
/** /**
* 根据位置信息查询当前月份的促销门店 * 根据位置信息查询当前月份的促销门店
* @param temporaryRegisterVo 查询条件参数 * @param planMonth 查询条件参数
* @return 门店信息列表 * @return 门店信息列表
*/ */
List<Map<String, String>> findThisMonthStoreListByLocation(TemporaryRegisterVo temporaryRegisterVo); List<Map<String, String>> findThisMonthStoreListByLocation(String planMonth);
} }
...@@ -129,19 +129,13 @@ public class ActivityPlanInfoDaoImpl implements ActivityPlanInfoDao { ...@@ -129,19 +129,13 @@ public class ActivityPlanInfoDaoImpl implements ActivityPlanInfoDao {
/** /**
* 根据地理位置信息查询本店本月门店列表 * 根据地理位置信息查询本店本月门店列表
* @param temporaryRegisterVo 查询条件参数 * @param planMonth 查询条件参数
* @return 门店列表 * @return 门店列表
*/ */
@Override @Override
public List<Map<String, String>> findThisMonthStoreListByLocation(TemporaryRegisterVo temporaryRegisterVo) { public List<Map<String, String>> findThisMonthStoreListByLocation(String planMonth) {
LambdaQueryWrapper<ActivityPlanInfoDo> qw = new LambdaQueryWrapper<>(); LambdaQueryWrapper<ActivityPlanInfoDo> qw = new LambdaQueryWrapper<>();
qw.likeRight(ActivityPlanInfoDo::getDate,temporaryRegisterVo.getMonth()); qw.likeRight(ActivityPlanInfoDo::getDate,planMonth);
if (StringUtils.isNotBlank(temporaryRegisterVo.getProvince())){
qw.eq(ActivityPlanInfoDo::getProvince,temporaryRegisterVo.getProvince());
}
if (StringUtils.isNotBlank(temporaryRegisterVo.getCity())){
qw.eq(ActivityPlanInfoDo::getCity,temporaryRegisterVo.getCity());
}
List<ActivityPlanInfoDo> activityPlanInfoDoList = activityPlanInfoMapper.selectList(qw); List<ActivityPlanInfoDo> activityPlanInfoDoList = activityPlanInfoMapper.selectList(qw);
List<Map<String, String>> resultList = activityPlanInfoDoList.stream().map(activityPlanInfoDo -> { List<Map<String, String>> resultList = activityPlanInfoDoList.stream().map(activityPlanInfoDo -> {
Map<String, String> map = new HashMap<>(); Map<String, String> map = new HashMap<>();
......
...@@ -17,7 +17,7 @@ public interface WeChatUserQueryService { ...@@ -17,7 +17,7 @@ public interface WeChatUserQueryService {
LoginVo temporaryLoginByPhone(String phone); LoginVo temporaryLoginByPhone(String phone);
List<Map<String, String>> findStoreList(TemporaryRegisterVo temporaryRegisterVo); List<Map<String, String>> findStoreList(String planMonth);
/** /**
* 根据临时ID查询手机号 * 根据临时ID查询手机号
......
...@@ -91,8 +91,8 @@ public class WeChatUserQueryServiceImpl implements WeChatUserQueryService { ...@@ -91,8 +91,8 @@ public class WeChatUserQueryServiceImpl implements WeChatUserQueryService {
} }
@Override @Override
public List<Map<String, String>> findStoreList(TemporaryRegisterVo temporaryRegisterVo) { public List<Map<String, String>> findStoreList(String planMonth) {
return activityPlanInfoDao.findThisMonthStoreListByLocation(temporaryRegisterVo); return activityPlanInfoDao.findThisMonthStoreListByLocation(planMonth);
} }
@Override @Override
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论