package com.hw.dms.mapper;

import java.util.List;

import com.hw.dms.domain.DmsBillsMaintDetail;
import com.hw.dms.domain.DmsBillsMaintInstance;

/**
 * 保养工单Mapper接口
 *
 * @author Open Platform
 * @date 2024-02-29
 */
public interface DmsBillsMaintInstanceMapper {
    /**
     * 查询保养工单
     *
     * @param maintInstanceId 保养工单主键
     * @return 保养工单
     */
    public DmsBillsMaintInstance selectDmsBillsMaintInstanceByMaintInstanceId(Long maintInstanceId);

    /**
     * 查询保养工单列表
     *
     * @param dmsBillsMaintInstance 保养工单
     * @return 保养工单集合
     */
    public List<DmsBillsMaintInstance> selectDmsBillsMaintInstanceList(DmsBillsMaintInstance dmsBillsMaintInstance);

    /**
     * 新增保养工单
     *
     * @param dmsBillsMaintInstance 保养工单
     * @return 结果
     */
    public int insertDmsBillsMaintInstance(DmsBillsMaintInstance dmsBillsMaintInstance);

    /**
     * 修改保养工单
     *
     * @param dmsBillsMaintInstance 保养工单
     * @return 结果
     */
    public int updateDmsBillsMaintInstance(DmsBillsMaintInstance dmsBillsMaintInstance);

    /**
     * 删除保养工单
     *
     * @param maintInstanceId 保养工单主键
     * @return 结果
     */
    public int deleteDmsBillsMaintInstanceByMaintInstanceId(Long maintInstanceId);

    /**
     * 批量删除保养工单
     *
     * @param maintInstanceIds 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteDmsBillsMaintInstanceByMaintInstanceIds(Long[] maintInstanceIds);




    /**
     * 批量新增保养工单明细
     *
     * @param dmsBillsMaintDetailList 保养工单明细列表
     * @return 结果
     */
    public int batchDmsBillsMaintDetail(List<DmsBillsMaintDetail> dmsBillsMaintDetailList);

    /**
     * 查询最新一条保养工单，Join 第一步节点
     *
     * @param dmsBillsMaintInstance 保养工单
     * @return 保养工单
     */
    public DmsBillsMaintInstance selectNewestDmsBillsMaintInstance(DmsBillsMaintInstance dmsBillsMaintInstance);
}
