修改API domain
This commit is contained in:
parent
a8c1c401d4
commit
62c2be087f
@ -22,7 +22,7 @@ window.onload = function () {
|
|||||||
paramValue = getParameterByName('id');
|
paramValue = getParameterByName('id');
|
||||||
console.log(paramValue);
|
console.log(paramValue);
|
||||||
|
|
||||||
axios.get("http://127.0.0.1:10001/api/record/" + paramValue)
|
axios.get("https://pcredive.ray650128.com/backend/api/record/" + paramValue)
|
||||||
.then(function (response) {
|
.then(function (response) {
|
||||||
// 在這裡處理回傳的資料
|
// 在這裡處理回傳的資料
|
||||||
var options = response.data;
|
var options = response.data;
|
||||||
@ -97,7 +97,7 @@ function fillRecord(
|
|||||||
knife3c_damage
|
knife3c_damage
|
||||||
) {
|
) {
|
||||||
// 发送登录请求
|
// 发送登录请求
|
||||||
axios.put("http://127.0.0.1:10001/api/record/" + recordId, {
|
axios.put("https://pcredive.ray650128.com/backend/api/record/" + recordId, {
|
||||||
memberId: memberId,
|
memberId: memberId,
|
||||||
record1: {
|
record1: {
|
||||||
boss: knife1_boss,
|
boss: knife1_boss,
|
||||||
|
|||||||
@ -39,7 +39,7 @@ row_1.appendChild(heading_6);
|
|||||||
row_1.appendChild(heading_7);
|
row_1.appendChild(heading_7);
|
||||||
thead.appendChild(row_1);
|
thead.appendChild(row_1);
|
||||||
// 取得刀表
|
// 取得刀表
|
||||||
axios.get("http://127.0.0.1:10001/api/record", {
|
axios.get("https://pcredive.ray650128.com/backend/api/record", {
|
||||||
headers: {
|
headers: {
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'Accept': 'application/json'
|
'Accept': 'application/json'
|
||||||
@ -99,7 +99,7 @@ function getDate() {
|
|||||||
var dateSplit = selectedDate.value.split("-");
|
var dateSplit = selectedDate.value.split("-");
|
||||||
console.log(dateSplit);
|
console.log(dateSplit);
|
||||||
// 取得刀表
|
// 取得刀表
|
||||||
axios.get("http://127.0.0.1:10001/api/record/" + dateSplit[0] + "/" + dateSplit[1] + "/" + dateSplit[2], {
|
axios.get("https://pcredive.ray650128.com/backend/api/record/" + dateSplit[0] + "/" + dateSplit[1] + "/" + dateSplit[2], {
|
||||||
headers: {
|
headers: {
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'Accept': 'application/json'
|
'Accept': 'application/json'
|
||||||
|
|||||||
@ -40,7 +40,7 @@ document
|
|||||||
});
|
});
|
||||||
|
|
||||||
axios
|
axios
|
||||||
.get("http://127.0.0.1:10001/api/member/not_leave")
|
.get("https://pcredive.ray650128.com/backend/api/member/not_leave")
|
||||||
.then(function (response) {
|
.then(function (response) {
|
||||||
// 在這裡處理回傳的資料
|
// 在這裡處理回傳的資料
|
||||||
var options = response.data;
|
var options = response.data;
|
||||||
@ -77,7 +77,7 @@ function fillRecord(
|
|||||||
knife3c_damage
|
knife3c_damage
|
||||||
) {
|
) {
|
||||||
// 发送登录请求
|
// 发送登录请求
|
||||||
axios.post("http://127.0.0.1:10001/api/record/" + memberId, {
|
axios.post("https://pcredive.ray650128.com/backend/api/record/" + memberId, {
|
||||||
record1: {
|
record1: {
|
||||||
boss: knife1_boss,
|
boss: knife1_boss,
|
||||||
damage: parseInt(knife1_damage),
|
damage: parseInt(knife1_damage),
|
||||||
|
|||||||
@ -12,7 +12,7 @@ window.onload = function () {
|
|||||||
paramValue = getParameterByName('id');
|
paramValue = getParameterByName('id');
|
||||||
console.log(paramValue);
|
console.log(paramValue);
|
||||||
|
|
||||||
axios.get("http://127.0.0.1:10001/api/member/" + paramValue)
|
axios.get("https://pcredive.ray650128.com/backend/api/member/" + paramValue)
|
||||||
.then(function (response) {
|
.then(function (response) {
|
||||||
// 在這裡處理回傳的資料
|
// 在這裡處理回傳的資料
|
||||||
var options = response.data;
|
var options = response.data;
|
||||||
@ -69,7 +69,7 @@ function updateMember(memberId, nickName, playerName, gameUid, discordId) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 发送登录请求
|
// 发送登录请求
|
||||||
axios.put("http://127.0.0.1:10001/api/member/" + memberId, {
|
axios.put("https://pcredive.ray650128.com/backend/api/member/" + memberId, {
|
||||||
playerName: playerName,
|
playerName: playerName,
|
||||||
nickName: nickName,
|
nickName: nickName,
|
||||||
discordID: discordId,
|
discordID: discordId,
|
||||||
@ -87,7 +87,7 @@ function updateMember(memberId, nickName, playerName, gameUid, discordId) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function deleteMember(memberId) {
|
function deleteMember(memberId) {
|
||||||
axios.delete("http://127.0.0.1:10001/api/member/" + memberId)
|
axios.delete("https://pcredive.ray650128.com/backend/api/member/" + memberId)
|
||||||
.then(function (response) {
|
.then(function (response) {
|
||||||
window.location.href = "./index.html";
|
window.location.href = "./index.html";
|
||||||
})
|
})
|
||||||
|
|||||||
@ -20,7 +20,7 @@ let heading_3 = document.createElement("th");
|
|||||||
heading_3.innerHTML = "角色UID";
|
heading_3.innerHTML = "角色UID";
|
||||||
let heading_4 = document.createElement("th");
|
let heading_4 = document.createElement("th");
|
||||||
heading_4.innerHTML = "DC ID";
|
heading_4.innerHTML = "DC ID";
|
||||||
let heading_5= document.createElement("th");
|
let heading_5 = document.createElement("th");
|
||||||
heading_5.innerHTML = "已離開";
|
heading_5.innerHTML = "已離開";
|
||||||
|
|
||||||
row_1.appendChild(heading_1);
|
row_1.appendChild(heading_1);
|
||||||
@ -30,7 +30,7 @@ row_1.appendChild(heading_4);
|
|||||||
row_1.appendChild(heading_5);
|
row_1.appendChild(heading_5);
|
||||||
thead.appendChild(row_1);
|
thead.appendChild(row_1);
|
||||||
// 取得刀表
|
// 取得刀表
|
||||||
axios.get("http://127.0.0.1:10001/api/member", {
|
axios.get("https://pcredive.ray650128.com/backend/api/member", {
|
||||||
headers: {
|
headers: {
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'Accept': 'application/json'
|
'Accept': 'application/json'
|
||||||
|
|||||||
@ -14,7 +14,7 @@ document
|
|||||||
|
|
||||||
function newMember(nickName, playerName, gameUid, discordId) {
|
function newMember(nickName, playerName, gameUid, discordId) {
|
||||||
// 发送登录请求
|
// 发送登录请求
|
||||||
axios.post("http://127.0.0.1:10001/api/member", {
|
axios.post("https://pcredive.ray650128.com/backend/api/member", {
|
||||||
playerName: playerName,
|
playerName: playerName,
|
||||||
nickName: nickName,
|
nickName: nickName,
|
||||||
discordID: discordId,
|
discordID: discordId,
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user