Created
May 29, 2021 14:42
-
-
Save ankitjoshi/2e5412571b0bc0c848e35f0aeea3f52c to your computer and use it in GitHub Desktop.
Search Dictionary domain item script (SXA Add Dictionary Script #3)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Test-ItemIsDictionaryDomain { | |
[CmdletBinding()] | |
param( | |
[Parameter(Mandatory=$true, ValueFromPipeline = $true, Position=0 )] | |
[Item]$Item | |
) | |
begin { | |
Write-Verbose "Cmdlet Test-ItemIsDictionaryDomain - Begin" | |
} | |
process { | |
Write-Verbose "Cmdlet Test-ItemIsDictionaryDomain - Process" | |
# dictionary domain template Id... | |
[Sitecore.Data.ID]$DataSourceConfigurationsTemplateID = "{0A2847E6-9885-450B-B61E-F9E6528480EF}" | |
[Sitecore.Data.Managers.TemplateManager]::GetTemplate($Item).InheritsFrom($DataSourceConfigurationsTemplateID) | |
} | |
end { | |
Write-Verbose "Cmdlet Test-ItemIsDictionaryDomain - End" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment