models

package
v0.0.0-...-e2eb9aa Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLastBlock

func GetLastBlock() (uint32, error)

func GetMongoClient

func GetMongoClient() (*mongo.Client, error)

func SaveTelegramChannel

func SaveTelegramChannel(channel TelegramChannel) error

Types

type TelegramChannel

type TelegramChannel struct {
	ID          primitive.ObjectID `bson:"_id"`
	ChannelID   int64              `bson:"channel_id"`
	Title       string             `bson:"title"`
	UserName    string             `bson:"username"`
	Description string             `bson:"description"`
	CreatedAt   time.Time          `bson:"created_at"`
	BlockID     uint32             `bson:"block_id"`
}

func GetTelegramChannel

func GetTelegramChannel(channelID int64) (TelegramChannel, error)

Jump to

Keyboard shortcuts

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