|
@@ -105,6 +105,19 @@ public class SearchIndexApi {
|
|
|
return searchIndexService.updateProductIndexById(updateIndexDto.getProductId());
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * 根据多个商品Id更新
|
|
|
+ */
|
|
|
+ @ApiOperation("根据多个商品Id更新")
|
|
|
+ @PostMapping("/update/products")
|
|
|
+ public ResponseJson updateProductsIndex(String productIds) {
|
|
|
+ String[] productIdArr = productIds.split(",");
|
|
|
+ for (String productId : productIdArr) {
|
|
|
+ searchIndexService.updateProductIndexById(Integer.parseInt(productId));
|
|
|
+ }
|
|
|
+ return ResponseJson.success();
|
|
|
+ }
|
|
|
+
|
|
|
/**
|
|
|
* 根据供应商Id更新
|
|
|
*
|