Created
December 4, 2020 06:42
-
-
Save dgtlmonk/1f2168c42194a95a31dff574f8bd4236 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getBookingById( | |
ownerId: number, | |
bookingId: number, | |
fields: string[], | |
) { | |
return gql` | |
query getBookingById { | |
bookingsByOwnerIds(ownerIds: [${ownerId}], where: { id: ${bookingId} }) { | |
nodes { | |
${fields.join('\n')} | |
} | |
} | |
} | |
`; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment