package com.yifu.cloud.plus.v1.yifu.social.service;/*
 *    Copyright (c) 2018-2025, lengleng All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the yifu4cloud.com developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: lengleng (wangiegie@gmail.com)
 */

import com.baomidou.mybatisplus.extension.service.IService;
import com.yifu.cloud.plus.v1.yifu.social.entity.TPaymentInfo;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yifu.cloud.plus.v1.yifu.common.core.util.ErrorMessage;
import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import com.yifu.cloud.plus.v1.yifu.social.vo.TPaymentInfoSearchVo;

import javax.servlet.http.HttpServletResponse;
import java.io.InputStream;
import java.util.List;

/**
 * 缴费库
 * @author huyc
 * @date 2022-07-22 17:01:22
 */
public interface TPaymentInfoService extends IService<TPaymentInfo> {
	/**
	 * 缴费库简单分页查询
	 * @param tPaymentInfo 缴费库
	 * @return
	 */
	IPage<TPaymentInfo> getTPaymentInfoPage(Page<TPaymentInfo> page, TPaymentInfo tPaymentInfo);

	/**
	 * 缴费库批量导入社保
	 * @param inputStream
	 * @return
	 */
	R<List<ErrorMessage>> importSocialDiy(InputStream inputStream, String random);

	/**
	 * 批量新增缴费库-合肥三险
	 * @param inputStream
	 * @param random
	 * @param type
	 * @return
	 */
	R<List<ErrorMessage>> importSocialHeFeiDiy(InputStream inputStream, String random, String type);

	/**
	 * 批量导入公积金
	 * @param inputStream
	 * @return
	 */
	R<List<ErrorMessage>> batchImportPaymentFundInfo(InputStream inputStream);

	/**
	 * 导出缴费库
	 * @param response
	 * @param searchVo
	 * @return
	 */
	void listExport(HttpServletResponse response, TPaymentInfoSearchVo searchVo);

	/**
	 * 按类型删除
	 * @Author huyc
	 * @Date 2022-07-24
	 * @param id
	 * @param type
	 * @return
	 **/
	R<Boolean> removeByIdAndType(String id, String type);

	/**
	 * 通过ID获取缴费库 及社保、公积金明细
	 * @Author huyc
	 * @Date 2022-07-24
	 * @param id
	 * @return
	 **/
	R getAllInfoById(String id);

	/**
	 * 删除当月 当前登录人的 指定类型的缴费库数据
	 * @Author huyc
	 * @Date 2022-07-27
	 * @param type
	 * @param settleDepartId
	 * @param unitId
	 * @param empIdCard
	 * @param socialHouseId
	 * @param fundHouseId
	 * @return
	 **/
	R removeBatchByIdsAndType(String type, String settleDepartId, String unitId, String empIdCard, String socialHouseId, String fundHouseId);
}
