package com.huiju.estateagents.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.huiju.estateagents.base.ResponseBean;
import com.huiju.estateagents.entity.TdBizEvent;
import com.huiju.estateagents.mapper.TdBizEventMapper;
import com.huiju.estateagents.service.ITdBizEventService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Map;

/**
 * <p>
 * 事件字典  服务实现类
 * </p>
 *
 * @author jobob
 * @since 2019-08-06
 */
@Service
public class TdBizEventServiceImpl extends ServiceImpl<TdBizEventMapper, TdBizEvent> implements ITdBizEventService {

    @Autowired
    private TdBizEventMapper tdBizEventMapper;

    @Override
    public ResponseBean getBizEventAndIntention(IPage<TdBizEvent> pg, String buildingId, Integer orgId) {
        ResponseBean responseBean = new ResponseBean();
        IPage<TdBizEvent> page = tdBizEventMapper.selectBizEventAndIntention(pg, buildingId, orgId);
        responseBean.addSuccess(page);
        return responseBean;
    }
}
