diff --git a/nursing-unit-admin/nu-admin-biz/src/main/java/com/nu/modules/bizEmployeesInfo/controller/NuBizEmployeesServcieTagsController.java b/nursing-unit-admin/nu-admin-biz/src/main/java/com/nu/modules/bizEmployeesInfo/controller/NuBizEmployeesServcieTagsController.java index c864538..fda7aaa 100644 --- a/nursing-unit-admin/nu-admin-biz/src/main/java/com/nu/modules/bizEmployeesInfo/controller/NuBizEmployeesServcieTagsController.java +++ b/nursing-unit-admin/nu-admin-biz/src/main/java/com/nu/modules/bizEmployeesInfo/controller/NuBizEmployeesServcieTagsController.java @@ -83,6 +83,7 @@ public class NuBizEmployeesServcieTagsController extends JeecgController add(@RequestBody NuBizEmployeesServcieTags nuBizEmployeesServcieTags) { nuBizEmployeesServcieTagsService.save(nuBizEmployeesServcieTags); @@ -112,12 +113,13 @@ public class NuBizEmployeesServcieTagsController extends JeecgController delete(@RequestParam(name="id",required=true) String id) { nuBizEmployeesServcieTagsService.removeById(id); return Result.OK("删除成功!"); } - + /** * 批量删除 * @@ -132,7 +134,7 @@ public class NuBizEmployeesServcieTagsController extends JeecgController addBatch(@RequestBody List serverList) { + nuBizNuCustomerServerService.addBatch(serverList); + return Result.OK("操作成功"); + } + + } diff --git a/nursing-unit-api/src/main/java/com/nu/modules/NuBizNuCustomerServer/service/INuBizNuCustomerServerService.java b/nursing-unit-api/src/main/java/com/nu/modules/NuBizNuCustomerServer/service/INuBizNuCustomerServerService.java index 3534c3b..bc9c7a9 100644 --- a/nursing-unit-api/src/main/java/com/nu/modules/NuBizNuCustomerServer/service/INuBizNuCustomerServerService.java +++ b/nursing-unit-api/src/main/java/com/nu/modules/NuBizNuCustomerServer/service/INuBizNuCustomerServerService.java @@ -19,4 +19,6 @@ public interface INuBizNuCustomerServerService extends IService serverList); } diff --git a/nursing-unit-api/src/main/java/com/nu/modules/NuBizNuCustomerServer/service/impl/NuBizNuCustomerServerServiceImpl.java b/nursing-unit-api/src/main/java/com/nu/modules/NuBizNuCustomerServer/service/impl/NuBizNuCustomerServerServiceImpl.java index 3e4b543..1509864 100644 --- a/nursing-unit-api/src/main/java/com/nu/modules/NuBizNuCustomerServer/service/impl/NuBizNuCustomerServerServiceImpl.java +++ b/nursing-unit-api/src/main/java/com/nu/modules/NuBizNuCustomerServer/service/impl/NuBizNuCustomerServerServiceImpl.java @@ -93,4 +93,22 @@ public class NuBizNuCustomerServerServiceImpl extends ServiceImpl serverList) { + if(serverList.size()>0){ + NuBizNuCustomerServer nuBizNuCustomerServer = serverList.get(0); + String nuId = nuBizNuCustomerServer.getNuId(); + String customerId = nuBizNuCustomerServer.getCustomerId(); + + QueryWrapper nuBizNuCustomerServerQueryWrapper = new QueryWrapper<>(); + nuBizNuCustomerServerQueryWrapper.eq("nu_id",nuId); + nuBizNuCustomerServerQueryWrapper.eq("customer_id",customerId); + baseMapper.delete(nuBizNuCustomerServerQueryWrapper); + + for(NuBizNuCustomerServer par : serverList){ + baseMapper.insert(par); + } + } + } }