Files
hk4e/gs/model/chat.go
2023-02-12 05:03:52 +08:00

22 lines
499 B
Go

package model
import (
"go.mongodb.org/mongo-driver/bson/primitive"
)
const (
ChatMsgTypeText = iota
ChatMsgTypeIcon
)
type ChatMsg struct {
ID primitive.ObjectID `bson:"_id,omitempty"`
Time uint32 `bson:"Time"`
ToUid uint32 `bson:"ToUid"`
Uid uint32 `bson:"Uid"`
IsRead bool `bson:"IsRead"`
MsgType uint8 `bson:"MsgType"`
Text string `bson:"Text"`
Icon uint32 `bson:"Icon"`
}