个股论坛重做
This commit is contained in:
@@ -824,6 +824,9 @@ def send_message(channel_id):
|
||||
message_id = generate_id()
|
||||
now = datetime.utcnow()
|
||||
|
||||
# 将 Markdown 图片语法转换为 HTML(支持 base64 图片)
|
||||
content_html = parse_markdown_images(content)
|
||||
|
||||
# 构建消息文档
|
||||
message_doc = {
|
||||
'id': message_id,
|
||||
@@ -833,6 +836,7 @@ def send_message(channel_id):
|
||||
'author_name': user['username'],
|
||||
'author_avatar': user.get('avatar', ''),
|
||||
'content': content,
|
||||
'content_html': content_html, # Markdown 转换后的 HTML
|
||||
'type': 'text',
|
||||
'mentioned_users': data.get('mentionedUsers', []),
|
||||
'mentioned_stocks': data.get('mentionedStocks', []),
|
||||
|
||||
Reference in New Issue
Block a user