package com.qmth.distributed.print.business.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.qmth.distributed.print.business.bean.dto.ExamTaskDetailDto;
import com.qmth.distributed.print.business.bean.params.RelatePaperParam;
import com.qmth.distributed.print.business.entity.ExamCard;
import com.qmth.distributed.print.business.entity.ExamTaskDetail;

import java.io.IOException;
import java.util.List;
import java.util.Map;

/**
 * <p>
 * 命题任务明细表（入库申请） 服务类
 * </p>
 *
 * @author xf
 * @since 2021-03-23
 */
public interface ExamTaskDetailService extends IService<ExamTaskDetail> {

    boolean enable(ExamTaskDetail examTaskDetail) throws IOException;

    boolean updatePaper(RelatePaperParam paperParam) throws IOException;

    IPage<ExamTaskDetailDto> list(String relateType, List<Long> printPlanId, String courseCode, String paperNumber,String userName,Long cardRuleId, Integer pageNumber, Integer pageSize);

    List<ExamTaskDetail> listByCardId(Long cardId);

    void bindCardId(String examTaskId, ExamCard examCard);

    void resetCardId(Long id);

    List<ExamTaskDetail> listByTemplateId(Long templateId);

    List<Map<String, String>>  getPaperUrl(Long schoolId, Long printPlanId, Long examTaskId);

    boolean paperUpdate(ExamTaskDetail examTaskDetail);

    ExamTaskDetail getByExamTaskId(Long examTaskId);
}
