package com.prolog.cs.biz.inbound.service.rqc;

import com.prolog.cs.biz.inbound.dto.PageParam;
import com.prolog.cs.biz.inbound.dto.rcv.RcvHAndPDTO;
import com.prolog.cs.biz.inbound.dto.rcv.RcvHDTO;
import com.prolog.cs.biz.inbound.dto.rcv.RcvLinesPicDTO;
import com.prolog.cs.biz.inbound.dto.rqc.RqcDTO;
import com.prolog.cs.biz.inbound.dto.rqc.RqcHeadersDTO;
import com.prolog.cs.biz.inbound.dto.rqc.RqcLinesDTO;
import com.prolog.cs.biz.inbound.dto.task.TaskQcDetailDTO;
import com.prolog.cs.biz.inbound.vo.*;
import com.prolog.cs.biz.inbound.vo.task.TaskQcDetailQueryVO;
import com.prolog.framework.authority.core.dto.UserDTO;
import com.prolog.framework.core.pojo.Page;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * @Description
 * @Date 2021-03-24
 */

public interface RqcHeadersService {

	/**
	 * @Description
	 * @Date 2021-03-24 add RqcHeadersDTO
	 */
	public Object add(RqcHeadersDTO rqcHeadersDTO);

	/**
	 * @Description
	 * @Date 2021-03-24 edit RqcHeadersDTO
	 */
	public Object edit(String pkId, RqcHeadersDTO rqcHeadersDTO);

	/**
	 * @Description
	 * @Date 2021-03-24 delete RqcHeadersDTO
	 */
	public Object deletePkId(String pkId);

	/**
	 * @Description
	 * @Date 2021-03-24 delete RqcHeadersDTO
	 */
	public Object delIds(List<String> pkIdList);

	/**
	 * @Description
	 * @Date 2021-03-24 page condition search RqcHeadersDTO
	 */
	public Page<RqcHeadersDTO> findList(RqcHeadersDTO rqcHeadersDTO, PageParam pageParam);

	/**
	 * @Description
	 * @Date 2021-03-24 batchAdd RqcHeadersDTO
	 */
	public Object batchAdd(List<RqcHeadersDTO> rqcHeadersDTOList);

	/**
	 * @Description
	 * @Date 2021-03-24 batchEdit RqcHeadersDTO
	 */
	public Object batchEdit(List<RqcHeadersDTO> rqcHeadersDTOList);

	/**
	 * @Description
	 * @Date 2021-03-24 condition search all RqcHeadersDTO
	 */
	public List<RqcHeadersDTO> findAll(RqcHeadersDTO rqcHeadersDTO);

	/**
	 * @Description
	 * @Date 2021-03-24 findOne RqcHeadersDTO
	 */
	public RqcHeadersDTO findByPkId(String pkId);

	public Object addWithRelated(RqcDTO rqcDTO);

	public Page<TaskQcDetailDTO> extractRqcTask(TaskQcDetailQueryVO taskQcDetailQueryVO);

	public Page<RcvHAndPDTO> extractRcvH(RcvQueryVO rcvQueryVO, PageParam pageParam);

	Page<RcvHDTO> extractRcvHAndPro(RcvQueryVO rcvQueryVO, PageParam pageParam);

	public Page<RqcHeadersDTO> findList(RqcHQueryVO rqcHQueryVO, PageParam pageParam);

	public Object splitTask(List<TaskQcDetailDTO> taskQcDetailDTOList);

	public Object doException(List<RqcLinesDTO> rqcLinesDTOList);

	/**
	 * 质检完成后打印上架标签的数据 用于测试 orgnName
	 * 
	 * @param rqcHeadersDTO
	 * @param userDTO
	 * @return
	 */
	Object excuteAssembleInstockPrintData(RqcDQueryVO queryVO, RqcHeadersDTO rqcHeadersDTO, UserDTO userDTO,boolean reFlag);

	/**
	 * 获取质检明细打印数据
	 * 
	 * @param queryVO
	 * @return
	 */
	public Object getRqcDetailsPrintData(RqcDQueryVO queryVO);

	public Object getRqcGatherPrintData(RqcHQueryVO queryVO);

	public Object getRqcNoticeHeader(RcvQueryVO rcvQueryVO, PageParam pageParam);

	public Object getRqcNoticeDetails(String rcvHeaderId,String printStatus, PageParam pageParam);

	public Object getRqcNoticePrintData(TaskQcDetailQueryVO queryVo);

	public Object getRqcDetailsList(RqcDQueryVO rqcDQueryVO);

	public Object getRqcInstockLabelPrintData(RqcDQueryVO queryVO);

	public Object checkTaskExcute(List<String> taskIds);

	public List<RcvLinesPicDTO> showRcvLinePic(String rcvLineId);

	public Object taskMerge(List<TaskQcDetailDTO> taskQcDetailDTOList);

	/**
	 * 自动生成质检记录
	 * @param rqcDTO
	 * @return
	 */
	public Object addWithRelatedAuto(RqcDTO rqcDTO);

	public TaskQcDetailDTO getRqcTask(String taskRqcId);

	public Object splitTaskByPad(List<TaskQcDetailDTO> taskQcDetailDTOList);

	public Page<TaskQcDetailDTO> extractRqcTaskByPad(TaskQcDetailQueryVO taskQcDetailQueryVO);

	public Object addWithRelatedByPad(RqcDTO rqcDTO);

	public Page<RcvHDTO> extractRcvHByPad(RcvQueryVO rcvQueryVO, PageParam pageParam);

	public RqcHeadersDTO getRqcHeaderByRcvId(String rcvHeaderId);

	public List<RqcLinesDTO> getHostRqcResult( String itemId, String batchId);

    @Transactional(rollbackFor = Exception.class)
    Object addWithRelatedRf(RqcDTO rqcDTO);

	public Object getRqcNoticeHeaderNew(RcvQueryVO rcvQueryVO, PageParam pageParam);

	public Object getRqcNoticeDetailsNew(String rcvHeaderId, PageParam pageParam);

	public Object getRqcNoticePrintDataNew(RcvLinesQueryVO queryVo);

	public Object getRqcDetailsPrintDataNew(RqcDQueryVO queryVO);

	public Object getRqcInstockLabelPrintDataNew(RqcDQueryVO queryVO);

	Object uploadCircubillRcvDetails(RqcLinesDTO rqcLinesDTO);

    void outBoundUploadCircubill(OutBoundUploadCircubParamVO vo);

	void uploadCircubillTimer();

	void saveSupervisionCodeSmallTimer();

	void toHisSupervisionCodeSmallTimer();

	void saveCusEntIdTimer();

}
