package com.dayou.mapper;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.dayou.dto.RealFundAssetsStatDTO;
import com.dayou.dto.history.HisClaimProd;
import com.dayou.entity.FinanceClaim;
import com.dayou.dao.CustomBaseMapper;
import com.dayou.entity.OrderFund;
import com.dayou.vo.*;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;
import java.util.List;

/**
 * <p>
 * 实收款认领 Mapper 接口
 * </p>
 *
 * @author wucl
 * @since 2023-12-08
 */
public interface FinanceClaimMapper extends CustomBaseMapper<FinanceClaim> {

    List<FinanceClaimVO> getList(@Param("realFundId") Long  realFundId);

    BigDecimal getTotalClaimAmountByProductionFundId(@Param("productionFundId") Long productionFundId);

    BigDecimal getTotalClaimAmountByOrderFundId(@Param("orderFundId") Long productionFundId);

    BigDecimal residueAmount(@Param("financeFundId") Long financeFundId);

    Page<RealFundMajorStatVO> majorStat(Page page,@Param("majorStat")  RealFundMajorStatVO majorStat,@Param("keyword") String keyword);

    List<RealFundMajorStatVO> majorStatExport(@Param("majorStat") RealFundMajorStatVO majorStat,@Param("keyword") String keyword);

    /**
     * 分页查询资产实收款统计
     * @param page 分页信息
     * @param dto 查询dto
     * @return Page<RealFundAssetsStatVO>
     */
    Page<RealFundAssetsStatVO> assetsSate(Page page, @Param("dto") RealFundAssetsStatDTO dto,@Param("keyword") String keyword);

    /**
     * 资产实收款统计导出
     * @param dto 查询dto
     * @return Page<RealFundAssetsStatVO>
     */
    List<RealFundAssetsStatVO> assetsSateExport(@Param("dto") RealFundAssetsStatDTO dto,@Param("keyword")String keyword);

    Page<RealFundPersonalVO> personalStat(Page page, @Param("dto")RealFundPersonalVO personalVO);

    List<RealFundPersonalVO> personalStatExport(@Param("dto") RealFundPersonalVO personalVO);

    List<OrderFund> queryOrderTotalAmount();

    Page<FinanceClaimsVO> financeClaimsList(Page page, @Param("vo") FinanceClaimsVO financeClaimVO,@Param("keyword") String keyword);

    List<FinanceClaimsVO> exportList(@Param("vo")FinanceClaimsVO financeClaimVO, @Param("keyword") String keyword);

    List<HisClaimProd> updateClaimProductionId(@Param("businessType") String businessType);
}
