add 删除下载历史、删除下载文件历史

This commit is contained in:
thsrite 2024-06-25 10:03:29 +08:00
parent 7dd1e75ad7
commit fd2682bc6a

View File

@ -139,3 +139,15 @@ class DownloadHistoryOper(DbOper):
return DownloadHistory.list_by_type(db=self._db, return DownloadHistory.list_by_type(db=self._db,
mtype=mtype, mtype=mtype,
days=days) days=days)
def delete_history(self, historyid):
"""
删除下载记录
"""
DownloadHistory.delete(self._db, historyid)
def delete_downloadfile(self, downloadfileid):
"""
删除下载文件记录
"""
DownloadFiles.delete(self._db, downloadfileid)