model

package
v1.3.14 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Code generated by goctl. DO NOT EDIT.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotFound        = mon.ErrNotFound
	ErrInvalidObjectId = errors.New("invalid objectId")
)

Functions

This section is empty.

Types

type Alarm_config

type Alarm_config struct {
	ID primitive.ObjectID `bson:"_id,omitempty" json:"id,omitempty"`
	// TODO: Fill your own fields
	UpdateAt     time.Time `bson:"updateAt,omitempty" json:"updateAt,omitempty"`
	CreateAt     time.Time `bson:"createAt,omitempty" json:"createAt,omitempty"`
	AddxUserId   string    `bson:"addxUserId,omitempty" json:"userId,omitempty"`
	SerialNumber string    `bson:"serialNumber,omitempty" json:"deviceSn,omitempty"`
	//0 提示
	//1 不提示
	Config int32 `bson:"config,omitempty" json:"config,omitempty"`
}

type Alarm_configModel

type Alarm_configModel interface {
	FindOneByUserIdAndDeviceSn(ctx context.Context, addxUserId, serialNumber string) (*Alarm_config, error)
	SetConfigByUserIdAndDeviceSn(ctx context.Context, addxUserId, serialNumber string, config int32) error
	// contains filtered or unexported methods
}

Alarm_configModel is an interface to be customized, add more methods here, and implement the added methods in customAlarm_configModel.

func NewAlarm_configModel

func NewAlarm_configModel(url, db, collection string) Alarm_configModel

NewAlarm_configModel returns a model for the mongo.

Jump to

Keyboard shortcuts

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