package io.renren.modules.business.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import io.renren.common.utils.PageUtils;
import io.renren.common.utils.Query;
import io.renren.modules.business.dao.BusinessPlanTlDao;
import io.renren.modules.business.entity.BusinessPlanTlEntity;
import io.renren.modules.business.service.BusinessPlanTlService;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;


@Service("businessPlanTlService")
public class BusinessPlanTlServiceImpl extends ServiceImpl<BusinessPlanTlDao, BusinessPlanTlEntity> implements BusinessPlanTlService {

    @Override
    public PageUtils queryPage(Map<String, Object> params) {
        IPage<BusinessPlanTlEntity> page = this.page(
                new Query<BusinessPlanTlEntity>().getPage(params),
                new QueryWrapper<BusinessPlanTlEntity>()
        );

        return new PageUtils(page);
    }

    /**
     * 获取列表
     * @param params
     * @return
     */
    @Override
    public List<BusinessPlanTlEntity> queryList(Map<String, Object> params) {
        return baseMapper.queryList(params);
    }

    /**
     * 获取完成人id列表
     * @param params
     * @return
     */
    @Override
    public List<Integer> queryEndUserId() {
        return baseMapper.queryEndUserId();
    }

}