model

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ListOfChats map[int64]Chat

Functions

func DeleteChatFromList

func DeleteChatFromList(chatId int64)

Remove a chat id from the map

func Init

func Init()

func IsChatIdInProgress

func IsChatIdInProgress(chatId int64) bool

Find if the chat id is already in progress TODO: Add the command to be sure it's on progress for the correct command

func UpsertChatToList

func UpsertChatToList(chat Chat)

Add/update chat to list

Types

type Chat

type Chat struct {
	ID         int64
	UserId     int64
	Step       int8
	InProgress string
}

func NewChat

func NewChat(chatId int64, userId int64, step int8, command string) *Chat

Create a new Chat

Jump to

Keyboard shortcuts

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