package com.usky.ems.service.impl;

import com.usky.ems.domain.DmpDevice;
import com.usky.ems.mapper.DmpDeviceMapper;
import com.usky.ems.service.DmpDeviceService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 设备信息服务实现类
 *
 * @author system
 * @since 2024-01-01
 */
@Service
public class DmpDeviceServiceImpl implements DmpDeviceService {

    @Autowired
    private DmpDeviceMapper dmpDeviceMapper;

    @Override
    public List<DmpDevice> getGatewayByDeviceId(Integer tenantId, String productCode) {
        return dmpDeviceMapper.selectGatewayByDeviceId(tenantId, productCode);
    }

    @Override
    public List<DmpDevice> getDevicesByGatewayUuid(String gatewayUuid) {
        return dmpDeviceMapper.selectDevicesByGatewayUuid(gatewayUuid);
    }
}
