🎉 first commit
This commit is contained in:
20
entity/friend.go
Normal file
20
entity/friend.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package entity
|
||||
|
||||
// Friend
|
||||
// @description: 好友列表
|
||||
type Friend struct {
|
||||
CustomAccount string `json:"customAccount"` // 微信号
|
||||
EncryptName string `json:"encryptName"` // 不知道
|
||||
Nickname string `json:"nickname"` // 昵称
|
||||
Pinyin string `json:"pinyin"` // 昵称拼音大写首字母
|
||||
PinyinAll string `json:"pinyinAll"` // 昵称全拼
|
||||
Reserved1 int `json:"reserved1"` // 未知
|
||||
Reserved2 int `json:"reserved2"` // 未知
|
||||
Type int `json:"type"` // 类型
|
||||
VerifyFlag int `json:"verifyFlag"` // 未知
|
||||
Wxid string `json:"wxid"` // 微信原始Id
|
||||
}
|
||||
|
||||
func (Friend) TableName() string {
|
||||
return "t_friend"
|
||||
}
|
||||
25
entity/message.go
Normal file
25
entity/message.go
Normal file
@@ -0,0 +1,25 @@
|
||||
package entity
|
||||
|
||||
import (
|
||||
"go-wechat/types"
|
||||
"time"
|
||||
)
|
||||
|
||||
// Message
|
||||
// @description: 消息数据库结构体
|
||||
type Message struct {
|
||||
MsgId int64 `gorm:"primaryKey"` // 消息Id
|
||||
CreateTime int // 发送时间戳
|
||||
CreateAt time.Time // 发送时间
|
||||
Type types.MessageType // 消息类型
|
||||
Content string // 内容
|
||||
DisplayFullContent string // 显示的完整内容
|
||||
FromUser string // 发送者
|
||||
GroupUser string // 群成员
|
||||
ToUser string // 接收者
|
||||
Raw string // 原始通知字符串
|
||||
}
|
||||
|
||||
func (Message) TableName() string {
|
||||
return "t_message"
|
||||
}
|
||||
Reference in New Issue
Block a user