From 565ce81e3443a6820c3f06c506a8c6d59950d894 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=BD=A6=E6=B0=91?= Date: Thu, 13 Dec 2018 18:19:20 +0800 Subject: [PATCH] fix: update instance --- .../static/console-fe/build/webpack.dev.conf.js | 2 +- .../ServiceManagement/ServiceDetail/InstanceTable.js | 10 +++++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/console/src/main/resources/static/console-fe/build/webpack.dev.conf.js b/console/src/main/resources/static/console-fe/build/webpack.dev.conf.js index 9f78be315..83254fa75 100644 --- a/console/src/main/resources/static/console-fe/build/webpack.dev.conf.js +++ b/console/src/main/resources/static/console-fe/build/webpack.dev.conf.js @@ -26,7 +26,7 @@ module.exports = Object.assign({}, base, { context: ['/'], changeOrigin: true, secure: false, - target: 'http://11.160.165.126:8848', + target: 'http://11.163.128.34:8848', pathRewrite: {'^/v1' : '/nacos/v1'} }], disableHostCheck: true, diff --git a/console/src/main/resources/static/console-fe/src/pages/ServiceManagement/ServiceDetail/InstanceTable.js b/console/src/main/resources/static/console-fe/src/pages/ServiceManagement/ServiceDetail/InstanceTable.js index dccf0102a..c6062e527 100644 --- a/console/src/main/resources/static/console-fe/src/pages/ServiceManagement/ServiceDetail/InstanceTable.js +++ b/console/src/main/resources/static/console-fe/src/pages/ServiceManagement/ServiceDetail/InstanceTable.js @@ -81,7 +81,15 @@ class InstanceTable extends React.Component { request({ method: 'POST', url: 'v1/ns/instance/update', - data: { serviceName, clusterName, ip, port, weight, enable: !enabled, metadata }, + data: { + serviceName, + clusterName, + ip, + port, + weight, + enable: !enabled, + metadata: JSON.stringify(metadata), + }, dataType: 'text', beforeSend: () => this.openLoading(), success: () => this.setState({ instance: newVal }),