feat: expose url field for link/appmsg messages#18
Open
LegendLeo wants to merge 2 commits intojackwener:mainfrom
Open
feat: expose url field for link/appmsg messages#18LegendLeo wants to merge 2 commits intojackwener:mainfrom
LegendLeo wants to merge 2 commits intojackwener:mainfrom
Conversation
Extract <url> from appmsg XML in type-49 messages and append it as a 'url' field in history/search output. The field is omitted when the message has no valid URL (non-link types, empty, non-http).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
问题
wx history/wx search输出的链接消息(local_type=49)只有标题,没有 URL,导致无法直接跳转原文。方案
在
src/daemon/query.rs中新增extract_appmsg_url()函数,解析 appmsg XML 中的<url>字段(fallback 到<url1>),并在query_messages和search_in_table的输出 JSON 中附加url字段。local_type & 0xFFFFFFFF == 49的消息提取输出变化
修复前:
修复后: