package com.xisc.pm.infra.repository.impl;

import com.xisc.pm.api.dto.PmPolicyReqDTO;
import com.xisc.pm.domain.entity.PmPolicy;
import com.xisc.pm.domain.repository.PmPolicyRepository;
import com.xisc.pm.infra.mapper.PmPolicyMapper;
import org.hzero.mybatis.base.impl.BaseRepositoryImpl;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;
import java.util.List;

/**
 * 策略信息表(PmPolicy)资源库
 *
 * @author 纪文桃 wentao.ji01@hand-china.com
 * @since 2024-10-16 10:43:06
 */
@Component
public class PmPolicyRepositoryImpl extends BaseRepositoryImpl<PmPolicy> implements PmPolicyRepository {
    @Resource
    private PmPolicyMapper pmPolicyMapper;

    @Override
    public List<PmPolicy> selectList(PmPolicyReqDTO dto, Long tenantId, List<Long> policyIdList, List<String> stNoList) {
        return pmPolicyMapper.selectList(dto, tenantId, policyIdList, stNoList);
    }

    @Override
    public List<PmPolicy> selectByPolicyGroupId(Long tenantId, Long policyGroupId) {
        return pmPolicyMapper.selectByPolicyGroupId(tenantId, policyGroupId);
    }
}
