feat 历史同步插件支持同步插件记录和转移记录

This commit is contained in:
thsrite
2023-08-08 11:19:53 +08:00
parent 83c9499489
commit 914a7e74f2
3 changed files with 344 additions and 64 deletions

View File

@ -36,3 +36,9 @@ class DownloadHistoryOper(DbOper):
分页查询下载历史
"""
return DownloadHistory.list_by_page(self._db, page, count)
def truncate(self):
"""
清空转移记录
"""
DownloadHistory.truncate(self._db)

View File

@ -43,3 +43,9 @@ class PluginDataOper(DbOper):
if ObjectUtils.is_obj(data.value):
return json.loads(data.value)
return data.value
def truncate(self):
"""
清空转移记录
"""
PluginData.truncate(self._db)