Authored by wangshusheng

缓存

package com.yoho.activity.queue.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.google.common.collect.Lists;
import com.yoho.activity.common.convert.BeanConvert;
import com.yoho.activity.common.redis.CacheKeyEnum;
... ... @@ -228,7 +229,7 @@ public class CutDownPriceServiceImpl implements ICutDownPriceService {
PageResponseBo.class, String.valueOf(request.getPage()), String.valueOf(request.getSize()));
if (cacheResult != null) {
// 处理砍价状态,赋值当前时间
// buildCutStatusAndCurrentTime(cacheResult);
buildCutStatusAndCurrentTime(cacheResult);
return cacheResult;
}
// 查询我的砍价列表
... ... @@ -619,6 +620,12 @@ public class CutDownPriceServiceImpl implements ICutDownPriceService {
if (CollectionUtils.isEmpty(productList)) {
return;
}
for (int i = 0; i < productList.size(); i++) {
Object o = productList.get(i);
if (o instanceof JSONObject) {
productList.set(i, ((JSONObject) o).toJavaObject(CutDownPriceActivityProductBo.class));
}
}
for (CutDownPriceActivityProductBo bo : productList) {
buildCutStatus(bo);
}
... ...