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

import java.math.BigDecimal;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import com.ruoyi.web.modules.finance.domain.BizShopWallet;
import com.ruoyi.web.modules.finance.dto.PlatformShopFundRankQuery;
import com.ruoyi.web.modules.finance.vo.PlatformShopFundRankRowVO;

public interface BizShopWalletMapper
{
    BigDecimal sumAvailableBalance();

    BigDecimal sumFrozenAmount();

    List<PlatformShopFundRankRowVO> selectPlatformShopRankList(@Param("query") PlatformShopFundRankQuery query);

    BizShopWallet selectByShopId(Long shopId);

    BizShopWallet selectByShopIdForUpdate(Long shopId);

    int insert(BizShopWallet wallet);

    int updateBalance(@Param("shopId") Long shopId, @Param("availableBalance") java.math.BigDecimal availableBalance,
            @Param("frozenAmount") java.math.BigDecimal frozenAmount, @Param("updateTime") java.util.Date updateTime);
}
