package com.ruoyi.project.invoice.service.impl;

import com.ruoyi.project.invoice.domain.TApproveReserveInvoice;
import com.ruoyi.project.invoice.mapper.TApproveReserveInvoiceMapper;
import com.ruoyi.project.invoice.service.ITApproveReserveInvoiceService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 预约开票申请Service业务层处理
 *
 * @author ruoyi
 * @date 2022-08-29
 */
@Service("tApproveReserveInvoiceService")
public class TApproveReserveInvoiceServiceImpl implements ITApproveReserveInvoiceService
{
    @Autowired
    private TApproveReserveInvoiceMapper tApproveReserveInvoiceMapper;

    /**
     * 查询预约开票申请
     *
     * @param id 预约开票申请ID
     * @return 预约开票申请
     */
    @Override
    public TApproveReserveInvoice selectTApproveReserveInvoiceById(Long id)
    {
        return tApproveReserveInvoiceMapper.selectTApproveReserveInvoiceById(id);
    }

    /**
     * 查询预约开票申请列表
     *
     * @param tApproveReserveInvoice 预约开票申请
     * @return 预约开票申请
     */
    @Override
    public List<TApproveReserveInvoice> selectTApproveReserveInvoiceList(TApproveReserveInvoice tApproveReserveInvoice)
    {
        return tApproveReserveInvoiceMapper.selectTApproveReserveInvoiceList(tApproveReserveInvoice);
    }

    /**
     * 新增预约开票申请
     *
     * @param tApproveReserveInvoice 预约开票申请
     * @return 结果
     */
    @Override
    public int insertTApproveReserveInvoice(TApproveReserveInvoice tApproveReserveInvoice)
    {
        return tApproveReserveInvoiceMapper.insertTApproveReserveInvoice(tApproveReserveInvoice);
    }

    /**
     * 修改预约开票申请
     *
     * @param tApproveReserveInvoice 预约开票申请
     * @return 结果
     */
    @Override
    public int updateTApproveReserveInvoice(TApproveReserveInvoice tApproveReserveInvoice)
    {
        return tApproveReserveInvoiceMapper.updateTApproveReserveInvoice(tApproveReserveInvoice);
    }

    /**
     * 批量删除预约开票申请
     *
     * @param ids 需要删除的预约开票申请ID
     * @return 结果
     */
    @Override
    public int deleteTApproveReserveInvoiceByIds(Long[] ids)
    {
        return tApproveReserveInvoiceMapper.deleteTApproveReserveInvoiceByIds(ids);
    }

    /**
     * 删除预约开票申请信息
     *
     * @param id 预约开票申请ID
     * @return 结果
     */
    @Override
    public int deleteTApproveReserveInvoiceById(Long id)
    {
        return tApproveReserveInvoiceMapper.deleteTApproveReserveInvoiceById(id);
    }

    /**
     * 查询预约开票申请
     *
     * @param invoiceId 预约开票申请ID
     * @return 预约开票申请
     */
    @Override
    public TApproveReserveInvoice selectTApproveReserveInvoiceByinvoiceId(String invoiceId) {
       return tApproveReserveInvoiceMapper.selectTApproveReserveInvoiceByinvoiceId(invoiceId);
    }
}
