| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.yeshi.fanli.entity.goods.CommonGoods; |
| | | import com.yeshi.fanli.lijin.manager.GoodsLijinMnager; |
| | | import com.yeshi.fanli.util.CommonGoodsUtil; |
| | | import com.yeshi.fanli.util.factory.CommonGoodsFactory; |
| | | import org.springframework.cache.annotation.Cacheable; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | |
| | | |
| | | JSONArray array = new JSONArray(); |
| | | Gson gson = JsonUtil.getConvertBigDecimalToStringSubZeroBuilder(new GsonBuilder()).create(); |
| | | List<TaoBaoGoodsBrief> goodsList = new ArrayList<>(); |
| | | List<CommonGoods> goodsList = new ArrayList<>(); |
| | | if (result != null) |
| | | goodsList = result.getGoodsList(); |
| | | |
| | | GoodsMoneyConfigParamsDTO paramsDTO = orderHongBaoMoneyComputeService.getShowComputeRate(acceptData.getPlatform(), |
| | | acceptData.getVersion(), acceptData.getSystem()); |
| | | |
| | | List<GoodsDetailVO> goodsDetailVOList = goodsLijinMnager.loadTBMoneyInfo(acceptData.getSystem(), uid, goodsList, paramsDTO); |
| | | List<GoodsDetailVO> goodsDetailVOList = goodsLijinMnager.loadCommonGoodsMoneyInfo(acceptData.getSystem(), uid, goodsList, paramsDTO); |
| | | int p = 0; |
| | | for (GoodsDetailVO vo : goodsDetailVOList) { |
| | | vo.setCreatetime(null); |
| | | if (type == CommonContentTypeEnum.mianDan)// 免单商品 |
| | | { |
| | | vo.getMoneyInfo().setFanliMoney("¥" + TaoBaoUtil.getCouponPrice(goodsList.get(p))); |
| | | vo.getMoneyInfo().setShareMoney("¥" + TaoBaoUtil.getCouponPrice(goodsList.get(p))); |
| | | vo.getMoneyInfo().setFanliMoney("¥" + CommonGoodsUtil.getAfterUseCouplePrice(goodsList.get(p))); |
| | | vo.getMoneyInfo().setShareMoney("¥" + CommonGoodsUtil.getAfterUseCouplePrice(goodsList.get(p))); |
| | | vo.getMoneyInfo().setMaxMoney(null); |
| | | } |
| | | array.add(gson.toJson(vo)); |
| | |
| | | && searchResult.getTaoBaoGoodsBriefs().size() > 0) { |
| | | CommonContentResult result = new CommonContentResult(); |
| | | result.setCount(searchResult.getPageEntity().getTotalCount()); |
| | | result.setGoodsList(searchResult.getTaoBaoGoodsBriefs()); |
| | | result.setGoodsList(CommonGoodsFactory.createTaoBaoList(searchResult.getTaoBaoGoodsBriefs())); |
| | | return result; |
| | | } |
| | | return null; |