package com.cloudcross.ssp.back.service;
import java.util.List;
import java.util.Map;

import com.cloudcross.ssp.back.model.AdvBalance;
import com.cloudcross.ssp.base.service.IGenericService;


/**
 * 广告主充值服务接口
 * @author chenyou
 *
 */
public interface IAdvBalanceService extends IGenericService<AdvBalance> {
	/**
	 * 根据代理商id查找它的当前余额
	 */
	Float findBalanceByAgentId(Long agentId);
	
	/**
	 * 根据代理商id更新它的当前余额
	 * @param balance
	 * @return
	 */
	boolean updateBalanceByAgentId(Long agentId, Float balance);
	
	/**
	 * 删掉当前的广告主充值记录
	 * @param id
	 * @return
	 */
	boolean deleteAdvBalanceById(Long id);
	
	List<AdvBalance> findByParams(Map<String, Object>paramMap);
}
