I have a column (Review and Approval) which shows a button if the value is Start Workflow, and clicking it opens a flow in Power Automate. In the example below the ID of the power Automate Flow is 0123456789 (See below: Json code column Review and approval:) .
I need to have the result of a choice column instead of 0123456789. See below what I've tried (Idea I tried:).
I added a column Approval_Flow_ID, and replaced 01234567879 with [$Approval_Flow_ID], but the button doesn't show.
Any Idea's? THANXX
Json code column Review and approval:
{
"$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json",
"elmType": "button",
"txtContent": "@currentField",
"customRowAction": {
"action": "executeFlow",
"actionParams": "{\"id\": \"01234567890"}"
},
"style": {
"background-color": "#008082",
"color": "white",
"border-radius": "0 15px",
"visibility": "=if((@currentField == 'Start Workflow'),'visible','hidden')"
}
}
Idea I tried:
Json code column Review and approval:
{
"$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json",
"elmType": "button",
"txtContent": "@currentField",
"customRowAction": {
"action": "executeFlow",
"actionParams": "{\"id\": \"[$Approval_Flow_ID]"}"
},
"style": {
"background-color": "#008082",
"color": "white",
"border-radius": "0 15px",
"visibility": "=if((@currentField == 'Start Workflow'),'visible','hidden')"
}
}
