android - Google Now Activity 卡片 - 如何显示更多信息

标签 android gmail google-schemas google-now

我正在通过将架构数据添加到确认电子邮件来测试 Google Now 中的事件卡片。目前我正在尝试用铁路旅程信息填充事件卡,因为不支持铁路旅程模式。 不幸的是,我只能获得一小部分提供的信息以显示在 Google Now 的卡片中。

这是我要添加到电子邮件中的内容:

<html>
  <body>
<script type="application/ld+json">
{
  "@context": "http://schema.org",
  "@type": "EventReservation",
  "reservationNumber": "123456789",
  "reservationStatus": "http://schema.org/Confirmed",
  "url": "http://www.eastcoast.co.uk",
  "underName": {
    "@type": "Person",
    "name": "Conor Marron"
  },
  "bookingAgent": {
   "@type": "Organization",
   "name": "East Coast",
   "url": "http://www.eastcoast.co.uk",
   "image": "http://losttrack.co.uk/wp-content/uploads/2013/09/cr-1-may-30-img-East-Coast-Logo.jpg" 
  },
  "modifyReservationUrl": "http://www.eastcoast.co.uk",
  "reservationFor": {
    "@type": "Event",
    "name": "Train to London King's Cross",
    "description": "Leaving at 16:00. Coach B, seat 12",
    "image": "http://static.guim.co.uk/sys-images/Observer/Pix/pictures/2012/3/24/1332602521578/new-concourse-kings-cross-008.jpg",
    "startDate": "2014-02-25T16:00:00+00:00",
    "endDate": "2014-02-25T19:00:00+00:00",
    "location": {
      "@type": "Place",
      "name": "Newcastle Central Station",
      "address": {
        "@type": "PostalAddress",
        "streetAddress": "Neville Street",
        "addressLocality": "Newcastle Upon Tyne",
        "addressRegion": "Tyne and Wear",
        "postalCode": "NE1 5DL",
        "addressCountry": "UK"
      }
    }
  },
  "numSeats": "1",
  "venueSeat": "12",
  "venueSection": "Coach B",
  "ticketNumber": "1257250214-1",
  "modifiedTime": "2014-02-25T15:15:00+00:00",
  "additionalTicketText": "Collect tickets at the station. Ref: ABCD1234"
}
</script>

    <p>
      Full Event Schema Example. 
    </p>
  </body>
</html>

不幸的是,我从中得到的是:

Train to London

所以你可以看到没有图片,没有导航提示,没有附加说明,没有预订信息。

有什么方法可以增加默认显示的信息量?

事件卡片的 Google 示例看起来好多了。我想要获取信息链接、图像和导航提示等项目。

Expected

有什么想法吗?

最佳答案

也许预订代理的图像没有显示在卡片中。为表演者或 Activity 设置图像怎么样?

从您提供的屏幕截图来看,恐龙似乎是表演者,from the doc :

reservationFor.performer.image URL(推荐用于 Google Now/Search Answers)人物图像的 URL。

关于android - Google Now Activity 卡片 - 如何显示更多信息,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22020184/

相关文章:

android - Executors.newFixedThreadPool(size) 是要考虑 CPU 内核,还是我应该考虑。值得吗?

ios - 通过 Gmail API 获取未读邮件数

hyperlink - 在浏览器窗口中打开在 Gmail API 中创建的 Gmail 草稿

c# - Schema.NET HowTo 项不能添加多于一个步骤

google-schemas - 收件箱 : End to end example with google apps account 中的 Gmail 操作

google-schemas - 无法让架构按钮显示在 GMail 中

java - Android - Java - 在代码中使用的预定义 XML 模板

在 ICS 上几分钟未调用 Android AsyncTask

java - 当用户将标记添加到 map 上时,如何访问标记?

facebook 和 gmail 无法在模拟器中的 safari 中打开登录页面