- When an Open Shift is requested, the trigger posts an adaptive card that has a "approve" and a "decline" button to a chat.
- When approved, a "Thank you for your response" message is sent, then a message is posted in chat saying "your open shift request has been approved," and the Open Shift requested is successfully approved and recorded in the scheduling group
- When Declined, a "Thank you for your response message is sent, then a message is posted in chat saying "your open shift request has been approved", and the Open shift requested is approved NOT declined/denied, and records in the scheduling group as approved, so regardless of response the Open Shift is approved
- When responding to the adaptive card for the first time, after selecting "approve" or "Decline" buttons, the loop starts again, and the adaptive card is posted again because of original trigger.
- How to I prevent the flow from looping/re-starting again when I respond to the adaptive card with the two buttons awaiting a response? Do I have to add another condition or a "terminate" control? If so, what section would the condition or control be in the workflow?
- What is wrong in with the "or" condition or the expressions? How can I make them react appropriately to the approve or decline actions?
- Is the problem in my Adaptive Card JSON code? If so what needs to be changed?
"$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
"type": "AdaptiveCard",
"version": "1.3",
"body": [
{
"type": "TextBlock",
"text": "Open Shift Request",
"weight": "Bolder",
"size": "Medium"
},
{
"type": "TextBlock",
"text": "An Open Shift request has been created. Please reply with your decision.",
"wrap": true
}
],
"actions": [
{
"type": "Action.Submit",
"title": "Approve",
"data": { "response": "Approved" }
},
{
"type": "Action.Submit",
"title": "Decline",
"data": { "response": "Declined" }
}
]
}

Report
All responses (
Answers (