diff --git a/filter.html b/filter.html
index 3cf4bf0..65c571f 100644
--- a/filter.html
+++ b/filter.html
@@ -195,13 +195,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- let res = $.parseJSON(res)
- if (res.success) {
- data.mic1 = res.content.mic1
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.mic1 = resData.content.mic1
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -227,13 +227,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- let res = $.parseJSON(res)
- if (res.success) {
- data.mic2 = res.content.mic2
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.mic2 = resData.content.mic2
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -257,13 +257,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- let res = $.parseJSON(res)
- if (res.success) {
- data.mic1 = res.content.mic1
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.mic1 = resData.content.mic1
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -287,13 +287,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- let res = $.parseJSON(res)
- if (res.success) {
- data.mic2 = res.content.mic2
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.mic2 = resData.content.mic2
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -318,18 +318,18 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- let res = $.parseJSON(res)
- if (res.success) {
+ let resData = $.parseJSON(res)
+ if (resData.success) {
if (module == 'mic1') {
- data.mic1 = res.content.mic1
+ data.mic1 = resData.content.mic1
}
else {
- data.mic2 = res.content.mic2
+ data.mic2 = resData.content.mic2
}
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -343,9 +343,9 @@
type: "GET",
url: url,
success: function (res) {
- let res = $.parseJSON(res)
- if (res.success) {
- data = res.content
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data = resData.content
bindData()
}
else {
diff --git a/home.html b/home.html
index 9ce33a5..08b5eda 100644
--- a/home.html
+++ b/home.html
@@ -983,12 +983,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- if (res.success) {
- data.lineinput = res.content.lineinput
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.lineinput = resData.content.lineinput
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -1023,12 +1024,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- if (res.success) {
- data.lineinput = res.content.lineinput
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.lineinput = resData.content.lineinput
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -1065,12 +1067,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- if (res.success) {
- data.mic1 = res.content.mic1
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.mic1 = resData.content.mic1
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -1108,12 +1111,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- if (res.success) {
- data.mic2 = res.content.mic2
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.mic2 = resData.content.mic2
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -1149,12 +1153,13 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- if (res.success) {
- data.output = res.content.output
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data.output = resData.content.output
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -1180,30 +1185,31 @@
dataType: "json",
contentType: "application/json; charset=utf-8",
success: function (res) {
- if (res.success) {
+ let resData = $.parseJSON(res)
+ if (resData.success) {
if (module == 'lineinput') {
- data.lineinput = res.content.lineinput
+ data.lineinput = resData.content.lineinput
lineinputValue = data.lineinput.audio
}
else if (module == 'mic1') {
- data.mic1 = res.content.mic1
+ data.mic1 = resData.content.mic1
mic1Value = data.mic1.audio
}
else if (module == 'mic2') {
- data.mic2 = res.content.mic2
+ data.mic2 = resData.content.mic2
mic2Value = data.mic2.audio
}
else {
- data.output = res.content.output
+ data.output = resData.content.output
outputValue = data.mic2.audio
}
bindData()
}
else {
- alert(res.message)
+ alert(resData.message)
}
},
error: function (res) {
@@ -1219,8 +1225,9 @@
type: "GET",
url: url,
success: function (res) {
- if (res.success) {
- data = res.content
+ let resData = $.parseJSON(res)
+ if (resData.success) {
+ data = resData.content
lineinputValue = data.lineinput.audio
mic1Value = data.mic1.audio
mic2Value = data.mic2.audio