cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

SharePoint Online column json formatting on folders issue

Hello,

 

I have an SP list where the user is allowed to create folders and then add list item inside those folders. I have a flow attached to this list which gets triggered manually. I have added json formatting to show/hide the Manual trigger button based on the Content Approval status.

 

Issue:

The issue I am having is that the json formatting also shows up on the folders created in the list. How can I only show the json formatting on list items and skip if there is a folder

 

Here is the json I have written so far.

 

{
"elmType": "button",
"style": {
"border": "solid",
"background-color": "white",
"color": "#0078d7",
"cursor": "pointer",
"visibility": "=if(([$_ModerationStatus] == 'Pending'),'visible','hidden')"
},
"txtContent": "Click to begin review",
"customRowAction": {
"action": "executeFlow",
"actionParams": "{\"id\": \"flowID\"}"
}
}

1 ACCEPTED SOLUTION

Accepted Solutions
Anonymous
Not applicable

Re: SharePoint Online column json formatting on folders issue

I think I figured out the solution. I added a condition to see if the ContentType == 'Item' and that seems to have done the job. Now the formatting only shows up on list items and not on Folders.

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Re: SharePoint Online column json formatting on folders issue

I think I figured out the solution. I added a condition to see if the ContentType == 'Item' and that seems to have done the job. Now the formatting only shows up on list items and not on Folders.

View solution in original post

Helpful resources

Announcements
MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.

‘Better Together’ T-Shirt Contest – Winner Announced!

‘Better Together’ T-Shirt Contest – Winner Announced!

And the winner is...

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Apps Community!

Power Platform 2020 release wave 1 plan

Power Platform 2020 release wave 1 plan

Features releasing from April 2020 through September 2020

Top Solution Authors
Top Kudoed Authors
Users online (7,778)