package com.goldenwater.slgc.service.impl.pms;

import com.goldenwater.slgc.entity.pms.PmsPhaseTask;
import com.goldenwater.slgc.mapper.pms.PmsPhaseTaskMapper;
import com.goldenwater.slgc.service.pms.IPmsPhaseTaskService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.List;

@Service
@Transactional
public class PmsPhaseTaskServiceImpl implements IPmsPhaseTaskService {
    @Autowired
    private PmsPhaseTaskMapper pmsPhaseTaskMapper;

    /**
     * 查询阶段任务列表
     */
    @Override
    public List<PmsPhaseTask> selectList(PmsPhaseTask phaseTask) {
        return pmsPhaseTaskMapper.selectList(phaseTask);
    }

    /**
     * 根据主键查询阶段任务
     */
    @Override
    public PmsPhaseTask selectById(Long id) {
        return pmsPhaseTaskMapper.selectById(id);
    }

    /**
     * 新增阶段任务
     */
    @Override
    public int insert(PmsPhaseTask phaseTask) {
        return pmsPhaseTaskMapper.insert(phaseTask);
    }

    /**
     * 修改阶段任务
     */
    @Override
    public int update(PmsPhaseTask phaseTask) {
        return pmsPhaseTaskMapper.update(phaseTask);
    }

    /**
     * 删除阶段任务
     */
    @Override
    public int deleteById(Long id) {
        return pmsPhaseTaskMapper.deleteById(id);
    }

    /**
     * 批量删除阶段任务
     */
    @Override
    public int deleteByIds(Long[] ids) {
        return pmsPhaseTaskMapper.deleteByIds(ids);
    }

    /**
     * 根据阶段ID查询阶段任务列表
     */
    @Override
    public List<PmsPhaseTask> selectByPhaseId(Long phaseId) {
        return pmsPhaseTaskMapper.selectByPhaseId(phaseId);
    }
}
