...
|
...
|
@@ -112,7 +112,7 @@ public class TencentMktServiceImpl implements ITencentMktService { |
|
|
ProfileInfoRsp result = service.call("users.getUserprofileByEmailOrMobile", bo, ProfileInfoRsp.class);
|
|
|
log.info("call users.getUserprofileByEmailOrMobile result is {}", result);
|
|
|
|
|
|
TencentMktActivityBO activity = getActivityInfoByCode(activityCode);
|
|
|
TencentMktActivityBO activity = getActivityInfoByUnionType(activityCode);
|
|
|
|
|
|
if(result != null && result.getUid() != 0){
|
|
|
//判断是否领取过
|
...
|
...
|
@@ -193,7 +193,7 @@ public class TencentMktServiceImpl implements ITencentMktService { |
|
|
|
|
|
//已注册的用户,再去判断是否是未购买的用户
|
|
|
//根据活动id,获取活动详情
|
|
|
TencentMktActivityBO bo = getActivityInfoByCode(activityCode);
|
|
|
TencentMktActivityBO bo = getActivityInfoByUnionType(activityCode);
|
|
|
if (!checkUser(response, bo)) {
|
|
|
log.warn("validCodeAndSendCode error register error with code={}, area={}, mobile={}, activityCode={}", code, area, mobile, activityCode);
|
|
|
return response;
|
...
|
...
|
@@ -316,6 +316,18 @@ public class TencentMktServiceImpl implements ITencentMktService { |
|
|
return response.get();
|
|
|
}
|
|
|
|
|
|
public TencentMktActivityBO getActivityInfoByUnionType(String unionType) {
|
|
|
|
|
|
MktMarketingUrl mktMarketingUrl = mktMarketingUrlDAO.selectByPrimaryKey(Long.parseLong(unionType));
|
|
|
|
|
|
if (mktMarketingUrl == null || StringUtils.isBlank(mktMarketingUrl.getMktActivityCode())) {
|
|
|
log.error("no tencent mkt mktMarketingUrl exists");
|
|
|
return null;
|
|
|
}
|
|
|
|
|
|
return getActivityInfoByCode(mktMarketingUrl.getMktActivityCode());
|
|
|
}
|
|
|
|
|
|
public TencentMktActivityBO getActivityInfoByCode(String activityCode) {
|
|
|
TencentMktActivityBO activityBO = CacheKeyHelper.string2Value(yhValueOperations.get(getCacheKey(activityCode)), TencentMktActivityBO.class);
|
|
|
if(activityBO != null) {
|
...
|
...
|
@@ -323,8 +335,6 @@ public class TencentMktServiceImpl implements ITencentMktService { |
|
|
return activityBO;
|
|
|
}
|
|
|
|
|
|
//缓存不命中,从数据库获取
|
|
|
|
|
|
|
|
|
TencentMktActivity db = tencentMktActivityDAO.selectByActivityCode(activityCode);
|
|
|
if (db == null) {
|
...
|
...
|
|