Closed InciteDemocracy closed 7 years ago
i was looking at this. can reverse engineer the url from the data we currently have with
getFacebookUrl(event) {
const {identifiers} = event;
if (identifiers[0]) {
const id = identifiers[0].split(':')[1]
return `https://facebook.com/events/${id}`
}
return null;
}
but this should work as soon as the api returns base_url
@ignu We are getting the eventUrl from the api, no? If not we should because the button would break if we added events from other sources.
Just checking in -- what's the status of this ticket? I don't see the PR in the backend and it doesn't seem like the URL is coming back in the data.
I created an issue not a PR. Sorry.
Ah ok -- @aaghevli or @KamillaKhabibrakhmanova is this something one of you can knock out relatively easily? If not, we can reverse engineer the URL for facebook but would break for other sources, I think
Could also break for facebook if other sources get added and FB was no longer the first item in the array, so we'd have to do a string match or something like that :hankey:.
This has been implemented in the API and should be available by now (had to wait for ETL run).
Awesome, I see browser_url
now -- I'll wrap this up today
@aaghevli any idea why some of them don't have a browser_url
, like this one? https://resistance-calendar-staging.herokuapp.com/event/58e9a50d74ceb9d94e193e02
@InciteDemocracy if it's something we can't account for and don't have a URL, we should hide the button in the UI right?
The PR hasn't been merged yet so I'm re-opening
Clicking the event page button on the event details page should open the event's external event page in a new tab.