package com.pqs9900.serviceImpl.DataInfo;
/**
 * @Author denghuajun
 * @Description //TODO 终端状态impl
 * @Date 2019/3/15 13:49
 **/

import com.njcn.pojo.commons.DeviceType;
import com.njcn.utils.UserUtil;
import com.pqs9900.mapper.DataInfo.DevStateDetailMapper;
import com.pqs9900.pojo.DataInfo.DevStateDetail;
import com.pqs9900.service.DataInfo.DevStateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

@Service
public class DevStateServiceImpl implements DevStateService {
    @Autowired
    DevStateDetailMapper devStateDetailMapper;

    @Override
    public List<DevStateDetail> getDevStateDetail(List<Integer> dataType) {
        List<DevStateDetail> devStateServices = new ArrayList<>();
        devStateServices = devStateDetailMapper.getDevStateDetail(dataType);
        return devStateServices;
    }

    @Override
    public List<DevStateDetail> getDevStateInfo(Long devIndex, Date startTime, Date endTime) {
        List<DevStateDetail> stateDetails = new ArrayList<>();
        stateDetails = devStateDetailMapper.getDevStateInfo(devIndex, startTime, endTime);
        return stateDetails;
    }

    @Override
    public DevStateDetail getDeviceDetail(Long devIndex) {
        DevStateDetail devStateDetail = devStateDetailMapper.getDeviceDetail(devIndex);
        return devStateDetail;
    }
}
