Router2IOT

package
v5.1.37 Latest Latest
Warning

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

Go to latest
Published: May 16, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckDeviceAndOrg

func CheckDeviceAndOrg(c any, args *ArgsCheckDeviceAndOrg) (b bool)

CheckDeviceAndOrg 检查设备是否存在且授权

func CheckDeviceAndOrgReturnDevice

func CheckDeviceAndOrgReturnDevice(c any, args *ArgsCheckDeviceAndOrg) (deviceID int64, b bool)

Types

type ArgsCheckDeviceAndOrg

type ArgsCheckDeviceAndOrg struct {
	//设备分组
	GroupMark string `db:"group_mark" json:"groupMark" check:"mark"`
	//设备编号
	// 同一个分组下,必须唯一
	Code string `db:"code" json:"code" check:"mark"`
	//时间戳
	NowTime int64 `db:"now_time" json:"nowTime"`
	//随机码
	Rand string `db:"rand" json:"rand"`
	//key计算结果
	// key+code+时间戳+随机码
	Key string `db:"key" json:"key"`
	//组织ID
	OrgID int64 `db:"org_id" json:"orgID" check:"id"`
}

ArgsCheckDeviceAndOrg 检查设备是否存在且授权参数

Jump to

Keyboard shortcuts

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