package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.system.mapper.SysPointControlMapper;
import com.ruoyi.system.domain.SysPointControl;
import com.ruoyi.system.service.ISysPointControlService;

/**
 * 积分控制Service业务层处理
 *
 * @author ruoyi
 * @date 2025-05-28
 */
@Service
public class SysPointControlServiceImpl extends ServiceImpl<BaseMapper<SysPointControl>, SysPointControl> implements ISysPointControlService
{
    @Autowired
    private SysPointControlMapper sysReviewControlMapper;

    /**
     * 查询积分控制
     *
     * @param id 积分控制主键
     * @return 积分控制
     */
    @Override
    public SysPointControl selectSysReviewControlById(Long id)
    {
        return sysReviewControlMapper.selectSysReviewControlById(id);
    }

    /**
     * 查询积分控制列表
     *
     * @param sysReviewControl 积分控制
     * @return 积分控制
     */
    @Override
    public List<SysPointControl> selectSysReviewControlList(SysPointControl sysReviewControl)
    {
        return sysReviewControlMapper.selectSysReviewControlList(sysReviewControl);
    }

    /**
     * 新增积分控制
     *
     * @param sysReviewControl 积分控制
     * @return 结果
     */
    @Override
    public int insertSysReviewControl(SysPointControl sysReviewControl)
    {
        return sysReviewControlMapper.insertSysReviewControl(sysReviewControl);
    }

    /**
     * 修改积分控制
     *
     * @param sysReviewControl 积分控制
     * @return 结果
     */
    @Override
    public int updateSysReviewControl(SysPointControl sysReviewControl)
    {
        sysReviewControl.setUpdateTime(DateUtils.getNowDate());
        return sysReviewControlMapper.updateSysReviewControl(sysReviewControl);
    }

    /**
     * 批量删除积分控制
     *
     * @param ids 需要删除的积分控制主键
     * @return 结果
     */
    @Override
    public int deleteSysReviewControlByIds(Long[] ids)
    {
        return sysReviewControlMapper.deleteSysReviewControlByIds(ids);
    }

    /**
     * 删除积分控制信息
     *
     * @param id 积分控制主键
     * @return 结果
     */
    @Override
    public int deleteSysReviewControlById(Long id)
    {
        return sysReviewControlMapper.deleteSysReviewControlById(id);
    }
}
