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.ruoyi.system.mapper.TFallSolveMapper;
import com.ruoyi.system.domain.TFallSolve;
import com.ruoyi.system.service.ITFallSolveService;

/**
 * 跌倒告警Service业务层处理
 * 
 * @author zhengjie
 * @date 2023-09-09
 */
@Service
public class TFallSolveServiceImpl implements ITFallSolveService 
{
    @Autowired
    private TFallSolveMapper tFallSolveMapper;

    /**
     * 查询跌倒告警
     * 
     * @param id 跌倒告警主键
     * @return 跌倒告警
     */
    @Override
    public TFallSolve selectTFallSolveById(Integer id)
    {
        return tFallSolveMapper.selectTFallSolveById(id);
    }

    /**
     * 查询跌倒告警列表
     * 
     * @param tFallSolve 跌倒告警
     * @return 跌倒告警
     */
    @Override
    public List<TFallSolve> selectTFallSolveList(TFallSolve tFallSolve)
    {
        return tFallSolveMapper.selectTFallSolveList(tFallSolve);
    }

    /**
     * 新增跌倒告警
     * 
     * @param tFallSolve 跌倒告警
     * @return 结果
     */
    @Override
    public int insertTFallSolve(TFallSolve tFallSolve)
    {
        tFallSolve.setCreateTime(DateUtils.getNowDate());
        return tFallSolveMapper.insertTFallSolve(tFallSolve);
    }

    /**
     * 修改跌倒告警
     * 
     * @param tFallSolve 跌倒告警
     * @return 结果
     */
    @Override
    public int updateTFallSolve(TFallSolve tFallSolve)
    {
        return tFallSolveMapper.updateTFallSolve(tFallSolve);
    }

    /**
     * 批量删除跌倒告警
     * 
     * @param ids 需要删除的跌倒告警主键
     * @return 结果
     */
    @Override
    public int deleteTFallSolveByIds(Integer[] ids)
    {
        return tFallSolveMapper.deleteTFallSolveByIds(ids);
    }

    /**
     * 删除跌倒告警信息
     * 
     * @param id 跌倒告警主键
     * @return 结果
     */
    @Override
    public int deleteTFallSolveById(Integer id)
    {
        return tFallSolveMapper.deleteTFallSolveById(id);
    }
}
