pnp / PnP-PowerShell

SharePoint PnP PowerShell CmdLets
https://pnp.github.io/powershell
Other
990 stars 663 forks source link

[BUG] Set-PnPView breaks Document Library #2830

Open InnovationForge-com opened 4 years ago

InnovationForge-com commented 4 years ago

Hi, Set-PnPView seems to create a bug in Document Libraries through which we can't open Office documents in Online View anymore and after a while documents can only be downloaded but not opened in the desktop version. Even when deleting all views and creating new ones it does not fix the problem.

This problem only occurs from within the Document Library. If we open the document through a direct link, share link, Teams, another systems through embed code - then everything works as expected.

I created a ticket at Microsoft some weeks ago when I didn't knew it was because of the cmdlet. After some testing I was able to recreate the problem every time I used Set-PnPView. After waiting for 3 weeks MS Support was still not able to understand what I wrote and always being told that escalation Team is working on it... so I'm here.

Steps to reproduce behavior

  1. Create document library
  2. Use Set-PnPView -Identity "All Documents" -List "Document Library" -Fields "Name", "Modified"
  3. Create and save an Excel file 4, Open it again
  4. Following message is being shown: https://lnag-my.sharepoint.com/:i:/g/personal/tobiass_lucanet_com/EZABniryufNFt8-5eYBCuagB7-Ry4N2Pwa_TZCwKTxGNPA?e=e6hxH2
  5. After a while the message changes to: https://lnag-my.sharepoint.com/:i:/g/personal/tobiass_lucanet_com/EfOMgN5wzy9Lm79ag1dzQpwBwpVlAHlpe41yvr3u8YRiOg?e=BGZWj1 and we are not able to open it in the client anymore, just download.

PnP PowerShell for SharePoint Online 3.23.2007.0 (also with an older version which I used before) Installed through the PowerShell Gallery with Install-Module

Can someone help us? Does someone know how we can fix it in our current document libraries? I used it on 24 document libraries which are now broken with no fix in sight.

If we cant fix it I will need to change the OneDrive mapping on 400+ computers and move their existing data to new document libraries.