* Install upstash redis again - base of noficationSender * Setup email handler etc and use tasker * Remove logs * Sending emails and correct format and spacing in emails * Update email styles * Update email styles * add switch to enable feature * fix: reset tasker types - will fix in new PR * WIP: test suite * WIP: test suite * Add redis service and add WIP mock test * Add tests for redis service and fix lpush * More working tests * More working tests * fix: type error + typo * update export to match i18n next mock * (debug) push for debug * Fix: fixed hosting in mocks * Add common.json i18n * add better test descriptions * reset mocks after each test to allow concurancy * Remove redundant RedisService.test.ts * Rename and remove redundant isAdmin check * Rename to .d.ts * Add key versioning to constructRedisKey * Update packages/trpc/server/routers/viewer/slots/handleNotificationWhenNoSlots.ts Co-authored-by: Hariom Balhara <hariombalhara@gmail.com> * Update packages/trpc/server/routers/viewer/slots/handleNotificationWhenNoSlots.ts Co-authored-by: Hariom Balhara <hariombalhara@gmail.com> * Add try/catch * fix breaking when option === undefined * Add missing await to Promise.all * Rename data stored in redis to save space * Include thrown error in logs --------- Co-authored-by: Hariom Balhara <hariombalhara@gmail.com> Co-authored-by: Joe Au-Yeung <65426560+joeauyeung@users.noreply.github.com>
37 lines
1.1 KiB
TypeScript
37 lines
1.1 KiB
TypeScript
import { z } from "zod";
|
|
|
|
import { teamMetadataSchema } from "@calcom/prisma/zod-utils";
|
|
|
|
export const ZUpdateInputSchema = z.object({
|
|
name: z.string().optional(),
|
|
orgId: z
|
|
.string()
|
|
.regex(/^\d+$/)
|
|
.transform((id) => parseInt(id))
|
|
.or(z.number())
|
|
.optional(),
|
|
bio: z.string().optional(),
|
|
logoUrl: z.string().optional().nullable(),
|
|
calVideoLogo: z
|
|
.string()
|
|
.optional()
|
|
.nullable()
|
|
.transform((v) => v || null),
|
|
banner: z.string().nullable().optional(),
|
|
slug: z.string().optional(),
|
|
hideBranding: z.boolean().optional(),
|
|
hideBookATeamMember: z.boolean().optional(),
|
|
brandColor: z.string().optional(),
|
|
darkBrandColor: z.string().optional(),
|
|
theme: z.string().optional().nullable(),
|
|
timeZone: z.string().optional(),
|
|
weekStart: z.string().optional(),
|
|
timeFormat: z.number().optional(),
|
|
metadata: teamMetadataSchema.unwrap().optional(),
|
|
lockEventTypeCreation: z.boolean().optional(),
|
|
lockEventTypeCreationOptions: z.enum(["DELETE", "HIDE"]).optional(),
|
|
adminGetsNoSlotsNotification: z.boolean().optional(),
|
|
});
|
|
|
|
export type TUpdateInputSchema = z.infer<typeof ZUpdateInputSchema>;
|