package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.common.core.text.Convert;
import com.ruoyi.system.domain.RiskMaterial;
import com.ruoyi.system.mapper.RiskMaterialMapper;
import com.ruoyi.system.service.IRiskMaterialService;

/**
 * 资料管理服务实现
 */
@Service
public class RiskMaterialServiceImpl implements IRiskMaterialService
{
    @Autowired
    private RiskMaterialMapper riskMaterialMapper;

    @Override
    public RiskMaterial selectRiskMaterialById(Long materialId)
    {
        return riskMaterialMapper.selectRiskMaterialById(materialId);
    }

    @Override
    public List<RiskMaterial> selectRiskMaterialList(RiskMaterial riskMaterial)
    {
        return riskMaterialMapper.selectRiskMaterialList(riskMaterial);
    }

    @Override
    public int insertRiskMaterial(RiskMaterial riskMaterial)
    {
        return riskMaterialMapper.insertRiskMaterial(riskMaterial);
    }

    @Override
    public int updateRiskMaterial(RiskMaterial riskMaterial)
    {
        return riskMaterialMapper.updateRiskMaterial(riskMaterial);
    }

    @Override
    public int deleteRiskMaterialByIds(String ids)
    {
        return riskMaterialMapper.deleteRiskMaterialByIds(Convert.toStrArray(ids));
    }
}
