package org.dromara.payment.invoice.service;

import org.dromara.common.mybatis.core.page.PageQuery;
import org.dromara.common.mybatis.core.page.TableDataInfo;
import org.dromara.payment.invoice.domain.bo.MerInvoiceBo;
import org.dromara.payment.invoice.domain.bo.UploadInvoiceBo;
import org.dromara.payment.invoice.domain.vo.MerInvoiceVo;

import java.util.Collection;
import java.util.List;

/**
 * 商户发票记录Service接口
 *
 * @author LionLi
 * @date 2024-05-06
 */
public interface IMerInvoiceService {

    /**
     * 查询商户发票记录
     */
    MerInvoiceVo queryById(Long id);

    /**
     * 查询商户发票记录列表
     */
    TableDataInfo<MerInvoiceVo> queryPageList(MerInvoiceBo bo, PageQuery pageQuery);

    /**
     * 查询商户发票记录列表
     */
    List<MerInvoiceVo> queryList(MerInvoiceBo bo);

    /**
     * 新增商户发票记录
     */
    Boolean insertByBo(MerInvoiceBo bo);

    /**
     * 修改商户发票记录
     */
    Boolean updateByBo(MerInvoiceBo bo);

    /**
     * 校验并批量删除商户发票记录信息
     */
    Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);

    /**
     * 服务商驳回发票申请
     * @return
     */
    Boolean reject(MerInvoiceBo bo);

    /**
     * 服务商上传发票
     * @param bo
     * @return
     */
    Boolean uploadInvoice(UploadInvoiceBo bo);

    /**
     * 服务商添加或修改发票申请快递
     * @return
     */
    Boolean editIogistics(MerInvoiceBo bo);

    /**
     * 商户签收发票快递
     * @param invId 发票申请id
     * @param oper 操作人
     * @return
     */
    Boolean receivingIogistics(long invId,String oper);


    /***
     * 根据发票流水号查询发票详情
     * @param no
     * @return
     */
    public MerInvoiceVo queryByNo(String no);
}
