Prepared google calendar deletion
This commit is contained in:
1 parent
d05ae49e8d
commit
b376e9e5a4
3 files changed
+115
-56
No files matched your search
@@ -53,7 +53,10 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse)
|
||||
userId: currentUser.id,
|
||||
references: {
|
||||
create: [
|
||||
//TODO Create references
|
||||
{
|
||||
type: currentUser.credentials[0].type,
|
||||
uid: result.id
|
||||
}
|
||||
]
|
||||
},
|
||||
eventTypeId: eventType.id,
|
||||
|
||||
@@ -28,6 +28,7 @@ export default async function handler(req, res) {
|
||||
});
|
||||
|
||||
//TODO Delete booking from calendar integrations
|
||||
//TODO Perhaps send emails to user and client to tell about the cancellation
|
||||
|
||||
const deleteBooking = await prisma.booking.delete({
|
||||
where: {
|
||||
|
||||
Reference in new issue
Block a user