2

我正在尝试将“isRequired”属性放在 JSON 代码中,以使用显示在 Botframework Emulator 上的自适应卡创建附件,但它不起作用。

{
  "type": "AdaptiveCard",
  "body": [
    {
      "type": "TextBlock",
      "size": "Medium",
      "weight": "Bolder",
      "text": "Create List"
    },
    {
      "type": "Input.Text",
      "placeholder": "Restaurant Name",
      "id": "restaurantInput",
      "isRequired":  true
    },
    {
      "type": "Input.Time",
      "id": "timeInput",
      "isRequired": true
    },
    {
      "type": "ActionSet",
      "actions": [
        {
          "type": "Action.Submit",
          "title": "Create"
        }
      ]
    }
  ],
  "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
  "version": "1.3"
}

添加“isRequired”属性后的消息框(空) https://i.stack.imgur.com/wWt5S.png

没有“isRequired”属性的消息框 https://i.stack.imgur.com/myJrq.png

有什么建议吗?

4

0 回答 0