feat: 增加群聊消息查询条件
This commit is contained in:
@@ -330,7 +330,19 @@ func groupMessagesInternalQuerySpec() *internalQuerySpec {
|
||||
LEFT JOIN im_group_settings AS gs ON gs.topic=m.topic COLLATE utf8mb4_0900_ai_ci
|
||||
LEFT JOIN im_message_admin_actions AS aa ON aa.id=(SELECT MAX(a2.id) FROM im_message_admin_actions AS a2 WHERE a2.conversation_type='group' AND a2.topic=m.topic COLLATE utf8mb4_0900_ai_ci AND a2.seqid=m.seqid AND a2.action_status='success')`,
|
||||
DefaultSort: "ORDER BY m.id DESC",
|
||||
Filters: []internalQueryFilter{{"topic", "m.topic", "LIKE", "string"}, {"sender_user_id", "m.from_user", "=", "uid"}, {"content_type", contentType, "=", "string"}, {"status", status, "=", "string"}, {"keyword", "CAST(m.content AS CHAR)", "LIKE", "string"}, {"created_at_start", "m.created_at", ">=", "time"}, {"created_at_end", "m.created_at", "<=", "time"}},
|
||||
Filters: []internalQueryFilter{
|
||||
{"topic", "m.topic", "LIKE", "string"},
|
||||
{"seq_id", "m.seqid", "=", "int"},
|
||||
{"sender_user_id", "m.from_user", "=", "uid"},
|
||||
{"sender_username", "u.username", "LIKE", "string"},
|
||||
{"sender_nickname", "p.nickname", "LIKE", "string"},
|
||||
{"group_name", "gs.name", "LIKE", "string"},
|
||||
{"content_type", contentType, "=", "string"},
|
||||
{"status", status, "=", "string"},
|
||||
{"keyword", "CAST(m.content AS CHAR)", "LIKE", "string"},
|
||||
{"created_at_start", "m.created_at", ">=", "time"},
|
||||
{"created_at_end", "m.created_at", "<=", "time"},
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user