mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2024-11-23 20:36:33 +01:00
Merge pull request #661 from MihaelaStoica/CA-181208
CA-181208: : Display the status of last failed upload in the Health Check overview dialog
This commit is contained in:
commit
82ab747bd6
@ -39,6 +39,8 @@ namespace XenAdmin.Dialogs.HealthCheck
|
||||
this.poolNameLabel = new System.Windows.Forms.Label();
|
||||
this.poolDetailsPanel = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.healthCheckStatusPanel = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.failedUploadDateLabel = new System.Windows.Forms.Label();
|
||||
this.failedUploadLabel = new System.Windows.Forms.Label();
|
||||
this.lastUploadDateLabel = new System.Windows.Forms.Label();
|
||||
this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel();
|
||||
this.issuesLabel = new System.Windows.Forms.Label();
|
||||
@ -149,19 +151,31 @@ namespace XenAdmin.Dialogs.HealthCheck
|
||||
// healthCheckStatusPanel
|
||||
//
|
||||
resources.ApplyResources(this.healthCheckStatusPanel, "healthCheckStatusPanel");
|
||||
this.healthCheckStatusPanel.Controls.Add(this.failedUploadDateLabel, 1, 5);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.failedUploadLabel, 0, 5);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.lastUploadDateLabel, 1, 1);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.flowLayoutPanel1, 0, 3);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.disableLinkLabel, 0, 9);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.uploadRequestLinkLabel, 0, 10);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.scheduleLabel, 0, 7);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.editLinkLabel, 0, 8);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.label4, 0, 6);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.disableLinkLabel, 0, 10);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.uploadRequestLinkLabel, 0, 11);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.scheduleLabel, 0, 8);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.editLinkLabel, 0, 9);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.label4, 0, 7);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.label1, 0, 0);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.lastUploadLabel, 0, 1);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.ReportAnalysisLinkLabel, 0, 4);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.previousUploadPanel, 0, 5);
|
||||
this.healthCheckStatusPanel.Controls.Add(this.previousUploadPanel, 0, 6);
|
||||
this.healthCheckStatusPanel.Name = "healthCheckStatusPanel";
|
||||
//
|
||||
// failedUploadDateLabel
|
||||
//
|
||||
resources.ApplyResources(this.failedUploadDateLabel, "failedUploadDateLabel");
|
||||
this.failedUploadDateLabel.Name = "failedUploadDateLabel";
|
||||
//
|
||||
// failedUploadLabel
|
||||
//
|
||||
resources.ApplyResources(this.failedUploadLabel, "failedUploadLabel");
|
||||
this.failedUploadLabel.Name = "failedUploadLabel";
|
||||
//
|
||||
// lastUploadDateLabel
|
||||
//
|
||||
resources.ApplyResources(this.lastUploadDateLabel, "lastUploadDateLabel");
|
||||
@ -410,6 +424,8 @@ namespace XenAdmin.Dialogs.HealthCheck
|
||||
private System.Windows.Forms.LinkLabel refreshLinkLabel;
|
||||
private System.Windows.Forms.FlowLayoutPanel flowLayoutPanel1;
|
||||
private System.Windows.Forms.Label lastUploadDateLabel;
|
||||
private System.Windows.Forms.Label failedUploadDateLabel;
|
||||
private System.Windows.Forms.Label failedUploadLabel;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -203,11 +203,21 @@ namespace XenAdmin.Dialogs.HealthCheck
|
||||
}
|
||||
|
||||
var poolRow = (PoolRow)poolsDataGridView.SelectedRows[0];
|
||||
var healthcheckSettings = poolRow.Pool.HealthCheckSettings;
|
||||
poolNameLabel.Text = poolRow.Pool.Name.Ellipsise(120);
|
||||
scheduleLabel.Text = GetScheduleDescription(poolRow.Pool.HealthCheckSettings);
|
||||
lastUploadLabel.Visible = lastUploadDateLabel.Visible = !string.IsNullOrEmpty(poolRow.Pool.HealthCheckSettings.LastSuccessfulUpload);
|
||||
lastUploadDateLabel.Text = GetLastUploadDescription(poolRow.Pool.HealthCheckSettings);
|
||||
|
||||
scheduleLabel.Text = GetScheduleDescription(healthcheckSettings);
|
||||
lastUploadLabel.Visible = lastUploadDateLabel.Visible = !string.IsNullOrEmpty(healthcheckSettings.LastSuccessfulUpload);
|
||||
lastUploadDateLabel.Text = GetLastUploadDescription(healthcheckSettings);
|
||||
|
||||
// show the "Last failed upload" if we have a failed upload AND
|
||||
// there is no successful upload or the failed upload happened after a successful upload
|
||||
var lastFailedUploadTime = healthcheckSettings.LastFailedUploadTime;
|
||||
bool showFailedUpload = lastFailedUploadTime > DateTime.MinValue
|
||||
&& (string.IsNullOrEmpty(healthcheckSettings.LastSuccessfulUpload) || lastFailedUploadTime > healthcheckSettings.LastSuccessfulUploadTime);
|
||||
failedUploadLabel.Visible = failedUploadDateLabel.Visible = showFailedUpload;
|
||||
if (showFailedUpload)
|
||||
failedUploadDateLabel.Text = HelpersGUI.DateTimeToString(lastFailedUploadTime.ToLocalTime(), Messages.DATEFORMAT_DMY_HM, true);
|
||||
|
||||
UpdateButtonsVisibility(poolRow.Pool);
|
||||
|
||||
healthCheckStatusPanel.Visible = poolRow.Pool.HealthCheckSettings.Status == HealthCheckStatus.Enabled;
|
||||
|
@ -249,6 +249,78 @@
|
||||
<data name="healthCheckStatusPanel.ColumnCount" type="System.Int32, mscorlib">
|
||||
<value>2</value>
|
||||
</data>
|
||||
<data name="failedUploadDateLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="failedUploadDateLabel.Font" type="System.Drawing.Font, System.Drawing">
|
||||
<value>Segoe UI, 9pt</value>
|
||||
</data>
|
||||
<data name="failedUploadDateLabel.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="failedUploadDateLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>134, 94</value>
|
||||
</data>
|
||||
<data name="failedUploadDateLabel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>3, 10, 3, 3</value>
|
||||
</data>
|
||||
<data name="failedUploadDateLabel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>0, 15</value>
|
||||
</data>
|
||||
<data name="failedUploadDateLabel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>25</value>
|
||||
</data>
|
||||
<data name=">>failedUploadDateLabel.Name" xml:space="preserve">
|
||||
<value>failedUploadDateLabel</value>
|
||||
</data>
|
||||
<data name=">>failedUploadDateLabel.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>failedUploadDateLabel.Parent" xml:space="preserve">
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>failedUploadDateLabel.ZOrder" xml:space="preserve">
|
||||
<value>0</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.Font" type="System.Drawing.Font, System.Drawing">
|
||||
<value>Segoe UI, 9pt</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>3, 94</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>3, 10, 0, 3</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>103, 15</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>24</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.Text" xml:space="preserve">
|
||||
<value>Last failed upload:</value>
|
||||
</data>
|
||||
<data name="failedUploadLabel.Visible" type="System.Boolean, mscorlib">
|
||||
<value>False</value>
|
||||
</data>
|
||||
<data name=">>failedUploadLabel.Name" xml:space="preserve">
|
||||
<value>failedUploadLabel</value>
|
||||
</data>
|
||||
<data name=">>failedUploadLabel.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>failedUploadLabel.Parent" xml:space="preserve">
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>failedUploadLabel.ZOrder" xml:space="preserve">
|
||||
<value>1</value>
|
||||
</data>
|
||||
<data name="lastUploadDateLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
@ -280,7 +352,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>lastUploadDateLabel.ZOrder" xml:space="preserve">
|
||||
<value>0</value>
|
||||
<value>2</value>
|
||||
</data>
|
||||
<data name="flowLayoutPanel1.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -394,7 +466,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>flowLayoutPanel1.ZOrder" xml:space="preserve">
|
||||
<value>1</value>
|
||||
<value>3</value>
|
||||
</data>
|
||||
<data name="disableLinkLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -406,7 +478,7 @@
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="disableLinkLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>3, 212</value>
|
||||
<value>3, 240</value>
|
||||
</data>
|
||||
<data name="disableLinkLabel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>3, 3, 3, 3</value>
|
||||
@ -430,7 +502,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>disableLinkLabel.ZOrder" xml:space="preserve">
|
||||
<value>2</value>
|
||||
<value>4</value>
|
||||
</data>
|
||||
<data name="uploadRequestLinkLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -442,19 +514,19 @@
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="uploadRequestLinkLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>3, 240</value>
|
||||
<value>3, 268</value>
|
||||
</data>
|
||||
<data name="uploadRequestLinkLabel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>3, 10, 3, 3</value>
|
||||
</data>
|
||||
<data name="uploadRequestLinkLabel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>131, 15</value>
|
||||
<value>187, 15</value>
|
||||
</data>
|
||||
<data name="uploadRequestLinkLabel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>19</value>
|
||||
</data>
|
||||
<data name="uploadRequestLinkLabel.Text" xml:space="preserve">
|
||||
<value>Request an upload now</value>
|
||||
<value>Request an additional upload now</value>
|
||||
</data>
|
||||
<data name=">>uploadRequestLinkLabel.Name" xml:space="preserve">
|
||||
<value>uploadRequestLinkLabel</value>
|
||||
@ -466,7 +538,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>uploadRequestLinkLabel.ZOrder" xml:space="preserve">
|
||||
<value>3</value>
|
||||
<value>5</value>
|
||||
</data>
|
||||
<data name="scheduleLabel.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
|
||||
<value>Top, Left, Right</value>
|
||||
@ -481,7 +553,7 @@
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="scheduleLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>3, 170</value>
|
||||
<value>3, 198</value>
|
||||
</data>
|
||||
<data name="scheduleLabel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>3, 3, 3, 3</value>
|
||||
@ -505,7 +577,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>scheduleLabel.ZOrder" xml:space="preserve">
|
||||
<value>4</value>
|
||||
<value>6</value>
|
||||
</data>
|
||||
<data name="editLinkLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -517,7 +589,7 @@
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="editLinkLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>3, 191</value>
|
||||
<value>3, 219</value>
|
||||
</data>
|
||||
<data name="editLinkLabel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>3, 3, 3, 3</value>
|
||||
@ -541,7 +613,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>editLinkLabel.ZOrder" xml:space="preserve">
|
||||
<value>5</value>
|
||||
<value>7</value>
|
||||
</data>
|
||||
<data name="label4.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -553,7 +625,7 @@
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="label4.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>3, 149</value>
|
||||
<value>3, 177</value>
|
||||
</data>
|
||||
<data name="label4.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>3, 10, 3, 3</value>
|
||||
@ -577,7 +649,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>label4.ZOrder" xml:space="preserve">
|
||||
<value>6</value>
|
||||
<value>8</value>
|
||||
</data>
|
||||
<data name="label1.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -610,7 +682,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>label1.ZOrder" xml:space="preserve">
|
||||
<value>7</value>
|
||||
<value>9</value>
|
||||
</data>
|
||||
<data name="lastUploadLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -646,7 +718,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>lastUploadLabel.ZOrder" xml:space="preserve">
|
||||
<value>8</value>
|
||||
<value>10</value>
|
||||
</data>
|
||||
<data name="ReportAnalysisLinkLabel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -682,7 +754,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>ReportAnalysisLinkLabel.ZOrder" xml:space="preserve">
|
||||
<value>9</value>
|
||||
<value>11</value>
|
||||
</data>
|
||||
<data name="previousUploadPanel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -805,7 +877,7 @@
|
||||
<value>Segoe UI, 9pt</value>
|
||||
</data>
|
||||
<data name="previousUploadPanel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>0, 94</value>
|
||||
<value>0, 122</value>
|
||||
</data>
|
||||
<data name="previousUploadPanel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>0, 10, 0, 3</value>
|
||||
@ -832,7 +904,7 @@
|
||||
<value>healthCheckStatusPanel</value>
|
||||
</data>
|
||||
<data name=">>previousUploadPanel.ZOrder" xml:space="preserve">
|
||||
<value>10</value>
|
||||
<value>12</value>
|
||||
</data>
|
||||
<data name="previousUploadPanel.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
|
||||
<value><?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="viewReportLinkLabel" Row="1" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="previousUploadDateLabel" Row="0" RowSpan="1" Column="1" ColumnSpan="1" /><Control Name="label3" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /></Controls><Columns Styles="AutoSize,52,Percent,48" /><Rows Styles="AutoSize,0,AutoSize,0,Absolute,20" /></TableLayoutSettings></value>
|
||||
@ -847,10 +919,10 @@
|
||||
<value>3, 3</value>
|
||||
</data>
|
||||
<data name="healthCheckStatusPanel.RowCount" type="System.Int32, mscorlib">
|
||||
<value>11</value>
|
||||
<value>12</value>
|
||||
</data>
|
||||
<data name="healthCheckStatusPanel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>276, 279</value>
|
||||
<value>276, 307</value>
|
||||
</data>
|
||||
<data name="healthCheckStatusPanel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>16</value>
|
||||
@ -868,7 +940,7 @@
|
||||
<value>0</value>
|
||||
</data>
|
||||
<data name="healthCheckStatusPanel.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
|
||||
<value><?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="lastUploadDateLabel" Row="1" RowSpan="1" Column="1" ColumnSpan="1" /><Control Name="flowLayoutPanel1" Row="3" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="disableLinkLabel" Row="9" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="uploadRequestLinkLabel" Row="10" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="scheduleLabel" Row="7" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="editLinkLabel" Row="8" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="label4" Row="6" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="label1" Row="0" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="lastUploadLabel" Row="1" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="ReportAnalysisLinkLabel" Row="4" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="previousUploadPanel" Row="5" RowSpan="1" Column="0" ColumnSpan="2" /></Controls><Columns Styles="AutoSize,0,Percent,100" /><Rows Styles="AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0" /></TableLayoutSettings></value>
|
||||
<value><?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="failedUploadDateLabel" Row="5" RowSpan="1" Column="1" ColumnSpan="1" /><Control Name="failedUploadLabel" Row="5" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="lastUploadDateLabel" Row="1" RowSpan="1" Column="1" ColumnSpan="1" /><Control Name="flowLayoutPanel1" Row="3" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="disableLinkLabel" Row="10" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="uploadRequestLinkLabel" Row="11" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="scheduleLabel" Row="8" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="editLinkLabel" Row="9" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="label4" Row="7" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="label1" Row="0" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="lastUploadLabel" Row="1" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="ReportAnalysisLinkLabel" Row="4" RowSpan="1" Column="0" ColumnSpan="2" /><Control Name="previousUploadPanel" Row="6" RowSpan="1" Column="0" ColumnSpan="2" /></Controls><Columns Styles="AutoSize,0,Percent,100" /><Rows Styles="AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,20,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,Absolute,20" /></TableLayoutSettings></value>
|
||||
</data>
|
||||
<data name="notEnrolledPanel.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
@ -961,7 +1033,7 @@
|
||||
<value>Segoe UI, 9pt</value>
|
||||
</data>
|
||||
<data name="notEnrolledPanel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>3, 288</value>
|
||||
<value>3, 316</value>
|
||||
</data>
|
||||
<data name="notEnrolledPanel.RowCount" type="System.Int32, mscorlib">
|
||||
<value>2</value>
|
||||
|
@ -60,6 +60,7 @@ namespace XenAdmin.Model
|
||||
public string UserNameSecretUuid;
|
||||
public string PasswordSecretUuid;
|
||||
public string LastSuccessfulUpload;
|
||||
public string LastFailedUpload;
|
||||
public string DiagnosticTokenSecretUuid;
|
||||
public string UploadUuid;
|
||||
public DiagnosticAlertSeverity ReportAnalysisSeverity;
|
||||
@ -113,6 +114,7 @@ namespace XenAdmin.Model
|
||||
UserNameSecretUuid = Get(config, UPLOAD_CREDENTIAL_USER_SECRET);
|
||||
PasswordSecretUuid = Get(config, UPLOAD_CREDENTIAL_PASSWORD_SECRET);
|
||||
LastSuccessfulUpload = Get(config, LAST_SUCCESSFUL_UPLOAD);
|
||||
LastFailedUpload = Get(config, LAST_FAILED_UPLOAD);
|
||||
UploadUuid = Get(config, UPLOAD_UUID);
|
||||
ReportAnalysisSeverity = StringToDiagnosticAlertSeverity(Get(config, REPORT_ANALYSIS_SEVERITY));
|
||||
ReportAnalysisIssuesDetected = IntKey(config, REPORT_ANALYSIS_ISSUES_DETECTED, 0);
|
||||
@ -221,6 +223,28 @@ namespace XenAdmin.Model
|
||||
}
|
||||
}
|
||||
|
||||
public DateTime LastFailedUploadTime
|
||||
{
|
||||
get
|
||||
{
|
||||
DateTime lastFailedUploadTime;
|
||||
return !string.IsNullOrEmpty(LastFailedUpload) && TryParseStringToDateTime(LastFailedUpload, out lastFailedUploadTime)
|
||||
? lastFailedUploadTime
|
||||
: DateTime.MinValue;
|
||||
}
|
||||
}
|
||||
|
||||
public DateTime LastSuccessfulUploadTime
|
||||
{
|
||||
get
|
||||
{
|
||||
DateTime lastSuccessfulUploadTime;
|
||||
return !string.IsNullOrEmpty(LastSuccessfulUpload) && TryParseStringToDateTime(LastSuccessfulUpload, out lastSuccessfulUploadTime)
|
||||
? lastSuccessfulUploadTime
|
||||
: DateTime.MinValue;
|
||||
}
|
||||
}
|
||||
|
||||
#region Helper functions
|
||||
private static T Get<T>(Dictionary<string, T> d, string k) where T : class
|
||||
{
|
||||
|
4
XenModel/Messages.Designer.cs
generated
4
XenModel/Messages.Designer.cs
generated
@ -16380,7 +16380,7 @@ namespace XenAdmin {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Request an upload now.
|
||||
/// Looks up a localized string similar to Request an additional upload now.
|
||||
/// </summary>
|
||||
public static string HEALTHCHECK_ON_DEMAND_REQUEST {
|
||||
get {
|
||||
@ -16389,7 +16389,7 @@ namespace XenAdmin {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Upload requested at {0}.
|
||||
/// Looks up a localized string similar to Additional upload requested at {0}.
|
||||
/// </summary>
|
||||
public static string HEALTHCHECK_ON_DEMAND_REQUESTED_AT {
|
||||
get {
|
||||
|
@ -5729,10 +5729,10 @@ Click Configure HA to alter the settings displayed below.</value>
|
||||
<value>Health Check Enrollment - {0}</value>
|
||||
</data>
|
||||
<data name="HEALTHCHECK_ON_DEMAND_REQUEST" xml:space="preserve">
|
||||
<value>Request an upload now</value>
|
||||
<value>Request an additional upload now</value>
|
||||
</data>
|
||||
<data name="HEALTHCHECK_ON_DEMAND_REQUESTED_AT" xml:space="preserve">
|
||||
<value>Upload requested at {0}</value>
|
||||
<value>Additional upload requested at {0}</value>
|
||||
</data>
|
||||
<data name="HEALTHCHECK_SCHEDULE_DESCRIPTION" xml:space="preserve">
|
||||
<value>Upload a Health Check report every {0} weeks on {1} starting at {2}</value>
|
||||
|
Loading…
Reference in New Issue
Block a user