package com.cool.store.mapper;

import com.cool.store.entity.SigningBaseInfoDO;
import com.cool.store.request.IntentAgreementSubmitRequest;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface IntentAgreementMapper {

    boolean insert(@Param("request") SigningBaseInfoDO request);

    SigningBaseInfoDO selectByPartnerIdOrLineId(@Param("partnerId") String partnerId,
                                                @Param("lineId") Long lineId);

    /**
     * 判断身份证或营业执照是否有重复
     * @param request
     * @return
     */
    SigningBaseInfoDO judge(@Param("request") IntentAgreementSubmitRequest request);

    void updateAuditId(@Param("lineId") Long id,
                       @Param("auditId") Long auditId);


    /**
     *  查询签约信息
     * @param lineIds
     * @return
     */
    List<SigningBaseInfoDO> selectByLineIds(List<Long>  lineIds);

    SigningBaseInfoDO selectByMobile(String mobile,String idCard);
}
