admin
2020-02-23 6543afb9698fcdd89fdffba5f71b3df97c7b0833
fanli/src/main/java/com/yeshi/fanli/service/impl/dynamic/GoodsEvaluateServiceImpl.java
@@ -76,7 +76,7 @@
   private PinDuoDuoCacheUtil pinDuoDuoCacheUtil;
   @Override
   public void saveHead(MultipartFile file, GoodsEvaluate record) throws GoodsEvaluateException {
   public String saveHead(MultipartFile file, GoodsEvaluate record) throws GoodsEvaluateException {
      Integer state = record.getState();
      if (state == null) {
         state = 0;
@@ -119,13 +119,15 @@
         record.setStartTime(new Date());
      record.setPublishTime(record.getStartTime());
      if (StringUtil.isNullOrEmpty(record.getId())) {
         record.setId(UUID.randomUUID().toString().replace("-", ""));
      String id = record.getId();
      if (StringUtil.isNullOrEmpty(id)) {
         id = UUID.randomUUID().toString().replace("-", "");
         record.setId(id);
         record.setShareNumReal(0);
         record.setCreateTime(new Date());
         goodsEvaluateDao.save(record);
      } else {
         GoodsEvaluate resultObj = goodsEvaluateDao.getById(record.getId());
         GoodsEvaluate resultObj = goodsEvaluateDao.getById(id);
         if (resultObj == null)
            throw new GoodsEvaluateException(1, "修改内容已不存在");
@@ -137,6 +139,7 @@
         resultObj.setTitle(tilte);
         goodsEvaluateDao.save(resultObj);
      }
      return id;
   }
   /**