package com.jkcredit.invoice.mapper.waybill;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.jkcredit.invoice.model.entity.waybill.NoCarWayBillFileInfo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;
@Repository
public interface WayBillFileMapper  extends BaseMapper<NoCarWayBillFileInfo> {

    int insert(NoCarWayBillFileInfo noCarWayBillFileInfo);

    IPage<List<NoCarWayBillFileInfo>> selectAllFiles(Page page, @Param("noCarWayBillFileInfo")NoCarWayBillFileInfo noCarWayBillFileInfo);

    NoCarWayBillFileInfo selectFileInfo(@Param("batchNum") String batchNum, @Param("wayBillNum") String wayBillNum);

    NoCarWayBillFileInfo selectFileInfoNoFile(@Param("batchNum") String batchNum, @Param("wayBillNum") String wayBillNum);

    NoCarWayBillFileInfo selectFileInfoNoBatch( @Param("wayBillNum") String wayBillNum);

    NoCarWayBillFileInfo selectFileInfoNoFileNoBatch(@Param("wayBillNum") String wayBillNum);

    int deleteFileByTime(String yesTime);

}
