package com.ruoyi.project.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.mapper.TrsAttachmentMapper;
import com.ruoyi.project.domain.TrsAttachment;
import com.ruoyi.project.service.ITrsAttachmentService;
import com.ruoyi.common.core.text.Convert;

/**
 * 智能报告Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-03-30
 */
@Service
public class TrsAttachmentServiceImpl implements ITrsAttachmentService 
{
    @Autowired
    private TrsAttachmentMapper trsAttachmentMapper;

    /**
     * 查询智能报告
     * 
     * @param id 智能报告主键
     * @return 智能报告
     */
    @Override
    public TrsAttachment selectTrsAttachmentById(Long id)
    {
        return trsAttachmentMapper.selectTrsAttachmentById(id);
    }

    /**
     * 查询智能报告列表
     * 
     * @param trsAttachment 智能报告
     * @return 智能报告
     */
    @Override
    public List<TrsAttachment> selectTrsAttachmentList(TrsAttachment trsAttachment)
    {
        return trsAttachmentMapper.selectTrsAttachmentList(trsAttachment);
    }

    /**
     * 新增智能报告
     * 
     * @param trsAttachment 智能报告
     * @return 结果
     */
    @Override
    public int insertTrsAttachment(TrsAttachment trsAttachment)
    {
        return trsAttachmentMapper.insertTrsAttachment(trsAttachment);
    }

    /**
     * 修改智能报告
     * 
     * @param trsAttachment 智能报告
     * @return 结果
     */
    @Override
    public int updateTrsAttachment(TrsAttachment trsAttachment)
    {
        return trsAttachmentMapper.updateTrsAttachment(trsAttachment);
    }

    /**
     * 批量删除智能报告
     * 
     * @param ids 需要删除的智能报告主键
     * @return 结果
     */
    @Override
    public int deleteTrsAttachmentByIds(String ids)
    {
        return trsAttachmentMapper.deleteTrsAttachmentByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除智能报告信息
     * 
     * @param id 智能报告主键
     * @return 结果
     */
    @Override
    public int deleteTrsAttachmentById(Long id)
    {
        return trsAttachmentMapper.deleteTrsAttachmentById(id);
    }
}
