Closed mnixry closed 9 months ago
Thanks for opening your first issue here! Be sure to follow the issue template!
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Please make sure of the following things
Description of the feature / 需求描述
在MySQL和PostgreSQL中,存在多种插件/扩展程序来优化数据库的全文搜索能力,例如PGroonga,Mroonga,zhparser 等。
在大量AList用户存在CJK文本搜索的需求,而MySQL/PGSQL对CJK搜索支持较为薄弱的情况下,使用自定义的搜索引擎/扩展就显得尤为重要。通常来讲,使用这些搜索扩展需要对SQL查询进行不同程度的改动,而目前硬编码SQL查询的代码写法暂不支持这种需求。
Suggested solution / 实现思路
https://github.com/alist-org/alist/blob/83c22693306f36853d6c6c2b50f567d9b58cb834/internal/db/searchnode.go#L57-L74
从配置文件中读取SQL查询模板以代替使用硬编码的SQL查询来进行
Additional context / 附件
个人不是很熟悉AList项目的组织架构,如果有意见以及建议请多指教。