#720 fix rocketmq console fail to update nameserver address (#721)

This commit is contained in:
yuz10
2021-05-31 09:47:58 +08:00
committed by GitHub
parent 2c32ed9b27
commit ed950510c1
2 changed files with 4 additions and 4 deletions

View File

@@ -16,14 +16,14 @@
*/
app.controller('opsController', ['$scope','$location','$http','Notification','remoteApi','tools', function ($scope,$location,$http,Notification,remoteApi,tools) {
$scope.namesvrAddrList = [];
$scope.namesvrAddrList = "";
$scope.useVIPChannel = true;
$http({
method: "GET",
url: "ops/homePage.query"
}).success(function (resp) {
if (resp.status == 0) {
$scope.namesvrAddrList = resp.data.namesvrAddrList;
$scope.namesvrAddrList = resp.data.namesvrAddrList.join(";");
$scope.useVIPChannel = resp.data.useVIPChannel
}else{
Notification.error({message: resp.errMsg, delay: 2000});
@@ -34,7 +34,7 @@ app.controller('opsController', ['$scope','$location','$http','Notification','re
$http({
method: "POST",
url: "ops/updateNameSvrAddr.do",
params:{nameSvrAddrList:$scope.namesvrAddrList.join(";")}
params:{nameSvrAddrList:$scope.namesvrAddrList}
}).success(function (resp) {
if (resp.status == 0) {
Notification.info({message: "SUCCESS", delay: 2000});

View File

@@ -18,7 +18,7 @@
<div class="page-content">
<h2 class="md-title">NameServerAddressList</h2>
<div class="pull-left">
<md-chips ng-model="namesvrAddrList" readonly="ctrl.readonly" md-removable="ctrl.removable" md-enable-chip-edit="true"></md-chips>
<input type="text" class="form-control" ng-model="namesvrAddrList" />
</div>
<div class="pull-left">
<button class="btn btn-raised btn-sm btn-primary" type="button" ng-click="updateNameSvrAddr()">{{'UPDATE' | translate}}