diff --git a/jeecg-module-auto-process/src/main/java/org/jeecg/modules/properties/SpectrumPathProperties.java b/jeecg-boot-base-core/src/main/java/org/jeecg/common/properties/SpectrumPathProperties.java similarity index 86% rename from jeecg-module-auto-process/src/main/java/org/jeecg/modules/properties/SpectrumPathProperties.java rename to jeecg-boot-base-core/src/main/java/org/jeecg/common/properties/SpectrumPathProperties.java index 11794f5c..ba2ac55a 100644 --- a/jeecg-module-auto-process/src/main/java/org/jeecg/modules/properties/SpectrumPathProperties.java +++ b/jeecg-boot-base-core/src/main/java/org/jeecg/common/properties/SpectrumPathProperties.java @@ -1,4 +1,4 @@ -package org.jeecg.modules.properties; +package org.jeecg.common.properties; import lombok.Data; import org.springframework.boot.context.properties.ConfigurationProperties; @@ -13,7 +13,7 @@ import java.util.Map; */ @Data @Component -@ConfigurationProperties(prefix = "file-system") +@ConfigurationProperties(prefix = "filesystem") public class SpectrumPathProperties implements Serializable { /** diff --git a/jeecg-module-auto-process/src/main/java/org/jeecg/modules/properties/TaskProperties.java b/jeecg-boot-base-core/src/main/java/org/jeecg/common/properties/TaskProperties.java similarity index 95% rename from jeecg-module-auto-process/src/main/java/org/jeecg/modules/properties/TaskProperties.java rename to jeecg-boot-base-core/src/main/java/org/jeecg/common/properties/TaskProperties.java index f3d3b2db..f8789796 100644 --- a/jeecg-module-auto-process/src/main/java/org/jeecg/modules/properties/TaskProperties.java +++ b/jeecg-boot-base-core/src/main/java/org/jeecg/common/properties/TaskProperties.java @@ -1,4 +1,4 @@ -package org.jeecg.modules.properties; +package org.jeecg.common.properties; import lombok.Data; import org.springframework.boot.context.properties.ConfigurationProperties; diff --git a/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/controller/AlarmContactGroupController.java b/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/controller/AlarmContactGroupController.java index 0d2981dc..25640db7 100644 --- a/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/controller/AlarmContactGroupController.java +++ b/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/controller/AlarmContactGroupController.java @@ -45,4 +45,10 @@ public class AlarmContactGroupController { return alarmContactGroupService.deleteById(id); } + @DeleteMapping("deleteUserById") + @ApiOperation(value = "删除报警人联系人组下单独联系人", notes = "删除报警联系人组下单独联系人") + public Result deleteUserById(String id, String userId){ + return alarmContactGroupService.deleteUserById(id, userId); + } + } diff --git a/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/service/IAlarmContactGroupService.java b/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/service/IAlarmContactGroupService.java index 8bb41e4a..7ce6721f 100644 --- a/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/service/IAlarmContactGroupService.java +++ b/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/service/IAlarmContactGroupService.java @@ -17,4 +17,6 @@ public interface IAlarmContactGroupService extends IService { Result deleteById(String id); + Result deleteUserById(String id, String userId); + } diff --git a/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/service/impl/AlarmContactGroupServiceImpl.java b/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/service/impl/AlarmContactGroupServiceImpl.java index b5a09484..75447336 100644 --- a/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/service/impl/AlarmContactGroupServiceImpl.java +++ b/jeecg-module-abnormal-alarm/src/main/java/org/jeecg/modules/service/impl/AlarmContactGroupServiceImpl.java @@ -36,7 +36,7 @@ public class AlarmContactGroupServiceImpl extends ServiceImpl userList = systemClient.findUserMap(); - Page page = new Page<>(); + Page page = new Page<>(queryRequest.getPageNo(), queryRequest.getPageSize()); LambdaQueryWrapper queryWrapper = new LambdaQueryWrapper<>(); Page alarmContactGroupPage = this.baseMapper.selectPage(page, queryWrapper); LambdaQueryWrapper contactGroupMemberQueryWrapper = new LambdaQueryWrapper<>(); @@ -101,6 +101,7 @@ public class AlarmContactGroupServiceImpl extends ServiceImpl userIds = alarmContactGroup.getUserIds(); for (String userId:userIds) { @@ -167,4 +168,16 @@ public class AlarmContactGroupServiceImpl extends ServiceImpl contactGroupMemberQueryWrapper = new LambdaQueryWrapper<>(); + contactGroupMemberQueryWrapper.eq(AlarmContactGroupMember::getGroupId, id); + contactGroupMemberQueryWrapper.eq(AlarmContactGroupMember::getUserId, userId); + alarmContactGroupMemberMapper.delete(contactGroupMemberQueryWrapper); + result.setSuccess(true); + result.success("删除成功"); + return result; + } + } diff --git a/jeecg-module-auto-process/src/main/java/org/jeecg/modules/AutoProcessManager.java b/jeecg-module-auto-process/src/main/java/org/jeecg/modules/AutoProcessManager.java index 18ef29ae..492d919e 100644 --- a/jeecg-module-auto-process/src/main/java/org/jeecg/modules/AutoProcessManager.java +++ b/jeecg-module-auto-process/src/main/java/org/jeecg/modules/AutoProcessManager.java @@ -9,8 +9,8 @@ import org.jeecg.common.util.RedisUtil; import org.jeecg.modules.email.EmailParsingActuator; import org.jeecg.modules.emuns.SysMailEnableType; import org.jeecg.modules.email.EmailProperties; -import org.jeecg.modules.properties.SpectrumPathProperties; -import org.jeecg.modules.properties.TaskProperties; +import org.jeecg.common.properties.SpectrumPathProperties; +import org.jeecg.common.properties.TaskProperties; import org.jeecg.modules.service.ISysMailService; import org.springframework.stereotype.Component; import org.springframework.util.CollectionUtils; diff --git a/jeecg-module-auto-process/src/main/java/org/jeecg/modules/email/EmailParsingActuator.java b/jeecg-module-auto-process/src/main/java/org/jeecg/modules/email/EmailParsingActuator.java index 4b06c8c1..f33d8c93 100644 --- a/jeecg-module-auto-process/src/main/java/org/jeecg/modules/email/EmailParsingActuator.java +++ b/jeecg-module-auto-process/src/main/java/org/jeecg/modules/email/EmailParsingActuator.java @@ -3,7 +3,7 @@ package org.jeecg.modules.email; import org.apache.commons.lang3.ArrayUtils; import org.jeecg.common.email.EmailServiceManager; import org.jeecg.common.util.FTPUtil; -import org.jeecg.modules.properties.TaskProperties; +import org.jeecg.common.properties.TaskProperties; import org.jeecg.modules.spectrum.SpectrumParsingActuator; import org.springframework.scheduling.concurrent.CustomizableThreadFactory; import javax.mail.Message;