package com.iamberry.wechat.service.eo;

import com.iamberry.wechat.core.entity.eo.GiftPool;
import com.iamberry.wechat.face.eo.GiftPoolService;
import com.iamberry.wechat.service.mapper.GiftPoolMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 *  赠品池接口
 * @author Administrator
 * @Date 2019-10-21
 */
@Service
public class GiftPoolServiceImpl  implements GiftPoolService {
    @Autowired
    private GiftPoolMapper giftPoolMapper;
    /**
     * 获取集合
     * @param  giftPool
     * @return List
     */
    @Override
    public List<GiftPool> getGiftPoolList(GiftPool giftPool){
        return  giftPoolMapper.getGiftPoolList(giftPool);
    }
    /**
     * 查询单条数据
     * @param  id
     * @return  giftPool
     */
    @Override
    public GiftPool getGiftPoolById(Integer  id){
        return  giftPoolMapper.getGiftPoolById(id);
    }

    /**
     * 修改数据
     * @param  giftPool
     * @return Integer
     */
    @Override
    public  Integer  updateStock(GiftPool  giftPool){
        return  giftPoolMapper.updateStock(giftPool);
    }

    /**
     * 修改数据
     * @param  giftPool
     * @return Integer
     */
    @Override
    public  Integer  updateAddStock(GiftPool  giftPool){
        return  giftPoolMapper.updateAddStock(giftPool);
    }

}