mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2024-11-23 20:36:33 +01:00
CA-84876: Show more infrastructure information for objects
-Fixing recently found issues
This commit is contained in:
parent
da8fbb4aa1
commit
cc85dc0142
@ -209,6 +209,9 @@ namespace XenAPI
|
||||
if (Connection != null)
|
||||
{
|
||||
var srOfVdi = Connection.Resolve(SR);
|
||||
if (srOfVdi == null)
|
||||
return base.NameWithLocation;
|
||||
|
||||
return string.Format(Messages.VDI_ON_SR_TITLE, Name, srOfVdi.Name, srOfVdi.LocationString);
|
||||
}
|
||||
|
||||
|
@ -1099,6 +1099,9 @@ namespace XenAPI
|
||||
else if (this.is_a_snapshot)
|
||||
{
|
||||
var snapshotOf = this.Connection.Resolve(this.snapshot_of);
|
||||
if (snapshot_of == null)
|
||||
return base.NameWithLocation;
|
||||
|
||||
return string.Format(Messages.SNAPSHOT_OF_TITLE, Name, snapshotOf.Name, LocationString);
|
||||
}
|
||||
else if (this.is_a_template)
|
||||
@ -1110,7 +1113,7 @@ namespace XenAPI
|
||||
}
|
||||
}
|
||||
|
||||
return NameWithLocation;
|
||||
return base.NameWithLocation;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -281,12 +281,12 @@ namespace XenAPI
|
||||
{
|
||||
get
|
||||
{
|
||||
if (Connection == null)
|
||||
if (Connection == null || string.IsNullOrEmpty(Connection.Name))
|
||||
return string.Empty;
|
||||
|
||||
if (Helpers.IsPool(Connection))
|
||||
return string.Format(Messages.IN_POOL, Connection.Name);
|
||||
|
||||
|
||||
return string.Format(Messages.ON_SERVER, Connection.Name);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user