package com.zehong.system.service.impl;

import java.util.List;
import com.zehong.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.zehong.system.mapper.TCarTaskPointMapper;
import com.zehong.system.domain.TCarTaskPoint;
import com.zehong.system.service.ITCarTaskPointService;

/**
 * 泄漏点Service业务层处理
 * 
 * @author zehong
 * @date 2026-05-15
 */
@Service
public class TCarTaskPointServiceImpl implements ITCarTaskPointService 
{
    @Autowired
    private TCarTaskPointMapper tCarTaskPointMapper;

    /**
     * 查询泄漏点
     * 
     * @param id 泄漏点ID
     * @return 泄漏点
     */
    @Override
    public TCarTaskPoint selectTCarTaskPointById(Long id)
    {
        return tCarTaskPointMapper.selectTCarTaskPointById(id);
    }

    /**
     * 查询泄漏点列表
     * 
     * @param tCarTaskPoint 泄漏点
     * @return 泄漏点
     */
    @Override
    public List<TCarTaskPoint> selectTCarTaskPointList(TCarTaskPoint tCarTaskPoint)
    {
        return tCarTaskPointMapper.selectTCarTaskPointList(tCarTaskPoint);
    }

    /**
     * 新增泄漏点
     * 
     * @param tCarTaskPoint 泄漏点
     * @return 结果
     */
    @Override
    public int insertTCarTaskPoint(TCarTaskPoint tCarTaskPoint)
    {
        tCarTaskPoint.setCreateTime(DateUtils.getNowDate());
        return tCarTaskPointMapper.insertTCarTaskPoint(tCarTaskPoint);
    }

    /**
     * 修改泄漏点
     * 
     * @param tCarTaskPoint 泄漏点
     * @return 结果
     */
    @Override
    public int updateTCarTaskPoint(TCarTaskPoint tCarTaskPoint)
    {
        return tCarTaskPointMapper.updateTCarTaskPoint(tCarTaskPoint);
    }

    /**
     * 批量删除泄漏点
     * 
     * @param ids 需要删除的泄漏点ID
     * @return 结果
     */
    @Override
    public int deleteTCarTaskPointByIds(Long[] ids)
    {
        return tCarTaskPointMapper.deleteTCarTaskPointByIds(ids);
    }

    /**
     * 删除泄漏点信息
     * 
     * @param id 泄漏点ID
     * @return 结果
     */
    @Override
    public int deleteTCarTaskPointById(Long id)
    {
        return tCarTaskPointMapper.deleteTCarTaskPointById(id);
    }
}
