Commit 38dbc2d1 by 吴博

hotfix: [1007515] 修改斗罗首页状态

parent 824809f5
......@@ -75,5 +75,16 @@ public class FunctionConsr {
}
return allBookIds;
}
public boolean checkIsUnlock(Long serveId, Long wechatUserId) {
log.info("function.DlBookService.checkIsUnlock()获取所有高清大图解锁信息");
Boolean isUnlock = false;
try {
isUnlock = ResponseHandleUtil.parseResponse( dlBookService.checkIsUnlock(serveId, wechatUserId), Boolean.class);
} catch (Exception e) {
log.error("function.DlBookService.checkIsUnlock()远程调用失败");
}
return isUnlock;
}
}
......@@ -151,6 +151,7 @@ import com.pcloud.common.core.constant.AdviserTaskConstants;
import com.pcloud.common.core.constant.MQTopicProducer;
import com.pcloud.common.core.constant.ProductTypeConstant;
import com.pcloud.common.core.constant.SystemCode;
import com.pcloud.common.enums.AppTypeEnum;
import com.pcloud.common.exceptions.BizException;
import com.pcloud.common.page.PageBeanNew;
import com.pcloud.common.page.PageParam;
......@@ -4570,7 +4571,7 @@ public class ResourcePageBizImpl implements ResourcePageBiz {
itemVOList.sort(Comparator.comparing(ResourcePageItemVO::getId));
}
setChannel(itemVOList);
fillTaskType(itemVOList);
fillTaskType(itemVOList,wechatUserId);
}
if (CollUtil.isNotEmpty(itemVOList)) {
JedisClusterUtils.setJsonList(StrUtil.join(":",DL_BOOK_SERVES_CACHE,sceneId, wechatUserId), itemVOList, 3600 * 24);
......@@ -4599,7 +4600,7 @@ public class ResourcePageBizImpl implements ResourcePageBiz {
}
private void fillTaskType(List<ResourcePageItemVO> itemAppAndProductVOList) {
private void fillTaskType(List<ResourcePageItemVO> itemAppAndProductVOList, Long wechatUserId) {
if (CollUtil.isEmpty(itemAppAndProductVOList)) {
return;
}
......@@ -4613,6 +4614,12 @@ public class ResourcePageBizImpl implements ResourcePageBiz {
if (CollUtil.isNotEmpty(appTaskMap) && null != appTaskMap.get(item.getServeId())) {
item.setTaskType(appTaskMap.get(item.getServeId()));
}
//如果是高清大图 判断是否可以打开
if (AppTypeEnum.IMAGE.value.equals(item.getTypeCode())) {
if (functionConsr.checkIsUnlock(item.getServeId(), wechatUserId)) {
item.setBuyState(true);
};
}
});
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment