[ui] format peers
This commit is contained in:
@@ -15,7 +15,7 @@ func (ms *MasterServer) uiStatusHandler(w http.ResponseWriter, r *http.Request)
|
|||||||
Version string
|
Version string
|
||||||
Topology interface{}
|
Topology interface{}
|
||||||
Peers interface{}
|
Peers interface{}
|
||||||
Stats interface{}
|
Stats map[string]interface{}
|
||||||
Counters *stats.ServerStats
|
Counters *stats.ServerStats
|
||||||
}{
|
}{
|
||||||
util.VERSION,
|
util.VERSION,
|
||||||
|
|||||||
@@ -32,8 +32,8 @@ var StatusTpl = template.Must(template.New("status").Parse(`<!DOCTYPE html>
|
|||||||
<tr>
|
<tr>
|
||||||
<td class="col-sm-2 field-label"><label>Peers:</label></td>
|
<td class="col-sm-2 field-label"><label>Peers:</label></td>
|
||||||
<td class="col-sm-10"><ul class="list-unstyled">
|
<td class="col-sm-10"><ul class="list-unstyled">
|
||||||
{{ range .Peers }}
|
{{ range $k, $p := .Peers }}
|
||||||
<li><a href="https://{{ . }}">{{ . }}</a></li>
|
<li><a href="{{ $p.ConnectionString }}">{{ $p.Name }}</a></li>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</ul></td>
|
</ul></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|||||||
Reference in New Issue
Block a user