package com.openhis.web.inhospitalcharge.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.openhis.web.inhospitalcharge.dto.AdvancePaymentFlowRecordDto;
import com.openhis.web.inhospitalcharge.dto.AdvancePaymentInfoDto;

/**
 * 预交金管理 应用Mapper
 */
@Repository
public interface AdvancePaymentManageAppMapper {

    /**
     * 查询预交金基本信息
     *
     * @param kindEnum 住院存款
     * @param wardEnum 病区
     * @param houseEnum 病房
     * @param bedEnum 床位
     * @param encounterActivityStatus 使用状态
     * @param status1 待结算
     * @param status2 已收费
     * @param status3 已退费
     * @param classEnum 住院
     * @param accountTypeCode 个人现金账号
     * @return 预交金基本信息
     */
    IPage<AdvancePaymentInfoDto> getAdvancePaymentInfo(@Param("page") Page<AdvancePaymentInfoDto> page,
        @Param("kindEnum") Integer kindEnum, @Param("wardEnum") Integer wardEnum, @Param("houseEnum") Integer houseEnum,
        @Param("bedEnum") Integer bedEnum, @Param("encounterActivityStatus") Integer encounterActivityStatus,
        @Param("status1") Integer status1, @Param("status2") Integer status2, @Param("status3") Integer status3,
        @Param("classEnum") Integer classEnum, @Param("accountTypeCode") String accountTypeCode,
        @Param(Constants.WRAPPER) QueryWrapper<AdvancePaymentInfoDto> queryWrapper);

    /**
     * 查询预交金支付流水记录
     * 
     * @param encounterId 住院就诊Id
     * @return 预交金支付流水记录
     */
    List<AdvancePaymentFlowRecordDto> getAdvancePaymentFlowRecordList(@Param("encounterId") Long encounterId);

}
