diff --git a/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/controller/ItemCategoryController.java b/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/controller/ItemCategoryController.java index c04eb64..d8ecea4 100644 --- a/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/controller/ItemCategoryController.java +++ b/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/controller/ItemCategoryController.java @@ -106,6 +106,7 @@ public class ItemCategoryController extends BaseController { @PostMapping("/update/orderNum") public R updateOrderNum(@RequestBody List tree) { - return toAjax(itemCategoryService.updateOrderNum(tree)); + itemCategoryService.updateOrderNum(tree); + return R.ok(); } } diff --git a/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/mapper/ItemCategoryMapper.java b/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/mapper/ItemCategoryMapper.java index d46270d..ef2901d 100644 --- a/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/mapper/ItemCategoryMapper.java +++ b/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/mapper/ItemCategoryMapper.java @@ -8,5 +8,4 @@ import org.apache.ibatis.annotations.Param; import java.util.List; public interface ItemCategoryMapper extends BaseMapperPlus { - int updateOrderNum(@Param("list") List list); } diff --git a/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/service/ItemCategoryService.java b/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/service/ItemCategoryService.java index 2b390f5..6fdfcef 100644 --- a/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/service/ItemCategoryService.java +++ b/ruoyi-modules/ruoyi-wms-service/src/main/java/com/ruoyi/wms/service/ItemCategoryService.java @@ -213,7 +213,7 @@ public class ItemCategoryService extends ServiceImpl 0; } - public int updateOrderNum(List tree) { + public void updateOrderNum(List tree) { List updateList = new ArrayList<>(); for (int i = 0; i < tree.size(); i++) { ItemCategory itemType = new ItemCategory(); @@ -221,6 +221,6 @@ public class ItemCategoryService extends ServiceImpl - - - - update wms_item_type - set order_num=#{item.orderNum} - where id=#{item.id} - -