Authored by Ge

update

@@ -110,16 +110,18 @@ public class TencentMktServiceImpl implements ITencentMktService { @@ -110,16 +110,18 @@ public class TencentMktServiceImpl implements ITencentMktService {
110 return new ApiResponse(503, "手机号码格式不对"); 110 return new ApiResponse(503, "手机号码格式不对");
111 } 111 }
112 112
113 - if(StringUtils.isEmpty(code)){  
114 - log.warn("call getUserprofileByEmailOrMobile. code is null");  
115 - return new ApiResponse(504, "验证码不能为空");  
116 - }  
117 -  
118 - //验证union_type和code能不能对应  
119 - MktUnionCode mktUnionCode =mktUnionCodeMapper.selectByCode(code);  
120 - if (null==mktUnionCode||!activityCode.equals(String.valueOf(mktUnionCode.getUnionType()))){  
121 - log.warn("call getUserprofileByEmailOrMobile. check error");  
122 - return new ApiResponse(506, "校验失败"); 113 + //新的活动链接,必须要带校验code
  114 + if(Long.valueOf(activityCode)>100000000008331L){
  115 + if(StringUtils.isEmpty(code)){
  116 + log.warn("call getUserprofileByEmailOrMobile. code is null");
  117 + return new ApiResponse(506, "校验失败");
  118 + }
  119 + //验证union_type和code能不能对应
  120 + MktUnionCode mktUnionCode =mktUnionCodeMapper.selectByCode(code);
  121 + if (null==mktUnionCode||!activityCode.equals(String.valueOf(mktUnionCode.getUnionType()))){
  122 + log.warn("call getUserprofileByEmailOrMobile. check error");
  123 + return new ApiResponse(506, "校验失败");
  124 + }
123 } 125 }
124 126
125 // 验证新老用户 127 // 验证新老用户
@@ -209,13 +211,20 @@ public class TencentMktServiceImpl implements ITencentMktService { @@ -209,13 +211,20 @@ public class TencentMktServiceImpl implements ITencentMktService {
209 return response; 211 return response;
210 } 212 }
211 213
212 - //验证union_type和code能不能对应  
213 - MktUnionCode mktUnionCode =mktUnionCodeMapper.selectByCode(checkCode);  
214 - if (null==mktUnionCode||!activityCode.equals(String.valueOf(mktUnionCode.getUnionType()))){  
215 - log.warn("call getUserprofileByEmailOrMobile. check error");  
216 - return new ApiResponse(505, "校验失败"); 214 + if(Long.valueOf(activityCode)>100000000008331L){
  215 + if(StringUtils.isEmpty(code)){
  216 + log.warn("call getUserprofileByEmailOrMobile. code is null");
  217 + return new ApiResponse(506, "校验失败");
  218 + }
  219 + //验证union_type和code能不能对应
  220 + MktUnionCode mktUnionCode =mktUnionCodeMapper.selectByCode(checkCode);
  221 + if (null==mktUnionCode||!activityCode.equals(String.valueOf(mktUnionCode.getUnionType()))){
  222 + log.warn("call getUserprofileByEmailOrMobile. check error");
  223 + return new ApiResponse(505, "校验失败");
  224 + }
217 } 225 }
218 226
  227 +
219 // 判断用户是否已经注册过,如果未注册,则调用注册接口 228 // 判断用户是否已经注册过,如果未注册,则调用注册接口
220 // 老用户则直接返回 229 // 老用户则直接返回
221 //看一下这个活动是否设置了老用户也可以领取 230 //看一下这个活动是否设置了老用户也可以领取