package com.ruoyi.web.modules.pay.mapper;

import java.math.BigDecimal;
import org.apache.ibatis.annotations.Param;
import com.ruoyi.web.modules.pay.domain.BizRefundRecord;

public interface BizRefundRecordMapper
{
    BizRefundRecord selectByAftersaleId(@Param("aftersaleId") Long aftersaleId);

    BigDecimal sumSuccessRefundAmountByOrderId(@Param("orderId") Long orderId);

    int insert(BizRefundRecord record);

    int updateForSuccess(@Param("refundId") Long refundId, @Param("wxRefundId") String wxRefundId,
            @Param("refundStatus") String refundStatus, @Param("notifyTime") java.util.Date notifyTime);

    int updateForFail(@Param("refundId") Long refundId, @Param("failReason") String failReason);
}
