ming 3 lat temu
rodzic
commit
7a09674b40
1 zmienionych plików z 3 dodań i 1 usunięć
  1. 3 1
      api/main.py

+ 3 - 1
api/main.py

@@ -432,7 +432,9 @@ def gen_video_queue(name_hash,name,text_content, image_urls,avatar,user_id):
             if left_time is None:
                 left_time = 5*60
             if left_time < vid_duration:
-                mailer.send('您本月額度剩下'+str(left_time)+'秒,此部影片有'+str(vid_duration)+'秒, 若要繼續產生影片請至 http://192.168.1.106:8007/confirm_add_value?name_hash='+name_hash+' 加值')
+                msg = '您本月額度剩下'+str(left_time)+'秒,此部影片有'+str(vid_duration)+'秒, 若要繼續產生影片請至 http://192.168.1.106:8007/confirm_add_value?name_hash='+name_hash+' 加值'
+                print(msg)
+                mailer.send(msg)
             else:
                 left_time = left_time - vid_duration
                 db.query('UPDATE users SET left_time ='+str(left_time)+' WHERE id='+str(user_id)+';')