Return ID as part of foco-live events and venues
This commit is contained in:
@@ -28,9 +28,12 @@ export interface Event {
|
||||
"Cost Select": string;
|
||||
Cost: string,
|
||||
"Date Select": string
|
||||
'"Specials" at Venue': string,
|
||||
id: string;
|
||||
}
|
||||
|
||||
export interface Venue {
|
||||
id: string;
|
||||
"Bar or Venue Name": string,
|
||||
"Street Address": string,
|
||||
"City": string,
|
||||
@@ -42,7 +45,6 @@ export interface Venue {
|
||||
"Facebook Page": string,
|
||||
"Instagram": string,
|
||||
"Twitter Account": string,
|
||||
|
||||
}
|
||||
|
||||
const cacheKeys = {
|
||||
@@ -70,7 +72,10 @@ export class FocoLiveService {
|
||||
return ((await this.airtableBase('Events').select({
|
||||
view: "Grid view",
|
||||
}).all())
|
||||
.map(record => record.fields) as any as Event[])
|
||||
.map(record => ({
|
||||
id: record.id,
|
||||
...record.fields
|
||||
})) as any as Event[])
|
||||
.sort(compareDates)
|
||||
.reverse();
|
||||
}
|
||||
@@ -90,7 +95,10 @@ export class FocoLiveService {
|
||||
return ((await this.airtableBase('Venues').select({
|
||||
view: "Grid view",
|
||||
}).all())
|
||||
.map(record => record.fields) as any as Venue[])
|
||||
.map(record => ({
|
||||
id: record.id,
|
||||
...record.fields
|
||||
})) as any as Venue[])
|
||||
.sort(compareDates)
|
||||
.reverse();
|
||||
}
|
||||
|
Reference in New Issue
Block a user