PnP-PowerShell icon indicating copy to clipboard operation
PnP-PowerShell copied to clipboard

Apply-PnPProvisioningTemplate - webparts default with full toolbar and search enabled

Open LateNightDBA opened this issue 9 years ago • 3 comments

###Notice: many issues / bugs reported are actually related to the PnP Core Library which is used behind the scenes. Consider carefully where to report an issue:###

  1. Are you using Apply-SPOProvisioningTemplate or Get-SPOProvisioningTemplate? The issue is most likely related to the Provisioning Engine. The Provisioning engine is not located in the PowerShell repo. Please report the issue here: https://github.com/officedev/PnP-Sites-Core/issues.
  2. Is the issue related to the cmdlet itself, its parameters, the syntax, or do you suspect it is the code of the cmdlet that is causing the issue? Then please continue reporting the issue in this repo.
  3. If you think that the functionality might be related to the underlying libraries that the cmdlet is calling (We realize that that might be difficult to determine), please first double check the code of the cmdlet, which can be found here: https://github.com/OfficeDev/PnP-PowerShell/tree/master/Commands. If related to the cmdlet, continue reporting the issue here, otherwise report the issue at https://github.com/officedev/PnP-Sites-Core/issues

Reporting an Issue or Missing Feature

Please confirm what it is that your reporting BUG: Provisioning using Apply-PnPProvisioningTemplate majority of web parts default without desired view, full toolbar and search available.

Expected behavior

Please describe what output you expect to see from PnP-PowerShell Cmdlet Page and webParts honour the original settings

Actual behavior

Please describe what you see instead. Please provide samples of HTML output or screenshots Source site has a number of web parts on home page, standard type parts, Announcements, lists etc. when applying template these web parts all default with full toolbar and search available.

Steps to reproduce behavior

Please include complete code samples in-line or linked from gists

Create home page with desired web parts and views, toolbar, Chrome, search options applied. Execute following Powershell to create template. Excluding workflows as I can not also get this to provision well.

Get-PnPProvisioningTemplate -Out ZZZ-DEV-template.pnp -PersistMultiLanguageResources -ResourceFilePrefix MyResources -ExcludeHandlers Workflows -Web 'ZZZ'

Now apply template to another site (within same collection) another issue when crossing collection with content types etc.

Apply-PnPProvisioningTemplate -Path ZZZ-DEV-template.pnp -ClearNavigation -Web 'DestinationWeb';

Apply: Successful, though a number of web parts now default with FULL TOOLBAR and search & Chrome options now on. NOT as defined in Source web site.

Note: I have similar problem when deploying webparts individually using Add-PnPWebPartToWebPartPage Same issue and unable to simply change these options.

Maybe underlying issue.

Which version of the PnP-PowerShell Cmdlets are you using?

  • [ ] PnP PowerShell for SharePoint 2013
  • [ ] PnP PowerShell for SharePoint 2016
  • [# ] PnP PowerShell for SharePoint Online

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

(you can retrieve this by executing Get-Module -Name *pnppowershell* -ListAvailable) 17

How did you install the PnP-PowerShell Cmdlets?

  • [ ] MSI Installed downloaded from GitHub
  • [ X] Installed through the PowerShell Gallery with Install-Module
  • [ ] Other means

LateNightDBA avatar Mar 01 '17 09:03 LateNightDBA

I get the same behavior using SharePoint 2016 OnPrem. PowerShell module version: 2.12.17.0 (Used to get template) PNP .Net version: 2.12.17.0 (Used to apply template)

jopose avatar Mar 03 '17 12:03 jopose

too Add: DEFECT? - when running Get-PnPProvisioningTemplate It 'resets' web parts on home page (at least) to include the search option! Get action is actually do an update?

LateNightDBA avatar Mar 06 '17 12:03 LateNightDBA

I am also facing the same issue with SharePoint Online. The PNP-Powershell module was updated on 10 of August 2017.

kannan-balasubramanian avatar Aug 16 '17 08:08 kannan-balasubramanian