From e7920b14a9baab97035a1a529da85d124a2bcacd Mon Sep 17 00:00:00 2001 From: yujian <yujian@163.com> Date: 星期二, 16 六月 2020 10:54:29 +0800 Subject: [PATCH] 云发单对测试用户显示 --- fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java | 32 ++++++++++++++++++++++++-------- 1 files changed, 24 insertions(+), 8 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java b/fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java index bf01463..c1dda2a 100644 --- a/fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java +++ b/fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java @@ -66,7 +66,6 @@ import com.yeshi.fanli.util.MoneyBigDecimalUtil; import com.yeshi.fanli.util.RedisManager; import com.yeshi.fanli.util.StringUtil; -import com.yeshi.fanli.util.TimeUtil; import com.yeshi.fanli.util.cache.JDGoodsCacheUtil; import com.yeshi.fanli.util.cache.PinDuoDuoCacheUtil; import com.yeshi.fanli.util.factory.goods.GoodsDetailVOFactory; @@ -1419,7 +1418,14 @@ public GoodsEvaluate getById(String id) { return goodsEvaluateDao.getById(id); } + + + @Override + public List<GoodsEvaluate> listByStartTime(Date date) { + return goodsEvaluateDao.listByStartTime(date); + } + @Override public void saveComment(String pid, CommentInfo commentInfo) throws GoodsEvaluateException { GoodsEvaluate goodsEvaluate = goodsEvaluateDao.getById(pid); @@ -1921,7 +1927,7 @@ throw new GoodsEvaluateException(1, "鐩稿叧鍙傛暟涓嶈兘涓虹┖"); } - List<GoodsEvaluate> evaluateList = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_TAOBAO, Long.parseLong(goodsId)); + List<GoodsEvaluate> evaluateList = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_TAOBAO, goodsId); if (evaluateList != null && evaluateList.size() > 0) return; @@ -2311,7 +2317,7 @@ return; } List<GoodsEvaluate> queryExist = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_TAOBAO, - goods.getAuctionId()); + goods.getAuctionId()+""); if (queryExist == null || queryExist.size() == 0) { return; } @@ -2331,7 +2337,7 @@ if (jdGoods == null) { return; } - List<GoodsEvaluate> queryExist = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_JD, jdGoods.getSkuId()); + List<GoodsEvaluate> queryExist = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_JD, jdGoods.getSkuId()+""); if (queryExist == null || queryExist.size() == 0) { return; } @@ -2348,7 +2354,7 @@ if (pddGoods == null) { return; } - List<GoodsEvaluate> queryExist = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_PDD, pddGoods.getGoodsId()); + List<GoodsEvaluate> queryExist = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_PDD, pddGoods.getGoodsId()+""); if (queryExist == null || queryExist.size() == 0) { return; } @@ -2365,7 +2371,7 @@ return; } List<GoodsEvaluate> queryExist = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_VIP, - Long.parseLong(goods.getGoodsId())); + goods.getGoodsId()); if (queryExist == null || queryExist.size() == 0) { return; } @@ -2382,7 +2388,7 @@ return; } List<GoodsEvaluate> queryExist = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_SUNING, - Long.parseLong(goods.getCommodityInfo().getCommodityCode())); + goods.getCommodityInfo().getCommodityCode()); if (queryExist == null || queryExist.size() == 0) { return; } @@ -2442,7 +2448,7 @@ if (goodsId == null) { return; } - List<GoodsEvaluate> list = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_TAOBAO,Long.parseLong(goodsId)); + List<GoodsEvaluate> list = goodsEvaluateDao.queryExist(Constant.SOURCE_TYPE_TAOBAO,goodsId); if (list == null || list.size() == 0) { return; } @@ -2536,4 +2542,14 @@ } } + + @Override + public GoodsEvaluate queryExistSingle(String goodsId, int goodsType) { + List<GoodsEvaluate> list = goodsEvaluateDao.queryExistSingle(goodsType, goodsId); + if (list != null && list.size() > 0) + return list.get(0); + return null; + } + + } -- Gitblit v1.8.0