CiscoDevNet / intersight-powershell

Cisco Intersight PowerShell
Apache License 2.0
16 stars 4 forks source link

Get-IntersightTamAdvisoryInstance does not return AffectedObject.Name #123

Closed dsoper2 closed 1 month ago

dsoper2 commented 1 year ago

Get-IntersightTamAdvisoryInstance does not return AffectedObject.Name when expanding AffectedObject.

(Get-IntersightTamAdvisoryInstance -Expand AffectedObject).Results

AffectedObject : class MoBaseMoRelationship { ActualInstance: class MoBaseMo { ClassId: ComputeRackUnit ObjectType: ComputeRackUnit AccountMoid: 636d24f77564612d3375a70e CreateTime: 9/20/2023 2:27:21 PM DomainGroupMoid: 636d24f77564612d3375a70f ModTime: 9/20/2023 2:27:30 PM Moid: 650b014961767535015d7fca Owners: System.Collections.Generic.List1[System.String] SharedScope: Tags: System.Collections.Generic.List1[Intersight.Model.MoTag] VersionContext: Ancestors: System.Collections.Generic.List1[Intersight.Model.MoBaseMoRelationship] Parent: PermissionResources: System.Collections.Generic.List1[Intersight.Model.MoBaseMoRelationship] DisplayNames: AdditionalProperties: System.Collections.Generic.Dictionary`2[System.String,System.Object] }

                   }

image

Version used 1.0.11.13515

Ghufz commented 1 month ago

The Name property is available in additional properties.

$result = (Get-IntersightTamAdvisoryInstance -Expand AffectedObject).Results
$result[0].AffectedObject.ActualInstance.AdditionalProperties.Name