Get-PC/Private/Get-CMDBDELInfo.ps1

24 lines
648 B
PowerShell
Raw Normal View History

2024-06-11 18:27:55 +00:00
function Get-CMDBDELInfo {
param (
$cmdb
)
Write-host "***NOTICE: $comp is a Device Exception computer. Please check CMDB/Asset Mgmt prior to supporting this workstation. ***" -BackgroundColor Black -ForegroundColor Yellow
if($null -eq $cmdb){
return
}
2024-07-30 20:25:32 +00:00
if($cmdb.SHS_IsVendorPC -eq 'True'){
2024-06-11 18:27:55 +00:00
$vendor = "Yes | Non-standard SHS Image/Hardware"
}
else{
$vendor = "No | Standard SHS Hardware"
}
$delInfo = [PSCustomObject]@{
2024-07-30 20:25:32 +00:00
Contact = $cmdb.SHS_ExceptionContact
2024-06-11 18:27:55 +00:00
Vendor = $vendor
2024-07-30 20:25:32 +00:00
Description = $cmdb.AssignedDescription
2024-06-11 18:27:55 +00:00
}
return $delInfo
}