1

当我使用 fql 查询 Facebook 的 256996217750754 eid 时,它返回 end_time 为空:

SELECT eid, name, pic_small, pic_big, pic_square, pic, host, description, start_time, end_time, creator, update_time, location, venue, privacy from event where eid=256996217750754

返回:

...
"start_time": "2012-09-01T22:00:00-0400",
"end_time": null,
...

但是,当我查询图表时,它返回准确:

https://graph.facebook.com/256996217750754?access_token=<access_token>

返回:

...
start_time: "2012-09-01T22:00:00",
end_time: "2012-09-02T01:00:00",
...

有谁知道为什么?

4

2 回答 2

1

end_time当事件没有定义可选的结束时间时为 null。此外,当我查询该事件的图表时,我看不出end_time哪个与返回 null 的 FQL 一致:

{
   "id": "256996217750754",
   "owner": {
      "name": "Buffalo Wings & Rings Morrisville, NC",
      "category": "Restaurant/cafe",
      "id": "136674116345739"
   },
   "name": "UFC 151 on Pay Per View - Jones vs. Henderson",
   "description": "Main Card -\nJones vs Henderson\nJohnson vs Castillo\nMizugaki vs Hougland\nSiver vs Yagin\nLineker vs Urushitani\nPrelims - \nCruickshank vs Martinez\nRoller vs Volkmann",
   "start_time": "2012-09-01T22:00:00-0400",
   "timezone": "America/New_York",
   "location": "Buffalo Wings & Rings Morrisville, NC",
   "venue": {
      "id": "136674116345739"
   },
   "privacy": "OPEN",
   "updated_time": "2012-08-02T14:37:21+0000"
}

我用了:

https://graph.facebook.com/256996217750754?access_token=AAACEdEose...
于 2012-08-16T20:24:56.410 回答
0

我相信 Donn Lee 是部分正确的。根据 Facebook 开发者文章,“end_time”始终是为事件定义的。但是,这将在 2012 年 10 月 30 日之前消失。

请注意 Donn Lee 对图表的反应与我自己的反应之间的差异。

我的回复禁用了“事件时区”:

...
"start_time": "2012-09-01T22:00:00-0400",
"end_time": null,
...

Donn Lee 的回复,可能启用了“事件时区”:

...
"start_time": "2012-09-01T22:00:00-0400",
...

此设置可在 Facebook 应用程序的“高级”设置页面的“迁移”下找到:

在此处输入图像描述

结论

看来我需要迁移我的代码以支持 Facebook 的新事件时间约定

  1. 处理带有偏移量的 ISO-8601
  2. 如果没有指定,则期望没有“end_time”。
于 2012-09-04T19:06:55.220 回答