package com.gyee.wisdom.alarm.sharding.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.gyee.wisdom.alarm.sharding.entity.Device;
import com.gyee.wisdom.alarm.sharding.entity.DeviceStructure;
import com.gyee.wisdom.alarm.sharding.entity.Scadabj;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;


@Mapper
public interface DeviceStructureMapper extends BaseMapper<DeviceStructure> {

    DeviceStructure getDeviceStructureByCode(@Param("deviceId")String deviceId,
                                             @Param("nodeCode")String nodeCode);

    List<DeviceStructure> getAllDeviceStructure();

    List<DeviceStructure> getDeviceStructureByDeviceId(@Param("deviceId")String deviceId);

    List<DeviceStructure> getDeviceStructureChildNode(@Param("deviceId")String deviceId,
                                                      @Param("nodeCode")String nodeCode);

}
