cli-microsoft365 icon indicating copy to clipboard operation
cli-microsoft365 copied to clipboard

Add AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled property to `spo tenant settings set`

Open martinlingstuyl opened this issue 1 year ago • 13 comments

A super interesting setting has been added to the CSOM API for tenant settings: AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled.

This enables people to update the property bag of a site without having to disable NoScript.

Which is freaking awesome 😉

Read the official documentation, or more on my blog if you're interested.

So I thought: we need to update the list of available options to be able to use this on spo tenant settings set.

Option Description Value
--AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled [AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled] Enables or disables web property bag updates when DenyAddAndCustomizePages is enabled. true or false

There's plenty of other options we are yet missing, but let's start with this one, as it's interesting.

martinlingstuyl avatar Nov 01 '24 20:11 martinlingstuyl

This probably overlaps with https://github.com/pnp/cli-microsoft365/issues/5034

milanholemans avatar Nov 01 '24 20:11 milanholemans

This specific option is not in Ganeshes PR though. And I think it is best if we don't keep changing the scope of that issue. It's been open quite long now. So let's just keep this separate is my opinion...

martinlingstuyl avatar Nov 03 '24 20:11 martinlingstuyl

good idea 👍 Lets do that

Adam-it avatar Nov 04 '24 20:11 Adam-it

May I work on this?

tmaestrini avatar Nov 06 '24 21:11 tmaestrini

May I work on this?

All yours

Adam-it avatar Nov 07 '24 06:11 Adam-it

Nice @tmaestrini! We're awaiting your PR with gratitude 😎

martinlingstuyl avatar Nov 08 '24 11:11 martinlingstuyl

Hey @martinlingstuyl, sorry for this "dumb" question, but: is there anything else to do than adding the new option to the interface definition and to make it know within the methods of the class?

tmaestrini avatar Feb 02 '25 22:02 tmaestrini

Hi @tmaestrini, there's no dumb questions here 😉 but I would look at how the other options are implemented. At least you would have to make sure the new option is sent along with the HTTP request. And also: it would be nice to have a test or two in place.

martinlingstuyl avatar Feb 03 '25 07:02 martinlingstuyl

Hey @martinlingstuyl, sorry for this "dumb" question, but: is there anything else to do than adding the new option to the interface definition and to make it know within the methods of the class?

Also add it to booleanOptions

martinlingstuyl avatar Feb 03 '25 07:02 martinlingstuyl

I already did, but thank you!

tmaestrini avatar Feb 03 '25 11:02 tmaestrini

How about this one @tmaestrini? Same treatment? Or did you already have some code in place and is it only waiting for time to create a PR? In that case it's perfectly fine to wait a bit..

martinlingstuyl avatar Apr 17 '25 06:04 martinlingstuyl

Same here, @martinlingstuyl... although this would be an easy task...

tmaestrini avatar Apr 17 '25 06:04 tmaestrini

Done, and feel free to ask to be reassigned later. Or if you fancy another issue more it's always good...

martinlingstuyl avatar Apr 17 '25 06:04 martinlingstuyl