package com.yeshi.fanli.service.inter.redpack;
|
|
import java.math.BigDecimal;
|
import java.util.List;
|
|
import com.yeshi.fanli.entity.common.AdminUser;
|
import com.yeshi.fanli.entity.redpack.RedPackExchange;
|
import com.yeshi.fanli.exception.redpack.RedPackExchangeException;
|
|
public interface RedPackExchangeService {
|
|
/**
|
* 提现转换现金
|
* @param uid
|
* @param amount
|
* @throws RedPackExchangeException
|
*/
|
public void exchangeCash(Long uid, BigDecimal amount) throws RedPackExchangeException;
|
|
/**
|
* 后台查询
|
* @param start
|
* @param count
|
* @param key
|
* @param state
|
* @return
|
*/
|
public List<RedPackExchange> query(Integer start, Integer count, String key, Integer state);
|
|
public Long count(String key, Integer state);
|
|
/**
|
* 统计各个状态
|
* @param uid
|
* @return
|
*/
|
public Long countByUidAndState(long uid, Integer state);
|
|
|
/**
|
* 获取申请
|
* @param id
|
* @return
|
*/
|
public RedPackExchange selectByPrimaryKey(long id);
|
|
/**
|
* 提现通过
|
* @param id
|
* @param admin
|
* @throws RedPackExchangeException
|
*/
|
public void passExchange(long id, AdminUser admin) throws RedPackExchangeException;
|
|
/**
|
* 提现拒绝
|
* @param id
|
* @param reason
|
* @param admin
|
* @throws RedPackExchangeException
|
*/
|
public void rejectExchange(long id, String reason, AdminUser admin) throws RedPackExchangeException;
|
|
/**
|
* 统计状态
|
* @param uid
|
* @param state
|
* @return
|
*/
|
public BigDecimal countMoneyByUidAndState(Long uid, Integer state);
|
|
|
}
|