✨ Basic realtime text command
This commit is contained in:
21
pkg/models/messages.go
Normal file
21
pkg/models/messages.go
Normal file
@ -0,0 +1,21 @@
|
||||
package models
|
||||
|
||||
import "gorm.io/datatypes"
|
||||
|
||||
type MessageType = uint8
|
||||
|
||||
const (
|
||||
MessageTypeText = MessageType(iota)
|
||||
MessageTypeAudio
|
||||
MessageTypeFile
|
||||
)
|
||||
|
||||
type Message struct {
|
||||
BaseModel
|
||||
|
||||
Content string `json:"content"`
|
||||
Metadata datatypes.JSONMap `json:"metadata"`
|
||||
Type MessageType `json:"type"`
|
||||
ChannelID uint `json:"channel_id"`
|
||||
SenderID uint `json:"sender_id"`
|
||||
}
|
Reference in New Issue
Block a user