Documentation ¶
Index ¶
- func DeviceAdd(c *gin.Context)
- func DeviceDelete(c *gin.Context)
- func DeviceGet(c *gin.Context)
- func DeviceList(c *gin.Context)
- func DeviceUpdate(c *gin.Context)
- func IssuedDeviceAdd(c *gin.Context)
- func IssuedDeviceDelete(c *gin.Context)
- func IssuedDeviceGet(c *gin.Context)
- func IssuedDeviceList(c *gin.Context)
- func IssuedDeviceUpdate(c *gin.Context)
- func Login(c *gin.Context)
- func Logout(c *gin.Context)
- func MetricsGet(c *gin.Context)
- func UserAdd(c *gin.Context)
- func UserDelete(c *gin.Context)
- func UserGet(c *gin.Context)
- func UserList(c *gin.Context)
- func UserUpdate(c *gin.Context)
- type Device
- type IssuedDevice
- type ListQuery
- type MetricsQuery
- type Session
- type User
- type Variables
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeviceDelete ¶
func DeviceList ¶
func DeviceUpdate ¶
func IssuedDeviceAdd ¶
func IssuedDeviceDelete ¶
func IssuedDeviceGet ¶
func IssuedDeviceList ¶
func IssuedDeviceUpdate ¶
func UserDelete ¶
func UserUpdate ¶
Types ¶
type Device ¶
type Device struct { ID primitive.ObjectID `json:"id" bson:"_id"` UserID primitive.ObjectID `json:"userId" bson:"userId"` Name string `json:"name" bson:"name"` LastMetricTime *time.Time `json:"lastMetricTime" bson:"lastMetricTime"` Active bool `json:"active" bson:"active"` CreatedAt time.Time `json:"createdAt" bson:"createdAt"` UpdatedAt time.Time `json:"updatedAt" bson:"updatedAt"` }
type IssuedDevice ¶
type MetricsQuery ¶
type Session ¶
type Session struct { ID primitive.ObjectID `json:"_id" bson:"_id"` UserID primitive.ObjectID `json:"userId" bson:"userId"` StartTime time.Time `json:"startTime" bson:"startTime"` EndTime *time.Time `json:"endTime" bson:"endTime"` CreatedAt time.Time `json:"createdAt" bson:"createdAt"` UpdatedAt time.Time `json:"updatedAt" bson:"updatedAt"` }
type User ¶
type User struct { ID primitive.ObjectID `json:"_id" bson:"_id"` Email string `json:"email,omitempty" bson:"email"` Password string `json:"password" bson:"password"` Name string `json:"name" bson:"name"` Surename string `json:"surename" bson:"surename"` Admin bool `json:"admin" bson:"admin"` Active bool `json:"active" bson:"active"` CreatedAt time.Time `json:"createdAt" bson:"createdAt"` UpdatedAt time.Time `json:"updatedAt" bson:"updatedAt"` }
type Variables ¶
type Variables struct { Conf *configuration.Configuration Db *database.Database User *token.User }
Click to show internal directories.
Click to hide internal directories.