我用两个步骤创建了一个瀑布对话框。当我单击卡时,它将数据显示为来自用户的消息。如何捕获此数据而不将其作为消息从用户发送,然后如何根据数据在步骤2中进行sendActivity。
我的卡1数据:
"selectAction": {
"type": "Action.Submit",
"title": "TITLE",
"data": "DATA"
}
瀑布步骤-
async Step1(stepContext) {
await stepContext.context.sendActivity({
attachments: [
this.createAdaptiveCard1(),
this.createAdaptiveCard2(),
this.createAdaptiveCard3()
],
attachmentLayout: AttachmentLayoutTypes.Carousel
});
return await stepContext.prompt('somePrompt','Choose an option');
}
async Step2(stepContext) {
//capture data value and do something
}