package com.ruoyi.project.aspen.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.aspen.mapper.TDashboarddayMapper;
import com.ruoyi.project.aspen.domain.TDashboardday;
import com.ruoyi.project.aspen.service.ITDashboarddayService;

import javax.annotation.Resource;

/**
 * DASHBOARD每日抓取数据Service业务层处理
 *
 * @author ruoyi
 * @date 2022-02-11
 */
@Service
public class TDashboarddayServiceImpl implements ITDashboarddayService
{
    @Resource
    private TDashboarddayMapper tDashboarddayMapper;

    /**
     * 查询DASHBOARD每日抓取数据
     *
     * @param id DASHBOARD每日抓取数据ID
     * @return DASHBOARD每日抓取数据
     */
    @Override
    public TDashboardday selectTDashboarddayById(Long id)
    {
        return tDashboarddayMapper.selectTDashboarddayById(id);
    }

    /**
     * 查询最近31条dashboard抓取数据
     *
     * @param tDashboardday dashboard抓取数据
     * @return DASHBOARD每日抓取数据集合
     */
    @Override
    public List<TDashboardday> selectLast(TDashboardday tDashboardday) { return tDashboarddayMapper.selectLast(tDashboardday); }

    /**
     * 查询DASHBOARD每日抓取数据列表
     *
     * @param tDashboardday DASHBOARD每日抓取数据
     * @return DASHBOARD每日抓取数据
     */
    @Override
    public List<TDashboardday> selectTDashboarddayList(TDashboardday tDashboardday)
    {
        return tDashboarddayMapper.selectTDashboarddayList(tDashboardday);
    }

    /**
     * 新增DASHBOARD每日抓取数据
     *
     * @param tDashboardday DASHBOARD每日抓取数据
     * @return 结果
     */
    @Override
    public int insertTDashboardday(TDashboardday tDashboardday)
    {
        return tDashboarddayMapper.insertTDashboardday(tDashboardday);
    }

    /**
     * 修改DASHBOARD每日抓取数据
     *
     * @param tDashboardday DASHBOARD每日抓取数据
     * @return 结果
     */
    @Override
    public int updateTDashboardday(TDashboardday tDashboardday)
    {
        return tDashboarddayMapper.updateTDashboardday(tDashboardday);
    }

    /**
     * 批量删除DASHBOARD每日抓取数据
     *
     * @param ids 需要删除的DASHBOARD每日抓取数据ID
     * @return 结果
     */
    @Override
    public int deleteTDashboarddayByIds(Long[] ids)
    {
        return tDashboarddayMapper.deleteTDashboarddayByIds(ids);
    }

    /**
     * 删除DASHBOARD每日抓取数据信息
     *
     * @param id DASHBOARD每日抓取数据ID
     * @return 结果
     */
    @Override
    public int deleteTDashboarddayById(Long id)
    {
        return tDashboarddayMapper.deleteTDashboarddayById(id);
    }
}
