package com.dxhy.erp.dao;

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

import com.dxhy.api.model.config.Tax;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dxhy.erp.entity.InvoiceElectron;
import com.dxhy.erp.model.SignInvoiceInfos;

/**
 * 签收dao
 *
 * @author dxhy
 */
@Mapper
public interface TdxInvoiceDao extends BaseMapper<InvoiceElectron> {

    /**
     * 待填
     *
     * @param map
     * @return
     */
    Integer selectAllCount(@Param("pramsMap") Map<String, Object> map);

    /**
     * 查询符合条件的签收发票
     *
     * @param map
     * @return
     */
    List<InvoiceElectron> selectByParam(@Param("pramsMap") Map<String, Object> map);

    /**
     * 查询用户拥有权限的税号
     *
     * @param userId
     * @return
     */
    List<Tax> getTaxs(@Param("userId") Long userId);

    Integer selectSignResultCount(@Param("start") Date start, @Param("end") Date end,
        @Param("enterpriseCode") List<String> enterpriseCode);

    List<SignInvoiceInfos> selectSignResul(@Param("start") Date startTime, @Param("end") Date endTime,
        @Param("enterpriseCode") List<String> enterpriseCode, @Param("startNum") int start, @Param("num") int num);

    String findDetailByUUid(@Param("uuid") String uuid);
}
