/*
 * MIT License
 *
 * Copyright (c) [2023]
 *
 * Permission is hereby granted, free of charge, to any person obtaining a copy
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 */
package com.alipay.altershield.change.exe.dal.mapper;

import com.alipay.altershield.change.exe.dal.dataobject.ExeChangeOrderDO;
import com.alipay.altershield.change.exe.dal.dataobject.ExeChangeOrderParam;
import java.util.List;
import org.apache.ibatis.annotations.Param;

/**
 * This class was generated by Ali-Generator
 * @author xiangyue
 */
public interface ExeChangeOrderMapper {
    /**
     * 根据WHERE条件COUNT
     * @param exeChangeOrderParam
     * @return
     *
     * @mbg.generated
     */
    long countByParam(ExeChangeOrderParam exeChangeOrderParam);

    /**
     * 根据WHERE条件删除
     * @param exeChangeOrderParam
     * @return
     *
     * @mbg.generated
     */
    int deleteByParam(ExeChangeOrderParam exeChangeOrderParam);

    /**
     * 根据主键删除
     * @param orderId
     * @return
     *
     * @mbg.generated
     */
    int deleteByPrimaryKey(String orderId);

    /**
     * 插入单条记录
     * @param record
     * @return
     *
     * @mbg.generated
     */
    int insert(ExeChangeOrderDO record);

    /**
     * 根据字段选择性插入单条记录
     * @param record
     * @return
     *
     * @mbg.generated
     */
    int insertSelective(ExeChangeOrderDO record);

    /**
     * 根据WHERE条件查询，返回不包含长文本字段
     * @param exeChangeOrderParam
     * @return
     *
     * @mbg.generated
     */
    List<ExeChangeOrderDO> selectByParam(ExeChangeOrderParam exeChangeOrderParam);

    /**
     * 根据主键查询
     * @param orderId
     * @return
     *
     * @mbg.generated
     */
    ExeChangeOrderDO selectByPrimaryKey(String orderId);

    /**
     * 根据WHERE条件选择性更新
     * @param record
     * @param exeChangeOrderParam
     * @return
     *
     * @mbg.generated
     */
    int updateByParamSelective(@Param("record") ExeChangeOrderDO record, @Param("exeChangeOrderParam") ExeChangeOrderParam exeChangeOrderParam);

    /**
     * 根据WHERE条件更新，不更新长文本字段
     * @param record
     * @param exeChangeOrderParam
     * @return
     *
     * @mbg.generated
     */
    int updateByParam(@Param("record") ExeChangeOrderDO record, @Param("exeChangeOrderParam") ExeChangeOrderParam exeChangeOrderParam);

    /**
     * 根据主键选择性更新
     * @param record
     * @return
     *
     * @mbg.generated
     */
    int updateByPrimaryKeySelective(ExeChangeOrderDO record);

    /**
     * 根据主键更新，不更新长文本字段
     * @param record
     * @return
     *
     * @mbg.generated
     */
    int updateByPrimaryKey(ExeChangeOrderDO record);

    /**
     * 批量插入
     * @param records
     * @return
     *
     * @mbg.generated
     */
    int batchInsert(List<ExeChangeOrderDO> records);

    /**
     * 根据平台和业务工单id工单信息
     * @param platform
     * @param bizExecOrderId
     * @return
     */
    ExeChangeOrderDO selectByPlatformAndBizOrderId(@Param("platform") String platform, @Param("bizExecOrderId") String bizExecOrderId);

    /**
     * Gets get biz exec order id by order id.
     *
     * @param orderId the order id
     * @return the get biz exec order id by order id
     */
    String getBizExecOrderIdByOrderId(String orderId);

    /**
     * 根据平台和业务工单id工单id
     * @param platform
     * @param bizExecOrderId
     * @return
     */
    String getOrderIdByPlatformAndBizOrderId(@Param("platform") String platform, @Param("bizExecOrderId") String bizExecOrderId);

}