package com.bonus.canteen.core.account.service;

import com.bonus.canteen.core.account.domain.AccWalletInfo;
import com.bonus.canteen.core.account.domain.WalletUpdateDTO;
import com.bonus.canteen.core.account.domain.vo.AccWalletInfoVO;

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

/**
 * 钱包详情信息Service接口
 * 
 * @author xsheng
 * @date 2025-04-05
 */
public interface IAccWalletInfoService {
    /**
     * 查询钱包详情信息
     * 
     * @param userId 钱包详情信息主键
     * @return 钱包详情信息
     */
    public List<AccWalletInfo> selectAccWalletInfoByUserId(Long userId);
    public AccWalletInfo selectAccWalletInfoByUserIdAndWalletType(Long userId, Integer walletType);

    /**
     * 查询钱包详情信息列表
     * 
     * @param accWalletInfo 钱包详情信息
     * @return 钱包详情信息集合
     */
    public List<AccWalletInfo> selectAccWalletInfoList(AccWalletInfo accWalletInfo);

    /**
     * 新增钱包详情信息
     * 
     * @param accWalletInfo 钱包详情信息
     * @return 结果
     */
    public int insertAccWalletInfo(AccWalletInfo accWalletInfo);

    public int batchInsertAccWalletInfo(List<AccWalletInfo> accWalletInfos);

    /**
     * 批量删除钱包详情信息
     * 
     * @param userIds 需要删除的钱包详情信息主键集合
     * @return 结果
     */
    public int deleteAccWalletInfoByUserIds(Long[] userIds);

    /**
     * 删除钱包详情信息信息
     * 
     * @param userId 钱包详情信息主键
     * @return 结果
     */
    public int deleteAccWalletInfoByUserId(Long userId);

    Map<Long, List<AccWalletInfoVO>> selectAccWalletInfoByUserIds(List<Long> userIds);

    void updateMinBalance(List<Long> userIds, Integer walletType, BigDecimal minBalance);

    void addAccWalletBalance(WalletUpdateDTO walletUpdateDTO);

    void clearAccWalletBalance(WalletUpdateDTO walletUpdateDTO);
}
