Files
EchoChat/backend/go-service/app/group/model/join_request.go
bujinyuan 19979da59e feat(phase2c): 群聊与已读回执功能完整实现
Phase 2c 全部 14 个 Task 完成,包含:

后端(Go):
- MinIO 文件存储服务集成(Docker + Go SDK + 通用上传 API)
- Group 模块完整实现(DAO + Service + Controller + Router + Wire)
  - 18 个群管理 REST API + 11 个 WS 群事件推送
  - 群创建/解散/邀请/踢人/退出/转让群主/设管理员/禁言/全体禁言/群公告/群昵称/免打扰/搜索
- IM Service 扩展(群消息发送/撤回 + @提醒 + 管理员无时限撤回)
- 已读回执后端(单聊会话级 last_read_msg_id + 群聊消息级 im_message_reads)
- 管理端群组管理(列表/详情/解散)
- 数据库迁移(3 张新表 + 2 张表字段扩展)

前端(uni-app):
- 群聊 Store + API 封装 + 11 个 WS 事件监听
- 已读回执 UI(单聊已读/未读标记 + 群聊 X人已读 + 已读详情页)
- 7 个群聊页面(对话/创建/设置/成员/邀请/审批/搜索)
- 会话列表改造(全部/单聊/群聊 Tab + @标记 + 免打扰标识)

管理端(Vue 3 + Element Plus):
- 群组列表页(搜索/分页/详情弹窗/解散群聊)
- 侧边栏群组管理入口

文档同步:进度/架构/设计/API/规范文档全部更新

Made-with: Cursor
2026-03-04 14:58:23 +08:00

22 lines
1.2 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package model
import "time"
// GroupJoinRequest 入群申请模型,对应 im_group_join_requests 表
// Status: 0=待审批1=通过2=拒绝
type GroupJoinRequest struct {
ID int64 `json:"id" gorm:"primaryKey;autoIncrement"` // 申请唯一标识
GroupID int64 `json:"group_id" gorm:"not null;index:idx_group_join_req_group"` // 目标群 ID
UserID int64 `json:"user_id" gorm:"not null;index:idx_group_join_req_user"` // 申请人用户 ID
Message string `json:"message" gorm:"type:text;default:''"` // 申请附言
ReviewerID *int64 `json:"reviewer_id"` // 审批人用户 ID
Status int `json:"status" gorm:"not null;default:0"` // 状态0=待审批1=通过2=拒绝
CreatedAt time.Time `json:"created_at" gorm:"not null;autoCreateTime;type:timestamp(0)"` // 申请时间
UpdatedAt time.Time `json:"updated_at" gorm:"not null;autoUpdateTime;type:timestamp(0)"` // 更新时间
}
// TableName 指定数据库表名
func (GroupJoinRequest) TableName() string {
return "im_group_join_requests"
}