yujian
2019-11-11 fdb089cb8bee6099efcbd7b0ca2672c63cbb6784
fanli/src/main/java/com/yeshi/fanli/service/impl/shop/BanLiShopGoodsServiceImpl.java
@@ -133,7 +133,7 @@
         return;
      if (goods.getUpdateTime() == null)
         goods.setUpdateTime(new Date());
      banLiShopGoodsMapper.updateByPrimaryKeySelective(goods);
   }
@@ -156,4 +156,16 @@
            banLiShopGoodsSetService.deleteByPrimaryKey(set.getId());
   }
   @Override
   public void addSalesCount(Long id, int count) {
      BanLiShopGoods goods = selectByPrimaryKey(id);
      if (goods != null) {
         BanLiShopGoods update = new BanLiShopGoods(id);
         update.setSalesCount(goods.getSalesCount() + count);
         update.setUpdateTime(new Date());
         updateSelectiveByPrimaryKey(goods);
      }
   }
}