瀏覽代碼

路径修改

luojiehua 4 年之前
父節點
當前提交
7113af4067
共有 1 個文件被更改,包括 6 次插入2 次删除
  1. 6 2
      jobs/exportJobs.py

+ 6 - 2
jobs/exportJobs.py

@@ -1,7 +1,11 @@
 #coding:utf8
 
-from utils.Utils import sendEmail,getCurrent_date
+import sys
 import os
+sys.path.append(os.path.join(os.path.dirname(__file__),".."))
+
+from utils.Utils import sendEmail,getCurrent_date
+
 import datetime
 import time
 from export.exportDocument import exportDocument_medicine,list_df_columns
@@ -29,7 +33,7 @@ def export_medicine_friday():
 
 def job_medicine_friday():
     _scheduler = BlockingScheduler()
-    _scheduler.add_job(export_medicine_friday(),"cron",day_of_week='fri',hour=18)
+    _scheduler.add_job(export_medicine_friday,"cron",day_of_week='fri',hour=18)
     _scheduler.start()