diff --git a/warehousing-system/project/wh-manage-xxs/src/main/java/com/wh/controller/restrictedbrand/RestrictedBrandRest.java b/warehousing-system/project/wh-manage-xxs/src/main/java/com/wh/controller/restrictedbrand/RestrictedBrandRest.java index b8b779c3..15e21408 100644 --- a/warehousing-system/project/wh-manage-xxs/src/main/java/com/wh/controller/restrictedbrand/RestrictedBrandRest.java +++ b/warehousing-system/project/wh-manage-xxs/src/main/java/com/wh/controller/restrictedbrand/RestrictedBrandRest.java @@ -87,13 +87,15 @@ public class RestrictedBrandRest{ } - public ResultBean delBySid(String id) { + @ApiOperation("删除") + @GetMapping("/delBySid/{sid}") + public ResultBean delBySid(@PathVariable("sid") String sid) { ResultBean rb = ResultBean.fireFail(); - RestrictedBrand restrictedBrand = restrictedBrandService.getRestById(id); + RestrictedBrand restrictedBrand = restrictedBrandService.getRestById(sid); if(restrictedBrand == null){ return rb.setMsg("该监管品牌不存在"); } - restrictedBrandService.deleteById(id); + restrictedBrandService.deleteById(sid); return rb.success(); } diff --git a/warehousing-system/project/wh-manage-xxs/src/main/java/com/wh/service/restrictedbrand/RestrictedBrandService.java b/warehousing-system/project/wh-manage-xxs/src/main/java/com/wh/service/restrictedbrand/RestrictedBrandService.java index b7c806b5..e05c871d 100644 --- a/warehousing-system/project/wh-manage-xxs/src/main/java/com/wh/service/restrictedbrand/RestrictedBrandService.java +++ b/warehousing-system/project/wh-manage-xxs/src/main/java/com/wh/service/restrictedbrand/RestrictedBrandService.java @@ -105,17 +105,18 @@ public class RestrictedBrandService extends MybatisBaseService().eq("sid",sid)); } return rb.success(); @@ -199,9 +200,9 @@ public class RestrictedBrandService extends MybatisBaseService qw = new QueryWrapper<>(); - qw.eq("code", code); + qw.eq("sid", sid); List list = baseMapper.selectList(qw); if (list == null || list.isEmpty()) return null;