yujian
2019-09-25 8b3ef26b10d1dced4408dee62cc1a18f72205cd0
fanli/src/main/java/com/yeshi/fanli/service/impl/brand/BrandInfoServiceImpl.java
@@ -71,9 +71,13 @@
   @Override
   public void saveObject(MultipartFile file, BrandInfo record) throws BrandInfoException {
      String name = record.getName();
      if (name == null || name.trim().length() == 0)
      if (StringUtil.isNullOrEmpty(name))
         throw new BrandInfoException(1, "名称不能为空");
      String searchKey = record.getSearchKey();
      if (StringUtil.isNullOrEmpty(searchKey))
         record.setSearchKey(name);
      Integer state = record.getState();
      if (state == null)
         record.setState(0);
@@ -212,8 +216,9 @@
         return;
      for (BrandInfo brandInfo : list) {
         String key = brandInfo.getName();
         if (StringUtil.isNullOrEmpty(key))
         String name = brandInfo.getName();
         String searchKey = brandInfo.getSearchKey();
         if (StringUtil.isNullOrEmpty(name) && StringUtil.isNullOrEmpty(searchKey))
            continue;
         // 添加商品