import * as z from 'zod';
import { Prisma } from '../../../generated/prisma';
import Decimal from 'decimal.js';
import { DecimalFieldUpdateOperationsInputObjectSchema as DecimalFieldUpdateOperationsInputObjectSchema } from './DecimalFieldUpdateOperationsInput.schema';
import { CommissionBatchUpdateOneRequiredWithoutItemsNestedInputObjectSchema as CommissionBatchUpdateOneRequiredWithoutItemsNestedInputObjectSchema } from './CommissionBatchUpdateOneRequiredWithoutItemsNestedInput.schema'

import { DecimalJSLikeSchema, isValidDecimalInput } from '../../helpers/decimal-helpers';
const makeSchema = () => z.object({
  collectionAmount: z.union([z.union([
  z.number(),
  z.string(),
  z.instanceof(Decimal),
  z.instanceof(Prisma.Decimal),
  DecimalJSLikeSchema,
]).refine((v) => isValidDecimalInput(v), {
  message: "Field 'collectionAmount' must be a Decimal",
}), z.lazy(() => DecimalFieldUpdateOperationsInputObjectSchema)]).optional(),
  commissionBatch: z.lazy(() => CommissionBatchUpdateOneRequiredWithoutItemsNestedInputObjectSchema).optional()
}).strict();
export const CommissionBatchItemUpdateWithoutPaymentInputObjectSchema: z.ZodType<Prisma.CommissionBatchItemUpdateWithoutPaymentInput> = makeSchema() as unknown as z.ZodType<Prisma.CommissionBatchItemUpdateWithoutPaymentInput>;
export const CommissionBatchItemUpdateWithoutPaymentInputObjectZodSchema = makeSchema();
