models

package
v0.0.0-...-2f8ff05 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2020 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Device

type Device struct {
	Id bson.ObjectId `json:"id" bson:"_id,omitempty"`
	//		Userid   bson.ObjectId `json:"userid" bson:"userid"`
	Token    string `json:"token" bson:"token"`
	Name     string `json:"name" bson:"name"`
	Location string `json:"location" bson:"location"`
}

User represents the structure of our resource

type Job

type Job struct {
	Id          bson.ObjectId `json:"id" bson:"_id"`
	Deviceid    string        `json:"deviceid" bson:"deviceid"`
	Mediaid     string        `json:"mediaid" bson:"mediaid"`
	Token       string        `json:"token" bson:"token"`
	Name        string        `json:"name" bson:"name"`
	Cron        string        `json:"cron" bson:"cron"`
	CronEntryid int           `json:"cronentryid" bson:"cronentryid"`
	Speak       string        `json:"speak" bson:"speak"`
	Activated   bool          `json:"activated" bson:"activated"`
}

User represents the structure of our resource

type Media

type Media struct {
	Id bson.ObjectId `json:"id" bson:"_id,omitempty"`
	//Jobid bson.ObjectId `json:"jobid" bson:"jobid"`
	//	Userid bson.ObjectId `json:"userid" bson:"userid"`
	Gridfsid    string      `json:"gridfsid" bson:"gridfsid"`
	Name        string      `json:"name" bson:"name"`
	Category    string      `json:"category" bson:"category"`
	Tag         string      `json:"tag" bson:"tag"`
	Tags        []string    `json:"tag" bson:"tags"`
	Size        int64       `json:"size" bson:"size"`
	TSize       string      `json:"tsize" bson:"tsize"`
	Description string      `json:"description" bson:"description"`
	Submedia    []*Submedia `json:"submedia"`
	Thumbnail   bson.Binary `json:"thumbnail" bson:"thumbnail"`
}

type Submedia

type Submedia struct {
	Id       bson.ObjectId `json:"id" bson:"_id,omitempty"`
	Fatherid string        `json:"fatherid" bson:"fatherid"`
	Gridfsid string        `json:"gridfsid" bson:"gridfsid"`
	Name     string        `json:"name" bson:"name"`
	Size     int64         `json:"size" bson:"size"`
	TSize    string        `json:"tsize" bson:"tsize"`
}

type Tag

type Tag struct {
	Id bson.ObjectId `json:"id" bson:"_id,omitempty"`
	//Jobid bson.ObjectId `json:"jobid" bson:"jobid"`
	//	Userid bson.ObjectId `json:"userid" bson:"userid"`
	Name string `json:"name" bson:"name"`
}

type User

type User struct {
	Id        bson.ObjectId `json:"id" bson:"_id"`
	Token     string        `json:"token" bson:"token"`
	Validated string        `json:"validated" bson:"validated"`
	Nickname  string        `json:"nickname" bson:"nickname"`
	Email     string        `json:"email" bson:"email"`
}

User represents the structure of our resource

Jump to

Keyboard shortcuts

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