add 公共定时服务

This commit is contained in:
jxxghp
2023-06-20 16:17:23 +08:00
parent 3ae8ded8dd
commit 4f4a788594
3 changed files with 20 additions and 0 deletions

View File

@ -557,3 +557,9 @@ class TheMovieDbModule(_ModuleBase):
xml_str = doc.toprettyxml(indent=" ", encoding="utf-8")
file_path.write_bytes(xml_str)
logger.info(f"NFO文件已保存{file_path}")
def scheduler_job(self) -> None:
"""
定时任务每10分钟调用一次
"""
self.cache.save()