# AdjEmailTargetServiceImpl.java

    package cloud.wconnect.frontoffice.service.adjustment.impl;

    import cloud.wconnect.frontoffice.entity.adjustment.AdjEmailTarget;
    import cloud.wconnect.frontoffice.mapper.adjustment.AdjEmailTargetMapper;
    import cloud.wconnect.frontoffice.service.adjustment.IAdjEmailTargetService;
    import com.baomidou.dynamic.datasource.annotation.DS;
    import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
    import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
    import org.apache.commons.collections.CollectionUtils;
    import org.springframework.stereotype.Service;

    import java.util.Collections;
    import java.util.List;

    /**
     * <p>
     * Adjustment Requests 功能的邮件配置（收件人、抄送人）表 服务实现类
     * </p>
     *
     * @author lichen
     * @since 2023-03-30
     */
    @Service
    @DS("logbook")
    public class AdjEmailTargetServiceImpl extends ServiceImpl<AdjEmailTargetMapper, AdjEmailTarget> implements IAdjEmailTargetService {

        /**
         * 查询通知对象
         *
         * @param configIds 配置ID集合
         * @return java.util.List<cloud.wconnect.frontoffice.entity.adjustment.AdjEmailTarget>
         * @author lichen
         * @date 2024/3/11
         */
        @Override
        public List<AdjEmailTarget> listByConfigId(List<Integer> configIds) {
            if (CollectionUtils.isEmpty(configIds)) return Collections.emptyList();
            return list(new LambdaQueryWrapper<AdjEmailTarget>().in(AdjEmailTarget::getConfigId, configIds));
        }

        /**
         * 获取通知对象
         *
         * @param configId 配置ID
         * @return java.util.List<cloud.wconnect.frontoffice.entity.adjustment.AdjEmailTarget>
         * @author yyt
         * @date 2026/3/20
         */
        @Override
        public List<AdjEmailTarget> listByConfigId(Integer configId) {
            return list(new LambdaQueryWrapper<AdjEmailTarget>().eq(AdjEmailTarget::getConfigId, configId));
        }

        /**
         * 删除通知对象
         *
         * @param configId 配置ID
         * @return void
         * @author lichen
         * @date 2024/3/12
         */
        @Override
        public void removeByConfigId(Integer configId) {
            remove(new LambdaQueryWrapper<AdjEmailTarget>()
                    .eq(AdjEmailTarget::getConfigId, configId));
        }
    }