package com.yanzhu.jh.video.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.yanzhu.jh.video.mapper.SurProjectPhotographyMapper;
import com.yanzhu.jh.video.domain.SurProjectPhotography;
import com.yanzhu.jh.video.service.ISurProjectPhotographyService;
import com.ruoyi.common.utils.SecurityUtils;
/**
 * 项目延时摄影Service业务层处理
 * 
 * @author ruoyi
 * @date 2023-10-15
 */
@Service
public class SurProjectPhotographyServiceImpl implements ISurProjectPhotographyService 
{
    @Autowired
    private SurProjectPhotographyMapper surProjectPhotographyMapper;

    /**
     * 查询项目延时摄影
     * 
     * @param id 项目延时摄影主键
     * @return 项目延时摄影
     */
    @Override
    public SurProjectPhotography selectSurProjectPhotographyById(Long id)
    {
        return surProjectPhotographyMapper.selectSurProjectPhotographyById(id);
    }

    /**
     * 查询项目延时摄影列表
     * 
     * @param surProjectPhotography 项目延时摄影
     * @return 项目延时摄影
     */
    @Override
    public List<SurProjectPhotography> selectSurProjectPhotographyList(SurProjectPhotography surProjectPhotography)
    {
        return surProjectPhotographyMapper.selectSurProjectPhotographyList(surProjectPhotography);
    }

    /**
     * 新增项目延时摄影
     * 
     * @param surProjectPhotography 项目延时摄影
     * @return 结果
     */
    @Override
    public int insertSurProjectPhotography(SurProjectPhotography surProjectPhotography)
    {
        surProjectPhotography.setCreateBy(SecurityUtils.getUsername());
        return surProjectPhotographyMapper.insertSurProjectPhotography(surProjectPhotography);
    }

    /**
     * 修改项目延时摄影
     * 
     * @param surProjectPhotography 项目延时摄影
     * @return 结果
     */
    @Override
    public int updateSurProjectPhotography(SurProjectPhotography surProjectPhotography)
    {
        surProjectPhotography.setUpdateBy(SecurityUtils.getUsername());
        return surProjectPhotographyMapper.updateSurProjectPhotography(surProjectPhotography);
    }

    /**
     * 批量删除项目延时摄影
     * 
     * @param ids 需要删除的项目延时摄影主键
     * @return 结果
     */
    @Override
    public int deleteSurProjectPhotographyByIds(Long[] ids)
    {
        return surProjectPhotographyMapper.deleteSurProjectPhotographyByIds(ids);
    }

    /**
     * 删除项目延时摄影信息
     * 
     * @param id 项目延时摄影主键
     * @return 结果
     */
    @Override
    public int deleteSurProjectPhotographyById(Long id)
    {
        return surProjectPhotographyMapper.deleteSurProjectPhotographyById(id);
    }
}
