package com.fs.doctor.service.impl;

import java.util.List;
import com.fs.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.fs.doctor.mapper.DoctorLevelDataMapper;
import com.fs.doctor.domain.DoctorLevelData;
import com.fs.doctor.service.IDoctorLevelDataService;

/**
 * 医生级别Service业务层处理
 * 
 * @author fs
 * @date 2026-02-12
 */
@Service
public class DoctorLevelDataServiceImpl implements IDoctorLevelDataService 
{
    @Autowired
    private DoctorLevelDataMapper doctorLevelDataMapper;

    /**
     * 查询医生级别
     * 
     * @param id 医生级别主键
     * @return 医生级别
     */
    @Override
    public DoctorLevelData selectDoctorLevelDataById(Long id)
    {
        return doctorLevelDataMapper.selectDoctorLevelDataById(id);
    }

    /**
     * 查询医生级别列表
     * 
     * @param doctorLevelData 医生级别
     * @return 医生级别
     */
    @Override
    public List<DoctorLevelData> selectDoctorLevelDataList(DoctorLevelData doctorLevelData)
    {
        return doctorLevelDataMapper.selectDoctorLevelDataList(doctorLevelData);
    }

    /**
     * 新增医生级别
     * 
     * @param doctorLevelData 医生级别
     * @return 结果
     */
    @Override
    public int insertDoctorLevelData(DoctorLevelData doctorLevelData)
    {
        doctorLevelData.setCreateTime(DateUtils.getNowDate());
        return doctorLevelDataMapper.insertDoctorLevelData(doctorLevelData);
    }

    /**
     * 修改医生级别
     * 
     * @param doctorLevelData 医生级别
     * @return 结果
     */
    @Override
    public int updateDoctorLevelData(DoctorLevelData doctorLevelData)
    {
        doctorLevelData.setUpdateTime(DateUtils.getNowDate());
        return doctorLevelDataMapper.updateDoctorLevelData(doctorLevelData);
    }

    /**
     * 批量删除医生级别
     * 
     * @param ids 需要删除的医生级别主键
     * @return 结果
     */
    @Override
    public int deleteDoctorLevelDataByIds(Long[] ids)
    {
        return doctorLevelDataMapper.deleteDoctorLevelDataByIds(ids);
    }

    /**
     * 删除医生级别信息
     * 
     * @param id 医生级别主键
     * @return 结果
     */
    @Override
    public int deleteDoctorLevelDataById(Long id)
    {
        return doctorLevelDataMapper.deleteDoctorLevelDataById(id);
    }
}
