Files
calendar/packages/features/watchlist/watchlist.model.ts
T
1d8326ed83 feat: watchlist (#17947)
* lock users on signup if their email is in blacklist

* add to turbo env list

* prevent locked user or blocked email domain from using API

* Refactored to only run 1 query to find the user

* Fixing tests

* WIP

* WIP

* WIP

* Discard changes to turbo.json

* Fixed tests

* Update isLockedOrBlocked.test.ts

* Update isAdmin.integration-test.ts

* Update tsconfig.json

* chore: rename to watchlist

Signed-off-by: Omar López <zomars@me.com>

---------

Signed-off-by: Omar López <zomars@me.com>
Co-authored-by: sean-brydon <sean@cal.com>
Co-authored-by: Keith Williams <keithwillcode@gmail.com>
Co-authored-by: sean-brydon <55134778+sean-brydon@users.noreply.github.com>
2024-12-03 18:43:01 +01:00

23 lines
484 B
TypeScript

import type { z } from "zod";
import { _WatchlistModel } from "@calcom/prisma/zod/watchlist";
export const WatchlistModelSchema = _WatchlistModel.pick({
id: true,
type: true,
value: true,
description: true,
createdAt: true,
createdById: true,
updatedAt: true,
updatedById: true,
});
export type Watchlist = z.infer<typeof WatchlistModelSchema>;
export const insertWatchlistSchema = WatchlistModelSchema.pick({
type: true,
value: true,
description: true,
});