mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-15 20:54:55 +00:00
Merge pull request #1130 from PepperDash/feature/systemmonitor-programinfo-update
Update systemMonitor class to append Essentials version number
This commit is contained in:
@@ -564,10 +564,10 @@ namespace PepperDash.Essentials.Core.Monitoring
|
|||||||
new BoolFeedback(() => Program.RegistrationState == eProgramRegistrationState.Unregister);
|
new BoolFeedback(() => Program.RegistrationState == eProgramRegistrationState.Unregister);
|
||||||
ProgramUnregisteredFeedback.FireUpdate();
|
ProgramUnregisteredFeedback.FireUpdate();
|
||||||
|
|
||||||
ProgramNameFeedback = new StringFeedback(() => ProgramInfo.ProgramFile);
|
ProgramNameFeedback = new StringFeedback(() => ProgramInfo.ProgramFile);
|
||||||
|
CrestronDataBaseVersionFeedback = new StringFeedback(() => ProgramInfo.CrestronDb);
|
||||||
|
EnvironmentVersionFeedback = new StringFeedback(() => ProgramInfo.Environment);
|
||||||
ProgramCompileTimeFeedback = new StringFeedback(() => ProgramInfo.CompileTime);
|
ProgramCompileTimeFeedback = new StringFeedback(() => ProgramInfo.CompileTime);
|
||||||
CrestronDataBaseVersionFeedback = new StringFeedback(() => ProgramInfo.CrestronDb);
|
|
||||||
EnvironmentVersionFeedback = new StringFeedback(() => ProgramInfo.Environment);
|
|
||||||
AggregatedProgramInfoFeedback = new StringFeedback(() => JsonConvert.SerializeObject(ProgramInfo));
|
AggregatedProgramInfoFeedback = new StringFeedback(() => JsonConvert.SerializeObject(ProgramInfo));
|
||||||
|
|
||||||
GetProgramInfo();
|
GetProgramInfo();
|
||||||
@@ -620,7 +620,7 @@ namespace PepperDash.Essentials.Core.Monitoring
|
|||||||
// Assume no valid program info. Constructing a new object will wipe all properties
|
// Assume no valid program info. Constructing a new object will wipe all properties
|
||||||
ProgramInfo = new ProgramInfo(Program.Number)
|
ProgramInfo = new ProgramInfo(Program.Number)
|
||||||
{
|
{
|
||||||
OperatingState = Program.OperatingState,
|
OperatingState = Program.OperatingState,
|
||||||
RegistrationState = Program.RegistrationState
|
RegistrationState = Program.RegistrationState
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -646,6 +646,13 @@ namespace PepperDash.Essentials.Core.Monitoring
|
|||||||
ProgramInfo.MinFirmwareVersion = ParseConsoleData(response, "Min Firmware Version", ": ",
|
ProgramInfo.MinFirmwareVersion = ParseConsoleData(response, "Min Firmware Version", ": ",
|
||||||
"\n");
|
"\n");
|
||||||
ProgramInfo.PlugInVersion = ParseConsoleData(response, "PlugInVersion", ": ", "\n");
|
ProgramInfo.PlugInVersion = ParseConsoleData(response, "PlugInVersion", ": ", "\n");
|
||||||
|
|
||||||
|
ProgramInfo.ProgramFile += string.Format(" {0}.{1}.{2}",
|
||||||
|
ProgramInfo.CompilerRevisionInfo.Major,
|
||||||
|
ProgramInfo.CompilerRevisionInfo.Minor,
|
||||||
|
ProgramInfo.CompilerRevisionInfo.Build);
|
||||||
|
|
||||||
|
ProgramInfo.Environment = ProgramInfo.ProgramTool;
|
||||||
}
|
}
|
||||||
else if (ProgramInfo.ProgramFile.Contains(".smw"))
|
else if (ProgramInfo.ProgramFile.Contains(".smw"))
|
||||||
{
|
{
|
||||||
@@ -736,6 +743,15 @@ namespace PepperDash.Essentials.Core.Monitoring
|
|||||||
[JsonProperty("compilerRevision")]
|
[JsonProperty("compilerRevision")]
|
||||||
public string CompilerRevision { get; set; }
|
public string CompilerRevision { get; set; }
|
||||||
|
|
||||||
|
[JsonIgnore]
|
||||||
|
public Version CompilerRevisionInfo
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
return new Version(CompilerRevision);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
[JsonProperty("compileTime")]
|
[JsonProperty("compileTime")]
|
||||||
public string CompileTime { get; set; }
|
public string CompileTime { get; set; }
|
||||||
|
|
||||||
@@ -776,7 +792,7 @@ namespace PepperDash.Essentials.Core.Monitoring
|
|||||||
ProgramFile = "";
|
ProgramFile = "";
|
||||||
FriendlyName = "";
|
FriendlyName = "";
|
||||||
CompilerRevision = "";
|
CompilerRevision = "";
|
||||||
CompileTime = "";
|
CompileTime = "";
|
||||||
Include4Dat = "";
|
Include4Dat = "";
|
||||||
|
|
||||||
SystemName = "";
|
SystemName = "";
|
||||||
|
|||||||
Reference in New Issue
Block a user