Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6efabb8

Browse files
committed
fe: fix CodisLabs#1167, can't get server addresses if sentinel is disabled
1 parent c87ff6d commit 6efabb8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

cmd/fe/assets/dashboard-fe.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -548,6 +548,7 @@ function processGroupStats(codis_stats) {
548548
x.canslaveof = "create";
549549
x.actionstate = "";
550550
}
551+
x.server_text = x.server;
551552
}
552553
}
553554
return {group_array: group_array, keys: keys, memory: memory};
@@ -685,7 +686,6 @@ dashboard.controller('MainCodisCtrl', ['$scope', '$http', '$uibModal', '$timeout
685686
var ha_master_ingroup = false;
686687
for (var j = 0; j < g.servers.length; j ++) {
687688
var x = g.servers[j];
688-
x.server_text = x.server;
689689
if (ha_master == undefined) {
690690
x.ha_status = "ha_undefined";
691691
continue;

cmd/fe/assets/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,7 @@ <h4 style="padding-left:30px; padding-right:20px; display: inline;">Group</h4>
528528
data-toggle="tooltip" data-placement="right" title="HA: SLAVE">
529529
[[server.server_text]]
530530
</span>
531-
<span ng-switch-when="ha_defined" style="color: white; background-color: darkgray"
531+
<span ng-switch-when="ha_undefined" style="color: white; background-color: darkgray"
532532
data-toggle="tooltip" data-placement="right" title="HA: UNDEFINED">
533533
[[server.server_text]]
534534
</span>

0 commit comments

Comments
 (0)