package com.hw.qms.service;

import java.util.List;
import com.hw.qms.domain.QmsQualityInstance;
import com.hw.qms.domain.vo.QmsQualityInstanceActivityVo;
import org.springframework.transaction.annotation.Transactional;

/**
 * 质检工单Service接口
 *
 * @author xins
 * @date 2024-01-23
 */
public interface IQmsQualityInstanceService
{
    /**
     * 查询质检工单
     *
     * @param qualityInstanceId 质检工单主键
     * @return 质检工单
     */
    public QmsQualityInstance selectQmsQualityInstanceByQualityInstanceId(Long qualityInstanceId);

    /**
     * 查询质检工单列表
     *
     * @param qmsQualityInstance 质检工单
     * @return 质检工单集合
     */
    public List<QmsQualityInstance> selectQmsQualityInstanceList(QmsQualityInstance qmsQualityInstance);

    /**
     * 新增质检工单
     *
     * @param qmsQualityInstance 质检工单
     * @return 结果
     */
    public int insertQmsQualityInstance(QmsQualityInstance qmsQualityInstance);

    /**
     * 修改质检工单
     *
     * @param qmsQualityInstance 质检工单
     * @return 结果
     */
    public int updateQmsQualityInstance(QmsQualityInstance qmsQualityInstance);

    /**
     * 批量删除质检工单
     *
     * @param qualityInstanceIds 需要删除的质检工单主键集合
     * @return 结果
     */
    public int deleteQmsQualityInstanceByQualityInstanceIds(Long[] qualityInstanceIds);

    /**
     * 删除质检工单信息
     *
     * @param qualityInstanceId 质检工单主键
     * @return 结果
     */
    public int deleteQmsQualityInstanceByQualityInstanceId(Long qualityInstanceId);



    /**
     * 查询质检工单
     *
     * @param checkResultId 质检结果ID
     * @return 质检工单
     */
    public QmsQualityInstance selectQmsQualityInstanceByCheckResultId(Long checkResultId);

    /**
     * 不合格处置保存
     * @param qmsQualityInstanceActivityVo
     * @param fileUrls
     */
    public int handleQualityInstance(QmsQualityInstanceActivityVo qmsQualityInstanceActivityVo, List<String> fileUrls);
}
