package com.persagy.adm.server.delivery.service.impl;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.persagy.adm.server.delivery.dao.BossProjectDeliveryPlanMapper;
import com.persagy.adm.server.delivery.entity.BossProjectDeliveryPlan;
import com.persagy.adm.server.delivery.service.BossProjectDeliveryPlanService;
import com.persagy.dmp.delivery.entity.ObjectInfoCollect;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * BOSS项目交付计划
 * @author:linhuili
 * @date:2022/1/22
 */
@Service
@Slf4j
public class BossProjectDeliveryPlanServiceImpl extends ServiceImpl<BossProjectDeliveryPlanMapper, BossProjectDeliveryPlan>  implements BossProjectDeliveryPlanService {

    @Autowired
    private BossProjectDeliveryPlanMapper bossDeliveryPlanMapper;

    /**
     * 查询BOSS交付信息
     * @param queryWrapper 查询条件
     * @return
     */
    @Override
    public List<BossProjectDeliveryPlan> queryByCondition(Wrapper<BossProjectDeliveryPlan> queryWrapper) {
        return bossDeliveryPlanMapper.selectList(queryWrapper);
    }

    /**
     * 保存BOSS交付信息
     * @param voList 待新增数据
     * @return
     * @throws Exception
     */
    @Override
    public List<BossProjectDeliveryPlan> insert(List<BossProjectDeliveryPlan> voList){
        saveOrUpdateBatch(voList);
        return voList;
    }
}
