package cn.iocoder.yudao.module.shop.service.impl;

import cn.iocoder.yudao.module.shop.entity.ShopUserBalanceChanges;
import cn.iocoder.yudao.module.shop.mapper.ShopUserBalanceChangesMapper;
import cn.iocoder.yudao.module.shop.service.IShopUserBalanceChangesService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 积分记录Service业务层处理
 *
 * @author ruoyi
 * @date 2023-07-09
 */
@Service
public class ShopUserBalanceChangesServiceImpl implements IShopUserBalanceChangesService
{
    @Autowired
    private ShopUserBalanceChangesMapper shopUserBalanceChangesMapper;

    /**
     * 查询积分记录
     *
     * @param id 积分记录主键
     * @return 积分记录
     */
    @Override
    public ShopUserBalanceChanges selectShopUserBalanceChangesById(Long id)
    {
        return shopUserBalanceChangesMapper.selectShopUserBalanceChangesById(id);
    }

    /**
     * 查询积分记录列表
     *
     * @param shopUserBalanceChanges 积分记录
     * @return 积分记录
     */
    @Override
    public List<ShopUserBalanceChanges> selectShopUserBalanceChangesList(ShopUserBalanceChanges shopUserBalanceChanges)
    {
        return shopUserBalanceChangesMapper.selectShopUserBalanceChangesList(shopUserBalanceChanges);
    }

    /**
     * 新增积分记录
     *
     * @param shopUserBalanceChanges 积分记录
     * @return 结果
     */
    @Override
    public int insertShopUserBalanceChanges(ShopUserBalanceChanges shopUserBalanceChanges)
    {
        return shopUserBalanceChangesMapper.insertShopUserBalanceChanges(shopUserBalanceChanges);
    }

    /**
     * 修改积分记录
     *
     * @param shopUserBalanceChanges 积分记录
     * @return 结果
     */
    @Override
    public int updateShopUserBalanceChanges(ShopUserBalanceChanges shopUserBalanceChanges)
    {
        return shopUserBalanceChangesMapper.updateShopUserBalanceChanges(shopUserBalanceChanges);
    }

    /**
     * 批量删除积分记录
     *
     * @param ids 需要删除的积分记录主键
     * @return 结果
     */
    @Override
    public int deleteShopUserBalanceChangesByIds(Long[] ids)
    {
        return shopUserBalanceChangesMapper.deleteShopUserBalanceChangesByIds(ids);
    }

    /**
     * 删除积分记录信息
     *
     * @param id 积分记录主键
     * @return 结果
     */
    @Override
    public int deleteShopUserBalanceChangesById(Long id)
    {
        return shopUserBalanceChangesMapper.deleteShopUserBalanceChangesById(id);
    }
}
