Skip to content

Commit afb24cb

Browse files
authored
Merge pull request #31 from KiraCore/fix/missed_field
fix: Added missed "Node status" field to node info screen
2 parents 1aff4ee + 6970873 commit afb24cb

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

Diff for: gui/screen_nodeInfo.go

+10
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,9 @@ func makeNodeInfoTab(g *Gui) fyne.CanvasObject {
137137
// widget.NewLabel("Gen. SHA256::\t\t"), genesisChecksumLabel,
138138
// )
139139

140+
nodeCatchingData := binding.NewString()
141+
nodeCatchingLabel := widget.NewLabelWithData(nodeCatchingData)
142+
140143
// Numerical validators status
141144
activeValidatorsData := binding.NewInt()
142145
activeValidatorsLabel := widget.NewLabelWithData(binding.IntToString(activeValidatorsData))
@@ -205,6 +208,7 @@ func makeNodeInfoTab(g *Gui) fyne.CanvasObject {
205208
widget.NewFormItem("ChainID:", chainIDLabel),
206209
widget.NewFormItem("Moniker:", monikerLabel),
207210
widget.NewFormItem("Val.Status:", validatorStatusLabel),
211+
widget.NewFormItem("Node Status:", nodeCatchingLabel),
208212
widget.NewFormItem("Block:", latestBlockLabel),
209213
widget.NewFormItem("Latest Block:", lastProducedLabel),
210214
widget.NewFormItem("Produced:", producedBlocksLabel),
@@ -316,6 +320,12 @@ func makeNodeInfoTab(g *Gui) fyne.CanvasObject {
316320
chainIDData.Set(dashboardData.ChainID)
317321
// dateData.Set(dashboardData.Date)
318322
streakData.Set(dashboardData.Streak)
323+
324+
if dashboardData.CatchingUp {
325+
nodeCatchingData.Set("Syncing")
326+
} else {
327+
nodeCatchingData.Set("Running")
328+
}
319329
// dashboardData.CatchingUp,
320330
// widget.NewLabel()
321331

0 commit comments

Comments
 (0)