Files
DentalManagement2025/packages/db/shared/schemas/objects/PatientScalarWhereWithAggregatesInput.schema.ts
2025-05-08 21:27:29 +05:30

134 lines
3.9 KiB
TypeScript

import { z } from 'zod';
import { IntWithAggregatesFilterObjectSchema } from './IntWithAggregatesFilter.schema';
import { StringWithAggregatesFilterObjectSchema } from './StringWithAggregatesFilter.schema';
import { DateTimeWithAggregatesFilterObjectSchema } from './DateTimeWithAggregatesFilter.schema';
import { StringNullableWithAggregatesFilterObjectSchema } from './StringNullableWithAggregatesFilter.schema';
import type { Prisma } from '../../../generated/prisma';
const Schema: z.ZodType<Prisma.PatientScalarWhereWithAggregatesInput> = z
.object({
AND: z
.union([
z.lazy(() => PatientScalarWhereWithAggregatesInputObjectSchema),
z.lazy(() => PatientScalarWhereWithAggregatesInputObjectSchema).array(),
])
.optional(),
OR: z
.lazy(() => PatientScalarWhereWithAggregatesInputObjectSchema)
.array()
.optional(),
NOT: z
.union([
z.lazy(() => PatientScalarWhereWithAggregatesInputObjectSchema),
z.lazy(() => PatientScalarWhereWithAggregatesInputObjectSchema).array(),
])
.optional(),
id: z
.union([z.lazy(() => IntWithAggregatesFilterObjectSchema), z.number()])
.optional(),
firstName: z
.union([z.lazy(() => StringWithAggregatesFilterObjectSchema), z.string()])
.optional(),
lastName: z
.union([z.lazy(() => StringWithAggregatesFilterObjectSchema), z.string()])
.optional(),
dateOfBirth: z
.union([
z.lazy(() => DateTimeWithAggregatesFilterObjectSchema),
z.coerce.date(),
])
.optional(),
gender: z
.union([z.lazy(() => StringWithAggregatesFilterObjectSchema), z.string()])
.optional(),
phone: z
.union([z.lazy(() => StringWithAggregatesFilterObjectSchema), z.string()])
.optional(),
email: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
address: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
city: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
zipCode: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
insuranceProvider: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
insuranceId: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
groupNumber: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
policyHolder: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
allergies: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
medicalConditions: z
.union([
z.lazy(() => StringNullableWithAggregatesFilterObjectSchema),
z.string(),
])
.optional()
.nullable(),
status: z
.union([z.lazy(() => StringWithAggregatesFilterObjectSchema), z.string()])
.optional(),
userId: z
.union([z.lazy(() => IntWithAggregatesFilterObjectSchema), z.number()])
.optional(),
createdAt: z
.union([
z.lazy(() => DateTimeWithAggregatesFilterObjectSchema),
z.coerce.date(),
])
.optional(),
})
.strict();
export const PatientScalarWhereWithAggregatesInputObjectSchema = Schema;