package com.sunxung.factoring.service.signconfirmation;

import com.baomidou.mybatisplus.extension.service.IService;
import com.sunxung.factoring.entity.businessmanagement.BusinessBasicInfo;
import com.sunxung.factoring.entity.customerinformation.ElectronicSignaturePersonal;
import com.sunxung.factoring.entity.project.vo.BusinessProcessingTaskVo;
import com.sunxung.factoring.entity.project.vo.SearchBusinessProcessingTask;
import com.sunxung.factoring.entity.signconfirmation.SignConfirmation;
import com.sunxung.factoring.entity.signconfirmation.SignConfirmationApproval;
import com.sunxung.factoring.entity.sys.FileStorage;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * <p>
 * --销售合同审核人员信息历史表 服务类
 * </p>
 *
 * @author liutao
 * @since 2023-05-16
 */
public interface ISignConfirmationService extends IService<SignConfirmation> {

    /**
     * 开启流程
     * @param moduleName
     * @param electronicSignaturePersonal
     * @param files
     * @param businessBasicInfo
     * @param id
     */
    void startProcess(String moduleName, ElectronicSignaturePersonal electronicSignaturePersonal, List<FileStorage> files, BusinessBasicInfo businessBasicInfo, Long id);

    /**
     * 根据id查询所需数据 流程控制反射调用
     *
     * @param id
     * @return
     */
    SignConfirmation get(Long id);

    /**
     * 签署确认
     * @param signConfirmation
     */
    void confirm(SignConfirmation signConfirmation);

    /**
     * 法务审核
     * @param signConfirmationApproval
     */
    void approval(SignConfirmationApproval signConfirmationApproval);

    List<BusinessProcessingTaskVo> findMyCompletedList(SearchBusinessProcessingTask search);

    List<BusinessProcessingTaskVo> findAllList(SearchBusinessProcessingTask search);

    void downloadAllFile(HttpServletResponse response, Long id);

    void downloadReportFileZip(HttpServletResponse response, Long id);
}
