增加合并全部数据库的命令

This commit is contained in:
xaoyaoo 2024-05-06 17:56:55 +08:00
parent d2c4c07368
commit 0f721425ae
2 changed files with 3 additions and 3 deletions

View File

@ -233,7 +233,7 @@ def get_real_time_msg():
if not merge_path or not key or not wx_path or not wx_path:
return ReJson(1002, body="msg_path or media_path or wx_path or key is required")
code, ret = all_merge_real_time_db(wx_path, key, merge_path)
code, ret = all_merge_real_time_db(key=key, wx_path=wx_path, merge_path=merge_path)
if code:
return ReJson(0, ret)
else:

View File

@ -419,8 +419,8 @@ def all_merge_real_time_db(key, wx_path, merge_path):
db_paths = get_core_db(wx_path, ["MediaMSG", "MSG", "MicroMsg"])
if not db_paths[0]:
# return ReJson(1001, body="media_paths or msg_paths is required")
return False, "media_paths or msg_paths is required"
print(wx_path)
return False, db_paths[1]
db_paths = db_paths[1]
for i in db_paths:
merge_real_time_db(key=key, db_path=i, merge_path=merge_path)