From d883de7f9a13f14ca68727e6548b9e89535f7614 Mon Sep 17 00:00:00 2001
From: quangz <quangz@bluewisdom.com.cn>
Date: 星期六, 02 四月 2022 08:06:30 +0800
Subject: [PATCH] 修复ConcurrentModificationException
---
web_src/src/components/dialog/platformEdit.vue | 15 ++++++++++++---
1 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/web_src/src/components/dialog/platformEdit.vue b/web_src/src/components/dialog/platformEdit.vue
index fad0444..38a2aef 100644
--- a/web_src/src/components/dialog/platformEdit.vue
+++ b/web_src/src/components/dialog/platformEdit.vue
@@ -116,6 +116,7 @@
showDialog: false,
isLoging: false,
onSubmit_text: "绔嬪嵆鍒涘缓",
+ saveUrl: "/api/platform/save",
platform: {
id: null,
@@ -163,6 +164,7 @@
var that = this;
if (platform == null) {
this.onSubmit_text = "绔嬪嵆鍒涘缓";
+ this.saveUrl = "/api/platform/add";
this.$axios({
method: 'get',
url:`/api/platform/server_config`
@@ -196,7 +198,9 @@
this.platform.transport = platform.transport;
this.platform.characterSet = platform.characterSet;
this.platform.shareAllLiveStream = platform.shareAllLiveStream;
+ this.platform.catalogId = platform.catalogId;
this.onSubmit_text = "淇濆瓨";
+ this.saveUrl = "/api/platform/save";
}
this.showDialog = true;
this.listChangeCallback = callback;
@@ -211,14 +215,13 @@
this.platform.username = this.platform.deviceGBId ;
},
onSubmit: function () {
- console.log("onSubmit");
var that = this;
that.$axios({
method: 'post',
- url:`/api/platform/save`,
+ url: this.saveUrl,
data: that.platform
}).then(function (res) {
- if (res.data == "success") {
+ if (res.data.code === 0) {
that.$message({
showClose: true,
message: "淇濆瓨鎴愬姛",
@@ -228,6 +231,12 @@
if (that.listChangeCallback != null) {
that.listChangeCallback();
}
+ }else {
+ that.$message({
+ showClose: true,
+ message: res.data.msg,
+ type: "error",
+ });
}
}).catch(function (error) {
console.log(error);
--
Gitblit v1.8.0