feat: template recipients on blur

This commit is contained in:
Catalin Pit
2024-08-23 16:00:01 +03:00
parent da9287440b
commit b885aae511
5 changed files with 121 additions and 7 deletions

View File

@ -12,6 +12,7 @@ import {
ZAddTemplateSignersMutationSchema,
ZCompleteDocumentWithTokenMutationSchema,
ZRemoveSignerMutationSchema,
ZRemoveTemplateSignerMutationSchema,
} from './schema';
export const recipientRouter = router({
@ -72,6 +73,12 @@ export const recipientRouter = router({
}
}),
removeTemplateSigner: authenticatedProcedure
.input(ZRemoveTemplateSignerMutationSchema)
.mutation(async ({ input, ctx }) => {
// TODO: Implement
}),
removeSigner: authenticatedProcedure
.input(ZRemoveSignerMutationSchema)
.mutation(async ({ input, ctx }) => {

View File

@ -75,3 +75,13 @@ export const ZCompleteDocumentWithTokenMutationSchema = z.object({
export type TCompleteDocumentWithTokenMutationSchema = z.infer<
typeof ZCompleteDocumentWithTokenMutationSchema
>;
export const ZRemoveTemplateSignerMutationSchema = z.object({
templateId: z.number(),
teamId: z.number().optional(),
recipientId: z.number(),
});
export type TRemoveTemplateSignerMutationSchema = z.infer<
typeof ZRemoveTemplateSignerMutationSchema
>;