Src/Private/Get-AbrOntapVserverCIFSLGMembers.ps1
function Get-AbrOntapVserverCIFSLGMember { <# .SYNOPSIS Used by As Built Report to retrieve NetApp ONTAP Vserver CIFS Local Group Members information from the Cluster Management Network .DESCRIPTION .NOTES Version: 0.6.7 Author: Jonathan Colon Twitter: @jcolonfzenpr Github: rebelinux .EXAMPLE .LINK #> param ( [Parameter ( Position = 0, Mandatory)] [string] $Vserver ) begin { Write-PScriboMessage "Collecting ONTAP CIFS Local Group Members information." } process { try { $VserverData = Get-NcCifsLocalGroupMember -VserverContext $Vserver -Controller $Array $VserverObj = @() if ($VserverData) { foreach ($Item in $VserverData) { try { $inObj = [ordered] @{ 'Group Name' = $Item.GroupName 'Description' = $Item.Member } $VserverObj += [pscustomobject]$inobj } catch { Write-PScriboMessage -IsWarning $_.Exception.Message } } $TableParams = @{ Name = "CIFS Connected Local Group Members - $($Vserver)" List = $false ColumnWidths = 50, 50 } if ($Report.ShowTableCaptions) { $TableParams['Caption'] = "- $($TableParams.Name)" } $VserverObj | Table @TableParams } } catch { Write-PScriboMessage -IsWarning $_.Exception.Message } } end {} } |