model

package
v0.0.0-...-71e9963 Latest Latest
Warning

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

Go to latest
Published: May 13, 2023 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Channel

type Channel struct {
	ID       int    `json:"id" db:"id"`
	Name     string `json:"name" db:"name"`
	Title    string `json:"title" db:"title"`
	ImageURL string `json:"imageUrl" db:"image_url"`
	Stats    Stat
}

type DBChannel

type DBChannel struct {
	ID       int    `json:"ID" db:"id"`
	Name     string `json:"Username" db:"name"`
	Title    string `json:"Title" db:"title"`
	ImageURL string `json:"ImageURL" db:"image_url"`
}

type DBMessage

type DBMessage struct {
	ID         int    `db:"id"`
	ChannelID  int    `db:"channel_id"`
	UserID     int    `db:"user_id"`
	Title      string `db:"title"`
	MessageURL string `db:"message_url"`
	ImageURL   string `db:"image_url"`
}

type DBReply

type DBReply struct {
	ID        int    `db:"id"`
	MessageID int    `db:"message_id"`
	UserID    int    `db:"user_id"`
	Title     string `db:"title"`
	ImageURL  string `db:"image_url"`
}

type FullMessage

type FullMessage struct {
	ID              int    `db:"id"`
	MessageURL      string `db:"message_url"`
	Title           string `db:"title"`
	ImageURL        string `db:"image_url"`
	ChannelID       int    `db:"channel_id"`
	ChannelName     string `db:"channel_name"`
	ChannelTitle    string `db:"channel_title"`
	ChannelImageURL string `db:"channel_image_url"`
	UserID          int    `db:"user_id"`
	FullName        string `db:"fullname"`
	UserImageURL    string `db:"user_image_url"`
	RepliesCount    int    `db:"count"`
	Replies         []FullReply
	SavedID         int
	Status          bool
}

type FullReply

type FullReply struct {
	ID           int    `json:"id" db:"id"`
	UserID       int    `json:"userID" db:"user_id"`
	Title        string `json:"title" db:"title"`
	ImageURL     string `json:"ImageURL" db:"image_url"`
	FullName     string `json:"Fullname" db:"fullname"`
	UserImageURL string `json:"userImageURL" db:"user_image_url"`
}

type Saved

type Saved struct {
	ID        int `json:"id" db:"id"`
	WebUserID int `json:"webUserId" db:"user_id"`
	MessageID int `json:"messageId" db:"message_id"`
}

type Stat

type Stat struct {
	MessagesCount int
	RepliesCount  int
}

type TgMessage

type TgMessage struct {
	Message    string `json:"Message"`
	MessageURL string `json:"MessageURL"`
	ImageURL   string `json:"ImageURL"`
	FromID     struct {
		Username string `json:"Username"`
		ImageURL string `json:"ImageURL"`
		Fullname string `json:"Fullname"`
	} `json:"FromID"`
	PeerID struct {
		Username string `json:"Username"`
	} `json:"PeerID"`
	Replies struct {
		Count    int `json:"Count"`
		Messages []struct {
			FromID struct {
				Username string `json:"Username"`
				Fullname string `json:"Fullname"`
				ImageURL string `json:"ImageURL"`
			} `json:"FromID"`
			Message  string `json:"Message"`
			ImageURL string `json:"ImageURL"`
		} `json:"Messages"`
	} `json:"Replies"`
}

type User

type User struct {
	ID       int    `json:"id" db:"id"`
	Username string `json:"username" db:"username"`
	FullName string `json:"fullname" db:"fullname"`
	ImageURL string `json:"imageURL" db:"image_url"`
}

type WebUser

type WebUser struct {
	ID       int    `json:"id" db:"id"`
	Email    string `json:"email" db:"email"`
	Password string `json:"password" db:"password"`
}

Jump to

Keyboard shortcuts

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