Skip to content

Commit

Permalink
Add checkedIn and checkedOut to csv
Browse files Browse the repository at this point in the history
  • Loading branch information
tylermenezes committed Dec 22, 2023
1 parent 8ed78a6 commit 9026858
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/pages/events/[event]/tickets/index.gql
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ query getTickets($data: ClearEventWhereUniqueInput!) {
email
phone
type
checkedIn
checkedOut
guardian {
firstName
lastName
Expand Down
4 changes: 4 additions & 0 deletions src/pages/events/[event]/tickets/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ export default function Tickets({ event }) {
"waiverSigned",
"waiverUrl",
"organization",
"checkedIn",
"checkedOut",
...surveyHeaders,
];
const csv = (data?.clear?.event?.tickets || [])
Expand All @@ -100,6 +102,8 @@ export default function Tickets({ event }) {
t.waiverSigned ? 'signed' : 'not signed',
t.waiverUrl,
t.organization || "",
t.checkedIn || "",
t.checkedOut || "",
...surveyHeaders.map((h) => t.surveyResponses?.[h] || '').map((s) => s.replace(/,/g, ';')),
].join(",")
)
Expand Down

0 comments on commit 9026858

Please sign in to comment.