From 468a0b224d06e4e614e608f0edccfd5855a9a002 Mon Sep 17 00:00:00 2001
From: Senyoret1 <34079003+Senyoret1@users.noreply.github.com>
Date: Mon, 25 Oct 2021 19:23:41 -0400
Subject: [PATCH] Add the build tag to the UI
---
static/skywire-manager-src/src/app/app.datatypes.ts | 1 +
.../node-info-content/node-info-content.component.html | 6 +++++-
static/skywire-manager-src/src/app/services/node.service.ts | 1 +
static/skywire-manager-src/src/assets/i18n/en.json | 3 ++-
static/skywire-manager-src/src/assets/i18n/es.json | 3 ++-
static/skywire-manager-src/src/assets/i18n/es_base.json | 3 ++-
6 files changed, 13 insertions(+), 4 deletions(-)
diff --git a/static/skywire-manager-src/src/app/app.datatypes.ts b/static/skywire-manager-src/src/app/app.datatypes.ts
index f41a9d21e..86f0a682a 100644
--- a/static/skywire-manager-src/src/app/app.datatypes.ts
+++ b/static/skywire-manager-src/src/app/app.datatypes.ts
@@ -17,6 +17,7 @@ export class Node {
dmsgServerPk?: string;
roundTripPing?: string;
isHypervisor?: boolean;
+ buildTag: string;
skybianBuildVersion?: string;
autoconnectTransports: boolean;
}
diff --git a/static/skywire-manager-src/src/app/components/pages/node/node-info/node-info-content/node-info-content.component.html b/static/skywire-manager-src/src/app/components/pages/node/node-info/node-info-content/node-info-content.component.html
index f6d37eddd..748833837 100644
--- a/static/skywire-manager-src/src/app/components/pages/node/node-info/node-info-content/node-info-content.component.html
+++ b/static/skywire-manager-src/src/app/components/pages/node/node-info/node-info-content/node-info-content.component.html
@@ -38,8 +38,12 @@
{{ node.version ? node.version : ('common.unknown' | translate) }}
+ {{ 'node.details.node-info.build-type' | translate }}
+ {{ node.buildTag ? node.buildTag : ('node.details.node-info.unknown-build' | translate) }}
+
+
{{ 'node.details.node-info.skybian-version' | translate }}
- {{ node.skybianBuildVersion ? node.skybianBuildVersion : ('node.details.node-info.no-skybian-version' | translate) }}
+ {{ node.skybianBuildVersion }}
{{ 'node.details.node-info.time.title' | translate }}
diff --git a/static/skywire-manager-src/src/app/services/node.service.ts b/static/skywire-manager-src/src/app/services/node.service.ts
index afe13c60d..46225e0c0 100644
--- a/static/skywire-manager-src/src/app/services/node.service.ts
+++ b/static/skywire-manager-src/src/app/services/node.service.ts
@@ -586,6 +586,7 @@ export class NodeService {
node.version = response.overview.build_info.version;
node.secondsOnline = Math.floor(Number.parseFloat(response.uptime));
node.minHops = response.min_hops;
+ node.buildTag = response.build_tag;
node.skybianBuildVersion = response.skybian_build_version;
node.isSymmeticNat = response.overview.is_symmetic_nat;
node.publicIp = response.overview.public_ip;
diff --git a/static/skywire-manager-src/src/assets/i18n/en.json b/static/skywire-manager-src/src/assets/i18n/en.json
index 783f7119f..0716773ec 100644
--- a/static/skywire-manager-src/src/assets/i18n/en.json
+++ b/static/skywire-manager-src/src/assets/i18n/en.json
@@ -108,8 +108,9 @@
"dmsg-server": "DMSG server:",
"ping": "Ping:",
"node-version": "Visor version:",
+ "build-type": "Build type:",
"skybian-version": "Skybian version:",
- "no-skybian-version": "(not using Skybian)",
+ "unknown-build": "Unknown",
"time": {
"title": "Time online:",
"seconds": "a few seconds",
diff --git a/static/skywire-manager-src/src/assets/i18n/es.json b/static/skywire-manager-src/src/assets/i18n/es.json
index a1d4af9f5..ed0dce50c 100644
--- a/static/skywire-manager-src/src/assets/i18n/es.json
+++ b/static/skywire-manager-src/src/assets/i18n/es.json
@@ -108,8 +108,9 @@
"dmsg-server": "Servidor DMSG:",
"ping": "Ping:",
"node-version": "Versión del visor:",
+ "build-type": "Tipo de build:",
"skybian-version": "Versión de Skybian:",
- "no-skybian-version": "(no se usa Skybian)",
+ "unknown-build": "Desconocido",
"time": {
"title": "Tiempo online:",
"seconds": "unos segundos",
diff --git a/static/skywire-manager-src/src/assets/i18n/es_base.json b/static/skywire-manager-src/src/assets/i18n/es_base.json
index 390d2a68d..b17d749d6 100644
--- a/static/skywire-manager-src/src/assets/i18n/es_base.json
+++ b/static/skywire-manager-src/src/assets/i18n/es_base.json
@@ -108,8 +108,9 @@
"dmsg-server": "DMSG server:",
"ping": "Ping:",
"node-version": "Visor version:",
+ "build-type": "Build type:",
"skybian-version": "Skybian version:",
- "no-skybian-version": "(not using Skybian)",
+ "unknown-build": "Unknown",
"time": {
"title": "Time online:",
"seconds": "a few seconds",