Files
rootandClaude Opus 5 8679200f41 Initial commit
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-15 13:57:10 +08:00

34 lines
1.4 KiB
Go

package sessionmod
import (
"91porn-server/models/commod"
"time"
"go.mongodb.org/mongo-driver/bson/primitive"
)
// QueryCond 查询列表
type QueryCond struct {
commod.Page
}
// QuerySessionIdCond 查询会话id
type QuerySessionIdCond struct {
TakeUid uint64 `json:"takeUid" form:"takeUid"` // 接收者uid
}
// SessionApp 会话app返回实体
type SessionApp struct {
ID primitive.ObjectID `json:"id" bson:"_id"` // id
SendUid uint64 `json:"sendUid" bson:"sendUid"` // 发送者uid
TakeUid uint64 `json:"takeUid" bson:"takeUid"` // 接收者uid
UserId uint64 `json:"userId" bson:"userId"` // 用户uid
PeerImUserID int64 `json:"peerImUserId" bson:"peerImUserId"` // 对端 IM 平台用户 ID
UserName string `json:"userName" bson:"userName"` // 用户姓名
UserAvatar string `json:"userAvatar" bson:"userAvatar"` // 用户头像
SessionId string `json:"sessionId" bson:"sessionId"` // sessionId
NoReadNum int64 `json:"noReadNum"` // 未读消息数
PreContent string `json:"preContent" bson:"preContent"` // 预览消息内容,存最新一条
CreatedAt time.Time `json:"createdAt" bson:"updatedAt"` // 创建时间,返回更新时间
}