powershell icon indicating copy to clipboard operation
powershell copied to clipboard

[BUG] - Add-PnPContentType with Parent from ContentTypHub

Open MatthiasAbt-SVA opened this issue 11 months ago • 0 comments

Reporting an Issue or Missing Feature

Creating a Content Type in a site Collection with Add-PnPContentType can not use parent contentTyp from Content Typ Hub. "Content typ "xyz" not found in site".

Expected behavior

When using a Parent Content Typ from Content Typ Hub in the GUI is possible, i excpected that this should also work with PnP.PowerShell

Actual behavior

Site Content Type is created with parent "item".

Steps to reproduce behavior

Create and publish an content typ from the hub (parent is item), wait a moment until it is published and then try to use this published content type as parent: Add-PnPContentType -Connection $nCon -Name "localType" -Description "Personalmassnahme" -Group "My Group" -ParentContentType (Get-PnPContentType -Identity "FromHub")

What is the version of the Cmdlet module you are running?

(you can retrieve this by executing Get-Module -Name "PnP.PowerShell" -ListAvailable) 2.12.0 Core 2.4.0 Desk

Which operating system/environment are you running PnP PowerShell on?

  • [X] Windows (Editor: Visual Studio Code)
  • [ ] Linux
  • [ ] MacOS
  • [ ] Azure Cloud Shell
  • [ ] Azure Functions
  • [ ] Other : please specify

MatthiasAbt-SVA avatar Jan 06 '25 13:01 MatthiasAbt-SVA