Open emptyheadcode opened 1 year ago
Hi,
I am doing a POC for project developed with RASA , and Teams is the Channel. I am bot framework to display adaptive cards, and taking user inputs.
I am trying to integrate a datepicker , and want to record the date input value , selected by the user through the calendar, but I am unable to do it.
I am not able to access the date in the backend of RASA actions, or through tracker data.
Please explain or solve this issue, thanks.
Adaptive Card Code Below.
`adaptive_card_json = { "type": "AdaptiveCard", "$schema": "http://adaptivecards.io/schemas/adaptive-card.json", "version": "1.3", "body": [ { "type": "Input.Date", "id": "requested_departure_date", "title": "Select a date:", "value": "2023-08-01", "min": "2023-01-01", "max": "2023-12-31" } ], "actions": [ { "type": "Action.Submit", "title": "Submit", "text" : "August 23, 2023", "channel": "botframework", "id" :"requested_departure_date", "data": { "msteams":{ "text":"${requested_departure_date}", "title":"Select", "type":"messageBack", "value" : "/modify_departure_date" }, "style": "positive" } } ] }
message = { "type": "message", "text": "Here is the calendar:", "attachments": [ { "contentType": "application/vnd.microsoft.card.adaptive", "content": adaptive_card_json } ] } dispatcher.utter_message(json_message=message)`
Hey, did you find out any solution?
Hi,
I am doing a POC for project developed with RASA , and Teams is the Channel. I am bot framework to display adaptive cards, and taking user inputs.
I am trying to integrate a datepicker , and want to record the date input value , selected by the user through the calendar, but I am unable to do it.
I am not able to access the date in the backend of RASA actions, or through tracker data.
Please explain or solve this issue, thanks.
Adaptive Card Code Below.
`adaptive_card_json = { "type": "AdaptiveCard", "$schema": "http://adaptivecards.io/schemas/adaptive-card.json", "version": "1.3", "body": [ { "type": "Input.Date", "id": "requested_departure_date", "title": "Select a date:", "value": "2023-08-01", "min": "2023-01-01", "max": "2023-12-31" } ], "actions": [ { "type": "Action.Submit", "title": "Submit", "text" : "August 23, 2023", "channel": "botframework", "id" :"requested_departure_date", "data": { "msteams":{ "text":"${requested_departure_date}", "title":"Select", "type":"messageBack", "value" : "/modify_departure_date" }, "style": "positive" } } ] }