aaron-1015 4 anos atrás
pai
commit
ca139bf9b9

+ 1 - 1
api/main.py

@@ -434,7 +434,7 @@ 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:
-                msg = '您本月額度剩下'+str(left_time)+'秒,此部影片有'+str(vid_duration)+'秒, 若要繼續產生影片請至 www.choozmo.com:8888/confirm_add_value?name_hash='+name_hash+' 加值'
+                msg = '您本月額度剩下'+str(left_time)+'秒,此部影片有'+str(vid_duration)+'秒, 若要繼續產生影片請至 192.168.1.106:8887/confirm_add_value?name_hash='+name_hash+' 加值'
                 print(msg)
                 msg =msg.encode(encoding='utf-8')
                 mailer.send(msg, email)

+ 4 - 4
api/static/gen_avatar.js

@@ -15,7 +15,7 @@ function prepareUpload(event) {
     processData: false, // important
     contentType: false, // important
     data: data,
-    url: 'http://www.choozmo.com:8888/uploadfile',
+    url: '192.168.1.106:8887/uploadfile',
     dataType: 'json',
     success: function (jsonData) {
       event.target.previousSibling.value =jsonData.msg;
@@ -61,7 +61,7 @@ $(".next").click(function () {
   console.log(dataOBJ)
   //alert('資料已送出! 請耐心等候')
   $.ajax({
-    url: 'http://www.choozmo.com:8888/make_anchor_video_v2',
+    url: '192.168.1.106:8887/make_anchor_video_v2',
     //url: 'http://www.choozmo.com:8888/qqreq',
     dataType : 'json', // 預期從server接收的資料型態
     contentType : 'application/json; charset=utf-8', // 要送到server的資料型態
@@ -90,7 +90,7 @@ $(".gen_avatar").click(function () {
   console.log(dataOBJ)
   //alert('資料已送出! 請耐心等候')
   $.ajax({
-    url: 'http://www.choozmo.com:8888/swapFace',
+    url: '192.168.1.106:8887/swapFace',
     dataType: 'json', // 預期從server接收的資料型態
     contentType: 'application/json; charset=utf-8', // 要送到server的資料型態
     type: 'post',
@@ -110,7 +110,7 @@ var loaded_data = ''
 function openNav() {
   document.getElementById("mySidenav").style.width = "250px";
   document.querySelector('.loader').style.display = "block";
-  $.get("http://www.choozmo.com:8888/history_input", function (data, status) {
+  $.get("192.168.1.106:8887/history_input", function (data, status) {
     console.log(data)
     loaded_data = data
     for (var obj of data) {

+ 4 - 4
api/static/script_anchor_eng.js

@@ -60,7 +60,7 @@ function prepareUpload(event) {
     processData: false, // important
     contentType: false, // important
     data: data,
-    url: 'http://www.choozmo.com:8888/uploadfile',
+    url: '192.168.1.106:8887/uploadfile',
     dataType: 'json',
     success: function (jsonData) {
       event.target.previousSibling.value =jsonData.msg;
@@ -113,7 +113,7 @@ $(".next").click(function () {
   console.log(dataOBJ)
   //alert('資料已送出! 請耐心等候')
   $.ajax({
-    url: 'http://www.choozmo.com:8888/make_anchor_video_eng',
+    url: '192.168.1.106:8887/make_anchor_video_eng',
     //url: 'http://www.choozmo.com:8888/qqreq',
     dataType : 'json', // 預期從server接收的資料型態
     contentType : 'application/json; charset=utf-8', // 要送到server的資料型態
@@ -142,7 +142,7 @@ $(".gen_avatar").click(function () {
   console.log(dataOBJ)
   //alert('資料已送出! 請耐心等候')
   $.ajax({
-    url: 'http://www.choozmo.com:8888/swapFace',
+    url: '192.168.1.106:8887/swapFace',
     dataType: 'json', // 預期從server接收的資料型態
     contentType: 'application/json; charset=utf-8', // 要送到server的資料型態
     type: 'post',
@@ -162,7 +162,7 @@ var loaded_data = ''
 function openNav() {
   document.getElementById("mySidenav").style.width = "250px";
   document.querySelector('.loader').style.display = "block";
-  $.get("http://www.choozmo.com:8888/history_input", function (data, status) {
+  $.get("192.168.1.106:8887/history_input", function (data, status) {
     console.log(data)
     loaded_data = data
     for (var obj of data) {

+ 4 - 4
api/static/script_util.js

@@ -58,7 +58,7 @@ function prepareUpload(event) {
     processData: false, // important
     contentType: false, // important
     data: data,
-    url: 'http://www.choozmo.com:8888/uploadfile',
+    url: '192.168.1.106:8887/uploadfile',
     dataType: 'json',
     success: function (jsonData) {
       event.target.previousSibling.value = jsonData.msg;
@@ -105,7 +105,7 @@ $(".next").click(function () {
   console.log(dataOBJ)
   jwt_token =  get_jwt_token()
   var xhr = new XMLHttpRequest();
-  xhr.open("POST", "www.choozmo.com:8888/make_anchor_video");
+  xhr.open("POST", "192.168.1.106:8887/make_anchor_video");
   xhr.setRequestHeader("accept", "application/json");
   xhr.setRequestHeader("Authorization","Bearer "+jwt_token)
   xhr.setRequestHeader("Content-Type", "application/json");
@@ -130,7 +130,7 @@ $(".gen_avatar").click(function () {
   console.log(dataOBJ)
   //alert('資料已送出! 請耐心等候')
   $.ajax({
-    url: 'http://www.choozmo.com:8888/swapFace',
+    url: '192.168.1.106:8887/swapFace',
     dataType: 'json', // 預期從server接收的資料型態
     contentType: 'application/json; charset=utf-8', // 要送到server的資料型態
     type: 'post',
@@ -149,7 +149,7 @@ var loaded_data = ''
 function openNav() {
   document.getElementById("mySidenav").style.width = "250px";
   document.querySelector('.loader').style.display = "block";
-  $.get("http://www.choozmo.com:8888/history_input", function (data, status) {
+  $.get("192.168.1.106:8887/history_input", function (data, status) {
     console.log(data)
     loaded_data = data
     for (var obj of data) {

+ 1 - 1
etc/main.py

@@ -416,7 +416,7 @@ def generate_subtitle_image(name_hash,text_content):
     return img_list
 
 async def sendProgress(progress,client_id):
-    ws = create_connection("ws://www.choozmo.com:8888/progress/"+client_id)
+    ws = create_connection("ws://192.168.1.106:8887/progress/"+client_id)
     ws.send(str(progress))
     ws.close()