lin
2024-04-10 2d37fa5cf4ebf8bdcae40c5a9f63d561f307e2af
src/main/java/org/springblade/modules/article/controller/ArticleController.java
@@ -178,19 +178,6 @@
      }
      article.setUpdateTime(new Date());
      boolean saveOrUpdate = articleService.saveOrUpdate(article);
      if (saveOrUpdate){
         EsParam esParam = new EsParam();
         esParam.setIndexName("test");
         esParam.setTableName("jczz_article");
         if (flag) {
            // 更新到es库
            elasticsearchDocumentService.addArticle(esParam, article);
         }else {
            esParam.setTableId(article.getId().toString());
            // 更新
            elasticsearchDocumentService.update(esParam,article);
         }
      }
      return R.status(saveOrUpdate);
   }
@@ -204,7 +191,9 @@
   @ApiOperationSupport(order = 8)
   @ApiOperation(value = "删除", notes = "传入ids")
   public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) {
      return R.status(articleService.removeByIds(Func.toLongList(ids)));
      List<Long> longs = Func.toLongList(ids);
      boolean removeByIds = articleService.removeByIds(longs);
      return R.status(removeByIds);
   }
   /**