diff --git a/eiam-common/src/main/java/cn/topiam/employee/common/repository/app/AppGroupAssociationRepository.java b/eiam-common/src/main/java/cn/topiam/employee/common/repository/app/AppGroupAssociationRepository.java index 579d0d7f..74265be8 100644 --- a/eiam-common/src/main/java/cn/topiam/employee/common/repository/app/AppGroupAssociationRepository.java +++ b/eiam-common/src/main/java/cn/topiam/employee/common/repository/app/AppGroupAssociationRepository.java @@ -66,6 +66,19 @@ public interface AppGroupAssociationRepository extends + " WHERE app_id = :appId", nativeQuery = true) void deleteAllByAppId(@Param(value = "appId") Long appId); + + /** + * 根据应用组ID删除关联 + * + * @param groupId {@link Long} + * @return {@link Boolean} + */ + @Modifying + @Transactional(rollbackFor = Exception.class) + @Query(value = "UPDATE app_group_association SET " + SOFT_DELETE_SET + + " WHERE group_id = :groupId", nativeQuery = true) + void deleteAllByGroupId(@Param(value = "groupId") Long groupId); + /** * 根据应用组ID删除关联 *