package common.repository;

import common.model.ContractRelation;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import java.util.List;


/**
 * 合同 关联信息
 */
public interface ContractRelationRepository extends JpaRepository<ContractRelation, Long> {

    @Query(value = "select  relation_id from contract_relation where main_contract  = ?1",nativeQuery = true)
    List<Long> findRelationIds(String contractId);
}
