edge

package
v0.0.0-...-ae4999c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 10, 2022 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssignPermissionsToUsers

func AssignPermissionsToUsers(device model.Device, measure model.Measure) error

将新创建的点位授权给对设备有相应权限的用户 暂时采用循环遍历用户来判断

func Feedback

func Feedback(deviceID int64, ctx iris.Context)

func NotifyAllUsers

func NotifyAllUsers(alarm model.Alarm) error

Types

type Alarm

type Alarm struct {
	Name   string                 `json:"name"`
	Tags   map[string]string      `json:"tags"`
	Fields map[string]interface{} `json:"fields"`
	Time   time.Time              `json:"time"`
}

type Log

type Log struct {
	Level     string    `json:"level"`
	Message   string    `json:"msg"`
	CreatedAt time.Time `json:"time"`
}

type Measure

type Measure struct {
	TagName string `json:"tag"`
	Title   string `json:"title"`
}

type Perf

type Perf struct {
	Delay int `json:"delay"`
}

type Status

type Status struct {
	Index int    `json:"index"`
	Title string `json:"title"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL