From 30d8e227e8d823b6c38c3b9c90ac2df03b63befe Mon Sep 17 00:00:00 2001 From: admin <weikou2014> Date: 星期二, 25 二月 2025 16:41:22 +0800 Subject: [PATCH] 淘宝转链接口更新 --- fanli/src/main/java/com/yeshi/fanli/service/impl/goods/FreeGoodsCouponServiceImpl.java | 138 +++++++++++++++++++++++----------------------- 1 files changed, 69 insertions(+), 69 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/service/impl/goods/FreeGoodsCouponServiceImpl.java b/fanli/src/main/java/com/yeshi/fanli/service/impl/goods/FreeGoodsCouponServiceImpl.java index e3a2f3e..e9920d4 100644 --- a/fanli/src/main/java/com/yeshi/fanli/service/impl/goods/FreeGoodsCouponServiceImpl.java +++ b/fanli/src/main/java/com/yeshi/fanli/service/impl/goods/FreeGoodsCouponServiceImpl.java @@ -1,69 +1,69 @@ -package com.yeshi.fanli.service.impl.goods; - -import java.util.Date; -import java.util.List; - -import javax.annotation.Resource; - -import org.springframework.stereotype.Service; - -import com.yeshi.fanli.dao.goods.FreeGoodsCouponDao; -import com.yeshi.fanli.entity.goods.FreeGoodsCoupon; -import com.yeshi.fanli.service.inter.goods.FreeGoodsCouponService; -import com.yeshi.fanli.service.inter.order.OrderHongBaoMoneyComputeService; -import com.yeshi.fanli.service.inter.order.config.HongBaoManageService; -import com.yeshi.fanli.util.RedisManager; -import com.yeshi.fanli.vo.goods.GoodsDetailVO; - -@Service -public class FreeGoodsCouponServiceImpl implements FreeGoodsCouponService { - - @Resource - private FreeGoodsCouponDao freeGoodsCouponDao; - - @Resource - private RedisManager redisManager; - - @Resource - private HongBaoManageService hongBaoManageService; - - @Resource - private OrderHongBaoMoneyComputeService orderHongBaoMoneyComputeService; - - - @Override - public boolean saveFreeGoods(GoodsDetailVO detailVO) { - if (detailVO == null) { - return false; - } - - String id = detailVO.getGoodsType() + "#_#" + detailVO.getGoodsId(); - FreeGoodsCoupon freeGoods = new FreeGoodsCoupon(); - freeGoods.setId(id); - freeGoods.setGoodsId(detailVO.getGoodsId()); - freeGoods.setGoodsType(detailVO.getGoodsType()); - freeGoods.setGoods(detailVO); - freeGoods.setCreateTime(new Date()); - freeGoods.setUpdateTime(new Date()); - freeGoodsCouponDao.save(freeGoods); - return true; - } - - - @Override - public void delete(String goodsId, Integer goodsType) { - freeGoodsCouponDao.delete(goodsId + "#_#" + goodsType); - } - - - @Override - public List<FreeGoodsCoupon> listByType(int start, int count, Integer goodsType) { - return freeGoodsCouponDao.listByType(start,count, goodsType); - } - - @Override - public long countByType(Integer goodsType) { - return freeGoodsCouponDao.countByType(goodsType); - } - -} +package com.yeshi.fanli.service.impl.goods; + +import java.util.Date; +import java.util.List; + +import javax.annotation.Resource; + +import org.springframework.stereotype.Service; + +import com.yeshi.fanli.dao.goods.FreeGoodsCouponDao; +import com.yeshi.fanli.entity.goods.FreeGoodsCoupon; +import com.yeshi.fanli.service.inter.goods.FreeGoodsCouponService; +import com.yeshi.fanli.service.inter.order.OrderHongBaoMoneyComputeService; +import com.yeshi.fanli.service.inter.order.config.HongBaoManageService; +import com.yeshi.fanli.util.RedisManager; +import com.yeshi.fanli.vo.goods.GoodsDetailVO; + +@Service +public class FreeGoodsCouponServiceImpl implements FreeGoodsCouponService { + + @Resource + private FreeGoodsCouponDao freeGoodsCouponDao; + + @Resource + private RedisManager redisManager; + + @Resource + private HongBaoManageService hongBaoManageService; + + @Resource + private OrderHongBaoMoneyComputeService orderHongBaoMoneyComputeService; + + + @Override + public boolean saveFreeGoods(GoodsDetailVO detailVO) { + if (detailVO == null) { + return false; + } + + String id = detailVO.getGoodsType() + "#_#" + detailVO.getGoodsId(); + FreeGoodsCoupon freeGoods = new FreeGoodsCoupon(); + freeGoods.setId(id); + freeGoods.setGoodsId(detailVO.getGoodsId()); + freeGoods.setGoodsType(detailVO.getGoodsType()); + freeGoods.setGoods(detailVO); + freeGoods.setCreateTime(new Date()); + freeGoods.setUpdateTime(new Date()); + freeGoodsCouponDao.save(freeGoods); + return true; + } + + + @Override + public void delete(String goodsId, Integer goodsType) { + freeGoodsCouponDao.delete(goodsId + "#_#" + goodsType); + } + + + @Override + public List<FreeGoodsCoupon> listByType(int start, int count, Integer goodsType) { + return freeGoodsCouponDao.listByType(start,count, goodsType); + } + + @Override + public long countByType(Integer goodsType) { + return freeGoodsCouponDao.countByType(goodsType); + } + +} -- Gitblit v1.8.0