Command
Get-PermissionLevelMapping
Description
The command to get the permission level mappings from a source and destination site pair.
Index
Examples
Get mappings from a source site and a destination site
$srcSite = Connect-Site -Url "http://myfarm1/sites/mysourcesite" $dstSite = Connect-Site -Url "http://myfarm1/sites/mydestinationsite" $mappingSettings = Get-PermissionLevelMapping -SourceSite $srcSite -DestinationSite $dstSite $mappingSettings PropertyMappings : ContentTypeMappings : UserAndGroupMappings : PermissionLevelMappings : Approve -> Approve Contribute -> Contribute Design -> Design Full Control -> Full Control My Custom Permission -> <NO DESTINATION> Read -> Read View Only -> View Only SiteTemplateMappings :
Get mappings from the file system and a destination site
$dstSite = Connect-Site -Url "http://myfarm1/sites/mydestinationsite" $mappingSettings = Get-PermissionLevelMapping -FromFileSystem -DestinationSite $dstSite $mappingSettings PropertyMappings : ContentTypeMappings : UserAndGroupMappings : PermissionLevelMappings : Full Control -> Full Control Modify -> Contribute Read & execute -> Read Read -> Read Write -> Contribute SiteTemplateMappings :
Merge mappings with mappings from a source site and a destination site
$mappingSettings = Set-PermissionLevelMapping -Source "My Custom Permission" -Destination "Full Control" $srcSite = Connect-Site -Url "http://myfarm1/sites/mysourcesite" $dstSite = Connect-Site -Url "http://myfarm1/sites/mydestinationsite" $mappingSettings = Get-PermissionLevelMapping -MappingSettings $mappingSettings -SourceSite $srcSite -DestinationSite $dstSite $mappingSettings PropertyMappings : ContentTypeMappings : UserAndGroupMappings : PermissionLevelMappings : Approve -> Approve Contribute -> Contribute Design -> Design Full Control -> Full Control My Custom Permission -> Full Control Read -> <NO DESTINATION> View Only -> View Only SiteTemplateMappings :
Syntax
Get-PermissionLevelMapping-SourceSite <Site> -DestinationSite <Site> [-MappingSettings <MappingSettings>]
Get-PermissionLevelMapping-FromFileSystem <SwitchParameter> -DestinationSite <Site> [-MappingSettings <MappingSettings>]
Parameters
-DestinationSite <Site>
Specifies the destination site.
Required? | True |
Default value | None |
Accept pipeline input? | False |
Accept wildcard characters? | False |
Parameter set name | (All) |
Aliases | None |
-FromFileSystem <SwitchParameter>
Specifies that the source is the file system.
Required? | True |
Default value | None |
Accept pipeline input? | False |
Accept wildcard characters? | False |
Parameter set name | FileSystem |
Aliases | None |
-MappingSettings <MappingSettings>
Specifies the mapping settings.
Required? | False |
Default value | None |
Accept pipeline input? | True (ByValue, ByPropertyName) |
Accept wildcard characters? | False |
Parameter set name | (All) |
Aliases | None |
-SourceSite <Site>
Specifies the source site.
Required? | True |
Default value | None |
Accept pipeline input? | False |
Accept wildcard characters? | False |
Parameter set name | Default |
Aliases | None |