package cn.superdesk.uniorder.service.invoice.customer;

import cn.superdesk.uniorder.common.enums.invoice.common.InvoiceTypeMoudelXModeEnum;
import cn.superdesk.uniorder.common.exception.UnifiedOrderRuntimeException;
import cn.superdesk.uniorder.common.rest.response.R;
import cn.superdesk.uniorder.common.security.dto.LoginSysUser;
import cn.superdesk.uniorder.dto.param.invoice.customer.InvoiceApplyCustomerQueryCriteria;
import cn.superdesk.uniorder.dto.param.invoice.customer.InvoiceApplyCommonOpApplyForm;
import cn.superdesk.uniorder.dto.param.invoice.customer.InvoiceApplyFocusScoreOpApplyFormV2_1;
import cn.superdesk.uniorder.dto.param.invoice.customer.InvoiceApplyFocusScoreOpApplyReportV2_1;
import cn.superdesk.uniorder.dto.vo.invoice.customer.InvoiceApplyCustomerSelectScoreStruct;
import cn.superdesk.uniorder.dto.vo.invoice.customer.InvoiceApplyCustomerSelectScoreVo;
import cn.superdesk.uniorder.executor.scheduler.kafka._inner.dto.invoice.customer.InvoiceApplyCustomerKafkaEventCheckAndUpdateAccountingOrderFieldInvoiceStatusEvent;

import java.util.List;
import java.util.Map;

/**
 * @Description: 开票申请 拆分
 * 流线 从对账单点开票申请 到 一键分票
 * @Author: linjinyu
 * @CreateDate: 2022/2/24 上午11:49
 * @UpdateUser: linjinyu
 * @UpdateDate: 2022/2/24 上午11:49
 * @UpdateRemark: 修改内容
 * @Version: 1.0
 */
public interface InvoiceApplyCustomerOpCreateService {

    /****************************************** 开票申请相关 start ******************************************/

    List<InvoiceApplyCustomerSelectScoreVo> invoiceApplySelectFocusUnifiedDimOrder(Map<String, Object> params) throws UnifiedOrderRuntimeException;

    List<InvoiceApplyCustomerSelectScoreVo> invoiceApplySelectFocusUnifiedDimGoods(Map<String, Object> params) throws UnifiedOrderRuntimeException;

    List<InvoiceApplyCustomerSelectScoreVo> invoiceApplySelectFocusScoreDimCredit(InvoiceApplyCustomerQueryCriteria criteria) throws UnifiedOrderRuntimeException;

    InvoiceApplyCustomerSelectScoreStruct invoiceApplySelectFocusScoreDimCreditV2_1(InvoiceApplyCustomerQueryCriteria criteria, LoginSysUser loginSysUser) throws UnifiedOrderRuntimeException;


    /**
     * 共用 程序 里边有分支
     *
     * @param params       表单 (关系已经包含到 form 里边 注意 dimCreateBy accountingOrderTypeDim)
     * @param loginSysUser
     * @param invoiceModeEnum
     * @throws UnifiedOrderRuntimeException
     * @return
     */
    InvoiceApplyCustomerKafkaEventCheckAndUpdateAccountingOrderFieldInvoiceStatusEvent opInvoiceApply(InvoiceApplyCommonOpApplyForm params, LoginSysUser loginSysUser, InvoiceTypeMoudelXModeEnum invoiceModeEnum) throws UnifiedOrderRuntimeException;

    /**
     * 共用 程序 里边有分支
     *
     * @param form         表单 (关系已经包含到 form 里边 注意 dimCreateBy accountingOrderTypeDim)
     * @param loginSysUser
     * @throws UnifiedOrderRuntimeException
     */
    R<InvoiceApplyFocusScoreOpApplyReportV2_1> opInvoiceApplyV2_1(InvoiceApplyFocusScoreOpApplyFormV2_1 form, LoginSysUser loginSysUser);

    /****************************************** 开票申请相关   end ******************************************/
}
