package com.ruoyi.system.service;

import com.ruoyi.common.annotation.DataSource;
import com.ruoyi.common.enums.DataSourceType;
import com.ruoyi.system.mapper.SysAlarmMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
//@DataSource(value = DataSourceType.SLAVE)
public class SysAlarmService {
    @Resource
    public SysAlarmMapper sysAlarmMapper;

    public void insertalarm(String tableName,String faultId,String faultdescs,String faultstatus,String createtime,String messageType,String controllerId,String deviceId,String longitude,String latitude){
        sysAlarmMapper.insertalarm(tableName,faultId, faultdescs, faultstatus, createtime, messageType,controllerId,deviceId,longitude,latitude);
    }
    public void updatealarm(String controllerId,String deviceId){
        sysAlarmMapper.updatealarm(controllerId, deviceId);
    }
}
