2
0

feat(settings): ️ Can disable query params auto hide

This commit is contained in:
Baptiste Arnaud
2022-05-14 11:53:59 -07:00
parent 731e646377
commit 42721865c5
5 changed files with 66 additions and 2 deletions

View File

@ -74,6 +74,19 @@ export const createTypebots = async (partialTypebots: Partial<Typebot>[]) => {
})
}
export const updateTypebot = async (
partialTypebot: Partial<Typebot> & { id: string }
) => {
await prisma.typebot.updateMany({
where: { id: partialTypebot.id },
data: partialTypebot,
})
return prisma.publicTypebot.updateMany({
where: { typebotId: partialTypebot.id },
data: partialTypebot,
})
}
const parseTypebotToPublicTypebot = (
id: string,
typebot: Typebot