package com.jeeplus.test.reimbursementsys.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.jeeplus.test.reimbursementsys.domain.dto.ReimbursementBusinessTwoDTO;
import com.jeeplus.test.reimbursementsys.domain.dto.ReimbursementDTO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;


@Mapper
public interface ReimbursementBusinessTwoMapper extends BaseMapper<ReimbursementBusinessTwoDTO> {

    /**
     * 分页查询
     */
    IPage<ReimbursementBusinessTwoDTO> findListPage(Page<ReimbursementBusinessTwoDTO> page,
                                                              @Param("reimbursementBusiness")ReimbursementBusinessTwoDTO reimbursementBusiness);

    /**
     * 物理删除
     * @param id
     */
    void delPhysicsById(@Param("id")String id);
    /**
     * 物理删除
     * @param idList
     */
    void deleteByList(@Param("idList")List <String> idList);

    /**
     * 新增
     */
    void insertReimbursementBusiness(ReimbursementBusinessTwoDTO reimbursementBusiness);

    /**
     * 修改
     */
    void modifyBindCode(@Param("ids")String ids,@Param("businessCode")String businessCode, @Param("reimbursementAddress")String reimbursementAddress);

    /**
     * 下拉菜单
     */
    List<ReimbursementDTO> findSelectList();


    List<String> findSelectYearList();

    /**
     * 根据年份获取分所报销批次信息
     * @param year
     * @return
     */
    List<ReimbursementDTO> findSelectCodeListByYear(String year);

    /**
     * 根据年份获取总所报销批次信息
     * @param year
     * @return
     */
    List<ReimbursementDTO> findSelectCodeListByYearOnWuHan(String year);

    ReimbursementBusinessTwoDTO findDataById(@Param("id")String id);
}
