Files
DentalManagementMH07/packages/db/shared/schemas/objects/LabRxTemplateScalarWhereWithAggregatesInput.schema.ts
Gitead abb2a0ac96 feat: add Lab RX feature with template management and auto-seed defaults
- New lab_rx_template table with sortOrder and Prisma migrations
- Backend CRUD + reorder routes at /api/lab-rx/templates
- Auto-seeds 3 Highland Dental Studio defaults on first use per user
- LabRxModal: template picker, inline rename, up/down reorder, full
  template form with sections (Template Name / Lab Info / Case Details)
- RX popup: Tooth Number, Shade, Due Date, Doctor (from NPI providers),
  Instructions pre-filled with "Please make / Thank you!", print output
- lab-rx-templates.ts config file for future git-managed additions

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-02 23:20:44 -04:00

30 lines
3.2 KiB
TypeScript

import * as z from 'zod';
import type { Prisma } from '../../../generated/prisma';
import { IntWithAggregatesFilterObjectSchema as IntWithAggregatesFilterObjectSchema } from './IntWithAggregatesFilter.schema';
import { StringWithAggregatesFilterObjectSchema as StringWithAggregatesFilterObjectSchema } from './StringWithAggregatesFilter.schema';
import { StringNullableWithAggregatesFilterObjectSchema as StringNullableWithAggregatesFilterObjectSchema } from './StringNullableWithAggregatesFilter.schema';
import { DateTimeWithAggregatesFilterObjectSchema as DateTimeWithAggregatesFilterObjectSchema } from './DateTimeWithAggregatesFilter.schema'
const labrxtemplatescalarwherewithaggregatesinputSchema = z.object({
AND: z.union([z.lazy(() => LabRxTemplateScalarWhereWithAggregatesInputObjectSchema), z.lazy(() => LabRxTemplateScalarWhereWithAggregatesInputObjectSchema).array()]).optional(),
OR: z.lazy(() => LabRxTemplateScalarWhereWithAggregatesInputObjectSchema).array().optional(),
NOT: z.union([z.lazy(() => LabRxTemplateScalarWhereWithAggregatesInputObjectSchema), z.lazy(() => LabRxTemplateScalarWhereWithAggregatesInputObjectSchema).array()]).optional(),
id: z.union([z.lazy(() => IntWithAggregatesFilterObjectSchema), z.number().int()]).optional(),
userId: z.union([z.lazy(() => IntWithAggregatesFilterObjectSchema), z.number().int()]).optional(),
name: z.union([z.lazy(() => StringWithAggregatesFilterObjectSchema), z.string()]).optional(),
labName: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
labPhone: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
labFax: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
labAddress: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
labAccount: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
caseType: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
material: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
instructions: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
doctorName: z.union([z.lazy(() => StringNullableWithAggregatesFilterObjectSchema), z.string()]).optional().nullable(),
sortOrder: z.union([z.lazy(() => IntWithAggregatesFilterObjectSchema), z.number().int()]).optional(),
createdAt: z.union([z.lazy(() => DateTimeWithAggregatesFilterObjectSchema), z.coerce.date()]).optional(),
updatedAt: z.union([z.lazy(() => DateTimeWithAggregatesFilterObjectSchema), z.coerce.date()]).optional()
}).strict();
export const LabRxTemplateScalarWhereWithAggregatesInputObjectSchema: z.ZodType<Prisma.LabRxTemplateScalarWhereWithAggregatesInput> = labrxtemplatescalarwherewithaggregatesinputSchema as unknown as z.ZodType<Prisma.LabRxTemplateScalarWhereWithAggregatesInput>;
export const LabRxTemplateScalarWhereWithAggregatesInputObjectZodSchema = labrxtemplatescalarwherewithaggregatesinputSchema;