package com.ruoyi.web.modules.merchant.mapper;

import java.util.List;
import org.apache.ibatis.annotations.Param;
import com.ruoyi.web.modules.merchant.domain.BizMerchant;

/**
 * 商户 Mapper
 */
public interface BizMerchantMapper
{
    BizMerchant selectById(@Param("merchantId") Long merchantId);

    List<BizMerchant> selectList(BizMerchant query);

    List<BizMerchant> selectSelectableList();

    int countByCreditCode(@Param("creditCode") String creditCode, @Param("excludeId") Long excludeId);

    int countByIdCardNo(@Param("idCardNo") String idCardNo, @Param("excludeId") Long excludeId);

    int countByMerchantName(@Param("merchantName") String merchantName, @Param("excludeId") Long excludeId);

    int insert(BizMerchant merchant);

    int update(BizMerchant merchant);

    int updateCertStatus(@Param("merchantId") Long merchantId, @Param("certStatus") String certStatus);

    int updateBizComplete(@Param("merchantId") Long merchantId, @Param("bizComplete") String bizComplete);

    int incrementShopCount(@Param("merchantId") Long merchantId);

    int decrementShopCount(@Param("merchantId") Long merchantId);

    int logicDeleteByIds(@Param("ids") List<Long> ids, @Param("updateBy") String updateBy);
}
