zhs 3 年之前
父节点
当前提交
ff0301eebb
共有 1 个文件被更改,包括 4 次插入3 次删除
  1. 4 3
      src/main/resources/static/js/personal/function.js

+ 4 - 3
src/main/resources/static/js/personal/function.js

@@ -593,7 +593,8 @@ function withdrawal(){
         layer.load(3);
         //修改
         $.ajax({
-            url: "https://www.tuyatrip.com/api/zfbWithdrawal/zfbCash",
+            // url: "https://www.tuyatrip.com/api/zfbWithdrawal/zfbCash",
+            url: "http://localhost:9600/zfbWithdrawal/zfbCash",
             type: "put",
             data: {
                 "name": $("input[name=name]").val(),
@@ -602,14 +603,14 @@ function withdrawal(){
             },
             // contentType: "application/json",
             headers: {"token": localStorage.getItem("token")},
-            dataType: "text",
+            dataType: "json",
             success: (data) => {
                 if(data.msg =="500"){
                     layer.closeAll();
                     parent.layer.msg(data.errMsg, {icon: 3});
                 } else {
                     layer.closeAll();
-                    parent.layer.msg(data, {icon: 1});
+                    parent.layer.msg(data.data, {icon: 1});
                     load();
                 }
             },