/** * Client **/ import * as runtime from '@prisma/client/runtime/library.js'; import $Types = runtime.Types // general types import $Public = runtime.Types.Public import $Utils = runtime.Types.Utils import $Extensions = runtime.Types.Extensions import $Result = runtime.Types.Result export type PrismaPromise = $Public.PrismaPromise /** * Model City * */ export type City = $Result.DefaultSelection /** * Model AdminUser * */ export type AdminUser = $Result.DefaultSelection /** * Model Customer * */ export type Customer = $Result.DefaultSelection /** * Model CustomerAddress * */ export type CustomerAddress = $Result.DefaultSelection /** * Model Branch * */ export type Branch = $Result.DefaultSelection /** * Model Workshop * */ export type Workshop = $Result.DefaultSelection /** * Model Category * */ export type Category = $Result.DefaultSelection /** * Model Brand * */ export type Brand = $Result.DefaultSelection /** * Model Collection * Curated product groupings — replaces legacy "Ciny/CinyProduct" (a tagging * feature, NOT a gold-price snapshot mechanism, despite the misleading legacy name). */ export type Collection = $Result.DefaultSelection /** * Model CollectionProduct * */ export type CollectionProduct = $Result.DefaultSelection /** * Model Product * */ export type Product = $Result.DefaultSelection /** * Model ProductImage * */ export type ProductImage = $Result.DefaultSelection /** * Model ProductVariant * */ export type ProductVariant = $Result.DefaultSelection /** * Model Order * */ export type Order = $Result.DefaultSelection /** * Model OrderItem * */ export type OrderItem = $Result.DefaultSelection /** * Model OrderStatusEvent * */ export type OrderStatusEvent = $Result.DefaultSelection /** * Model PreOrder * */ export type PreOrder = $Result.DefaultSelection /** * Model PreOrderStatusEvent * */ export type PreOrderStatusEvent = $Result.DefaultSelection /** * Model LedgerEntry * */ export type LedgerEntry = $Result.DefaultSelection /** * Model GoldPriceQuote * Replaces legacy WebServiceGold / ConfigStatic.gold_price — timestamped price feed. */ export type GoldPriceQuote = $Result.DefaultSelection /** * Model WalletBonus * Time-limited gold cashback bonus — replaces the legacy Rooyesh\Wallet gold credit. */ export type WalletBonus = $Result.DefaultSelection /** * Enums */ export namespace $Enums { export const AdminRole: { SUPER_ADMIN: 'SUPER_ADMIN', SYSTEM_APPROVER: 'SYSTEM_APPROVER', SALES_EXPERT: 'SALES_EXPERT', WORKSHOP_SUPERVISOR: 'WORKSHOP_SUPERVISOR', ACCOUNTANT: 'ACCOUNTANT' }; export type AdminRole = (typeof AdminRole)[keyof typeof AdminRole] export const VerificationStep: { UNVERIFIED: 'UNVERIFIED', STEP_ONE_SUBMITTED: 'STEP_ONE_SUBMITTED', STEP_TWO_SUBMITTED: 'STEP_TWO_SUBMITTED', VERIFIED: 'VERIFIED' }; export type VerificationStep = (typeof VerificationStep)[keyof typeof VerificationStep] export const OrderStatus: { SUSPENDED: 'SUSPENDED', PLACED: 'PLACED', ADMIN_APPROVED: 'ADMIN_APPROVED', SOURCING: 'SOURCING', PREPARING: 'PREPARING', DELIVERED_TO_AGENT: 'DELIVERED_TO_AGENT', DELIVERED_TO_CUSTOMER: 'DELIVERED_TO_CUSTOMER', CANCELLED: 'CANCELLED' }; export type OrderStatus = (typeof OrderStatus)[keyof typeof OrderStatus] export const PreOrderStatus: { PLACED: 'PLACED', ADMIN_APPROVED: 'ADMIN_APPROVED', WORKSHOP_APPROVED: 'WORKSHOP_APPROVED', READY_TO_SHIP: 'READY_TO_SHIP', DELIVERED: 'DELIVERED', CANCELLED: 'CANCELLED' }; export type PreOrderStatus = (typeof PreOrderStatus)[keyof typeof PreOrderStatus] export const LedgerCurrency: { GOLD_GRAM: 'GOLD_GRAM', RIAL: 'RIAL' }; export type LedgerCurrency = (typeof LedgerCurrency)[keyof typeof LedgerCurrency] export const LedgerDirection: { DEBIT: 'DEBIT', CREDIT: 'CREDIT' }; export type LedgerDirection = (typeof LedgerDirection)[keyof typeof LedgerDirection] export const LedgerSourceType: { ORDER_STOCK: 'ORDER_STOCK', ORDER_PRE_ORDER: 'ORDER_PRE_ORDER', REPAYMENT_MELTED_GOLD: 'REPAYMENT_MELTED_GOLD', REPAYMENT_TRANSFER: 'REPAYMENT_TRANSFER', REPAYMENT_CHEQUE: 'REPAYMENT_CHEQUE', REPAYMENT_CASH: 'REPAYMENT_CASH', WALLET_BONUS: 'WALLET_BONUS', ADJUSTMENT: 'ADJUSTMENT' }; export type LedgerSourceType = (typeof LedgerSourceType)[keyof typeof LedgerSourceType] } export type AdminRole = $Enums.AdminRole export const AdminRole: typeof $Enums.AdminRole export type VerificationStep = $Enums.VerificationStep export const VerificationStep: typeof $Enums.VerificationStep export type OrderStatus = $Enums.OrderStatus export const OrderStatus: typeof $Enums.OrderStatus export type PreOrderStatus = $Enums.PreOrderStatus export const PreOrderStatus: typeof $Enums.PreOrderStatus export type LedgerCurrency = $Enums.LedgerCurrency export const LedgerCurrency: typeof $Enums.LedgerCurrency export type LedgerDirection = $Enums.LedgerDirection export const LedgerDirection: typeof $Enums.LedgerDirection export type LedgerSourceType = $Enums.LedgerSourceType export const LedgerSourceType: typeof $Enums.LedgerSourceType /** * ## Prisma Client ʲˢ * * Type-safe database client for TypeScript & Node.js * @example * ``` * const prisma = new PrismaClient() * // Fetch zero or more Cities * const cities = await prisma.city.findMany() * ``` * * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client). */ export class PrismaClient< ClientOptions extends Prisma.PrismaClientOptions = Prisma.PrismaClientOptions, U = 'log' extends keyof ClientOptions ? ClientOptions['log'] extends Array ? Prisma.GetEvents : never : never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs > { [K: symbol]: { types: Prisma.TypeMap['other'] } /** * ## Prisma Client ʲˢ * * Type-safe database client for TypeScript & Node.js * @example * ``` * const prisma = new PrismaClient() * // Fetch zero or more Cities * const cities = await prisma.city.findMany() * ``` * * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client). */ constructor(optionsArg ?: Prisma.Subset); $on(eventType: V, callback: (event: V extends 'query' ? Prisma.QueryEvent : Prisma.LogEvent) => void): void; /** * Connect with the database */ $connect(): $Utils.JsPromise; /** * Disconnect from the database */ $disconnect(): $Utils.JsPromise; /** * Add a middleware * @deprecated since 4.16.0. For new code, prefer client extensions instead. * @see https://pris.ly/d/extensions */ $use(cb: Prisma.Middleware): void /** * Executes a prepared raw query and returns the number of affected rows. * @example * ``` * const result = await prisma.$executeRaw`UPDATE User SET cool = ${true} WHERE email = ${'user@email.com'};` * ``` * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access). */ $executeRaw(query: TemplateStringsArray | Prisma.Sql, ...values: any[]): Prisma.PrismaPromise; /** * Executes a raw query and returns the number of affected rows. * Susceptible to SQL injections, see documentation. * @example * ``` * const result = await prisma.$executeRawUnsafe('UPDATE User SET cool = $1 WHERE email = $2 ;', true, 'user@email.com') * ``` * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access). */ $executeRawUnsafe(query: string, ...values: any[]): Prisma.PrismaPromise; /** * Performs a prepared raw query and returns the `SELECT` data. * @example * ``` * const result = await prisma.$queryRaw`SELECT * FROM User WHERE id = ${1} OR email = ${'user@email.com'};` * ``` * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access). */ $queryRaw(query: TemplateStringsArray | Prisma.Sql, ...values: any[]): Prisma.PrismaPromise; /** * Performs a raw query and returns the `SELECT` data. * Susceptible to SQL injections, see documentation. * @example * ``` * const result = await prisma.$queryRawUnsafe('SELECT * FROM User WHERE id = $1 OR email = $2;', 1, 'user@email.com') * ``` * * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access). */ $queryRawUnsafe(query: string, ...values: any[]): Prisma.PrismaPromise; /** * Allows the running of a sequence of read/write operations that are guaranteed to either succeed or fail as a whole. * @example * ``` * const [george, bob, alice] = await prisma.$transaction([ * prisma.user.create({ data: { name: 'George' } }), * prisma.user.create({ data: { name: 'Bob' } }), * prisma.user.create({ data: { name: 'Alice' } }), * ]) * ``` * * Read more in our [docs](https://www.prisma.io/docs/concepts/components/prisma-client/transactions). */ $transaction

[]>(arg: [...P], options?: { isolationLevel?: Prisma.TransactionIsolationLevel }): $Utils.JsPromise> $transaction(fn: (prisma: Omit) => $Utils.JsPromise, options?: { maxWait?: number, timeout?: number, isolationLevel?: Prisma.TransactionIsolationLevel }): $Utils.JsPromise $extends: $Extensions.ExtendsHook<"extends", Prisma.TypeMapCb, ExtArgs> /** * `prisma.city`: Exposes CRUD operations for the **City** model. * Example usage: * ```ts * // Fetch zero or more Cities * const cities = await prisma.city.findMany() * ``` */ get city(): Prisma.CityDelegate; /** * `prisma.adminUser`: Exposes CRUD operations for the **AdminUser** model. * Example usage: * ```ts * // Fetch zero or more AdminUsers * const adminUsers = await prisma.adminUser.findMany() * ``` */ get adminUser(): Prisma.AdminUserDelegate; /** * `prisma.customer`: Exposes CRUD operations for the **Customer** model. * Example usage: * ```ts * // Fetch zero or more Customers * const customers = await prisma.customer.findMany() * ``` */ get customer(): Prisma.CustomerDelegate; /** * `prisma.customerAddress`: Exposes CRUD operations for the **CustomerAddress** model. * Example usage: * ```ts * // Fetch zero or more CustomerAddresses * const customerAddresses = await prisma.customerAddress.findMany() * ``` */ get customerAddress(): Prisma.CustomerAddressDelegate; /** * `prisma.branch`: Exposes CRUD operations for the **Branch** model. * Example usage: * ```ts * // Fetch zero or more Branches * const branches = await prisma.branch.findMany() * ``` */ get branch(): Prisma.BranchDelegate; /** * `prisma.workshop`: Exposes CRUD operations for the **Workshop** model. * Example usage: * ```ts * // Fetch zero or more Workshops * const workshops = await prisma.workshop.findMany() * ``` */ get workshop(): Prisma.WorkshopDelegate; /** * `prisma.category`: Exposes CRUD operations for the **Category** model. * Example usage: * ```ts * // Fetch zero or more Categories * const categories = await prisma.category.findMany() * ``` */ get category(): Prisma.CategoryDelegate; /** * `prisma.brand`: Exposes CRUD operations for the **Brand** model. * Example usage: * ```ts * // Fetch zero or more Brands * const brands = await prisma.brand.findMany() * ``` */ get brand(): Prisma.BrandDelegate; /** * `prisma.collection`: Exposes CRUD operations for the **Collection** model. * Example usage: * ```ts * // Fetch zero or more Collections * const collections = await prisma.collection.findMany() * ``` */ get collection(): Prisma.CollectionDelegate; /** * `prisma.collectionProduct`: Exposes CRUD operations for the **CollectionProduct** model. * Example usage: * ```ts * // Fetch zero or more CollectionProducts * const collectionProducts = await prisma.collectionProduct.findMany() * ``` */ get collectionProduct(): Prisma.CollectionProductDelegate; /** * `prisma.product`: Exposes CRUD operations for the **Product** model. * Example usage: * ```ts * // Fetch zero or more Products * const products = await prisma.product.findMany() * ``` */ get product(): Prisma.ProductDelegate; /** * `prisma.productImage`: Exposes CRUD operations for the **ProductImage** model. * Example usage: * ```ts * // Fetch zero or more ProductImages * const productImages = await prisma.productImage.findMany() * ``` */ get productImage(): Prisma.ProductImageDelegate; /** * `prisma.productVariant`: Exposes CRUD operations for the **ProductVariant** model. * Example usage: * ```ts * // Fetch zero or more ProductVariants * const productVariants = await prisma.productVariant.findMany() * ``` */ get productVariant(): Prisma.ProductVariantDelegate; /** * `prisma.order`: Exposes CRUD operations for the **Order** model. * Example usage: * ```ts * // Fetch zero or more Orders * const orders = await prisma.order.findMany() * ``` */ get order(): Prisma.OrderDelegate; /** * `prisma.orderItem`: Exposes CRUD operations for the **OrderItem** model. * Example usage: * ```ts * // Fetch zero or more OrderItems * const orderItems = await prisma.orderItem.findMany() * ``` */ get orderItem(): Prisma.OrderItemDelegate; /** * `prisma.orderStatusEvent`: Exposes CRUD operations for the **OrderStatusEvent** model. * Example usage: * ```ts * // Fetch zero or more OrderStatusEvents * const orderStatusEvents = await prisma.orderStatusEvent.findMany() * ``` */ get orderStatusEvent(): Prisma.OrderStatusEventDelegate; /** * `prisma.preOrder`: Exposes CRUD operations for the **PreOrder** model. * Example usage: * ```ts * // Fetch zero or more PreOrders * const preOrders = await prisma.preOrder.findMany() * ``` */ get preOrder(): Prisma.PreOrderDelegate; /** * `prisma.preOrderStatusEvent`: Exposes CRUD operations for the **PreOrderStatusEvent** model. * Example usage: * ```ts * // Fetch zero or more PreOrderStatusEvents * const preOrderStatusEvents = await prisma.preOrderStatusEvent.findMany() * ``` */ get preOrderStatusEvent(): Prisma.PreOrderStatusEventDelegate; /** * `prisma.ledgerEntry`: Exposes CRUD operations for the **LedgerEntry** model. * Example usage: * ```ts * // Fetch zero or more LedgerEntries * const ledgerEntries = await prisma.ledgerEntry.findMany() * ``` */ get ledgerEntry(): Prisma.LedgerEntryDelegate; /** * `prisma.goldPriceQuote`: Exposes CRUD operations for the **GoldPriceQuote** model. * Example usage: * ```ts * // Fetch zero or more GoldPriceQuotes * const goldPriceQuotes = await prisma.goldPriceQuote.findMany() * ``` */ get goldPriceQuote(): Prisma.GoldPriceQuoteDelegate; /** * `prisma.walletBonus`: Exposes CRUD operations for the **WalletBonus** model. * Example usage: * ```ts * // Fetch zero or more WalletBonuses * const walletBonuses = await prisma.walletBonus.findMany() * ``` */ get walletBonus(): Prisma.WalletBonusDelegate; } export namespace Prisma { export import DMMF = runtime.DMMF export type PrismaPromise = $Public.PrismaPromise /** * Validator */ export import validator = runtime.Public.validator /** * Prisma Errors */ export import PrismaClientKnownRequestError = runtime.PrismaClientKnownRequestError export import PrismaClientUnknownRequestError = runtime.PrismaClientUnknownRequestError export import PrismaClientRustPanicError = runtime.PrismaClientRustPanicError export import PrismaClientInitializationError = runtime.PrismaClientInitializationError export import PrismaClientValidationError = runtime.PrismaClientValidationError export import NotFoundError = runtime.NotFoundError /** * Re-export of sql-template-tag */ export import sql = runtime.sqltag export import empty = runtime.empty export import join = runtime.join export import raw = runtime.raw export import Sql = runtime.Sql /** * Decimal.js */ export import Decimal = runtime.Decimal export type DecimalJsLike = runtime.DecimalJsLike /** * Metrics */ export type Metrics = runtime.Metrics export type Metric = runtime.Metric export type MetricHistogram = runtime.MetricHistogram export type MetricHistogramBucket = runtime.MetricHistogramBucket /** * Extensions */ export import Extension = $Extensions.UserArgs export import getExtensionContext = runtime.Extensions.getExtensionContext export import Args = $Public.Args export import Payload = $Public.Payload export import Result = $Public.Result export import Exact = $Public.Exact /** * Prisma Client JS version: 5.22.0 * Query Engine version: 605197351a3c8bdd595af2d2a9bc3025bca48ea2 */ export type PrismaVersion = { client: string } export const prismaVersion: PrismaVersion /** * Utility Types */ export import JsonObject = runtime.JsonObject export import JsonArray = runtime.JsonArray export import JsonValue = runtime.JsonValue export import InputJsonObject = runtime.InputJsonObject export import InputJsonArray = runtime.InputJsonArray export import InputJsonValue = runtime.InputJsonValue /** * Types of the values used to represent different kinds of `null` values when working with JSON fields. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ namespace NullTypes { /** * Type of `Prisma.DbNull`. * * You cannot use other instances of this class. Please use the `Prisma.DbNull` value. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ class DbNull { private DbNull: never private constructor() } /** * Type of `Prisma.JsonNull`. * * You cannot use other instances of this class. Please use the `Prisma.JsonNull` value. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ class JsonNull { private JsonNull: never private constructor() } /** * Type of `Prisma.AnyNull`. * * You cannot use other instances of this class. Please use the `Prisma.AnyNull` value. * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ class AnyNull { private AnyNull: never private constructor() } } /** * Helper for filtering JSON entries that have `null` on the database (empty on the db) * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ export const DbNull: NullTypes.DbNull /** * Helper for filtering JSON entries that have JSON `null` values (not empty on the db) * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ export const JsonNull: NullTypes.JsonNull /** * Helper for filtering JSON entries that are `Prisma.DbNull` or `Prisma.JsonNull` * * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field */ export const AnyNull: NullTypes.AnyNull type SelectAndInclude = { select: any include: any } type SelectAndOmit = { select: any omit: any } /** * Get the type of the value, that the Promise holds. */ export type PromiseType> = T extends PromiseLike ? U : T; /** * Get the return type of a function which returns a Promise. */ export type PromiseReturnType $Utils.JsPromise> = PromiseType> /** * From T, pick a set of properties whose keys are in the union K */ type Prisma__Pick = { [P in K]: T[P]; }; export type Enumerable = T | Array; export type RequiredKeys = { [K in keyof T]-?: {} extends Prisma__Pick ? never : K }[keyof T] export type TruthyKeys = keyof { [K in keyof T as T[K] extends false | undefined | null ? never : K]: K } export type TrueKeys = TruthyKeys>> /** * Subset * @desc From `T` pick properties that exist in `U`. Simple version of Intersection */ export type Subset = { [key in keyof T]: key extends keyof U ? T[key] : never; }; /** * SelectSubset * @desc From `T` pick properties that exist in `U`. Simple version of Intersection. * Additionally, it validates, if both select and include are present. If the case, it errors. */ export type SelectSubset = { [key in keyof T]: key extends keyof U ? T[key] : never } & (T extends SelectAndInclude ? 'Please either choose `select` or `include`.' : T extends SelectAndOmit ? 'Please either choose `select` or `omit`.' : {}) /** * Subset + Intersection * @desc From `T` pick properties that exist in `U` and intersect `K` */ export type SubsetIntersection = { [key in keyof T]: key extends keyof U ? T[key] : never } & K type Without = { [P in Exclude]?: never }; /** * XOR is needed to have a real mutually exclusive union type * https://stackoverflow.com/questions/42123407/does-typescript-support-mutually-exclusive-types */ type XOR = T extends object ? U extends object ? (Without & U) | (Without & T) : U : T /** * Is T a Record? */ type IsObject = T extends Array ? False : T extends Date ? False : T extends Uint8Array ? False : T extends BigInt ? False : T extends object ? True : False /** * If it's T[], return T */ export type UnEnumerate = T extends Array ? U : T /** * From ts-toolbelt */ type __Either = Omit & { // Merge all but K [P in K]: Prisma__Pick // With K possibilities }[K] type EitherStrict = Strict<__Either> type EitherLoose = ComputeRaw<__Either> type _Either< O extends object, K extends Key, strict extends Boolean > = { 1: EitherStrict 0: EitherLoose }[strict] type Either< O extends object, K extends Key, strict extends Boolean = 1 > = O extends unknown ? _Either : never export type Union = any type PatchUndefined = { [K in keyof O]: O[K] extends undefined ? At : O[K] } & {} /** Helper Types for "Merge" **/ export type IntersectOf = ( U extends unknown ? (k: U) => void : never ) extends (k: infer I) => void ? I : never export type Overwrite = { [K in keyof O]: K extends keyof O1 ? O1[K] : O[K]; } & {}; type _Merge = IntersectOf; }>>; type Key = string | number | symbol; type AtBasic = K extends keyof O ? O[K] : never; type AtStrict = O[K & keyof O]; type AtLoose = O extends unknown ? AtStrict : never; export type At = { 1: AtStrict; 0: AtLoose; }[strict]; export type ComputeRaw = A extends Function ? A : { [K in keyof A]: A[K]; } & {}; export type OptionalFlat = { [K in keyof O]?: O[K]; } & {}; type _Record = { [P in K]: T; }; // cause typescript not to expand types and preserve names type NoExpand = T extends unknown ? T : never; // this type assumes the passed object is entirely optional type AtLeast = NoExpand< O extends unknown ? | (K extends keyof O ? { [P in K]: O[P] } & O : O) | {[P in keyof O as P extends K ? K : never]-?: O[P]} & O : never>; type _Strict = U extends unknown ? U & OptionalFlat<_Record, keyof U>, never>> : never; export type Strict = ComputeRaw<_Strict>; /** End Helper Types for "Merge" **/ export type Merge = ComputeRaw<_Merge>>; /** A [[Boolean]] */ export type Boolean = True | False // /** // 1 // */ export type True = 1 /** 0 */ export type False = 0 export type Not = { 0: 1 1: 0 }[B] export type Extends = [A1] extends [never] ? 0 // anything `never` is false : A1 extends A2 ? 1 : 0 export type Has = Not< Extends, U1> > export type Or = { 0: { 0: 0 1: 1 } 1: { 0: 1 1: 1 } }[B1][B2] export type Keys = U extends unknown ? keyof U : never type Cast = A extends B ? A : B; export const type: unique symbol; /** * Used by group by */ export type GetScalarType = O extends object ? { [P in keyof T]: P extends keyof O ? O[P] : never } : never type FieldPaths< T, U = Omit > = IsObject extends True ? U : T type GetHavingFields = { [K in keyof T]: Or< Or, Extends<'AND', K>>, Extends<'NOT', K> > extends True ? // infer is only needed to not hit TS limit // based on the brilliant idea of Pierre-Antoine Mills // https://github.com/microsoft/TypeScript/issues/30188#issuecomment-478938437 T[K] extends infer TK ? GetHavingFields extends object ? Merge> : never> : never : {} extends FieldPaths ? never : K }[keyof T] /** * Convert tuple to union */ type _TupleToUnion = T extends (infer E)[] ? E : never type TupleToUnion = _TupleToUnion type MaybeTupleToUnion = T extends any[] ? TupleToUnion : T /** * Like `Pick`, but additionally can also accept an array of keys */ type PickEnumerable | keyof T> = Prisma__Pick> /** * Exclude all keys with underscores */ type ExcludeUnderscoreKeys = T extends `_${string}` ? never : T export type FieldRef = runtime.FieldRef type FieldRefInputType = Model extends never ? never : FieldRef export const ModelName: { City: 'City', AdminUser: 'AdminUser', Customer: 'Customer', CustomerAddress: 'CustomerAddress', Branch: 'Branch', Workshop: 'Workshop', Category: 'Category', Brand: 'Brand', Collection: 'Collection', CollectionProduct: 'CollectionProduct', Product: 'Product', ProductImage: 'ProductImage', ProductVariant: 'ProductVariant', Order: 'Order', OrderItem: 'OrderItem', OrderStatusEvent: 'OrderStatusEvent', PreOrder: 'PreOrder', PreOrderStatusEvent: 'PreOrderStatusEvent', LedgerEntry: 'LedgerEntry', GoldPriceQuote: 'GoldPriceQuote', WalletBonus: 'WalletBonus' }; export type ModelName = (typeof ModelName)[keyof typeof ModelName] export type Datasources = { db?: Datasource } interface TypeMapCb extends $Utils.Fn<{extArgs: $Extensions.InternalArgs, clientOptions: PrismaClientOptions }, $Utils.Record> { returns: Prisma.TypeMap } export type TypeMap = { meta: { modelProps: "city" | "adminUser" | "customer" | "customerAddress" | "branch" | "workshop" | "category" | "brand" | "collection" | "collectionProduct" | "product" | "productImage" | "productVariant" | "order" | "orderItem" | "orderStatusEvent" | "preOrder" | "preOrderStatusEvent" | "ledgerEntry" | "goldPriceQuote" | "walletBonus" txIsolationLevel: Prisma.TransactionIsolationLevel } model: { City: { payload: Prisma.$CityPayload fields: Prisma.CityFieldRefs operations: { findUnique: { args: Prisma.CityFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.CityFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.CityFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.CityFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.CityFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.CityCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.CityCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.CityCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.CityDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.CityUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.CityDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.CityUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.CityUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.CityAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.CityGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.CityCountArgs result: $Utils.Optional | number } } } AdminUser: { payload: Prisma.$AdminUserPayload fields: Prisma.AdminUserFieldRefs operations: { findUnique: { args: Prisma.AdminUserFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.AdminUserFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.AdminUserFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.AdminUserFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.AdminUserFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.AdminUserCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.AdminUserCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.AdminUserCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.AdminUserDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.AdminUserUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.AdminUserDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.AdminUserUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.AdminUserUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.AdminUserAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.AdminUserGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.AdminUserCountArgs result: $Utils.Optional | number } } } Customer: { payload: Prisma.$CustomerPayload fields: Prisma.CustomerFieldRefs operations: { findUnique: { args: Prisma.CustomerFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.CustomerFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.CustomerFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.CustomerFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.CustomerFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.CustomerCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.CustomerCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.CustomerCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.CustomerDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.CustomerUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.CustomerDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.CustomerUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.CustomerUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.CustomerAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.CustomerGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.CustomerCountArgs result: $Utils.Optional | number } } } CustomerAddress: { payload: Prisma.$CustomerAddressPayload fields: Prisma.CustomerAddressFieldRefs operations: { findUnique: { args: Prisma.CustomerAddressFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.CustomerAddressFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.CustomerAddressFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.CustomerAddressFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.CustomerAddressFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.CustomerAddressCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.CustomerAddressCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.CustomerAddressCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.CustomerAddressDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.CustomerAddressUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.CustomerAddressDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.CustomerAddressUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.CustomerAddressUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.CustomerAddressAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.CustomerAddressGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.CustomerAddressCountArgs result: $Utils.Optional | number } } } Branch: { payload: Prisma.$BranchPayload fields: Prisma.BranchFieldRefs operations: { findUnique: { args: Prisma.BranchFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.BranchFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.BranchFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.BranchFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.BranchFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.BranchCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.BranchCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.BranchCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.BranchDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.BranchUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.BranchDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.BranchUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.BranchUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.BranchAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.BranchGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.BranchCountArgs result: $Utils.Optional | number } } } Workshop: { payload: Prisma.$WorkshopPayload fields: Prisma.WorkshopFieldRefs operations: { findUnique: { args: Prisma.WorkshopFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.WorkshopFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.WorkshopFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.WorkshopFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.WorkshopFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.WorkshopCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.WorkshopCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.WorkshopCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.WorkshopDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.WorkshopUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.WorkshopDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.WorkshopUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.WorkshopUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.WorkshopAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.WorkshopGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.WorkshopCountArgs result: $Utils.Optional | number } } } Category: { payload: Prisma.$CategoryPayload fields: Prisma.CategoryFieldRefs operations: { findUnique: { args: Prisma.CategoryFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.CategoryFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.CategoryFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.CategoryFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.CategoryFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.CategoryCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.CategoryCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.CategoryCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.CategoryDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.CategoryUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.CategoryDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.CategoryUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.CategoryUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.CategoryAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.CategoryGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.CategoryCountArgs result: $Utils.Optional | number } } } Brand: { payload: Prisma.$BrandPayload fields: Prisma.BrandFieldRefs operations: { findUnique: { args: Prisma.BrandFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.BrandFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.BrandFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.BrandFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.BrandFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.BrandCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.BrandCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.BrandCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.BrandDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.BrandUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.BrandDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.BrandUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.BrandUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.BrandAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.BrandGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.BrandCountArgs result: $Utils.Optional | number } } } Collection: { payload: Prisma.$CollectionPayload fields: Prisma.CollectionFieldRefs operations: { findUnique: { args: Prisma.CollectionFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.CollectionFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.CollectionFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.CollectionFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.CollectionFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.CollectionCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.CollectionCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.CollectionCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.CollectionDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.CollectionUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.CollectionDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.CollectionUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.CollectionUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.CollectionAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.CollectionGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.CollectionCountArgs result: $Utils.Optional | number } } } CollectionProduct: { payload: Prisma.$CollectionProductPayload fields: Prisma.CollectionProductFieldRefs operations: { findUnique: { args: Prisma.CollectionProductFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.CollectionProductFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.CollectionProductFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.CollectionProductFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.CollectionProductFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.CollectionProductCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.CollectionProductCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.CollectionProductCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.CollectionProductDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.CollectionProductUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.CollectionProductDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.CollectionProductUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.CollectionProductUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.CollectionProductAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.CollectionProductGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.CollectionProductCountArgs result: $Utils.Optional | number } } } Product: { payload: Prisma.$ProductPayload fields: Prisma.ProductFieldRefs operations: { findUnique: { args: Prisma.ProductFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.ProductFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.ProductFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.ProductFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.ProductFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.ProductCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.ProductCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.ProductCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.ProductDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.ProductUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.ProductDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.ProductUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.ProductUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.ProductAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.ProductGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.ProductCountArgs result: $Utils.Optional | number } } } ProductImage: { payload: Prisma.$ProductImagePayload fields: Prisma.ProductImageFieldRefs operations: { findUnique: { args: Prisma.ProductImageFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.ProductImageFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.ProductImageFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.ProductImageFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.ProductImageFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.ProductImageCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.ProductImageCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.ProductImageCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.ProductImageDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.ProductImageUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.ProductImageDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.ProductImageUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.ProductImageUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.ProductImageAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.ProductImageGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.ProductImageCountArgs result: $Utils.Optional | number } } } ProductVariant: { payload: Prisma.$ProductVariantPayload fields: Prisma.ProductVariantFieldRefs operations: { findUnique: { args: Prisma.ProductVariantFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.ProductVariantFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.ProductVariantFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.ProductVariantFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.ProductVariantFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.ProductVariantCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.ProductVariantCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.ProductVariantCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.ProductVariantDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.ProductVariantUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.ProductVariantDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.ProductVariantUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.ProductVariantUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.ProductVariantAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.ProductVariantGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.ProductVariantCountArgs result: $Utils.Optional | number } } } Order: { payload: Prisma.$OrderPayload fields: Prisma.OrderFieldRefs operations: { findUnique: { args: Prisma.OrderFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.OrderFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.OrderFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.OrderFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.OrderFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.OrderCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.OrderCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.OrderCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.OrderDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.OrderUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.OrderDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.OrderUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.OrderUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.OrderAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.OrderGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.OrderCountArgs result: $Utils.Optional | number } } } OrderItem: { payload: Prisma.$OrderItemPayload fields: Prisma.OrderItemFieldRefs operations: { findUnique: { args: Prisma.OrderItemFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.OrderItemFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.OrderItemFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.OrderItemFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.OrderItemFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.OrderItemCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.OrderItemCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.OrderItemCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.OrderItemDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.OrderItemUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.OrderItemDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.OrderItemUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.OrderItemUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.OrderItemAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.OrderItemGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.OrderItemCountArgs result: $Utils.Optional | number } } } OrderStatusEvent: { payload: Prisma.$OrderStatusEventPayload fields: Prisma.OrderStatusEventFieldRefs operations: { findUnique: { args: Prisma.OrderStatusEventFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.OrderStatusEventFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.OrderStatusEventFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.OrderStatusEventFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.OrderStatusEventFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.OrderStatusEventCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.OrderStatusEventCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.OrderStatusEventCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.OrderStatusEventDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.OrderStatusEventUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.OrderStatusEventDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.OrderStatusEventUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.OrderStatusEventUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.OrderStatusEventAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.OrderStatusEventGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.OrderStatusEventCountArgs result: $Utils.Optional | number } } } PreOrder: { payload: Prisma.$PreOrderPayload fields: Prisma.PreOrderFieldRefs operations: { findUnique: { args: Prisma.PreOrderFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.PreOrderFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.PreOrderFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.PreOrderFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.PreOrderFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.PreOrderCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.PreOrderCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.PreOrderCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.PreOrderDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.PreOrderUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.PreOrderDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.PreOrderUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.PreOrderUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.PreOrderAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.PreOrderGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.PreOrderCountArgs result: $Utils.Optional | number } } } PreOrderStatusEvent: { payload: Prisma.$PreOrderStatusEventPayload fields: Prisma.PreOrderStatusEventFieldRefs operations: { findUnique: { args: Prisma.PreOrderStatusEventFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.PreOrderStatusEventFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.PreOrderStatusEventFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.PreOrderStatusEventFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.PreOrderStatusEventFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.PreOrderStatusEventCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.PreOrderStatusEventCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.PreOrderStatusEventCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.PreOrderStatusEventDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.PreOrderStatusEventUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.PreOrderStatusEventDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.PreOrderStatusEventUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.PreOrderStatusEventUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.PreOrderStatusEventAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.PreOrderStatusEventGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.PreOrderStatusEventCountArgs result: $Utils.Optional | number } } } LedgerEntry: { payload: Prisma.$LedgerEntryPayload fields: Prisma.LedgerEntryFieldRefs operations: { findUnique: { args: Prisma.LedgerEntryFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.LedgerEntryFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.LedgerEntryFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.LedgerEntryFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.LedgerEntryFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.LedgerEntryCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.LedgerEntryCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.LedgerEntryCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.LedgerEntryDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.LedgerEntryUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.LedgerEntryDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.LedgerEntryUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.LedgerEntryUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.LedgerEntryAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.LedgerEntryGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.LedgerEntryCountArgs result: $Utils.Optional | number } } } GoldPriceQuote: { payload: Prisma.$GoldPriceQuotePayload fields: Prisma.GoldPriceQuoteFieldRefs operations: { findUnique: { args: Prisma.GoldPriceQuoteFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.GoldPriceQuoteFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.GoldPriceQuoteFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.GoldPriceQuoteFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.GoldPriceQuoteFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.GoldPriceQuoteCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.GoldPriceQuoteCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.GoldPriceQuoteCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.GoldPriceQuoteDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.GoldPriceQuoteUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.GoldPriceQuoteDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.GoldPriceQuoteUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.GoldPriceQuoteUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.GoldPriceQuoteAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.GoldPriceQuoteGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.GoldPriceQuoteCountArgs result: $Utils.Optional | number } } } WalletBonus: { payload: Prisma.$WalletBonusPayload fields: Prisma.WalletBonusFieldRefs operations: { findUnique: { args: Prisma.WalletBonusFindUniqueArgs result: $Utils.PayloadToResult | null } findUniqueOrThrow: { args: Prisma.WalletBonusFindUniqueOrThrowArgs result: $Utils.PayloadToResult } findFirst: { args: Prisma.WalletBonusFindFirstArgs result: $Utils.PayloadToResult | null } findFirstOrThrow: { args: Prisma.WalletBonusFindFirstOrThrowArgs result: $Utils.PayloadToResult } findMany: { args: Prisma.WalletBonusFindManyArgs result: $Utils.PayloadToResult[] } create: { args: Prisma.WalletBonusCreateArgs result: $Utils.PayloadToResult } createMany: { args: Prisma.WalletBonusCreateManyArgs result: BatchPayload } createManyAndReturn: { args: Prisma.WalletBonusCreateManyAndReturnArgs result: $Utils.PayloadToResult[] } delete: { args: Prisma.WalletBonusDeleteArgs result: $Utils.PayloadToResult } update: { args: Prisma.WalletBonusUpdateArgs result: $Utils.PayloadToResult } deleteMany: { args: Prisma.WalletBonusDeleteManyArgs result: BatchPayload } updateMany: { args: Prisma.WalletBonusUpdateManyArgs result: BatchPayload } upsert: { args: Prisma.WalletBonusUpsertArgs result: $Utils.PayloadToResult } aggregate: { args: Prisma.WalletBonusAggregateArgs result: $Utils.Optional } groupBy: { args: Prisma.WalletBonusGroupByArgs result: $Utils.Optional[] } count: { args: Prisma.WalletBonusCountArgs result: $Utils.Optional | number } } } } } & { other: { payload: any operations: { $executeRaw: { args: [query: TemplateStringsArray | Prisma.Sql, ...values: any[]], result: any } $executeRawUnsafe: { args: [query: string, ...values: any[]], result: any } $queryRaw: { args: [query: TemplateStringsArray | Prisma.Sql, ...values: any[]], result: any } $queryRawUnsafe: { args: [query: string, ...values: any[]], result: any } } } } export const defineExtension: $Extensions.ExtendsHook<"define", Prisma.TypeMapCb, $Extensions.DefaultArgs> export type DefaultPrismaClient = PrismaClient export type ErrorFormat = 'pretty' | 'colorless' | 'minimal' export interface PrismaClientOptions { /** * Overwrites the datasource url from your schema.prisma file */ datasources?: Datasources /** * Overwrites the datasource url from your schema.prisma file */ datasourceUrl?: string /** * @default "colorless" */ errorFormat?: ErrorFormat /** * @example * ``` * // Defaults to stdout * log: ['query', 'info', 'warn', 'error'] * * // Emit as events * log: [ * { emit: 'stdout', level: 'query' }, * { emit: 'stdout', level: 'info' }, * { emit: 'stdout', level: 'warn' } * { emit: 'stdout', level: 'error' } * ] * ``` * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/logging#the-log-option). */ log?: (LogLevel | LogDefinition)[] /** * The default values for transactionOptions * maxWait ?= 2000 * timeout ?= 5000 */ transactionOptions?: { maxWait?: number timeout?: number isolationLevel?: Prisma.TransactionIsolationLevel } } /* Types for Logging */ export type LogLevel = 'info' | 'query' | 'warn' | 'error' export type LogDefinition = { level: LogLevel emit: 'stdout' | 'event' } export type GetLogType = T extends LogDefinition ? T['emit'] extends 'event' ? T['level'] : never : never export type GetEvents = T extends Array ? GetLogType | GetLogType | GetLogType | GetLogType : never export type QueryEvent = { timestamp: Date query: string params: string duration: number target: string } export type LogEvent = { timestamp: Date message: string target: string } /* End Types for Logging */ export type PrismaAction = | 'findUnique' | 'findUniqueOrThrow' | 'findMany' | 'findFirst' | 'findFirstOrThrow' | 'create' | 'createMany' | 'createManyAndReturn' | 'update' | 'updateMany' | 'upsert' | 'delete' | 'deleteMany' | 'executeRaw' | 'queryRaw' | 'aggregate' | 'count' | 'runCommandRaw' | 'findRaw' | 'groupBy' /** * These options are being passed into the middleware as "params" */ export type MiddlewareParams = { model?: ModelName action: PrismaAction args: any dataPath: string[] runInTransaction: boolean } /** * The `T` type makes sure, that the `return proceed` is not forgotten in the middleware implementation */ export type Middleware = ( params: MiddlewareParams, next: (params: MiddlewareParams) => $Utils.JsPromise, ) => $Utils.JsPromise // tested in getLogLevel.test.ts export function getLogLevel(log: Array): LogLevel | undefined; /** * `PrismaClient` proxy available in interactive transactions. */ export type TransactionClient = Omit export type Datasource = { url?: string } /** * Count Types */ /** * Count Type CityCountOutputType */ export type CityCountOutputType = { customers: number addresses: number branches: number preOrders: number } export type CityCountOutputTypeSelect = { customers?: boolean | CityCountOutputTypeCountCustomersArgs addresses?: boolean | CityCountOutputTypeCountAddressesArgs branches?: boolean | CityCountOutputTypeCountBranchesArgs preOrders?: boolean | CityCountOutputTypeCountPreOrdersArgs } // Custom InputTypes /** * CityCountOutputType without action */ export type CityCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the CityCountOutputType */ select?: CityCountOutputTypeSelect | null } /** * CityCountOutputType without action */ export type CityCountOutputTypeCountCustomersArgs = { where?: CustomerWhereInput } /** * CityCountOutputType without action */ export type CityCountOutputTypeCountAddressesArgs = { where?: CustomerAddressWhereInput } /** * CityCountOutputType without action */ export type CityCountOutputTypeCountBranchesArgs = { where?: BranchWhereInput } /** * CityCountOutputType without action */ export type CityCountOutputTypeCountPreOrdersArgs = { where?: PreOrderWhereInput } /** * Count Type AdminUserCountOutputType */ export type AdminUserCountOutputType = { referredCustomers: number postedLedgerEntries: number orderStatusEvents: number preOrderStatusEvents: number } export type AdminUserCountOutputTypeSelect = { referredCustomers?: boolean | AdminUserCountOutputTypeCountReferredCustomersArgs postedLedgerEntries?: boolean | AdminUserCountOutputTypeCountPostedLedgerEntriesArgs orderStatusEvents?: boolean | AdminUserCountOutputTypeCountOrderStatusEventsArgs preOrderStatusEvents?: boolean | AdminUserCountOutputTypeCountPreOrderStatusEventsArgs } // Custom InputTypes /** * AdminUserCountOutputType without action */ export type AdminUserCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the AdminUserCountOutputType */ select?: AdminUserCountOutputTypeSelect | null } /** * AdminUserCountOutputType without action */ export type AdminUserCountOutputTypeCountReferredCustomersArgs = { where?: CustomerWhereInput } /** * AdminUserCountOutputType without action */ export type AdminUserCountOutputTypeCountPostedLedgerEntriesArgs = { where?: LedgerEntryWhereInput } /** * AdminUserCountOutputType without action */ export type AdminUserCountOutputTypeCountOrderStatusEventsArgs = { where?: OrderStatusEventWhereInput } /** * AdminUserCountOutputType without action */ export type AdminUserCountOutputTypeCountPreOrderStatusEventsArgs = { where?: PreOrderStatusEventWhereInput } /** * Count Type CustomerCountOutputType */ export type CustomerCountOutputType = { addresses: number orders: number preOrders: number ledgerEntries: number walletBonuses: number } export type CustomerCountOutputTypeSelect = { addresses?: boolean | CustomerCountOutputTypeCountAddressesArgs orders?: boolean | CustomerCountOutputTypeCountOrdersArgs preOrders?: boolean | CustomerCountOutputTypeCountPreOrdersArgs ledgerEntries?: boolean | CustomerCountOutputTypeCountLedgerEntriesArgs walletBonuses?: boolean | CustomerCountOutputTypeCountWalletBonusesArgs } // Custom InputTypes /** * CustomerCountOutputType without action */ export type CustomerCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the CustomerCountOutputType */ select?: CustomerCountOutputTypeSelect | null } /** * CustomerCountOutputType without action */ export type CustomerCountOutputTypeCountAddressesArgs = { where?: CustomerAddressWhereInput } /** * CustomerCountOutputType without action */ export type CustomerCountOutputTypeCountOrdersArgs = { where?: OrderWhereInput } /** * CustomerCountOutputType without action */ export type CustomerCountOutputTypeCountPreOrdersArgs = { where?: PreOrderWhereInput } /** * CustomerCountOutputType without action */ export type CustomerCountOutputTypeCountLedgerEntriesArgs = { where?: LedgerEntryWhereInput } /** * CustomerCountOutputType without action */ export type CustomerCountOutputTypeCountWalletBonusesArgs = { where?: WalletBonusWhereInput } /** * Count Type BranchCountOutputType */ export type BranchCountOutputType = { adminUsers: number orders: number } export type BranchCountOutputTypeSelect = { adminUsers?: boolean | BranchCountOutputTypeCountAdminUsersArgs orders?: boolean | BranchCountOutputTypeCountOrdersArgs } // Custom InputTypes /** * BranchCountOutputType without action */ export type BranchCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the BranchCountOutputType */ select?: BranchCountOutputTypeSelect | null } /** * BranchCountOutputType without action */ export type BranchCountOutputTypeCountAdminUsersArgs = { where?: AdminUserWhereInput } /** * BranchCountOutputType without action */ export type BranchCountOutputTypeCountOrdersArgs = { where?: OrderWhereInput } /** * Count Type WorkshopCountOutputType */ export type WorkshopCountOutputType = { preOrders: number } export type WorkshopCountOutputTypeSelect = { preOrders?: boolean | WorkshopCountOutputTypeCountPreOrdersArgs } // Custom InputTypes /** * WorkshopCountOutputType without action */ export type WorkshopCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the WorkshopCountOutputType */ select?: WorkshopCountOutputTypeSelect | null } /** * WorkshopCountOutputType without action */ export type WorkshopCountOutputTypeCountPreOrdersArgs = { where?: PreOrderWhereInput } /** * Count Type CategoryCountOutputType */ export type CategoryCountOutputType = { children: number products: number } export type CategoryCountOutputTypeSelect = { children?: boolean | CategoryCountOutputTypeCountChildrenArgs products?: boolean | CategoryCountOutputTypeCountProductsArgs } // Custom InputTypes /** * CategoryCountOutputType without action */ export type CategoryCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the CategoryCountOutputType */ select?: CategoryCountOutputTypeSelect | null } /** * CategoryCountOutputType without action */ export type CategoryCountOutputTypeCountChildrenArgs = { where?: CategoryWhereInput } /** * CategoryCountOutputType without action */ export type CategoryCountOutputTypeCountProductsArgs = { where?: ProductWhereInput } /** * Count Type BrandCountOutputType */ export type BrandCountOutputType = { products: number } export type BrandCountOutputTypeSelect = { products?: boolean | BrandCountOutputTypeCountProductsArgs } // Custom InputTypes /** * BrandCountOutputType without action */ export type BrandCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the BrandCountOutputType */ select?: BrandCountOutputTypeSelect | null } /** * BrandCountOutputType without action */ export type BrandCountOutputTypeCountProductsArgs = { where?: ProductWhereInput } /** * Count Type CollectionCountOutputType */ export type CollectionCountOutputType = { products: number } export type CollectionCountOutputTypeSelect = { products?: boolean | CollectionCountOutputTypeCountProductsArgs } // Custom InputTypes /** * CollectionCountOutputType without action */ export type CollectionCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the CollectionCountOutputType */ select?: CollectionCountOutputTypeSelect | null } /** * CollectionCountOutputType without action */ export type CollectionCountOutputTypeCountProductsArgs = { where?: CollectionProductWhereInput } /** * Count Type ProductCountOutputType */ export type ProductCountOutputType = { variants: number images: number collections: number } export type ProductCountOutputTypeSelect = { variants?: boolean | ProductCountOutputTypeCountVariantsArgs images?: boolean | ProductCountOutputTypeCountImagesArgs collections?: boolean | ProductCountOutputTypeCountCollectionsArgs } // Custom InputTypes /** * ProductCountOutputType without action */ export type ProductCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the ProductCountOutputType */ select?: ProductCountOutputTypeSelect | null } /** * ProductCountOutputType without action */ export type ProductCountOutputTypeCountVariantsArgs = { where?: ProductVariantWhereInput } /** * ProductCountOutputType without action */ export type ProductCountOutputTypeCountImagesArgs = { where?: ProductImageWhereInput } /** * ProductCountOutputType without action */ export type ProductCountOutputTypeCountCollectionsArgs = { where?: CollectionProductWhereInput } /** * Count Type ProductVariantCountOutputType */ export type ProductVariantCountOutputType = { orderItems: number } export type ProductVariantCountOutputTypeSelect = { orderItems?: boolean | ProductVariantCountOutputTypeCountOrderItemsArgs } // Custom InputTypes /** * ProductVariantCountOutputType without action */ export type ProductVariantCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the ProductVariantCountOutputType */ select?: ProductVariantCountOutputTypeSelect | null } /** * ProductVariantCountOutputType without action */ export type ProductVariantCountOutputTypeCountOrderItemsArgs = { where?: OrderItemWhereInput } /** * Count Type OrderCountOutputType */ export type OrderCountOutputType = { items: number statusEvents: number ledgerEntries: number } export type OrderCountOutputTypeSelect = { items?: boolean | OrderCountOutputTypeCountItemsArgs statusEvents?: boolean | OrderCountOutputTypeCountStatusEventsArgs ledgerEntries?: boolean | OrderCountOutputTypeCountLedgerEntriesArgs } // Custom InputTypes /** * OrderCountOutputType without action */ export type OrderCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the OrderCountOutputType */ select?: OrderCountOutputTypeSelect | null } /** * OrderCountOutputType without action */ export type OrderCountOutputTypeCountItemsArgs = { where?: OrderItemWhereInput } /** * OrderCountOutputType without action */ export type OrderCountOutputTypeCountStatusEventsArgs = { where?: OrderStatusEventWhereInput } /** * OrderCountOutputType without action */ export type OrderCountOutputTypeCountLedgerEntriesArgs = { where?: LedgerEntryWhereInput } /** * Count Type PreOrderCountOutputType */ export type PreOrderCountOutputType = { statusEvents: number } export type PreOrderCountOutputTypeSelect = { statusEvents?: boolean | PreOrderCountOutputTypeCountStatusEventsArgs } // Custom InputTypes /** * PreOrderCountOutputType without action */ export type PreOrderCountOutputTypeDefaultArgs = { /** * Select specific fields to fetch from the PreOrderCountOutputType */ select?: PreOrderCountOutputTypeSelect | null } /** * PreOrderCountOutputType without action */ export type PreOrderCountOutputTypeCountStatusEventsArgs = { where?: PreOrderStatusEventWhereInput } /** * Models */ /** * Model City */ export type AggregateCity = { _count: CityCountAggregateOutputType | null _min: CityMinAggregateOutputType | null _max: CityMaxAggregateOutputType | null } export type CityMinAggregateOutputType = { id: string | null name: string | null province: string | null } export type CityMaxAggregateOutputType = { id: string | null name: string | null province: string | null } export type CityCountAggregateOutputType = { id: number name: number province: number _all: number } export type CityMinAggregateInputType = { id?: true name?: true province?: true } export type CityMaxAggregateInputType = { id?: true name?: true province?: true } export type CityCountAggregateInputType = { id?: true name?: true province?: true _all?: true } export type CityAggregateArgs = { /** * Filter which City to aggregate. */ where?: CityWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Cities to fetch. */ orderBy?: CityOrderByWithRelationInput | CityOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: CityWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Cities from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Cities. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Cities **/ _count?: true | CityCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: CityMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: CityMaxAggregateInputType } export type GetCityAggregateType = { [P in keyof T & keyof AggregateCity]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type CityGroupByArgs = { where?: CityWhereInput orderBy?: CityOrderByWithAggregationInput | CityOrderByWithAggregationInput[] by: CityScalarFieldEnum[] | CityScalarFieldEnum having?: CityScalarWhereWithAggregatesInput take?: number skip?: number _count?: CityCountAggregateInputType | true _min?: CityMinAggregateInputType _max?: CityMaxAggregateInputType } export type CityGroupByOutputType = { id: string name: string province: string | null _count: CityCountAggregateOutputType | null _min: CityMinAggregateOutputType | null _max: CityMaxAggregateOutputType | null } type GetCityGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof CityGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type CitySelect = $Extensions.GetSelect<{ id?: boolean name?: boolean province?: boolean customers?: boolean | City$customersArgs addresses?: boolean | City$addressesArgs branches?: boolean | City$branchesArgs preOrders?: boolean | City$preOrdersArgs _count?: boolean | CityCountOutputTypeDefaultArgs }, ExtArgs["result"]["city"]> export type CitySelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean name?: boolean province?: boolean }, ExtArgs["result"]["city"]> export type CitySelectScalar = { id?: boolean name?: boolean province?: boolean } export type CityInclude = { customers?: boolean | City$customersArgs addresses?: boolean | City$addressesArgs branches?: boolean | City$branchesArgs preOrders?: boolean | City$preOrdersArgs _count?: boolean | CityCountOutputTypeDefaultArgs } export type CityIncludeCreateManyAndReturn = {} export type $CityPayload = { name: "City" objects: { customers: Prisma.$CustomerPayload[] addresses: Prisma.$CustomerAddressPayload[] branches: Prisma.$BranchPayload[] preOrders: Prisma.$PreOrderPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string name: string province: string | null }, ExtArgs["result"]["city"]> composites: {} } type CityGetPayload = $Result.GetResult type CityCountArgs = Omit & { select?: CityCountAggregateInputType | true } export interface CityDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['City'], meta: { name: 'City' } } /** * Find zero or one City that matches the filter. * @param {CityFindUniqueArgs} args - Arguments to find a City * @example * // Get one City * const city = await prisma.city.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__CityClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one City that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {CityFindUniqueOrThrowArgs} args - Arguments to find a City * @example * // Get one City * const city = await prisma.city.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__CityClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first City that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CityFindFirstArgs} args - Arguments to find a City * @example * // Get one City * const city = await prisma.city.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__CityClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first City that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CityFindFirstOrThrowArgs} args - Arguments to find a City * @example * // Get one City * const city = await prisma.city.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__CityClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Cities that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CityFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Cities * const cities = await prisma.city.findMany() * * // Get first 10 Cities * const cities = await prisma.city.findMany({ take: 10 }) * * // Only select the `id` * const cityWithIdOnly = await prisma.city.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a City. * @param {CityCreateArgs} args - Arguments to create a City. * @example * // Create one City * const City = await prisma.city.create({ * data: { * // ... data to create a City * } * }) * */ create(args: SelectSubset>): Prisma__CityClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Cities. * @param {CityCreateManyArgs} args - Arguments to create many Cities. * @example * // Create many Cities * const city = await prisma.city.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Cities and returns the data saved in the database. * @param {CityCreateManyAndReturnArgs} args - Arguments to create many Cities. * @example * // Create many Cities * const city = await prisma.city.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Cities and only return the `id` * const cityWithIdOnly = await prisma.city.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a City. * @param {CityDeleteArgs} args - Arguments to delete one City. * @example * // Delete one City * const City = await prisma.city.delete({ * where: { * // ... filter to delete one City * } * }) * */ delete(args: SelectSubset>): Prisma__CityClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one City. * @param {CityUpdateArgs} args - Arguments to update one City. * @example * // Update one City * const city = await prisma.city.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__CityClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Cities. * @param {CityDeleteManyArgs} args - Arguments to filter Cities to delete. * @example * // Delete a few Cities * const { count } = await prisma.city.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Cities. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CityUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Cities * const city = await prisma.city.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one City. * @param {CityUpsertArgs} args - Arguments to update or create a City. * @example * // Update or create a City * const city = await prisma.city.upsert({ * create: { * // ... data to create a City * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the City we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__CityClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Cities. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CityCountArgs} args - Arguments to filter Cities to count. * @example * // Count the number of Cities * const count = await prisma.city.count({ * where: { * // ... the filter for the Cities we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a City. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CityAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by City. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CityGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends CityGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: CityGroupByArgs['orderBy'] } : { orderBy?: CityGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCityGroupByPayload : Prisma.PrismaPromise /** * Fields of the City model */ readonly fields: CityFieldRefs; } /** * The delegate class that acts as a "Promise-like" for City. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__CityClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" customers = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> addresses = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> branches = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> preOrders = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the City model */ interface CityFieldRefs { readonly id: FieldRef<"City", 'String'> readonly name: FieldRef<"City", 'String'> readonly province: FieldRef<"City", 'String'> } // Custom InputTypes /** * City findUnique */ export type CityFindUniqueArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * Filter, which City to fetch. */ where: CityWhereUniqueInput } /** * City findUniqueOrThrow */ export type CityFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * Filter, which City to fetch. */ where: CityWhereUniqueInput } /** * City findFirst */ export type CityFindFirstArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * Filter, which City to fetch. */ where?: CityWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Cities to fetch. */ orderBy?: CityOrderByWithRelationInput | CityOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Cities. */ cursor?: CityWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Cities from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Cities. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Cities. */ distinct?: CityScalarFieldEnum | CityScalarFieldEnum[] } /** * City findFirstOrThrow */ export type CityFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * Filter, which City to fetch. */ where?: CityWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Cities to fetch. */ orderBy?: CityOrderByWithRelationInput | CityOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Cities. */ cursor?: CityWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Cities from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Cities. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Cities. */ distinct?: CityScalarFieldEnum | CityScalarFieldEnum[] } /** * City findMany */ export type CityFindManyArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * Filter, which Cities to fetch. */ where?: CityWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Cities to fetch. */ orderBy?: CityOrderByWithRelationInput | CityOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Cities. */ cursor?: CityWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Cities from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Cities. */ skip?: number distinct?: CityScalarFieldEnum | CityScalarFieldEnum[] } /** * City create */ export type CityCreateArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * The data needed to create a City. */ data: XOR } /** * City createMany */ export type CityCreateManyArgs = { /** * The data used to create many Cities. */ data: CityCreateManyInput | CityCreateManyInput[] skipDuplicates?: boolean } /** * City createManyAndReturn */ export type CityCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelectCreateManyAndReturn | null /** * The data used to create many Cities. */ data: CityCreateManyInput | CityCreateManyInput[] skipDuplicates?: boolean } /** * City update */ export type CityUpdateArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * The data needed to update a City. */ data: XOR /** * Choose, which City to update. */ where: CityWhereUniqueInput } /** * City updateMany */ export type CityUpdateManyArgs = { /** * The data used to update Cities. */ data: XOR /** * Filter which Cities to update */ where?: CityWhereInput } /** * City upsert */ export type CityUpsertArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * The filter to search for the City to update in case it exists. */ where: CityWhereUniqueInput /** * In case the City found by the `where` argument doesn't exist, create a new City with this data. */ create: XOR /** * In case the City was found with the provided `where` argument, update it with this data. */ update: XOR } /** * City delete */ export type CityDeleteArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null /** * Filter which City to delete. */ where: CityWhereUniqueInput } /** * City deleteMany */ export type CityDeleteManyArgs = { /** * Filter which Cities to delete */ where?: CityWhereInput } /** * City.customers */ export type City$customersArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null where?: CustomerWhereInput orderBy?: CustomerOrderByWithRelationInput | CustomerOrderByWithRelationInput[] cursor?: CustomerWhereUniqueInput take?: number skip?: number distinct?: CustomerScalarFieldEnum | CustomerScalarFieldEnum[] } /** * City.addresses */ export type City$addressesArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null where?: CustomerAddressWhereInput orderBy?: CustomerAddressOrderByWithRelationInput | CustomerAddressOrderByWithRelationInput[] cursor?: CustomerAddressWhereUniqueInput take?: number skip?: number distinct?: CustomerAddressScalarFieldEnum | CustomerAddressScalarFieldEnum[] } /** * City.branches */ export type City$branchesArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null where?: BranchWhereInput orderBy?: BranchOrderByWithRelationInput | BranchOrderByWithRelationInput[] cursor?: BranchWhereUniqueInput take?: number skip?: number distinct?: BranchScalarFieldEnum | BranchScalarFieldEnum[] } /** * City.preOrders */ export type City$preOrdersArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null where?: PreOrderWhereInput orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[] cursor?: PreOrderWhereUniqueInput take?: number skip?: number distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[] } /** * City without action */ export type CityDefaultArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null } /** * Model AdminUser */ export type AggregateAdminUser = { _count: AdminUserCountAggregateOutputType | null _avg: AdminUserAvgAggregateOutputType | null _sum: AdminUserSumAggregateOutputType | null _min: AdminUserMinAggregateOutputType | null _max: AdminUserMaxAggregateOutputType | null } export type AdminUserAvgAggregateOutputType = { wagePercent: Decimal | null } export type AdminUserSumAggregateOutputType = { wagePercent: Decimal | null } export type AdminUserMinAggregateOutputType = { id: string | null fullName: string | null mobile: string | null passwordHash: string | null role: $Enums.AdminRole | null branchId: string | null wagePercent: Decimal | null isActive: boolean | null createdAt: Date | null } export type AdminUserMaxAggregateOutputType = { id: string | null fullName: string | null mobile: string | null passwordHash: string | null role: $Enums.AdminRole | null branchId: string | null wagePercent: Decimal | null isActive: boolean | null createdAt: Date | null } export type AdminUserCountAggregateOutputType = { id: number fullName: number mobile: number passwordHash: number role: number branchId: number wagePercent: number isActive: number createdAt: number _all: number } export type AdminUserAvgAggregateInputType = { wagePercent?: true } export type AdminUserSumAggregateInputType = { wagePercent?: true } export type AdminUserMinAggregateInputType = { id?: true fullName?: true mobile?: true passwordHash?: true role?: true branchId?: true wagePercent?: true isActive?: true createdAt?: true } export type AdminUserMaxAggregateInputType = { id?: true fullName?: true mobile?: true passwordHash?: true role?: true branchId?: true wagePercent?: true isActive?: true createdAt?: true } export type AdminUserCountAggregateInputType = { id?: true fullName?: true mobile?: true passwordHash?: true role?: true branchId?: true wagePercent?: true isActive?: true createdAt?: true _all?: true } export type AdminUserAggregateArgs = { /** * Filter which AdminUser to aggregate. */ where?: AdminUserWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of AdminUsers to fetch. */ orderBy?: AdminUserOrderByWithRelationInput | AdminUserOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: AdminUserWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` AdminUsers from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` AdminUsers. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned AdminUsers **/ _count?: true | AdminUserCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: AdminUserAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: AdminUserSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: AdminUserMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: AdminUserMaxAggregateInputType } export type GetAdminUserAggregateType = { [P in keyof T & keyof AggregateAdminUser]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type AdminUserGroupByArgs = { where?: AdminUserWhereInput orderBy?: AdminUserOrderByWithAggregationInput | AdminUserOrderByWithAggregationInput[] by: AdminUserScalarFieldEnum[] | AdminUserScalarFieldEnum having?: AdminUserScalarWhereWithAggregatesInput take?: number skip?: number _count?: AdminUserCountAggregateInputType | true _avg?: AdminUserAvgAggregateInputType _sum?: AdminUserSumAggregateInputType _min?: AdminUserMinAggregateInputType _max?: AdminUserMaxAggregateInputType } export type AdminUserGroupByOutputType = { id: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole branchId: string | null wagePercent: Decimal | null isActive: boolean createdAt: Date _count: AdminUserCountAggregateOutputType | null _avg: AdminUserAvgAggregateOutputType | null _sum: AdminUserSumAggregateOutputType | null _min: AdminUserMinAggregateOutputType | null _max: AdminUserMaxAggregateOutputType | null } type GetAdminUserGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof AdminUserGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type AdminUserSelect = $Extensions.GetSelect<{ id?: boolean fullName?: boolean mobile?: boolean passwordHash?: boolean role?: boolean branchId?: boolean wagePercent?: boolean isActive?: boolean createdAt?: boolean branch?: boolean | AdminUser$branchArgs referredCustomers?: boolean | AdminUser$referredCustomersArgs postedLedgerEntries?: boolean | AdminUser$postedLedgerEntriesArgs orderStatusEvents?: boolean | AdminUser$orderStatusEventsArgs preOrderStatusEvents?: boolean | AdminUser$preOrderStatusEventsArgs _count?: boolean | AdminUserCountOutputTypeDefaultArgs }, ExtArgs["result"]["adminUser"]> export type AdminUserSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean fullName?: boolean mobile?: boolean passwordHash?: boolean role?: boolean branchId?: boolean wagePercent?: boolean isActive?: boolean createdAt?: boolean branch?: boolean | AdminUser$branchArgs }, ExtArgs["result"]["adminUser"]> export type AdminUserSelectScalar = { id?: boolean fullName?: boolean mobile?: boolean passwordHash?: boolean role?: boolean branchId?: boolean wagePercent?: boolean isActive?: boolean createdAt?: boolean } export type AdminUserInclude = { branch?: boolean | AdminUser$branchArgs referredCustomers?: boolean | AdminUser$referredCustomersArgs postedLedgerEntries?: boolean | AdminUser$postedLedgerEntriesArgs orderStatusEvents?: boolean | AdminUser$orderStatusEventsArgs preOrderStatusEvents?: boolean | AdminUser$preOrderStatusEventsArgs _count?: boolean | AdminUserCountOutputTypeDefaultArgs } export type AdminUserIncludeCreateManyAndReturn = { branch?: boolean | AdminUser$branchArgs } export type $AdminUserPayload = { name: "AdminUser" objects: { branch: Prisma.$BranchPayload | null referredCustomers: Prisma.$CustomerPayload[] postedLedgerEntries: Prisma.$LedgerEntryPayload[] orderStatusEvents: Prisma.$OrderStatusEventPayload[] preOrderStatusEvents: Prisma.$PreOrderStatusEventPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole branchId: string | null wagePercent: Prisma.Decimal | null isActive: boolean createdAt: Date }, ExtArgs["result"]["adminUser"]> composites: {} } type AdminUserGetPayload = $Result.GetResult type AdminUserCountArgs = Omit & { select?: AdminUserCountAggregateInputType | true } export interface AdminUserDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['AdminUser'], meta: { name: 'AdminUser' } } /** * Find zero or one AdminUser that matches the filter. * @param {AdminUserFindUniqueArgs} args - Arguments to find a AdminUser * @example * // Get one AdminUser * const adminUser = await prisma.adminUser.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__AdminUserClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one AdminUser that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {AdminUserFindUniqueOrThrowArgs} args - Arguments to find a AdminUser * @example * // Get one AdminUser * const adminUser = await prisma.adminUser.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__AdminUserClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first AdminUser that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AdminUserFindFirstArgs} args - Arguments to find a AdminUser * @example * // Get one AdminUser * const adminUser = await prisma.adminUser.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__AdminUserClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first AdminUser that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AdminUserFindFirstOrThrowArgs} args - Arguments to find a AdminUser * @example * // Get one AdminUser * const adminUser = await prisma.adminUser.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__AdminUserClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more AdminUsers that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AdminUserFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all AdminUsers * const adminUsers = await prisma.adminUser.findMany() * * // Get first 10 AdminUsers * const adminUsers = await prisma.adminUser.findMany({ take: 10 }) * * // Only select the `id` * const adminUserWithIdOnly = await prisma.adminUser.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a AdminUser. * @param {AdminUserCreateArgs} args - Arguments to create a AdminUser. * @example * // Create one AdminUser * const AdminUser = await prisma.adminUser.create({ * data: { * // ... data to create a AdminUser * } * }) * */ create(args: SelectSubset>): Prisma__AdminUserClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many AdminUsers. * @param {AdminUserCreateManyArgs} args - Arguments to create many AdminUsers. * @example * // Create many AdminUsers * const adminUser = await prisma.adminUser.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many AdminUsers and returns the data saved in the database. * @param {AdminUserCreateManyAndReturnArgs} args - Arguments to create many AdminUsers. * @example * // Create many AdminUsers * const adminUser = await prisma.adminUser.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many AdminUsers and only return the `id` * const adminUserWithIdOnly = await prisma.adminUser.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a AdminUser. * @param {AdminUserDeleteArgs} args - Arguments to delete one AdminUser. * @example * // Delete one AdminUser * const AdminUser = await prisma.adminUser.delete({ * where: { * // ... filter to delete one AdminUser * } * }) * */ delete(args: SelectSubset>): Prisma__AdminUserClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one AdminUser. * @param {AdminUserUpdateArgs} args - Arguments to update one AdminUser. * @example * // Update one AdminUser * const adminUser = await prisma.adminUser.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__AdminUserClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more AdminUsers. * @param {AdminUserDeleteManyArgs} args - Arguments to filter AdminUsers to delete. * @example * // Delete a few AdminUsers * const { count } = await prisma.adminUser.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more AdminUsers. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AdminUserUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many AdminUsers * const adminUser = await prisma.adminUser.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one AdminUser. * @param {AdminUserUpsertArgs} args - Arguments to update or create a AdminUser. * @example * // Update or create a AdminUser * const adminUser = await prisma.adminUser.upsert({ * create: { * // ... data to create a AdminUser * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the AdminUser we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__AdminUserClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of AdminUsers. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AdminUserCountArgs} args - Arguments to filter AdminUsers to count. * @example * // Count the number of AdminUsers * const count = await prisma.adminUser.count({ * where: { * // ... the filter for the AdminUsers we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a AdminUser. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AdminUserAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by AdminUser. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {AdminUserGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends AdminUserGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: AdminUserGroupByArgs['orderBy'] } : { orderBy?: AdminUserGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetAdminUserGroupByPayload : Prisma.PrismaPromise /** * Fields of the AdminUser model */ readonly fields: AdminUserFieldRefs; } /** * The delegate class that acts as a "Promise-like" for AdminUser. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__AdminUserClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" branch = {}>(args?: Subset>): Prisma__BranchClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> referredCustomers = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> postedLedgerEntries = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> orderStatusEvents = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> preOrderStatusEvents = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the AdminUser model */ interface AdminUserFieldRefs { readonly id: FieldRef<"AdminUser", 'String'> readonly fullName: FieldRef<"AdminUser", 'String'> readonly mobile: FieldRef<"AdminUser", 'String'> readonly passwordHash: FieldRef<"AdminUser", 'String'> readonly role: FieldRef<"AdminUser", 'AdminRole'> readonly branchId: FieldRef<"AdminUser", 'String'> readonly wagePercent: FieldRef<"AdminUser", 'Decimal'> readonly isActive: FieldRef<"AdminUser", 'Boolean'> readonly createdAt: FieldRef<"AdminUser", 'DateTime'> } // Custom InputTypes /** * AdminUser findUnique */ export type AdminUserFindUniqueArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * Filter, which AdminUser to fetch. */ where: AdminUserWhereUniqueInput } /** * AdminUser findUniqueOrThrow */ export type AdminUserFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * Filter, which AdminUser to fetch. */ where: AdminUserWhereUniqueInput } /** * AdminUser findFirst */ export type AdminUserFindFirstArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * Filter, which AdminUser to fetch. */ where?: AdminUserWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of AdminUsers to fetch. */ orderBy?: AdminUserOrderByWithRelationInput | AdminUserOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for AdminUsers. */ cursor?: AdminUserWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` AdminUsers from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` AdminUsers. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of AdminUsers. */ distinct?: AdminUserScalarFieldEnum | AdminUserScalarFieldEnum[] } /** * AdminUser findFirstOrThrow */ export type AdminUserFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * Filter, which AdminUser to fetch. */ where?: AdminUserWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of AdminUsers to fetch. */ orderBy?: AdminUserOrderByWithRelationInput | AdminUserOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for AdminUsers. */ cursor?: AdminUserWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` AdminUsers from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` AdminUsers. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of AdminUsers. */ distinct?: AdminUserScalarFieldEnum | AdminUserScalarFieldEnum[] } /** * AdminUser findMany */ export type AdminUserFindManyArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * Filter, which AdminUsers to fetch. */ where?: AdminUserWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of AdminUsers to fetch. */ orderBy?: AdminUserOrderByWithRelationInput | AdminUserOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing AdminUsers. */ cursor?: AdminUserWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` AdminUsers from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` AdminUsers. */ skip?: number distinct?: AdminUserScalarFieldEnum | AdminUserScalarFieldEnum[] } /** * AdminUser create */ export type AdminUserCreateArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * The data needed to create a AdminUser. */ data: XOR } /** * AdminUser createMany */ export type AdminUserCreateManyArgs = { /** * The data used to create many AdminUsers. */ data: AdminUserCreateManyInput | AdminUserCreateManyInput[] skipDuplicates?: boolean } /** * AdminUser createManyAndReturn */ export type AdminUserCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelectCreateManyAndReturn | null /** * The data used to create many AdminUsers. */ data: AdminUserCreateManyInput | AdminUserCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: AdminUserIncludeCreateManyAndReturn | null } /** * AdminUser update */ export type AdminUserUpdateArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * The data needed to update a AdminUser. */ data: XOR /** * Choose, which AdminUser to update. */ where: AdminUserWhereUniqueInput } /** * AdminUser updateMany */ export type AdminUserUpdateManyArgs = { /** * The data used to update AdminUsers. */ data: XOR /** * Filter which AdminUsers to update */ where?: AdminUserWhereInput } /** * AdminUser upsert */ export type AdminUserUpsertArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * The filter to search for the AdminUser to update in case it exists. */ where: AdminUserWhereUniqueInput /** * In case the AdminUser found by the `where` argument doesn't exist, create a new AdminUser with this data. */ create: XOR /** * In case the AdminUser was found with the provided `where` argument, update it with this data. */ update: XOR } /** * AdminUser delete */ export type AdminUserDeleteArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null /** * Filter which AdminUser to delete. */ where: AdminUserWhereUniqueInput } /** * AdminUser deleteMany */ export type AdminUserDeleteManyArgs = { /** * Filter which AdminUsers to delete */ where?: AdminUserWhereInput } /** * AdminUser.branch */ export type AdminUser$branchArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null where?: BranchWhereInput } /** * AdminUser.referredCustomers */ export type AdminUser$referredCustomersArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null where?: CustomerWhereInput orderBy?: CustomerOrderByWithRelationInput | CustomerOrderByWithRelationInput[] cursor?: CustomerWhereUniqueInput take?: number skip?: number distinct?: CustomerScalarFieldEnum | CustomerScalarFieldEnum[] } /** * AdminUser.postedLedgerEntries */ export type AdminUser$postedLedgerEntriesArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null where?: LedgerEntryWhereInput orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[] cursor?: LedgerEntryWhereUniqueInput take?: number skip?: number distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[] } /** * AdminUser.orderStatusEvents */ export type AdminUser$orderStatusEventsArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null where?: OrderStatusEventWhereInput orderBy?: OrderStatusEventOrderByWithRelationInput | OrderStatusEventOrderByWithRelationInput[] cursor?: OrderStatusEventWhereUniqueInput take?: number skip?: number distinct?: OrderStatusEventScalarFieldEnum | OrderStatusEventScalarFieldEnum[] } /** * AdminUser.preOrderStatusEvents */ export type AdminUser$preOrderStatusEventsArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null where?: PreOrderStatusEventWhereInput orderBy?: PreOrderStatusEventOrderByWithRelationInput | PreOrderStatusEventOrderByWithRelationInput[] cursor?: PreOrderStatusEventWhereUniqueInput take?: number skip?: number distinct?: PreOrderStatusEventScalarFieldEnum | PreOrderStatusEventScalarFieldEnum[] } /** * AdminUser without action */ export type AdminUserDefaultArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null } /** * Model Customer */ export type AggregateCustomer = { _count: CustomerCountAggregateOutputType | null _avg: CustomerAvgAggregateOutputType | null _sum: CustomerSumAggregateOutputType | null _min: CustomerMinAggregateOutputType | null _max: CustomerMaxAggregateOutputType | null } export type CustomerAvgAggregateOutputType = { goldCreditLimitGrams: Decimal | null goldDebtGrams: Decimal | null fiatDebtRial: Decimal | null } export type CustomerSumAggregateOutputType = { goldCreditLimitGrams: Decimal | null goldDebtGrams: Decimal | null fiatDebtRial: Decimal | null } export type CustomerMinAggregateOutputType = { id: string | null fullName: string | null mobile: string | null nationalCode: string | null passwordHash: string | null cityId: string | null referredByAgentId: string | null goldCreditLimitGrams: Decimal | null goldDebtGrams: Decimal | null fiatDebtRial: Decimal | null verificationStep: $Enums.VerificationStep | null nationalIdImageUrl: string | null businessLicenseUrl: string | null shopImageUrl: string | null isActive: boolean | null createdAt: Date | null updatedAt: Date | null } export type CustomerMaxAggregateOutputType = { id: string | null fullName: string | null mobile: string | null nationalCode: string | null passwordHash: string | null cityId: string | null referredByAgentId: string | null goldCreditLimitGrams: Decimal | null goldDebtGrams: Decimal | null fiatDebtRial: Decimal | null verificationStep: $Enums.VerificationStep | null nationalIdImageUrl: string | null businessLicenseUrl: string | null shopImageUrl: string | null isActive: boolean | null createdAt: Date | null updatedAt: Date | null } export type CustomerCountAggregateOutputType = { id: number fullName: number mobile: number nationalCode: number passwordHash: number cityId: number referredByAgentId: number goldCreditLimitGrams: number goldDebtGrams: number fiatDebtRial: number verificationStep: number nationalIdImageUrl: number businessLicenseUrl: number shopImageUrl: number isActive: number createdAt: number updatedAt: number _all: number } export type CustomerAvgAggregateInputType = { goldCreditLimitGrams?: true goldDebtGrams?: true fiatDebtRial?: true } export type CustomerSumAggregateInputType = { goldCreditLimitGrams?: true goldDebtGrams?: true fiatDebtRial?: true } export type CustomerMinAggregateInputType = { id?: true fullName?: true mobile?: true nationalCode?: true passwordHash?: true cityId?: true referredByAgentId?: true goldCreditLimitGrams?: true goldDebtGrams?: true fiatDebtRial?: true verificationStep?: true nationalIdImageUrl?: true businessLicenseUrl?: true shopImageUrl?: true isActive?: true createdAt?: true updatedAt?: true } export type CustomerMaxAggregateInputType = { id?: true fullName?: true mobile?: true nationalCode?: true passwordHash?: true cityId?: true referredByAgentId?: true goldCreditLimitGrams?: true goldDebtGrams?: true fiatDebtRial?: true verificationStep?: true nationalIdImageUrl?: true businessLicenseUrl?: true shopImageUrl?: true isActive?: true createdAt?: true updatedAt?: true } export type CustomerCountAggregateInputType = { id?: true fullName?: true mobile?: true nationalCode?: true passwordHash?: true cityId?: true referredByAgentId?: true goldCreditLimitGrams?: true goldDebtGrams?: true fiatDebtRial?: true verificationStep?: true nationalIdImageUrl?: true businessLicenseUrl?: true shopImageUrl?: true isActive?: true createdAt?: true updatedAt?: true _all?: true } export type CustomerAggregateArgs = { /** * Filter which Customer to aggregate. */ where?: CustomerWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Customers to fetch. */ orderBy?: CustomerOrderByWithRelationInput | CustomerOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: CustomerWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Customers from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Customers. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Customers **/ _count?: true | CustomerCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: CustomerAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: CustomerSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: CustomerMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: CustomerMaxAggregateInputType } export type GetCustomerAggregateType = { [P in keyof T & keyof AggregateCustomer]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type CustomerGroupByArgs = { where?: CustomerWhereInput orderBy?: CustomerOrderByWithAggregationInput | CustomerOrderByWithAggregationInput[] by: CustomerScalarFieldEnum[] | CustomerScalarFieldEnum having?: CustomerScalarWhereWithAggregatesInput take?: number skip?: number _count?: CustomerCountAggregateInputType | true _avg?: CustomerAvgAggregateInputType _sum?: CustomerSumAggregateInputType _min?: CustomerMinAggregateInputType _max?: CustomerMaxAggregateInputType } export type CustomerGroupByOutputType = { id: string fullName: string mobile: string nationalCode: string passwordHash: string cityId: string | null referredByAgentId: string | null goldCreditLimitGrams: Decimal goldDebtGrams: Decimal fiatDebtRial: Decimal verificationStep: $Enums.VerificationStep nationalIdImageUrl: string | null businessLicenseUrl: string | null shopImageUrl: string | null isActive: boolean createdAt: Date updatedAt: Date _count: CustomerCountAggregateOutputType | null _avg: CustomerAvgAggregateOutputType | null _sum: CustomerSumAggregateOutputType | null _min: CustomerMinAggregateOutputType | null _max: CustomerMaxAggregateOutputType | null } type GetCustomerGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof CustomerGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type CustomerSelect = $Extensions.GetSelect<{ id?: boolean fullName?: boolean mobile?: boolean nationalCode?: boolean passwordHash?: boolean cityId?: boolean referredByAgentId?: boolean goldCreditLimitGrams?: boolean goldDebtGrams?: boolean fiatDebtRial?: boolean verificationStep?: boolean nationalIdImageUrl?: boolean businessLicenseUrl?: boolean shopImageUrl?: boolean isActive?: boolean createdAt?: boolean updatedAt?: boolean city?: boolean | Customer$cityArgs referredByAgent?: boolean | Customer$referredByAgentArgs addresses?: boolean | Customer$addressesArgs orders?: boolean | Customer$ordersArgs preOrders?: boolean | Customer$preOrdersArgs ledgerEntries?: boolean | Customer$ledgerEntriesArgs walletBonuses?: boolean | Customer$walletBonusesArgs _count?: boolean | CustomerCountOutputTypeDefaultArgs }, ExtArgs["result"]["customer"]> export type CustomerSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean fullName?: boolean mobile?: boolean nationalCode?: boolean passwordHash?: boolean cityId?: boolean referredByAgentId?: boolean goldCreditLimitGrams?: boolean goldDebtGrams?: boolean fiatDebtRial?: boolean verificationStep?: boolean nationalIdImageUrl?: boolean businessLicenseUrl?: boolean shopImageUrl?: boolean isActive?: boolean createdAt?: boolean updatedAt?: boolean city?: boolean | Customer$cityArgs referredByAgent?: boolean | Customer$referredByAgentArgs }, ExtArgs["result"]["customer"]> export type CustomerSelectScalar = { id?: boolean fullName?: boolean mobile?: boolean nationalCode?: boolean passwordHash?: boolean cityId?: boolean referredByAgentId?: boolean goldCreditLimitGrams?: boolean goldDebtGrams?: boolean fiatDebtRial?: boolean verificationStep?: boolean nationalIdImageUrl?: boolean businessLicenseUrl?: boolean shopImageUrl?: boolean isActive?: boolean createdAt?: boolean updatedAt?: boolean } export type CustomerInclude = { city?: boolean | Customer$cityArgs referredByAgent?: boolean | Customer$referredByAgentArgs addresses?: boolean | Customer$addressesArgs orders?: boolean | Customer$ordersArgs preOrders?: boolean | Customer$preOrdersArgs ledgerEntries?: boolean | Customer$ledgerEntriesArgs walletBonuses?: boolean | Customer$walletBonusesArgs _count?: boolean | CustomerCountOutputTypeDefaultArgs } export type CustomerIncludeCreateManyAndReturn = { city?: boolean | Customer$cityArgs referredByAgent?: boolean | Customer$referredByAgentArgs } export type $CustomerPayload = { name: "Customer" objects: { city: Prisma.$CityPayload | null referredByAgent: Prisma.$AdminUserPayload | null addresses: Prisma.$CustomerAddressPayload[] orders: Prisma.$OrderPayload[] preOrders: Prisma.$PreOrderPayload[] ledgerEntries: Prisma.$LedgerEntryPayload[] walletBonuses: Prisma.$WalletBonusPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string fullName: string mobile: string nationalCode: string passwordHash: string cityId: string | null referredByAgentId: string | null goldCreditLimitGrams: Prisma.Decimal goldDebtGrams: Prisma.Decimal fiatDebtRial: Prisma.Decimal verificationStep: $Enums.VerificationStep nationalIdImageUrl: string | null businessLicenseUrl: string | null shopImageUrl: string | null isActive: boolean createdAt: Date updatedAt: Date }, ExtArgs["result"]["customer"]> composites: {} } type CustomerGetPayload = $Result.GetResult type CustomerCountArgs = Omit & { select?: CustomerCountAggregateInputType | true } export interface CustomerDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Customer'], meta: { name: 'Customer' } } /** * Find zero or one Customer that matches the filter. * @param {CustomerFindUniqueArgs} args - Arguments to find a Customer * @example * // Get one Customer * const customer = await prisma.customer.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__CustomerClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one Customer that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {CustomerFindUniqueOrThrowArgs} args - Arguments to find a Customer * @example * // Get one Customer * const customer = await prisma.customer.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__CustomerClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first Customer that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerFindFirstArgs} args - Arguments to find a Customer * @example * // Get one Customer * const customer = await prisma.customer.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__CustomerClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first Customer that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerFindFirstOrThrowArgs} args - Arguments to find a Customer * @example * // Get one Customer * const customer = await prisma.customer.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__CustomerClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Customers that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Customers * const customers = await prisma.customer.findMany() * * // Get first 10 Customers * const customers = await prisma.customer.findMany({ take: 10 }) * * // Only select the `id` * const customerWithIdOnly = await prisma.customer.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a Customer. * @param {CustomerCreateArgs} args - Arguments to create a Customer. * @example * // Create one Customer * const Customer = await prisma.customer.create({ * data: { * // ... data to create a Customer * } * }) * */ create(args: SelectSubset>): Prisma__CustomerClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Customers. * @param {CustomerCreateManyArgs} args - Arguments to create many Customers. * @example * // Create many Customers * const customer = await prisma.customer.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Customers and returns the data saved in the database. * @param {CustomerCreateManyAndReturnArgs} args - Arguments to create many Customers. * @example * // Create many Customers * const customer = await prisma.customer.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Customers and only return the `id` * const customerWithIdOnly = await prisma.customer.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a Customer. * @param {CustomerDeleteArgs} args - Arguments to delete one Customer. * @example * // Delete one Customer * const Customer = await prisma.customer.delete({ * where: { * // ... filter to delete one Customer * } * }) * */ delete(args: SelectSubset>): Prisma__CustomerClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one Customer. * @param {CustomerUpdateArgs} args - Arguments to update one Customer. * @example * // Update one Customer * const customer = await prisma.customer.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__CustomerClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Customers. * @param {CustomerDeleteManyArgs} args - Arguments to filter Customers to delete. * @example * // Delete a few Customers * const { count } = await prisma.customer.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Customers. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Customers * const customer = await prisma.customer.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one Customer. * @param {CustomerUpsertArgs} args - Arguments to update or create a Customer. * @example * // Update or create a Customer * const customer = await prisma.customer.upsert({ * create: { * // ... data to create a Customer * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Customer we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__CustomerClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Customers. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerCountArgs} args - Arguments to filter Customers to count. * @example * // Count the number of Customers * const count = await prisma.customer.count({ * where: { * // ... the filter for the Customers we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Customer. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Customer. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends CustomerGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: CustomerGroupByArgs['orderBy'] } : { orderBy?: CustomerGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCustomerGroupByPayload : Prisma.PrismaPromise /** * Fields of the Customer model */ readonly fields: CustomerFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Customer. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__CustomerClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" city = {}>(args?: Subset>): Prisma__CityClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> referredByAgent = {}>(args?: Subset>): Prisma__AdminUserClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> addresses = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> orders = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> preOrders = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> ledgerEntries = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> walletBonuses = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the Customer model */ interface CustomerFieldRefs { readonly id: FieldRef<"Customer", 'String'> readonly fullName: FieldRef<"Customer", 'String'> readonly mobile: FieldRef<"Customer", 'String'> readonly nationalCode: FieldRef<"Customer", 'String'> readonly passwordHash: FieldRef<"Customer", 'String'> readonly cityId: FieldRef<"Customer", 'String'> readonly referredByAgentId: FieldRef<"Customer", 'String'> readonly goldCreditLimitGrams: FieldRef<"Customer", 'Decimal'> readonly goldDebtGrams: FieldRef<"Customer", 'Decimal'> readonly fiatDebtRial: FieldRef<"Customer", 'Decimal'> readonly verificationStep: FieldRef<"Customer", 'VerificationStep'> readonly nationalIdImageUrl: FieldRef<"Customer", 'String'> readonly businessLicenseUrl: FieldRef<"Customer", 'String'> readonly shopImageUrl: FieldRef<"Customer", 'String'> readonly isActive: FieldRef<"Customer", 'Boolean'> readonly createdAt: FieldRef<"Customer", 'DateTime'> readonly updatedAt: FieldRef<"Customer", 'DateTime'> } // Custom InputTypes /** * Customer findUnique */ export type CustomerFindUniqueArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * Filter, which Customer to fetch. */ where: CustomerWhereUniqueInput } /** * Customer findUniqueOrThrow */ export type CustomerFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * Filter, which Customer to fetch. */ where: CustomerWhereUniqueInput } /** * Customer findFirst */ export type CustomerFindFirstArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * Filter, which Customer to fetch. */ where?: CustomerWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Customers to fetch. */ orderBy?: CustomerOrderByWithRelationInput | CustomerOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Customers. */ cursor?: CustomerWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Customers from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Customers. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Customers. */ distinct?: CustomerScalarFieldEnum | CustomerScalarFieldEnum[] } /** * Customer findFirstOrThrow */ export type CustomerFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * Filter, which Customer to fetch. */ where?: CustomerWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Customers to fetch. */ orderBy?: CustomerOrderByWithRelationInput | CustomerOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Customers. */ cursor?: CustomerWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Customers from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Customers. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Customers. */ distinct?: CustomerScalarFieldEnum | CustomerScalarFieldEnum[] } /** * Customer findMany */ export type CustomerFindManyArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * Filter, which Customers to fetch. */ where?: CustomerWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Customers to fetch. */ orderBy?: CustomerOrderByWithRelationInput | CustomerOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Customers. */ cursor?: CustomerWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Customers from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Customers. */ skip?: number distinct?: CustomerScalarFieldEnum | CustomerScalarFieldEnum[] } /** * Customer create */ export type CustomerCreateArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * The data needed to create a Customer. */ data: XOR } /** * Customer createMany */ export type CustomerCreateManyArgs = { /** * The data used to create many Customers. */ data: CustomerCreateManyInput | CustomerCreateManyInput[] skipDuplicates?: boolean } /** * Customer createManyAndReturn */ export type CustomerCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelectCreateManyAndReturn | null /** * The data used to create many Customers. */ data: CustomerCreateManyInput | CustomerCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: CustomerIncludeCreateManyAndReturn | null } /** * Customer update */ export type CustomerUpdateArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * The data needed to update a Customer. */ data: XOR /** * Choose, which Customer to update. */ where: CustomerWhereUniqueInput } /** * Customer updateMany */ export type CustomerUpdateManyArgs = { /** * The data used to update Customers. */ data: XOR /** * Filter which Customers to update */ where?: CustomerWhereInput } /** * Customer upsert */ export type CustomerUpsertArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * The filter to search for the Customer to update in case it exists. */ where: CustomerWhereUniqueInput /** * In case the Customer found by the `where` argument doesn't exist, create a new Customer with this data. */ create: XOR /** * In case the Customer was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Customer delete */ export type CustomerDeleteArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null /** * Filter which Customer to delete. */ where: CustomerWhereUniqueInput } /** * Customer deleteMany */ export type CustomerDeleteManyArgs = { /** * Filter which Customers to delete */ where?: CustomerWhereInput } /** * Customer.city */ export type Customer$cityArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null where?: CityWhereInput } /** * Customer.referredByAgent */ export type Customer$referredByAgentArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null where?: AdminUserWhereInput } /** * Customer.addresses */ export type Customer$addressesArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null where?: CustomerAddressWhereInput orderBy?: CustomerAddressOrderByWithRelationInput | CustomerAddressOrderByWithRelationInput[] cursor?: CustomerAddressWhereUniqueInput take?: number skip?: number distinct?: CustomerAddressScalarFieldEnum | CustomerAddressScalarFieldEnum[] } /** * Customer.orders */ export type Customer$ordersArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null where?: OrderWhereInput orderBy?: OrderOrderByWithRelationInput | OrderOrderByWithRelationInput[] cursor?: OrderWhereUniqueInput take?: number skip?: number distinct?: OrderScalarFieldEnum | OrderScalarFieldEnum[] } /** * Customer.preOrders */ export type Customer$preOrdersArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null where?: PreOrderWhereInput orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[] cursor?: PreOrderWhereUniqueInput take?: number skip?: number distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[] } /** * Customer.ledgerEntries */ export type Customer$ledgerEntriesArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null where?: LedgerEntryWhereInput orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[] cursor?: LedgerEntryWhereUniqueInput take?: number skip?: number distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[] } /** * Customer.walletBonuses */ export type Customer$walletBonusesArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null where?: WalletBonusWhereInput orderBy?: WalletBonusOrderByWithRelationInput | WalletBonusOrderByWithRelationInput[] cursor?: WalletBonusWhereUniqueInput take?: number skip?: number distinct?: WalletBonusScalarFieldEnum | WalletBonusScalarFieldEnum[] } /** * Customer without action */ export type CustomerDefaultArgs = { /** * Select specific fields to fetch from the Customer */ select?: CustomerSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerInclude | null } /** * Model CustomerAddress */ export type AggregateCustomerAddress = { _count: CustomerAddressCountAggregateOutputType | null _min: CustomerAddressMinAggregateOutputType | null _max: CustomerAddressMaxAggregateOutputType | null } export type CustomerAddressMinAggregateOutputType = { id: string | null customerId: string | null cityId: string | null addressLine: string | null isDefault: boolean | null } export type CustomerAddressMaxAggregateOutputType = { id: string | null customerId: string | null cityId: string | null addressLine: string | null isDefault: boolean | null } export type CustomerAddressCountAggregateOutputType = { id: number customerId: number cityId: number addressLine: number isDefault: number _all: number } export type CustomerAddressMinAggregateInputType = { id?: true customerId?: true cityId?: true addressLine?: true isDefault?: true } export type CustomerAddressMaxAggregateInputType = { id?: true customerId?: true cityId?: true addressLine?: true isDefault?: true } export type CustomerAddressCountAggregateInputType = { id?: true customerId?: true cityId?: true addressLine?: true isDefault?: true _all?: true } export type CustomerAddressAggregateArgs = { /** * Filter which CustomerAddress to aggregate. */ where?: CustomerAddressWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CustomerAddresses to fetch. */ orderBy?: CustomerAddressOrderByWithRelationInput | CustomerAddressOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: CustomerAddressWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CustomerAddresses from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CustomerAddresses. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned CustomerAddresses **/ _count?: true | CustomerAddressCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: CustomerAddressMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: CustomerAddressMaxAggregateInputType } export type GetCustomerAddressAggregateType = { [P in keyof T & keyof AggregateCustomerAddress]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type CustomerAddressGroupByArgs = { where?: CustomerAddressWhereInput orderBy?: CustomerAddressOrderByWithAggregationInput | CustomerAddressOrderByWithAggregationInput[] by: CustomerAddressScalarFieldEnum[] | CustomerAddressScalarFieldEnum having?: CustomerAddressScalarWhereWithAggregatesInput take?: number skip?: number _count?: CustomerAddressCountAggregateInputType | true _min?: CustomerAddressMinAggregateInputType _max?: CustomerAddressMaxAggregateInputType } export type CustomerAddressGroupByOutputType = { id: string customerId: string cityId: string | null addressLine: string isDefault: boolean _count: CustomerAddressCountAggregateOutputType | null _min: CustomerAddressMinAggregateOutputType | null _max: CustomerAddressMaxAggregateOutputType | null } type GetCustomerAddressGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof CustomerAddressGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type CustomerAddressSelect = $Extensions.GetSelect<{ id?: boolean customerId?: boolean cityId?: boolean addressLine?: boolean isDefault?: boolean customer?: boolean | CustomerDefaultArgs city?: boolean | CustomerAddress$cityArgs }, ExtArgs["result"]["customerAddress"]> export type CustomerAddressSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean customerId?: boolean cityId?: boolean addressLine?: boolean isDefault?: boolean customer?: boolean | CustomerDefaultArgs city?: boolean | CustomerAddress$cityArgs }, ExtArgs["result"]["customerAddress"]> export type CustomerAddressSelectScalar = { id?: boolean customerId?: boolean cityId?: boolean addressLine?: boolean isDefault?: boolean } export type CustomerAddressInclude = { customer?: boolean | CustomerDefaultArgs city?: boolean | CustomerAddress$cityArgs } export type CustomerAddressIncludeCreateManyAndReturn = { customer?: boolean | CustomerDefaultArgs city?: boolean | CustomerAddress$cityArgs } export type $CustomerAddressPayload = { name: "CustomerAddress" objects: { customer: Prisma.$CustomerPayload city: Prisma.$CityPayload | null } scalars: $Extensions.GetPayloadResult<{ id: string customerId: string cityId: string | null addressLine: string isDefault: boolean }, ExtArgs["result"]["customerAddress"]> composites: {} } type CustomerAddressGetPayload = $Result.GetResult type CustomerAddressCountArgs = Omit & { select?: CustomerAddressCountAggregateInputType | true } export interface CustomerAddressDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['CustomerAddress'], meta: { name: 'CustomerAddress' } } /** * Find zero or one CustomerAddress that matches the filter. * @param {CustomerAddressFindUniqueArgs} args - Arguments to find a CustomerAddress * @example * // Get one CustomerAddress * const customerAddress = await prisma.customerAddress.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__CustomerAddressClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one CustomerAddress that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {CustomerAddressFindUniqueOrThrowArgs} args - Arguments to find a CustomerAddress * @example * // Get one CustomerAddress * const customerAddress = await prisma.customerAddress.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__CustomerAddressClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first CustomerAddress that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerAddressFindFirstArgs} args - Arguments to find a CustomerAddress * @example * // Get one CustomerAddress * const customerAddress = await prisma.customerAddress.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__CustomerAddressClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first CustomerAddress that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerAddressFindFirstOrThrowArgs} args - Arguments to find a CustomerAddress * @example * // Get one CustomerAddress * const customerAddress = await prisma.customerAddress.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__CustomerAddressClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more CustomerAddresses that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerAddressFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all CustomerAddresses * const customerAddresses = await prisma.customerAddress.findMany() * * // Get first 10 CustomerAddresses * const customerAddresses = await prisma.customerAddress.findMany({ take: 10 }) * * // Only select the `id` * const customerAddressWithIdOnly = await prisma.customerAddress.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a CustomerAddress. * @param {CustomerAddressCreateArgs} args - Arguments to create a CustomerAddress. * @example * // Create one CustomerAddress * const CustomerAddress = await prisma.customerAddress.create({ * data: { * // ... data to create a CustomerAddress * } * }) * */ create(args: SelectSubset>): Prisma__CustomerAddressClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many CustomerAddresses. * @param {CustomerAddressCreateManyArgs} args - Arguments to create many CustomerAddresses. * @example * // Create many CustomerAddresses * const customerAddress = await prisma.customerAddress.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many CustomerAddresses and returns the data saved in the database. * @param {CustomerAddressCreateManyAndReturnArgs} args - Arguments to create many CustomerAddresses. * @example * // Create many CustomerAddresses * const customerAddress = await prisma.customerAddress.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many CustomerAddresses and only return the `id` * const customerAddressWithIdOnly = await prisma.customerAddress.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a CustomerAddress. * @param {CustomerAddressDeleteArgs} args - Arguments to delete one CustomerAddress. * @example * // Delete one CustomerAddress * const CustomerAddress = await prisma.customerAddress.delete({ * where: { * // ... filter to delete one CustomerAddress * } * }) * */ delete(args: SelectSubset>): Prisma__CustomerAddressClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one CustomerAddress. * @param {CustomerAddressUpdateArgs} args - Arguments to update one CustomerAddress. * @example * // Update one CustomerAddress * const customerAddress = await prisma.customerAddress.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__CustomerAddressClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more CustomerAddresses. * @param {CustomerAddressDeleteManyArgs} args - Arguments to filter CustomerAddresses to delete. * @example * // Delete a few CustomerAddresses * const { count } = await prisma.customerAddress.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more CustomerAddresses. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerAddressUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many CustomerAddresses * const customerAddress = await prisma.customerAddress.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one CustomerAddress. * @param {CustomerAddressUpsertArgs} args - Arguments to update or create a CustomerAddress. * @example * // Update or create a CustomerAddress * const customerAddress = await prisma.customerAddress.upsert({ * create: { * // ... data to create a CustomerAddress * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the CustomerAddress we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__CustomerAddressClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of CustomerAddresses. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerAddressCountArgs} args - Arguments to filter CustomerAddresses to count. * @example * // Count the number of CustomerAddresses * const count = await prisma.customerAddress.count({ * where: { * // ... the filter for the CustomerAddresses we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a CustomerAddress. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerAddressAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by CustomerAddress. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CustomerAddressGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends CustomerAddressGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: CustomerAddressGroupByArgs['orderBy'] } : { orderBy?: CustomerAddressGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCustomerAddressGroupByPayload : Prisma.PrismaPromise /** * Fields of the CustomerAddress model */ readonly fields: CustomerAddressFieldRefs; } /** * The delegate class that acts as a "Promise-like" for CustomerAddress. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__CustomerAddressClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" customer = {}>(args?: Subset>): Prisma__CustomerClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> city = {}>(args?: Subset>): Prisma__CityClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the CustomerAddress model */ interface CustomerAddressFieldRefs { readonly id: FieldRef<"CustomerAddress", 'String'> readonly customerId: FieldRef<"CustomerAddress", 'String'> readonly cityId: FieldRef<"CustomerAddress", 'String'> readonly addressLine: FieldRef<"CustomerAddress", 'String'> readonly isDefault: FieldRef<"CustomerAddress", 'Boolean'> } // Custom InputTypes /** * CustomerAddress findUnique */ export type CustomerAddressFindUniqueArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * Filter, which CustomerAddress to fetch. */ where: CustomerAddressWhereUniqueInput } /** * CustomerAddress findUniqueOrThrow */ export type CustomerAddressFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * Filter, which CustomerAddress to fetch. */ where: CustomerAddressWhereUniqueInput } /** * CustomerAddress findFirst */ export type CustomerAddressFindFirstArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * Filter, which CustomerAddress to fetch. */ where?: CustomerAddressWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CustomerAddresses to fetch. */ orderBy?: CustomerAddressOrderByWithRelationInput | CustomerAddressOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for CustomerAddresses. */ cursor?: CustomerAddressWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CustomerAddresses from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CustomerAddresses. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of CustomerAddresses. */ distinct?: CustomerAddressScalarFieldEnum | CustomerAddressScalarFieldEnum[] } /** * CustomerAddress findFirstOrThrow */ export type CustomerAddressFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * Filter, which CustomerAddress to fetch. */ where?: CustomerAddressWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CustomerAddresses to fetch. */ orderBy?: CustomerAddressOrderByWithRelationInput | CustomerAddressOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for CustomerAddresses. */ cursor?: CustomerAddressWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CustomerAddresses from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CustomerAddresses. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of CustomerAddresses. */ distinct?: CustomerAddressScalarFieldEnum | CustomerAddressScalarFieldEnum[] } /** * CustomerAddress findMany */ export type CustomerAddressFindManyArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * Filter, which CustomerAddresses to fetch. */ where?: CustomerAddressWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CustomerAddresses to fetch. */ orderBy?: CustomerAddressOrderByWithRelationInput | CustomerAddressOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing CustomerAddresses. */ cursor?: CustomerAddressWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CustomerAddresses from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CustomerAddresses. */ skip?: number distinct?: CustomerAddressScalarFieldEnum | CustomerAddressScalarFieldEnum[] } /** * CustomerAddress create */ export type CustomerAddressCreateArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * The data needed to create a CustomerAddress. */ data: XOR } /** * CustomerAddress createMany */ export type CustomerAddressCreateManyArgs = { /** * The data used to create many CustomerAddresses. */ data: CustomerAddressCreateManyInput | CustomerAddressCreateManyInput[] skipDuplicates?: boolean } /** * CustomerAddress createManyAndReturn */ export type CustomerAddressCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelectCreateManyAndReturn | null /** * The data used to create many CustomerAddresses. */ data: CustomerAddressCreateManyInput | CustomerAddressCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressIncludeCreateManyAndReturn | null } /** * CustomerAddress update */ export type CustomerAddressUpdateArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * The data needed to update a CustomerAddress. */ data: XOR /** * Choose, which CustomerAddress to update. */ where: CustomerAddressWhereUniqueInput } /** * CustomerAddress updateMany */ export type CustomerAddressUpdateManyArgs = { /** * The data used to update CustomerAddresses. */ data: XOR /** * Filter which CustomerAddresses to update */ where?: CustomerAddressWhereInput } /** * CustomerAddress upsert */ export type CustomerAddressUpsertArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * The filter to search for the CustomerAddress to update in case it exists. */ where: CustomerAddressWhereUniqueInput /** * In case the CustomerAddress found by the `where` argument doesn't exist, create a new CustomerAddress with this data. */ create: XOR /** * In case the CustomerAddress was found with the provided `where` argument, update it with this data. */ update: XOR } /** * CustomerAddress delete */ export type CustomerAddressDeleteArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null /** * Filter which CustomerAddress to delete. */ where: CustomerAddressWhereUniqueInput } /** * CustomerAddress deleteMany */ export type CustomerAddressDeleteManyArgs = { /** * Filter which CustomerAddresses to delete */ where?: CustomerAddressWhereInput } /** * CustomerAddress.city */ export type CustomerAddress$cityArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null where?: CityWhereInput } /** * CustomerAddress without action */ export type CustomerAddressDefaultArgs = { /** * Select specific fields to fetch from the CustomerAddress */ select?: CustomerAddressSelect | null /** * Choose, which related nodes to fetch as well */ include?: CustomerAddressInclude | null } /** * Model Branch */ export type AggregateBranch = { _count: BranchCountAggregateOutputType | null _min: BranchMinAggregateOutputType | null _max: BranchMaxAggregateOutputType | null } export type BranchMinAggregateOutputType = { id: string | null name: string | null cityId: string | null } export type BranchMaxAggregateOutputType = { id: string | null name: string | null cityId: string | null } export type BranchCountAggregateOutputType = { id: number name: number cityId: number _all: number } export type BranchMinAggregateInputType = { id?: true name?: true cityId?: true } export type BranchMaxAggregateInputType = { id?: true name?: true cityId?: true } export type BranchCountAggregateInputType = { id?: true name?: true cityId?: true _all?: true } export type BranchAggregateArgs = { /** * Filter which Branch to aggregate. */ where?: BranchWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Branches to fetch. */ orderBy?: BranchOrderByWithRelationInput | BranchOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: BranchWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Branches from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Branches. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Branches **/ _count?: true | BranchCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: BranchMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: BranchMaxAggregateInputType } export type GetBranchAggregateType = { [P in keyof T & keyof AggregateBranch]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type BranchGroupByArgs = { where?: BranchWhereInput orderBy?: BranchOrderByWithAggregationInput | BranchOrderByWithAggregationInput[] by: BranchScalarFieldEnum[] | BranchScalarFieldEnum having?: BranchScalarWhereWithAggregatesInput take?: number skip?: number _count?: BranchCountAggregateInputType | true _min?: BranchMinAggregateInputType _max?: BranchMaxAggregateInputType } export type BranchGroupByOutputType = { id: string name: string cityId: string | null _count: BranchCountAggregateOutputType | null _min: BranchMinAggregateOutputType | null _max: BranchMaxAggregateOutputType | null } type GetBranchGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof BranchGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type BranchSelect = $Extensions.GetSelect<{ id?: boolean name?: boolean cityId?: boolean city?: boolean | Branch$cityArgs adminUsers?: boolean | Branch$adminUsersArgs orders?: boolean | Branch$ordersArgs _count?: boolean | BranchCountOutputTypeDefaultArgs }, ExtArgs["result"]["branch"]> export type BranchSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean name?: boolean cityId?: boolean city?: boolean | Branch$cityArgs }, ExtArgs["result"]["branch"]> export type BranchSelectScalar = { id?: boolean name?: boolean cityId?: boolean } export type BranchInclude = { city?: boolean | Branch$cityArgs adminUsers?: boolean | Branch$adminUsersArgs orders?: boolean | Branch$ordersArgs _count?: boolean | BranchCountOutputTypeDefaultArgs } export type BranchIncludeCreateManyAndReturn = { city?: boolean | Branch$cityArgs } export type $BranchPayload = { name: "Branch" objects: { city: Prisma.$CityPayload | null adminUsers: Prisma.$AdminUserPayload[] orders: Prisma.$OrderPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string name: string cityId: string | null }, ExtArgs["result"]["branch"]> composites: {} } type BranchGetPayload = $Result.GetResult type BranchCountArgs = Omit & { select?: BranchCountAggregateInputType | true } export interface BranchDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Branch'], meta: { name: 'Branch' } } /** * Find zero or one Branch that matches the filter. * @param {BranchFindUniqueArgs} args - Arguments to find a Branch * @example * // Get one Branch * const branch = await prisma.branch.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__BranchClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one Branch that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {BranchFindUniqueOrThrowArgs} args - Arguments to find a Branch * @example * // Get one Branch * const branch = await prisma.branch.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__BranchClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first Branch that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BranchFindFirstArgs} args - Arguments to find a Branch * @example * // Get one Branch * const branch = await prisma.branch.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__BranchClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first Branch that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BranchFindFirstOrThrowArgs} args - Arguments to find a Branch * @example * // Get one Branch * const branch = await prisma.branch.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__BranchClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Branches that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BranchFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Branches * const branches = await prisma.branch.findMany() * * // Get first 10 Branches * const branches = await prisma.branch.findMany({ take: 10 }) * * // Only select the `id` * const branchWithIdOnly = await prisma.branch.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a Branch. * @param {BranchCreateArgs} args - Arguments to create a Branch. * @example * // Create one Branch * const Branch = await prisma.branch.create({ * data: { * // ... data to create a Branch * } * }) * */ create(args: SelectSubset>): Prisma__BranchClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Branches. * @param {BranchCreateManyArgs} args - Arguments to create many Branches. * @example * // Create many Branches * const branch = await prisma.branch.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Branches and returns the data saved in the database. * @param {BranchCreateManyAndReturnArgs} args - Arguments to create many Branches. * @example * // Create many Branches * const branch = await prisma.branch.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Branches and only return the `id` * const branchWithIdOnly = await prisma.branch.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a Branch. * @param {BranchDeleteArgs} args - Arguments to delete one Branch. * @example * // Delete one Branch * const Branch = await prisma.branch.delete({ * where: { * // ... filter to delete one Branch * } * }) * */ delete(args: SelectSubset>): Prisma__BranchClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one Branch. * @param {BranchUpdateArgs} args - Arguments to update one Branch. * @example * // Update one Branch * const branch = await prisma.branch.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__BranchClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Branches. * @param {BranchDeleteManyArgs} args - Arguments to filter Branches to delete. * @example * // Delete a few Branches * const { count } = await prisma.branch.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Branches. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BranchUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Branches * const branch = await prisma.branch.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one Branch. * @param {BranchUpsertArgs} args - Arguments to update or create a Branch. * @example * // Update or create a Branch * const branch = await prisma.branch.upsert({ * create: { * // ... data to create a Branch * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Branch we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__BranchClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Branches. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BranchCountArgs} args - Arguments to filter Branches to count. * @example * // Count the number of Branches * const count = await prisma.branch.count({ * where: { * // ... the filter for the Branches we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Branch. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BranchAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Branch. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BranchGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends BranchGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: BranchGroupByArgs['orderBy'] } : { orderBy?: BranchGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetBranchGroupByPayload : Prisma.PrismaPromise /** * Fields of the Branch model */ readonly fields: BranchFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Branch. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__BranchClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" city = {}>(args?: Subset>): Prisma__CityClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> adminUsers = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> orders = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the Branch model */ interface BranchFieldRefs { readonly id: FieldRef<"Branch", 'String'> readonly name: FieldRef<"Branch", 'String'> readonly cityId: FieldRef<"Branch", 'String'> } // Custom InputTypes /** * Branch findUnique */ export type BranchFindUniqueArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * Filter, which Branch to fetch. */ where: BranchWhereUniqueInput } /** * Branch findUniqueOrThrow */ export type BranchFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * Filter, which Branch to fetch. */ where: BranchWhereUniqueInput } /** * Branch findFirst */ export type BranchFindFirstArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * Filter, which Branch to fetch. */ where?: BranchWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Branches to fetch. */ orderBy?: BranchOrderByWithRelationInput | BranchOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Branches. */ cursor?: BranchWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Branches from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Branches. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Branches. */ distinct?: BranchScalarFieldEnum | BranchScalarFieldEnum[] } /** * Branch findFirstOrThrow */ export type BranchFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * Filter, which Branch to fetch. */ where?: BranchWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Branches to fetch. */ orderBy?: BranchOrderByWithRelationInput | BranchOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Branches. */ cursor?: BranchWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Branches from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Branches. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Branches. */ distinct?: BranchScalarFieldEnum | BranchScalarFieldEnum[] } /** * Branch findMany */ export type BranchFindManyArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * Filter, which Branches to fetch. */ where?: BranchWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Branches to fetch. */ orderBy?: BranchOrderByWithRelationInput | BranchOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Branches. */ cursor?: BranchWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Branches from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Branches. */ skip?: number distinct?: BranchScalarFieldEnum | BranchScalarFieldEnum[] } /** * Branch create */ export type BranchCreateArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * The data needed to create a Branch. */ data: XOR } /** * Branch createMany */ export type BranchCreateManyArgs = { /** * The data used to create many Branches. */ data: BranchCreateManyInput | BranchCreateManyInput[] skipDuplicates?: boolean } /** * Branch createManyAndReturn */ export type BranchCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelectCreateManyAndReturn | null /** * The data used to create many Branches. */ data: BranchCreateManyInput | BranchCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: BranchIncludeCreateManyAndReturn | null } /** * Branch update */ export type BranchUpdateArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * The data needed to update a Branch. */ data: XOR /** * Choose, which Branch to update. */ where: BranchWhereUniqueInput } /** * Branch updateMany */ export type BranchUpdateManyArgs = { /** * The data used to update Branches. */ data: XOR /** * Filter which Branches to update */ where?: BranchWhereInput } /** * Branch upsert */ export type BranchUpsertArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * The filter to search for the Branch to update in case it exists. */ where: BranchWhereUniqueInput /** * In case the Branch found by the `where` argument doesn't exist, create a new Branch with this data. */ create: XOR /** * In case the Branch was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Branch delete */ export type BranchDeleteArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null /** * Filter which Branch to delete. */ where: BranchWhereUniqueInput } /** * Branch deleteMany */ export type BranchDeleteManyArgs = { /** * Filter which Branches to delete */ where?: BranchWhereInput } /** * Branch.city */ export type Branch$cityArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null where?: CityWhereInput } /** * Branch.adminUsers */ export type Branch$adminUsersArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null where?: AdminUserWhereInput orderBy?: AdminUserOrderByWithRelationInput | AdminUserOrderByWithRelationInput[] cursor?: AdminUserWhereUniqueInput take?: number skip?: number distinct?: AdminUserScalarFieldEnum | AdminUserScalarFieldEnum[] } /** * Branch.orders */ export type Branch$ordersArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null where?: OrderWhereInput orderBy?: OrderOrderByWithRelationInput | OrderOrderByWithRelationInput[] cursor?: OrderWhereUniqueInput take?: number skip?: number distinct?: OrderScalarFieldEnum | OrderScalarFieldEnum[] } /** * Branch without action */ export type BranchDefaultArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null } /** * Model Workshop */ export type AggregateWorkshop = { _count: WorkshopCountAggregateOutputType | null _min: WorkshopMinAggregateOutputType | null _max: WorkshopMaxAggregateOutputType | null } export type WorkshopMinAggregateOutputType = { id: string | null name: string | null isActive: boolean | null } export type WorkshopMaxAggregateOutputType = { id: string | null name: string | null isActive: boolean | null } export type WorkshopCountAggregateOutputType = { id: number name: number isActive: number _all: number } export type WorkshopMinAggregateInputType = { id?: true name?: true isActive?: true } export type WorkshopMaxAggregateInputType = { id?: true name?: true isActive?: true } export type WorkshopCountAggregateInputType = { id?: true name?: true isActive?: true _all?: true } export type WorkshopAggregateArgs = { /** * Filter which Workshop to aggregate. */ where?: WorkshopWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Workshops to fetch. */ orderBy?: WorkshopOrderByWithRelationInput | WorkshopOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: WorkshopWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Workshops from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Workshops. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Workshops **/ _count?: true | WorkshopCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: WorkshopMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: WorkshopMaxAggregateInputType } export type GetWorkshopAggregateType = { [P in keyof T & keyof AggregateWorkshop]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type WorkshopGroupByArgs = { where?: WorkshopWhereInput orderBy?: WorkshopOrderByWithAggregationInput | WorkshopOrderByWithAggregationInput[] by: WorkshopScalarFieldEnum[] | WorkshopScalarFieldEnum having?: WorkshopScalarWhereWithAggregatesInput take?: number skip?: number _count?: WorkshopCountAggregateInputType | true _min?: WorkshopMinAggregateInputType _max?: WorkshopMaxAggregateInputType } export type WorkshopGroupByOutputType = { id: string name: string isActive: boolean _count: WorkshopCountAggregateOutputType | null _min: WorkshopMinAggregateOutputType | null _max: WorkshopMaxAggregateOutputType | null } type GetWorkshopGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof WorkshopGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type WorkshopSelect = $Extensions.GetSelect<{ id?: boolean name?: boolean isActive?: boolean preOrders?: boolean | Workshop$preOrdersArgs _count?: boolean | WorkshopCountOutputTypeDefaultArgs }, ExtArgs["result"]["workshop"]> export type WorkshopSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean name?: boolean isActive?: boolean }, ExtArgs["result"]["workshop"]> export type WorkshopSelectScalar = { id?: boolean name?: boolean isActive?: boolean } export type WorkshopInclude = { preOrders?: boolean | Workshop$preOrdersArgs _count?: boolean | WorkshopCountOutputTypeDefaultArgs } export type WorkshopIncludeCreateManyAndReturn = {} export type $WorkshopPayload = { name: "Workshop" objects: { preOrders: Prisma.$PreOrderPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string name: string isActive: boolean }, ExtArgs["result"]["workshop"]> composites: {} } type WorkshopGetPayload = $Result.GetResult type WorkshopCountArgs = Omit & { select?: WorkshopCountAggregateInputType | true } export interface WorkshopDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Workshop'], meta: { name: 'Workshop' } } /** * Find zero or one Workshop that matches the filter. * @param {WorkshopFindUniqueArgs} args - Arguments to find a Workshop * @example * // Get one Workshop * const workshop = await prisma.workshop.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__WorkshopClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one Workshop that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {WorkshopFindUniqueOrThrowArgs} args - Arguments to find a Workshop * @example * // Get one Workshop * const workshop = await prisma.workshop.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__WorkshopClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first Workshop that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WorkshopFindFirstArgs} args - Arguments to find a Workshop * @example * // Get one Workshop * const workshop = await prisma.workshop.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__WorkshopClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first Workshop that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WorkshopFindFirstOrThrowArgs} args - Arguments to find a Workshop * @example * // Get one Workshop * const workshop = await prisma.workshop.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__WorkshopClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Workshops that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WorkshopFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Workshops * const workshops = await prisma.workshop.findMany() * * // Get first 10 Workshops * const workshops = await prisma.workshop.findMany({ take: 10 }) * * // Only select the `id` * const workshopWithIdOnly = await prisma.workshop.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a Workshop. * @param {WorkshopCreateArgs} args - Arguments to create a Workshop. * @example * // Create one Workshop * const Workshop = await prisma.workshop.create({ * data: { * // ... data to create a Workshop * } * }) * */ create(args: SelectSubset>): Prisma__WorkshopClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Workshops. * @param {WorkshopCreateManyArgs} args - Arguments to create many Workshops. * @example * // Create many Workshops * const workshop = await prisma.workshop.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Workshops and returns the data saved in the database. * @param {WorkshopCreateManyAndReturnArgs} args - Arguments to create many Workshops. * @example * // Create many Workshops * const workshop = await prisma.workshop.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Workshops and only return the `id` * const workshopWithIdOnly = await prisma.workshop.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a Workshop. * @param {WorkshopDeleteArgs} args - Arguments to delete one Workshop. * @example * // Delete one Workshop * const Workshop = await prisma.workshop.delete({ * where: { * // ... filter to delete one Workshop * } * }) * */ delete(args: SelectSubset>): Prisma__WorkshopClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one Workshop. * @param {WorkshopUpdateArgs} args - Arguments to update one Workshop. * @example * // Update one Workshop * const workshop = await prisma.workshop.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__WorkshopClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Workshops. * @param {WorkshopDeleteManyArgs} args - Arguments to filter Workshops to delete. * @example * // Delete a few Workshops * const { count } = await prisma.workshop.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Workshops. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WorkshopUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Workshops * const workshop = await prisma.workshop.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one Workshop. * @param {WorkshopUpsertArgs} args - Arguments to update or create a Workshop. * @example * // Update or create a Workshop * const workshop = await prisma.workshop.upsert({ * create: { * // ... data to create a Workshop * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Workshop we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__WorkshopClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Workshops. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WorkshopCountArgs} args - Arguments to filter Workshops to count. * @example * // Count the number of Workshops * const count = await prisma.workshop.count({ * where: { * // ... the filter for the Workshops we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Workshop. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WorkshopAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Workshop. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WorkshopGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends WorkshopGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: WorkshopGroupByArgs['orderBy'] } : { orderBy?: WorkshopGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetWorkshopGroupByPayload : Prisma.PrismaPromise /** * Fields of the Workshop model */ readonly fields: WorkshopFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Workshop. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__WorkshopClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" preOrders = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the Workshop model */ interface WorkshopFieldRefs { readonly id: FieldRef<"Workshop", 'String'> readonly name: FieldRef<"Workshop", 'String'> readonly isActive: FieldRef<"Workshop", 'Boolean'> } // Custom InputTypes /** * Workshop findUnique */ export type WorkshopFindUniqueArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * Filter, which Workshop to fetch. */ where: WorkshopWhereUniqueInput } /** * Workshop findUniqueOrThrow */ export type WorkshopFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * Filter, which Workshop to fetch. */ where: WorkshopWhereUniqueInput } /** * Workshop findFirst */ export type WorkshopFindFirstArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * Filter, which Workshop to fetch. */ where?: WorkshopWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Workshops to fetch. */ orderBy?: WorkshopOrderByWithRelationInput | WorkshopOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Workshops. */ cursor?: WorkshopWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Workshops from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Workshops. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Workshops. */ distinct?: WorkshopScalarFieldEnum | WorkshopScalarFieldEnum[] } /** * Workshop findFirstOrThrow */ export type WorkshopFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * Filter, which Workshop to fetch. */ where?: WorkshopWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Workshops to fetch. */ orderBy?: WorkshopOrderByWithRelationInput | WorkshopOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Workshops. */ cursor?: WorkshopWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Workshops from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Workshops. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Workshops. */ distinct?: WorkshopScalarFieldEnum | WorkshopScalarFieldEnum[] } /** * Workshop findMany */ export type WorkshopFindManyArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * Filter, which Workshops to fetch. */ where?: WorkshopWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Workshops to fetch. */ orderBy?: WorkshopOrderByWithRelationInput | WorkshopOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Workshops. */ cursor?: WorkshopWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Workshops from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Workshops. */ skip?: number distinct?: WorkshopScalarFieldEnum | WorkshopScalarFieldEnum[] } /** * Workshop create */ export type WorkshopCreateArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * The data needed to create a Workshop. */ data: XOR } /** * Workshop createMany */ export type WorkshopCreateManyArgs = { /** * The data used to create many Workshops. */ data: WorkshopCreateManyInput | WorkshopCreateManyInput[] skipDuplicates?: boolean } /** * Workshop createManyAndReturn */ export type WorkshopCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelectCreateManyAndReturn | null /** * The data used to create many Workshops. */ data: WorkshopCreateManyInput | WorkshopCreateManyInput[] skipDuplicates?: boolean } /** * Workshop update */ export type WorkshopUpdateArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * The data needed to update a Workshop. */ data: XOR /** * Choose, which Workshop to update. */ where: WorkshopWhereUniqueInput } /** * Workshop updateMany */ export type WorkshopUpdateManyArgs = { /** * The data used to update Workshops. */ data: XOR /** * Filter which Workshops to update */ where?: WorkshopWhereInput } /** * Workshop upsert */ export type WorkshopUpsertArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * The filter to search for the Workshop to update in case it exists. */ where: WorkshopWhereUniqueInput /** * In case the Workshop found by the `where` argument doesn't exist, create a new Workshop with this data. */ create: XOR /** * In case the Workshop was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Workshop delete */ export type WorkshopDeleteArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null /** * Filter which Workshop to delete. */ where: WorkshopWhereUniqueInput } /** * Workshop deleteMany */ export type WorkshopDeleteManyArgs = { /** * Filter which Workshops to delete */ where?: WorkshopWhereInput } /** * Workshop.preOrders */ export type Workshop$preOrdersArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null where?: PreOrderWhereInput orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[] cursor?: PreOrderWhereUniqueInput take?: number skip?: number distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[] } /** * Workshop without action */ export type WorkshopDefaultArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null } /** * Model Category */ export type AggregateCategory = { _count: CategoryCountAggregateOutputType | null _min: CategoryMinAggregateOutputType | null _max: CategoryMaxAggregateOutputType | null } export type CategoryMinAggregateOutputType = { id: string | null title: string | null parentId: string | null } export type CategoryMaxAggregateOutputType = { id: string | null title: string | null parentId: string | null } export type CategoryCountAggregateOutputType = { id: number title: number parentId: number _all: number } export type CategoryMinAggregateInputType = { id?: true title?: true parentId?: true } export type CategoryMaxAggregateInputType = { id?: true title?: true parentId?: true } export type CategoryCountAggregateInputType = { id?: true title?: true parentId?: true _all?: true } export type CategoryAggregateArgs = { /** * Filter which Category to aggregate. */ where?: CategoryWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Categories to fetch. */ orderBy?: CategoryOrderByWithRelationInput | CategoryOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: CategoryWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Categories from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Categories. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Categories **/ _count?: true | CategoryCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: CategoryMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: CategoryMaxAggregateInputType } export type GetCategoryAggregateType = { [P in keyof T & keyof AggregateCategory]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type CategoryGroupByArgs = { where?: CategoryWhereInput orderBy?: CategoryOrderByWithAggregationInput | CategoryOrderByWithAggregationInput[] by: CategoryScalarFieldEnum[] | CategoryScalarFieldEnum having?: CategoryScalarWhereWithAggregatesInput take?: number skip?: number _count?: CategoryCountAggregateInputType | true _min?: CategoryMinAggregateInputType _max?: CategoryMaxAggregateInputType } export type CategoryGroupByOutputType = { id: string title: string parentId: string | null _count: CategoryCountAggregateOutputType | null _min: CategoryMinAggregateOutputType | null _max: CategoryMaxAggregateOutputType | null } type GetCategoryGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof CategoryGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type CategorySelect = $Extensions.GetSelect<{ id?: boolean title?: boolean parentId?: boolean parent?: boolean | Category$parentArgs children?: boolean | Category$childrenArgs products?: boolean | Category$productsArgs _count?: boolean | CategoryCountOutputTypeDefaultArgs }, ExtArgs["result"]["category"]> export type CategorySelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean title?: boolean parentId?: boolean parent?: boolean | Category$parentArgs }, ExtArgs["result"]["category"]> export type CategorySelectScalar = { id?: boolean title?: boolean parentId?: boolean } export type CategoryInclude = { parent?: boolean | Category$parentArgs children?: boolean | Category$childrenArgs products?: boolean | Category$productsArgs _count?: boolean | CategoryCountOutputTypeDefaultArgs } export type CategoryIncludeCreateManyAndReturn = { parent?: boolean | Category$parentArgs } export type $CategoryPayload = { name: "Category" objects: { parent: Prisma.$CategoryPayload | null children: Prisma.$CategoryPayload[] products: Prisma.$ProductPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string title: string parentId: string | null }, ExtArgs["result"]["category"]> composites: {} } type CategoryGetPayload = $Result.GetResult type CategoryCountArgs = Omit & { select?: CategoryCountAggregateInputType | true } export interface CategoryDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Category'], meta: { name: 'Category' } } /** * Find zero or one Category that matches the filter. * @param {CategoryFindUniqueArgs} args - Arguments to find a Category * @example * // Get one Category * const category = await prisma.category.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__CategoryClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one Category that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {CategoryFindUniqueOrThrowArgs} args - Arguments to find a Category * @example * // Get one Category * const category = await prisma.category.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__CategoryClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first Category that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CategoryFindFirstArgs} args - Arguments to find a Category * @example * // Get one Category * const category = await prisma.category.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__CategoryClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first Category that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CategoryFindFirstOrThrowArgs} args - Arguments to find a Category * @example * // Get one Category * const category = await prisma.category.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__CategoryClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Categories that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CategoryFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Categories * const categories = await prisma.category.findMany() * * // Get first 10 Categories * const categories = await prisma.category.findMany({ take: 10 }) * * // Only select the `id` * const categoryWithIdOnly = await prisma.category.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a Category. * @param {CategoryCreateArgs} args - Arguments to create a Category. * @example * // Create one Category * const Category = await prisma.category.create({ * data: { * // ... data to create a Category * } * }) * */ create(args: SelectSubset>): Prisma__CategoryClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Categories. * @param {CategoryCreateManyArgs} args - Arguments to create many Categories. * @example * // Create many Categories * const category = await prisma.category.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Categories and returns the data saved in the database. * @param {CategoryCreateManyAndReturnArgs} args - Arguments to create many Categories. * @example * // Create many Categories * const category = await prisma.category.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Categories and only return the `id` * const categoryWithIdOnly = await prisma.category.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a Category. * @param {CategoryDeleteArgs} args - Arguments to delete one Category. * @example * // Delete one Category * const Category = await prisma.category.delete({ * where: { * // ... filter to delete one Category * } * }) * */ delete(args: SelectSubset>): Prisma__CategoryClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one Category. * @param {CategoryUpdateArgs} args - Arguments to update one Category. * @example * // Update one Category * const category = await prisma.category.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__CategoryClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Categories. * @param {CategoryDeleteManyArgs} args - Arguments to filter Categories to delete. * @example * // Delete a few Categories * const { count } = await prisma.category.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Categories. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CategoryUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Categories * const category = await prisma.category.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one Category. * @param {CategoryUpsertArgs} args - Arguments to update or create a Category. * @example * // Update or create a Category * const category = await prisma.category.upsert({ * create: { * // ... data to create a Category * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Category we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__CategoryClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Categories. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CategoryCountArgs} args - Arguments to filter Categories to count. * @example * // Count the number of Categories * const count = await prisma.category.count({ * where: { * // ... the filter for the Categories we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Category. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CategoryAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Category. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CategoryGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends CategoryGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: CategoryGroupByArgs['orderBy'] } : { orderBy?: CategoryGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCategoryGroupByPayload : Prisma.PrismaPromise /** * Fields of the Category model */ readonly fields: CategoryFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Category. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__CategoryClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" parent = {}>(args?: Subset>): Prisma__CategoryClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> children = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> products = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the Category model */ interface CategoryFieldRefs { readonly id: FieldRef<"Category", 'String'> readonly title: FieldRef<"Category", 'String'> readonly parentId: FieldRef<"Category", 'String'> } // Custom InputTypes /** * Category findUnique */ export type CategoryFindUniqueArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * Filter, which Category to fetch. */ where: CategoryWhereUniqueInput } /** * Category findUniqueOrThrow */ export type CategoryFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * Filter, which Category to fetch. */ where: CategoryWhereUniqueInput } /** * Category findFirst */ export type CategoryFindFirstArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * Filter, which Category to fetch. */ where?: CategoryWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Categories to fetch. */ orderBy?: CategoryOrderByWithRelationInput | CategoryOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Categories. */ cursor?: CategoryWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Categories from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Categories. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Categories. */ distinct?: CategoryScalarFieldEnum | CategoryScalarFieldEnum[] } /** * Category findFirstOrThrow */ export type CategoryFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * Filter, which Category to fetch. */ where?: CategoryWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Categories to fetch. */ orderBy?: CategoryOrderByWithRelationInput | CategoryOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Categories. */ cursor?: CategoryWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Categories from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Categories. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Categories. */ distinct?: CategoryScalarFieldEnum | CategoryScalarFieldEnum[] } /** * Category findMany */ export type CategoryFindManyArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * Filter, which Categories to fetch. */ where?: CategoryWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Categories to fetch. */ orderBy?: CategoryOrderByWithRelationInput | CategoryOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Categories. */ cursor?: CategoryWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Categories from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Categories. */ skip?: number distinct?: CategoryScalarFieldEnum | CategoryScalarFieldEnum[] } /** * Category create */ export type CategoryCreateArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * The data needed to create a Category. */ data: XOR } /** * Category createMany */ export type CategoryCreateManyArgs = { /** * The data used to create many Categories. */ data: CategoryCreateManyInput | CategoryCreateManyInput[] skipDuplicates?: boolean } /** * Category createManyAndReturn */ export type CategoryCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelectCreateManyAndReturn | null /** * The data used to create many Categories. */ data: CategoryCreateManyInput | CategoryCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: CategoryIncludeCreateManyAndReturn | null } /** * Category update */ export type CategoryUpdateArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * The data needed to update a Category. */ data: XOR /** * Choose, which Category to update. */ where: CategoryWhereUniqueInput } /** * Category updateMany */ export type CategoryUpdateManyArgs = { /** * The data used to update Categories. */ data: XOR /** * Filter which Categories to update */ where?: CategoryWhereInput } /** * Category upsert */ export type CategoryUpsertArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * The filter to search for the Category to update in case it exists. */ where: CategoryWhereUniqueInput /** * In case the Category found by the `where` argument doesn't exist, create a new Category with this data. */ create: XOR /** * In case the Category was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Category delete */ export type CategoryDeleteArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null /** * Filter which Category to delete. */ where: CategoryWhereUniqueInput } /** * Category deleteMany */ export type CategoryDeleteManyArgs = { /** * Filter which Categories to delete */ where?: CategoryWhereInput } /** * Category.parent */ export type Category$parentArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null where?: CategoryWhereInput } /** * Category.children */ export type Category$childrenArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null where?: CategoryWhereInput orderBy?: CategoryOrderByWithRelationInput | CategoryOrderByWithRelationInput[] cursor?: CategoryWhereUniqueInput take?: number skip?: number distinct?: CategoryScalarFieldEnum | CategoryScalarFieldEnum[] } /** * Category.products */ export type Category$productsArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null where?: ProductWhereInput orderBy?: ProductOrderByWithRelationInput | ProductOrderByWithRelationInput[] cursor?: ProductWhereUniqueInput take?: number skip?: number distinct?: ProductScalarFieldEnum | ProductScalarFieldEnum[] } /** * Category without action */ export type CategoryDefaultArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null } /** * Model Brand */ export type AggregateBrand = { _count: BrandCountAggregateOutputType | null _min: BrandMinAggregateOutputType | null _max: BrandMaxAggregateOutputType | null } export type BrandMinAggregateOutputType = { id: string | null title: string | null } export type BrandMaxAggregateOutputType = { id: string | null title: string | null } export type BrandCountAggregateOutputType = { id: number title: number _all: number } export type BrandMinAggregateInputType = { id?: true title?: true } export type BrandMaxAggregateInputType = { id?: true title?: true } export type BrandCountAggregateInputType = { id?: true title?: true _all?: true } export type BrandAggregateArgs = { /** * Filter which Brand to aggregate. */ where?: BrandWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Brands to fetch. */ orderBy?: BrandOrderByWithRelationInput | BrandOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: BrandWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Brands from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Brands. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Brands **/ _count?: true | BrandCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: BrandMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: BrandMaxAggregateInputType } export type GetBrandAggregateType = { [P in keyof T & keyof AggregateBrand]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type BrandGroupByArgs = { where?: BrandWhereInput orderBy?: BrandOrderByWithAggregationInput | BrandOrderByWithAggregationInput[] by: BrandScalarFieldEnum[] | BrandScalarFieldEnum having?: BrandScalarWhereWithAggregatesInput take?: number skip?: number _count?: BrandCountAggregateInputType | true _min?: BrandMinAggregateInputType _max?: BrandMaxAggregateInputType } export type BrandGroupByOutputType = { id: string title: string _count: BrandCountAggregateOutputType | null _min: BrandMinAggregateOutputType | null _max: BrandMaxAggregateOutputType | null } type GetBrandGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof BrandGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type BrandSelect = $Extensions.GetSelect<{ id?: boolean title?: boolean products?: boolean | Brand$productsArgs _count?: boolean | BrandCountOutputTypeDefaultArgs }, ExtArgs["result"]["brand"]> export type BrandSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean title?: boolean }, ExtArgs["result"]["brand"]> export type BrandSelectScalar = { id?: boolean title?: boolean } export type BrandInclude = { products?: boolean | Brand$productsArgs _count?: boolean | BrandCountOutputTypeDefaultArgs } export type BrandIncludeCreateManyAndReturn = {} export type $BrandPayload = { name: "Brand" objects: { products: Prisma.$ProductPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string title: string }, ExtArgs["result"]["brand"]> composites: {} } type BrandGetPayload = $Result.GetResult type BrandCountArgs = Omit & { select?: BrandCountAggregateInputType | true } export interface BrandDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Brand'], meta: { name: 'Brand' } } /** * Find zero or one Brand that matches the filter. * @param {BrandFindUniqueArgs} args - Arguments to find a Brand * @example * // Get one Brand * const brand = await prisma.brand.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__BrandClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one Brand that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {BrandFindUniqueOrThrowArgs} args - Arguments to find a Brand * @example * // Get one Brand * const brand = await prisma.brand.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__BrandClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first Brand that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BrandFindFirstArgs} args - Arguments to find a Brand * @example * // Get one Brand * const brand = await prisma.brand.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__BrandClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first Brand that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BrandFindFirstOrThrowArgs} args - Arguments to find a Brand * @example * // Get one Brand * const brand = await prisma.brand.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__BrandClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Brands that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BrandFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Brands * const brands = await prisma.brand.findMany() * * // Get first 10 Brands * const brands = await prisma.brand.findMany({ take: 10 }) * * // Only select the `id` * const brandWithIdOnly = await prisma.brand.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a Brand. * @param {BrandCreateArgs} args - Arguments to create a Brand. * @example * // Create one Brand * const Brand = await prisma.brand.create({ * data: { * // ... data to create a Brand * } * }) * */ create(args: SelectSubset>): Prisma__BrandClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Brands. * @param {BrandCreateManyArgs} args - Arguments to create many Brands. * @example * // Create many Brands * const brand = await prisma.brand.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Brands and returns the data saved in the database. * @param {BrandCreateManyAndReturnArgs} args - Arguments to create many Brands. * @example * // Create many Brands * const brand = await prisma.brand.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Brands and only return the `id` * const brandWithIdOnly = await prisma.brand.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a Brand. * @param {BrandDeleteArgs} args - Arguments to delete one Brand. * @example * // Delete one Brand * const Brand = await prisma.brand.delete({ * where: { * // ... filter to delete one Brand * } * }) * */ delete(args: SelectSubset>): Prisma__BrandClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one Brand. * @param {BrandUpdateArgs} args - Arguments to update one Brand. * @example * // Update one Brand * const brand = await prisma.brand.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__BrandClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Brands. * @param {BrandDeleteManyArgs} args - Arguments to filter Brands to delete. * @example * // Delete a few Brands * const { count } = await prisma.brand.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Brands. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BrandUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Brands * const brand = await prisma.brand.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one Brand. * @param {BrandUpsertArgs} args - Arguments to update or create a Brand. * @example * // Update or create a Brand * const brand = await prisma.brand.upsert({ * create: { * // ... data to create a Brand * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Brand we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__BrandClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Brands. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BrandCountArgs} args - Arguments to filter Brands to count. * @example * // Count the number of Brands * const count = await prisma.brand.count({ * where: { * // ... the filter for the Brands we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Brand. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BrandAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Brand. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {BrandGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends BrandGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: BrandGroupByArgs['orderBy'] } : { orderBy?: BrandGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetBrandGroupByPayload : Prisma.PrismaPromise /** * Fields of the Brand model */ readonly fields: BrandFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Brand. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__BrandClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" products = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the Brand model */ interface BrandFieldRefs { readonly id: FieldRef<"Brand", 'String'> readonly title: FieldRef<"Brand", 'String'> } // Custom InputTypes /** * Brand findUnique */ export type BrandFindUniqueArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * Filter, which Brand to fetch. */ where: BrandWhereUniqueInput } /** * Brand findUniqueOrThrow */ export type BrandFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * Filter, which Brand to fetch. */ where: BrandWhereUniqueInput } /** * Brand findFirst */ export type BrandFindFirstArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * Filter, which Brand to fetch. */ where?: BrandWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Brands to fetch. */ orderBy?: BrandOrderByWithRelationInput | BrandOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Brands. */ cursor?: BrandWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Brands from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Brands. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Brands. */ distinct?: BrandScalarFieldEnum | BrandScalarFieldEnum[] } /** * Brand findFirstOrThrow */ export type BrandFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * Filter, which Brand to fetch. */ where?: BrandWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Brands to fetch. */ orderBy?: BrandOrderByWithRelationInput | BrandOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Brands. */ cursor?: BrandWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Brands from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Brands. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Brands. */ distinct?: BrandScalarFieldEnum | BrandScalarFieldEnum[] } /** * Brand findMany */ export type BrandFindManyArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * Filter, which Brands to fetch. */ where?: BrandWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Brands to fetch. */ orderBy?: BrandOrderByWithRelationInput | BrandOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Brands. */ cursor?: BrandWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Brands from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Brands. */ skip?: number distinct?: BrandScalarFieldEnum | BrandScalarFieldEnum[] } /** * Brand create */ export type BrandCreateArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * The data needed to create a Brand. */ data: XOR } /** * Brand createMany */ export type BrandCreateManyArgs = { /** * The data used to create many Brands. */ data: BrandCreateManyInput | BrandCreateManyInput[] skipDuplicates?: boolean } /** * Brand createManyAndReturn */ export type BrandCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelectCreateManyAndReturn | null /** * The data used to create many Brands. */ data: BrandCreateManyInput | BrandCreateManyInput[] skipDuplicates?: boolean } /** * Brand update */ export type BrandUpdateArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * The data needed to update a Brand. */ data: XOR /** * Choose, which Brand to update. */ where: BrandWhereUniqueInput } /** * Brand updateMany */ export type BrandUpdateManyArgs = { /** * The data used to update Brands. */ data: XOR /** * Filter which Brands to update */ where?: BrandWhereInput } /** * Brand upsert */ export type BrandUpsertArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * The filter to search for the Brand to update in case it exists. */ where: BrandWhereUniqueInput /** * In case the Brand found by the `where` argument doesn't exist, create a new Brand with this data. */ create: XOR /** * In case the Brand was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Brand delete */ export type BrandDeleteArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null /** * Filter which Brand to delete. */ where: BrandWhereUniqueInput } /** * Brand deleteMany */ export type BrandDeleteManyArgs = { /** * Filter which Brands to delete */ where?: BrandWhereInput } /** * Brand.products */ export type Brand$productsArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null where?: ProductWhereInput orderBy?: ProductOrderByWithRelationInput | ProductOrderByWithRelationInput[] cursor?: ProductWhereUniqueInput take?: number skip?: number distinct?: ProductScalarFieldEnum | ProductScalarFieldEnum[] } /** * Brand without action */ export type BrandDefaultArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null } /** * Model Collection */ export type AggregateCollection = { _count: CollectionCountAggregateOutputType | null _min: CollectionMinAggregateOutputType | null _max: CollectionMaxAggregateOutputType | null } export type CollectionMinAggregateOutputType = { id: string | null title: string | null description: string | null isActive: boolean | null } export type CollectionMaxAggregateOutputType = { id: string | null title: string | null description: string | null isActive: boolean | null } export type CollectionCountAggregateOutputType = { id: number title: number description: number isActive: number _all: number } export type CollectionMinAggregateInputType = { id?: true title?: true description?: true isActive?: true } export type CollectionMaxAggregateInputType = { id?: true title?: true description?: true isActive?: true } export type CollectionCountAggregateInputType = { id?: true title?: true description?: true isActive?: true _all?: true } export type CollectionAggregateArgs = { /** * Filter which Collection to aggregate. */ where?: CollectionWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Collections to fetch. */ orderBy?: CollectionOrderByWithRelationInput | CollectionOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: CollectionWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Collections from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Collections. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Collections **/ _count?: true | CollectionCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: CollectionMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: CollectionMaxAggregateInputType } export type GetCollectionAggregateType = { [P in keyof T & keyof AggregateCollection]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type CollectionGroupByArgs = { where?: CollectionWhereInput orderBy?: CollectionOrderByWithAggregationInput | CollectionOrderByWithAggregationInput[] by: CollectionScalarFieldEnum[] | CollectionScalarFieldEnum having?: CollectionScalarWhereWithAggregatesInput take?: number skip?: number _count?: CollectionCountAggregateInputType | true _min?: CollectionMinAggregateInputType _max?: CollectionMaxAggregateInputType } export type CollectionGroupByOutputType = { id: string title: string description: string | null isActive: boolean _count: CollectionCountAggregateOutputType | null _min: CollectionMinAggregateOutputType | null _max: CollectionMaxAggregateOutputType | null } type GetCollectionGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof CollectionGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type CollectionSelect = $Extensions.GetSelect<{ id?: boolean title?: boolean description?: boolean isActive?: boolean products?: boolean | Collection$productsArgs _count?: boolean | CollectionCountOutputTypeDefaultArgs }, ExtArgs["result"]["collection"]> export type CollectionSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean title?: boolean description?: boolean isActive?: boolean }, ExtArgs["result"]["collection"]> export type CollectionSelectScalar = { id?: boolean title?: boolean description?: boolean isActive?: boolean } export type CollectionInclude = { products?: boolean | Collection$productsArgs _count?: boolean | CollectionCountOutputTypeDefaultArgs } export type CollectionIncludeCreateManyAndReturn = {} export type $CollectionPayload = { name: "Collection" objects: { products: Prisma.$CollectionProductPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string title: string description: string | null isActive: boolean }, ExtArgs["result"]["collection"]> composites: {} } type CollectionGetPayload = $Result.GetResult type CollectionCountArgs = Omit & { select?: CollectionCountAggregateInputType | true } export interface CollectionDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Collection'], meta: { name: 'Collection' } } /** * Find zero or one Collection that matches the filter. * @param {CollectionFindUniqueArgs} args - Arguments to find a Collection * @example * // Get one Collection * const collection = await prisma.collection.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__CollectionClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one Collection that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {CollectionFindUniqueOrThrowArgs} args - Arguments to find a Collection * @example * // Get one Collection * const collection = await prisma.collection.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__CollectionClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first Collection that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionFindFirstArgs} args - Arguments to find a Collection * @example * // Get one Collection * const collection = await prisma.collection.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__CollectionClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first Collection that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionFindFirstOrThrowArgs} args - Arguments to find a Collection * @example * // Get one Collection * const collection = await prisma.collection.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__CollectionClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Collections that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Collections * const collections = await prisma.collection.findMany() * * // Get first 10 Collections * const collections = await prisma.collection.findMany({ take: 10 }) * * // Only select the `id` * const collectionWithIdOnly = await prisma.collection.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a Collection. * @param {CollectionCreateArgs} args - Arguments to create a Collection. * @example * // Create one Collection * const Collection = await prisma.collection.create({ * data: { * // ... data to create a Collection * } * }) * */ create(args: SelectSubset>): Prisma__CollectionClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Collections. * @param {CollectionCreateManyArgs} args - Arguments to create many Collections. * @example * // Create many Collections * const collection = await prisma.collection.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Collections and returns the data saved in the database. * @param {CollectionCreateManyAndReturnArgs} args - Arguments to create many Collections. * @example * // Create many Collections * const collection = await prisma.collection.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Collections and only return the `id` * const collectionWithIdOnly = await prisma.collection.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a Collection. * @param {CollectionDeleteArgs} args - Arguments to delete one Collection. * @example * // Delete one Collection * const Collection = await prisma.collection.delete({ * where: { * // ... filter to delete one Collection * } * }) * */ delete(args: SelectSubset>): Prisma__CollectionClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one Collection. * @param {CollectionUpdateArgs} args - Arguments to update one Collection. * @example * // Update one Collection * const collection = await prisma.collection.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__CollectionClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Collections. * @param {CollectionDeleteManyArgs} args - Arguments to filter Collections to delete. * @example * // Delete a few Collections * const { count } = await prisma.collection.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Collections. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Collections * const collection = await prisma.collection.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one Collection. * @param {CollectionUpsertArgs} args - Arguments to update or create a Collection. * @example * // Update or create a Collection * const collection = await prisma.collection.upsert({ * create: { * // ... data to create a Collection * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Collection we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__CollectionClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Collections. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionCountArgs} args - Arguments to filter Collections to count. * @example * // Count the number of Collections * const count = await prisma.collection.count({ * where: { * // ... the filter for the Collections we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Collection. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Collection. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends CollectionGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: CollectionGroupByArgs['orderBy'] } : { orderBy?: CollectionGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCollectionGroupByPayload : Prisma.PrismaPromise /** * Fields of the Collection model */ readonly fields: CollectionFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Collection. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__CollectionClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" products = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the Collection model */ interface CollectionFieldRefs { readonly id: FieldRef<"Collection", 'String'> readonly title: FieldRef<"Collection", 'String'> readonly description: FieldRef<"Collection", 'String'> readonly isActive: FieldRef<"Collection", 'Boolean'> } // Custom InputTypes /** * Collection findUnique */ export type CollectionFindUniqueArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * Filter, which Collection to fetch. */ where: CollectionWhereUniqueInput } /** * Collection findUniqueOrThrow */ export type CollectionFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * Filter, which Collection to fetch. */ where: CollectionWhereUniqueInput } /** * Collection findFirst */ export type CollectionFindFirstArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * Filter, which Collection to fetch. */ where?: CollectionWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Collections to fetch. */ orderBy?: CollectionOrderByWithRelationInput | CollectionOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Collections. */ cursor?: CollectionWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Collections from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Collections. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Collections. */ distinct?: CollectionScalarFieldEnum | CollectionScalarFieldEnum[] } /** * Collection findFirstOrThrow */ export type CollectionFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * Filter, which Collection to fetch. */ where?: CollectionWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Collections to fetch. */ orderBy?: CollectionOrderByWithRelationInput | CollectionOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Collections. */ cursor?: CollectionWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Collections from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Collections. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Collections. */ distinct?: CollectionScalarFieldEnum | CollectionScalarFieldEnum[] } /** * Collection findMany */ export type CollectionFindManyArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * Filter, which Collections to fetch. */ where?: CollectionWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Collections to fetch. */ orderBy?: CollectionOrderByWithRelationInput | CollectionOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Collections. */ cursor?: CollectionWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Collections from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Collections. */ skip?: number distinct?: CollectionScalarFieldEnum | CollectionScalarFieldEnum[] } /** * Collection create */ export type CollectionCreateArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * The data needed to create a Collection. */ data: XOR } /** * Collection createMany */ export type CollectionCreateManyArgs = { /** * The data used to create many Collections. */ data: CollectionCreateManyInput | CollectionCreateManyInput[] skipDuplicates?: boolean } /** * Collection createManyAndReturn */ export type CollectionCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelectCreateManyAndReturn | null /** * The data used to create many Collections. */ data: CollectionCreateManyInput | CollectionCreateManyInput[] skipDuplicates?: boolean } /** * Collection update */ export type CollectionUpdateArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * The data needed to update a Collection. */ data: XOR /** * Choose, which Collection to update. */ where: CollectionWhereUniqueInput } /** * Collection updateMany */ export type CollectionUpdateManyArgs = { /** * The data used to update Collections. */ data: XOR /** * Filter which Collections to update */ where?: CollectionWhereInput } /** * Collection upsert */ export type CollectionUpsertArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * The filter to search for the Collection to update in case it exists. */ where: CollectionWhereUniqueInput /** * In case the Collection found by the `where` argument doesn't exist, create a new Collection with this data. */ create: XOR /** * In case the Collection was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Collection delete */ export type CollectionDeleteArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null /** * Filter which Collection to delete. */ where: CollectionWhereUniqueInput } /** * Collection deleteMany */ export type CollectionDeleteManyArgs = { /** * Filter which Collections to delete */ where?: CollectionWhereInput } /** * Collection.products */ export type Collection$productsArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null where?: CollectionProductWhereInput orderBy?: CollectionProductOrderByWithRelationInput | CollectionProductOrderByWithRelationInput[] cursor?: CollectionProductWhereUniqueInput take?: number skip?: number distinct?: CollectionProductScalarFieldEnum | CollectionProductScalarFieldEnum[] } /** * Collection without action */ export type CollectionDefaultArgs = { /** * Select specific fields to fetch from the Collection */ select?: CollectionSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionInclude | null } /** * Model CollectionProduct */ export type AggregateCollectionProduct = { _count: CollectionProductCountAggregateOutputType | null _min: CollectionProductMinAggregateOutputType | null _max: CollectionProductMaxAggregateOutputType | null } export type CollectionProductMinAggregateOutputType = { collectionId: string | null productId: string | null } export type CollectionProductMaxAggregateOutputType = { collectionId: string | null productId: string | null } export type CollectionProductCountAggregateOutputType = { collectionId: number productId: number _all: number } export type CollectionProductMinAggregateInputType = { collectionId?: true productId?: true } export type CollectionProductMaxAggregateInputType = { collectionId?: true productId?: true } export type CollectionProductCountAggregateInputType = { collectionId?: true productId?: true _all?: true } export type CollectionProductAggregateArgs = { /** * Filter which CollectionProduct to aggregate. */ where?: CollectionProductWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CollectionProducts to fetch. */ orderBy?: CollectionProductOrderByWithRelationInput | CollectionProductOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: CollectionProductWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CollectionProducts from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CollectionProducts. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned CollectionProducts **/ _count?: true | CollectionProductCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: CollectionProductMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: CollectionProductMaxAggregateInputType } export type GetCollectionProductAggregateType = { [P in keyof T & keyof AggregateCollectionProduct]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type CollectionProductGroupByArgs = { where?: CollectionProductWhereInput orderBy?: CollectionProductOrderByWithAggregationInput | CollectionProductOrderByWithAggregationInput[] by: CollectionProductScalarFieldEnum[] | CollectionProductScalarFieldEnum having?: CollectionProductScalarWhereWithAggregatesInput take?: number skip?: number _count?: CollectionProductCountAggregateInputType | true _min?: CollectionProductMinAggregateInputType _max?: CollectionProductMaxAggregateInputType } export type CollectionProductGroupByOutputType = { collectionId: string productId: string _count: CollectionProductCountAggregateOutputType | null _min: CollectionProductMinAggregateOutputType | null _max: CollectionProductMaxAggregateOutputType | null } type GetCollectionProductGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof CollectionProductGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type CollectionProductSelect = $Extensions.GetSelect<{ collectionId?: boolean productId?: boolean collection?: boolean | CollectionDefaultArgs product?: boolean | ProductDefaultArgs }, ExtArgs["result"]["collectionProduct"]> export type CollectionProductSelectCreateManyAndReturn = $Extensions.GetSelect<{ collectionId?: boolean productId?: boolean collection?: boolean | CollectionDefaultArgs product?: boolean | ProductDefaultArgs }, ExtArgs["result"]["collectionProduct"]> export type CollectionProductSelectScalar = { collectionId?: boolean productId?: boolean } export type CollectionProductInclude = { collection?: boolean | CollectionDefaultArgs product?: boolean | ProductDefaultArgs } export type CollectionProductIncludeCreateManyAndReturn = { collection?: boolean | CollectionDefaultArgs product?: boolean | ProductDefaultArgs } export type $CollectionProductPayload = { name: "CollectionProduct" objects: { collection: Prisma.$CollectionPayload product: Prisma.$ProductPayload } scalars: $Extensions.GetPayloadResult<{ collectionId: string productId: string }, ExtArgs["result"]["collectionProduct"]> composites: {} } type CollectionProductGetPayload = $Result.GetResult type CollectionProductCountArgs = Omit & { select?: CollectionProductCountAggregateInputType | true } export interface CollectionProductDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['CollectionProduct'], meta: { name: 'CollectionProduct' } } /** * Find zero or one CollectionProduct that matches the filter. * @param {CollectionProductFindUniqueArgs} args - Arguments to find a CollectionProduct * @example * // Get one CollectionProduct * const collectionProduct = await prisma.collectionProduct.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__CollectionProductClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one CollectionProduct that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {CollectionProductFindUniqueOrThrowArgs} args - Arguments to find a CollectionProduct * @example * // Get one CollectionProduct * const collectionProduct = await prisma.collectionProduct.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__CollectionProductClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first CollectionProduct that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionProductFindFirstArgs} args - Arguments to find a CollectionProduct * @example * // Get one CollectionProduct * const collectionProduct = await prisma.collectionProduct.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__CollectionProductClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first CollectionProduct that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionProductFindFirstOrThrowArgs} args - Arguments to find a CollectionProduct * @example * // Get one CollectionProduct * const collectionProduct = await prisma.collectionProduct.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__CollectionProductClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more CollectionProducts that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionProductFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all CollectionProducts * const collectionProducts = await prisma.collectionProduct.findMany() * * // Get first 10 CollectionProducts * const collectionProducts = await prisma.collectionProduct.findMany({ take: 10 }) * * // Only select the `collectionId` * const collectionProductWithCollectionIdOnly = await prisma.collectionProduct.findMany({ select: { collectionId: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a CollectionProduct. * @param {CollectionProductCreateArgs} args - Arguments to create a CollectionProduct. * @example * // Create one CollectionProduct * const CollectionProduct = await prisma.collectionProduct.create({ * data: { * // ... data to create a CollectionProduct * } * }) * */ create(args: SelectSubset>): Prisma__CollectionProductClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many CollectionProducts. * @param {CollectionProductCreateManyArgs} args - Arguments to create many CollectionProducts. * @example * // Create many CollectionProducts * const collectionProduct = await prisma.collectionProduct.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many CollectionProducts and returns the data saved in the database. * @param {CollectionProductCreateManyAndReturnArgs} args - Arguments to create many CollectionProducts. * @example * // Create many CollectionProducts * const collectionProduct = await prisma.collectionProduct.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many CollectionProducts and only return the `collectionId` * const collectionProductWithCollectionIdOnly = await prisma.collectionProduct.createManyAndReturn({ * select: { collectionId: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a CollectionProduct. * @param {CollectionProductDeleteArgs} args - Arguments to delete one CollectionProduct. * @example * // Delete one CollectionProduct * const CollectionProduct = await prisma.collectionProduct.delete({ * where: { * // ... filter to delete one CollectionProduct * } * }) * */ delete(args: SelectSubset>): Prisma__CollectionProductClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one CollectionProduct. * @param {CollectionProductUpdateArgs} args - Arguments to update one CollectionProduct. * @example * // Update one CollectionProduct * const collectionProduct = await prisma.collectionProduct.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__CollectionProductClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more CollectionProducts. * @param {CollectionProductDeleteManyArgs} args - Arguments to filter CollectionProducts to delete. * @example * // Delete a few CollectionProducts * const { count } = await prisma.collectionProduct.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more CollectionProducts. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionProductUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many CollectionProducts * const collectionProduct = await prisma.collectionProduct.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one CollectionProduct. * @param {CollectionProductUpsertArgs} args - Arguments to update or create a CollectionProduct. * @example * // Update or create a CollectionProduct * const collectionProduct = await prisma.collectionProduct.upsert({ * create: { * // ... data to create a CollectionProduct * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the CollectionProduct we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__CollectionProductClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of CollectionProducts. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionProductCountArgs} args - Arguments to filter CollectionProducts to count. * @example * // Count the number of CollectionProducts * const count = await prisma.collectionProduct.count({ * where: { * // ... the filter for the CollectionProducts we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a CollectionProduct. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionProductAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by CollectionProduct. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {CollectionProductGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends CollectionProductGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: CollectionProductGroupByArgs['orderBy'] } : { orderBy?: CollectionProductGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetCollectionProductGroupByPayload : Prisma.PrismaPromise /** * Fields of the CollectionProduct model */ readonly fields: CollectionProductFieldRefs; } /** * The delegate class that acts as a "Promise-like" for CollectionProduct. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__CollectionProductClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" collection = {}>(args?: Subset>): Prisma__CollectionClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> product = {}>(args?: Subset>): Prisma__ProductClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the CollectionProduct model */ interface CollectionProductFieldRefs { readonly collectionId: FieldRef<"CollectionProduct", 'String'> readonly productId: FieldRef<"CollectionProduct", 'String'> } // Custom InputTypes /** * CollectionProduct findUnique */ export type CollectionProductFindUniqueArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * Filter, which CollectionProduct to fetch. */ where: CollectionProductWhereUniqueInput } /** * CollectionProduct findUniqueOrThrow */ export type CollectionProductFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * Filter, which CollectionProduct to fetch. */ where: CollectionProductWhereUniqueInput } /** * CollectionProduct findFirst */ export type CollectionProductFindFirstArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * Filter, which CollectionProduct to fetch. */ where?: CollectionProductWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CollectionProducts to fetch. */ orderBy?: CollectionProductOrderByWithRelationInput | CollectionProductOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for CollectionProducts. */ cursor?: CollectionProductWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CollectionProducts from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CollectionProducts. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of CollectionProducts. */ distinct?: CollectionProductScalarFieldEnum | CollectionProductScalarFieldEnum[] } /** * CollectionProduct findFirstOrThrow */ export type CollectionProductFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * Filter, which CollectionProduct to fetch. */ where?: CollectionProductWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CollectionProducts to fetch. */ orderBy?: CollectionProductOrderByWithRelationInput | CollectionProductOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for CollectionProducts. */ cursor?: CollectionProductWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CollectionProducts from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CollectionProducts. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of CollectionProducts. */ distinct?: CollectionProductScalarFieldEnum | CollectionProductScalarFieldEnum[] } /** * CollectionProduct findMany */ export type CollectionProductFindManyArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * Filter, which CollectionProducts to fetch. */ where?: CollectionProductWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of CollectionProducts to fetch. */ orderBy?: CollectionProductOrderByWithRelationInput | CollectionProductOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing CollectionProducts. */ cursor?: CollectionProductWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` CollectionProducts from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` CollectionProducts. */ skip?: number distinct?: CollectionProductScalarFieldEnum | CollectionProductScalarFieldEnum[] } /** * CollectionProduct create */ export type CollectionProductCreateArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * The data needed to create a CollectionProduct. */ data: XOR } /** * CollectionProduct createMany */ export type CollectionProductCreateManyArgs = { /** * The data used to create many CollectionProducts. */ data: CollectionProductCreateManyInput | CollectionProductCreateManyInput[] skipDuplicates?: boolean } /** * CollectionProduct createManyAndReturn */ export type CollectionProductCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelectCreateManyAndReturn | null /** * The data used to create many CollectionProducts. */ data: CollectionProductCreateManyInput | CollectionProductCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: CollectionProductIncludeCreateManyAndReturn | null } /** * CollectionProduct update */ export type CollectionProductUpdateArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * The data needed to update a CollectionProduct. */ data: XOR /** * Choose, which CollectionProduct to update. */ where: CollectionProductWhereUniqueInput } /** * CollectionProduct updateMany */ export type CollectionProductUpdateManyArgs = { /** * The data used to update CollectionProducts. */ data: XOR /** * Filter which CollectionProducts to update */ where?: CollectionProductWhereInput } /** * CollectionProduct upsert */ export type CollectionProductUpsertArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * The filter to search for the CollectionProduct to update in case it exists. */ where: CollectionProductWhereUniqueInput /** * In case the CollectionProduct found by the `where` argument doesn't exist, create a new CollectionProduct with this data. */ create: XOR /** * In case the CollectionProduct was found with the provided `where` argument, update it with this data. */ update: XOR } /** * CollectionProduct delete */ export type CollectionProductDeleteArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null /** * Filter which CollectionProduct to delete. */ where: CollectionProductWhereUniqueInput } /** * CollectionProduct deleteMany */ export type CollectionProductDeleteManyArgs = { /** * Filter which CollectionProducts to delete */ where?: CollectionProductWhereInput } /** * CollectionProduct without action */ export type CollectionProductDefaultArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null } /** * Model Product */ export type AggregateProduct = { _count: ProductCountAggregateOutputType | null _min: ProductMinAggregateOutputType | null _max: ProductMaxAggregateOutputType | null } export type ProductMinAggregateOutputType = { id: string | null title: string | null description: string | null categoryId: string | null brandId: string | null isActive: boolean | null createdAt: Date | null } export type ProductMaxAggregateOutputType = { id: string | null title: string | null description: string | null categoryId: string | null brandId: string | null isActive: boolean | null createdAt: Date | null } export type ProductCountAggregateOutputType = { id: number title: number description: number categoryId: number brandId: number isActive: number createdAt: number _all: number } export type ProductMinAggregateInputType = { id?: true title?: true description?: true categoryId?: true brandId?: true isActive?: true createdAt?: true } export type ProductMaxAggregateInputType = { id?: true title?: true description?: true categoryId?: true brandId?: true isActive?: true createdAt?: true } export type ProductCountAggregateInputType = { id?: true title?: true description?: true categoryId?: true brandId?: true isActive?: true createdAt?: true _all?: true } export type ProductAggregateArgs = { /** * Filter which Product to aggregate. */ where?: ProductWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Products to fetch. */ orderBy?: ProductOrderByWithRelationInput | ProductOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: ProductWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Products from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Products. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Products **/ _count?: true | ProductCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: ProductMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: ProductMaxAggregateInputType } export type GetProductAggregateType = { [P in keyof T & keyof AggregateProduct]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type ProductGroupByArgs = { where?: ProductWhereInput orderBy?: ProductOrderByWithAggregationInput | ProductOrderByWithAggregationInput[] by: ProductScalarFieldEnum[] | ProductScalarFieldEnum having?: ProductScalarWhereWithAggregatesInput take?: number skip?: number _count?: ProductCountAggregateInputType | true _min?: ProductMinAggregateInputType _max?: ProductMaxAggregateInputType } export type ProductGroupByOutputType = { id: string title: string description: string | null categoryId: string | null brandId: string | null isActive: boolean createdAt: Date _count: ProductCountAggregateOutputType | null _min: ProductMinAggregateOutputType | null _max: ProductMaxAggregateOutputType | null } type GetProductGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof ProductGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type ProductSelect = $Extensions.GetSelect<{ id?: boolean title?: boolean description?: boolean categoryId?: boolean brandId?: boolean isActive?: boolean createdAt?: boolean category?: boolean | Product$categoryArgs brand?: boolean | Product$brandArgs variants?: boolean | Product$variantsArgs images?: boolean | Product$imagesArgs collections?: boolean | Product$collectionsArgs _count?: boolean | ProductCountOutputTypeDefaultArgs }, ExtArgs["result"]["product"]> export type ProductSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean title?: boolean description?: boolean categoryId?: boolean brandId?: boolean isActive?: boolean createdAt?: boolean category?: boolean | Product$categoryArgs brand?: boolean | Product$brandArgs }, ExtArgs["result"]["product"]> export type ProductSelectScalar = { id?: boolean title?: boolean description?: boolean categoryId?: boolean brandId?: boolean isActive?: boolean createdAt?: boolean } export type ProductInclude = { category?: boolean | Product$categoryArgs brand?: boolean | Product$brandArgs variants?: boolean | Product$variantsArgs images?: boolean | Product$imagesArgs collections?: boolean | Product$collectionsArgs _count?: boolean | ProductCountOutputTypeDefaultArgs } export type ProductIncludeCreateManyAndReturn = { category?: boolean | Product$categoryArgs brand?: boolean | Product$brandArgs } export type $ProductPayload = { name: "Product" objects: { category: Prisma.$CategoryPayload | null brand: Prisma.$BrandPayload | null variants: Prisma.$ProductVariantPayload[] images: Prisma.$ProductImagePayload[] collections: Prisma.$CollectionProductPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string title: string description: string | null categoryId: string | null brandId: string | null isActive: boolean createdAt: Date }, ExtArgs["result"]["product"]> composites: {} } type ProductGetPayload = $Result.GetResult type ProductCountArgs = Omit & { select?: ProductCountAggregateInputType | true } export interface ProductDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Product'], meta: { name: 'Product' } } /** * Find zero or one Product that matches the filter. * @param {ProductFindUniqueArgs} args - Arguments to find a Product * @example * // Get one Product * const product = await prisma.product.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__ProductClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one Product that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {ProductFindUniqueOrThrowArgs} args - Arguments to find a Product * @example * // Get one Product * const product = await prisma.product.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__ProductClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first Product that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductFindFirstArgs} args - Arguments to find a Product * @example * // Get one Product * const product = await prisma.product.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__ProductClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first Product that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductFindFirstOrThrowArgs} args - Arguments to find a Product * @example * // Get one Product * const product = await prisma.product.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__ProductClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Products that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Products * const products = await prisma.product.findMany() * * // Get first 10 Products * const products = await prisma.product.findMany({ take: 10 }) * * // Only select the `id` * const productWithIdOnly = await prisma.product.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a Product. * @param {ProductCreateArgs} args - Arguments to create a Product. * @example * // Create one Product * const Product = await prisma.product.create({ * data: { * // ... data to create a Product * } * }) * */ create(args: SelectSubset>): Prisma__ProductClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Products. * @param {ProductCreateManyArgs} args - Arguments to create many Products. * @example * // Create many Products * const product = await prisma.product.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Products and returns the data saved in the database. * @param {ProductCreateManyAndReturnArgs} args - Arguments to create many Products. * @example * // Create many Products * const product = await prisma.product.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Products and only return the `id` * const productWithIdOnly = await prisma.product.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a Product. * @param {ProductDeleteArgs} args - Arguments to delete one Product. * @example * // Delete one Product * const Product = await prisma.product.delete({ * where: { * // ... filter to delete one Product * } * }) * */ delete(args: SelectSubset>): Prisma__ProductClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one Product. * @param {ProductUpdateArgs} args - Arguments to update one Product. * @example * // Update one Product * const product = await prisma.product.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__ProductClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Products. * @param {ProductDeleteManyArgs} args - Arguments to filter Products to delete. * @example * // Delete a few Products * const { count } = await prisma.product.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Products. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Products * const product = await prisma.product.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one Product. * @param {ProductUpsertArgs} args - Arguments to update or create a Product. * @example * // Update or create a Product * const product = await prisma.product.upsert({ * create: { * // ... data to create a Product * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Product we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__ProductClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Products. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductCountArgs} args - Arguments to filter Products to count. * @example * // Count the number of Products * const count = await prisma.product.count({ * where: { * // ... the filter for the Products we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Product. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Product. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends ProductGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: ProductGroupByArgs['orderBy'] } : { orderBy?: ProductGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetProductGroupByPayload : Prisma.PrismaPromise /** * Fields of the Product model */ readonly fields: ProductFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Product. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__ProductClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" category = {}>(args?: Subset>): Prisma__CategoryClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> brand = {}>(args?: Subset>): Prisma__BrandClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> variants = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> images = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> collections = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the Product model */ interface ProductFieldRefs { readonly id: FieldRef<"Product", 'String'> readonly title: FieldRef<"Product", 'String'> readonly description: FieldRef<"Product", 'String'> readonly categoryId: FieldRef<"Product", 'String'> readonly brandId: FieldRef<"Product", 'String'> readonly isActive: FieldRef<"Product", 'Boolean'> readonly createdAt: FieldRef<"Product", 'DateTime'> } // Custom InputTypes /** * Product findUnique */ export type ProductFindUniqueArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * Filter, which Product to fetch. */ where: ProductWhereUniqueInput } /** * Product findUniqueOrThrow */ export type ProductFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * Filter, which Product to fetch. */ where: ProductWhereUniqueInput } /** * Product findFirst */ export type ProductFindFirstArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * Filter, which Product to fetch. */ where?: ProductWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Products to fetch. */ orderBy?: ProductOrderByWithRelationInput | ProductOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Products. */ cursor?: ProductWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Products from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Products. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Products. */ distinct?: ProductScalarFieldEnum | ProductScalarFieldEnum[] } /** * Product findFirstOrThrow */ export type ProductFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * Filter, which Product to fetch. */ where?: ProductWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Products to fetch. */ orderBy?: ProductOrderByWithRelationInput | ProductOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Products. */ cursor?: ProductWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Products from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Products. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Products. */ distinct?: ProductScalarFieldEnum | ProductScalarFieldEnum[] } /** * Product findMany */ export type ProductFindManyArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * Filter, which Products to fetch. */ where?: ProductWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Products to fetch. */ orderBy?: ProductOrderByWithRelationInput | ProductOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Products. */ cursor?: ProductWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Products from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Products. */ skip?: number distinct?: ProductScalarFieldEnum | ProductScalarFieldEnum[] } /** * Product create */ export type ProductCreateArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * The data needed to create a Product. */ data: XOR } /** * Product createMany */ export type ProductCreateManyArgs = { /** * The data used to create many Products. */ data: ProductCreateManyInput | ProductCreateManyInput[] skipDuplicates?: boolean } /** * Product createManyAndReturn */ export type ProductCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelectCreateManyAndReturn | null /** * The data used to create many Products. */ data: ProductCreateManyInput | ProductCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: ProductIncludeCreateManyAndReturn | null } /** * Product update */ export type ProductUpdateArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * The data needed to update a Product. */ data: XOR /** * Choose, which Product to update. */ where: ProductWhereUniqueInput } /** * Product updateMany */ export type ProductUpdateManyArgs = { /** * The data used to update Products. */ data: XOR /** * Filter which Products to update */ where?: ProductWhereInput } /** * Product upsert */ export type ProductUpsertArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * The filter to search for the Product to update in case it exists. */ where: ProductWhereUniqueInput /** * In case the Product found by the `where` argument doesn't exist, create a new Product with this data. */ create: XOR /** * In case the Product was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Product delete */ export type ProductDeleteArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null /** * Filter which Product to delete. */ where: ProductWhereUniqueInput } /** * Product deleteMany */ export type ProductDeleteManyArgs = { /** * Filter which Products to delete */ where?: ProductWhereInput } /** * Product.category */ export type Product$categoryArgs = { /** * Select specific fields to fetch from the Category */ select?: CategorySelect | null /** * Choose, which related nodes to fetch as well */ include?: CategoryInclude | null where?: CategoryWhereInput } /** * Product.brand */ export type Product$brandArgs = { /** * Select specific fields to fetch from the Brand */ select?: BrandSelect | null /** * Choose, which related nodes to fetch as well */ include?: BrandInclude | null where?: BrandWhereInput } /** * Product.variants */ export type Product$variantsArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null where?: ProductVariantWhereInput orderBy?: ProductVariantOrderByWithRelationInput | ProductVariantOrderByWithRelationInput[] cursor?: ProductVariantWhereUniqueInput take?: number skip?: number distinct?: ProductVariantScalarFieldEnum | ProductVariantScalarFieldEnum[] } /** * Product.images */ export type Product$imagesArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null where?: ProductImageWhereInput orderBy?: ProductImageOrderByWithRelationInput | ProductImageOrderByWithRelationInput[] cursor?: ProductImageWhereUniqueInput take?: number skip?: number distinct?: ProductImageScalarFieldEnum | ProductImageScalarFieldEnum[] } /** * Product.collections */ export type Product$collectionsArgs = { /** * Select specific fields to fetch from the CollectionProduct */ select?: CollectionProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: CollectionProductInclude | null where?: CollectionProductWhereInput orderBy?: CollectionProductOrderByWithRelationInput | CollectionProductOrderByWithRelationInput[] cursor?: CollectionProductWhereUniqueInput take?: number skip?: number distinct?: CollectionProductScalarFieldEnum | CollectionProductScalarFieldEnum[] } /** * Product without action */ export type ProductDefaultArgs = { /** * Select specific fields to fetch from the Product */ select?: ProductSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductInclude | null } /** * Model ProductImage */ export type AggregateProductImage = { _count: ProductImageCountAggregateOutputType | null _avg: ProductImageAvgAggregateOutputType | null _sum: ProductImageSumAggregateOutputType | null _min: ProductImageMinAggregateOutputType | null _max: ProductImageMaxAggregateOutputType | null } export type ProductImageAvgAggregateOutputType = { sortOrder: number | null } export type ProductImageSumAggregateOutputType = { sortOrder: number | null } export type ProductImageMinAggregateOutputType = { id: string | null productId: string | null url: string | null sortOrder: number | null } export type ProductImageMaxAggregateOutputType = { id: string | null productId: string | null url: string | null sortOrder: number | null } export type ProductImageCountAggregateOutputType = { id: number productId: number url: number sortOrder: number _all: number } export type ProductImageAvgAggregateInputType = { sortOrder?: true } export type ProductImageSumAggregateInputType = { sortOrder?: true } export type ProductImageMinAggregateInputType = { id?: true productId?: true url?: true sortOrder?: true } export type ProductImageMaxAggregateInputType = { id?: true productId?: true url?: true sortOrder?: true } export type ProductImageCountAggregateInputType = { id?: true productId?: true url?: true sortOrder?: true _all?: true } export type ProductImageAggregateArgs = { /** * Filter which ProductImage to aggregate. */ where?: ProductImageWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of ProductImages to fetch. */ orderBy?: ProductImageOrderByWithRelationInput | ProductImageOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: ProductImageWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` ProductImages from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` ProductImages. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned ProductImages **/ _count?: true | ProductImageCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: ProductImageAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: ProductImageSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: ProductImageMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: ProductImageMaxAggregateInputType } export type GetProductImageAggregateType = { [P in keyof T & keyof AggregateProductImage]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type ProductImageGroupByArgs = { where?: ProductImageWhereInput orderBy?: ProductImageOrderByWithAggregationInput | ProductImageOrderByWithAggregationInput[] by: ProductImageScalarFieldEnum[] | ProductImageScalarFieldEnum having?: ProductImageScalarWhereWithAggregatesInput take?: number skip?: number _count?: ProductImageCountAggregateInputType | true _avg?: ProductImageAvgAggregateInputType _sum?: ProductImageSumAggregateInputType _min?: ProductImageMinAggregateInputType _max?: ProductImageMaxAggregateInputType } export type ProductImageGroupByOutputType = { id: string productId: string url: string sortOrder: number _count: ProductImageCountAggregateOutputType | null _avg: ProductImageAvgAggregateOutputType | null _sum: ProductImageSumAggregateOutputType | null _min: ProductImageMinAggregateOutputType | null _max: ProductImageMaxAggregateOutputType | null } type GetProductImageGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof ProductImageGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type ProductImageSelect = $Extensions.GetSelect<{ id?: boolean productId?: boolean url?: boolean sortOrder?: boolean product?: boolean | ProductDefaultArgs }, ExtArgs["result"]["productImage"]> export type ProductImageSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean productId?: boolean url?: boolean sortOrder?: boolean product?: boolean | ProductDefaultArgs }, ExtArgs["result"]["productImage"]> export type ProductImageSelectScalar = { id?: boolean productId?: boolean url?: boolean sortOrder?: boolean } export type ProductImageInclude = { product?: boolean | ProductDefaultArgs } export type ProductImageIncludeCreateManyAndReturn = { product?: boolean | ProductDefaultArgs } export type $ProductImagePayload = { name: "ProductImage" objects: { product: Prisma.$ProductPayload } scalars: $Extensions.GetPayloadResult<{ id: string productId: string url: string sortOrder: number }, ExtArgs["result"]["productImage"]> composites: {} } type ProductImageGetPayload = $Result.GetResult type ProductImageCountArgs = Omit & { select?: ProductImageCountAggregateInputType | true } export interface ProductImageDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['ProductImage'], meta: { name: 'ProductImage' } } /** * Find zero or one ProductImage that matches the filter. * @param {ProductImageFindUniqueArgs} args - Arguments to find a ProductImage * @example * // Get one ProductImage * const productImage = await prisma.productImage.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__ProductImageClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one ProductImage that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {ProductImageFindUniqueOrThrowArgs} args - Arguments to find a ProductImage * @example * // Get one ProductImage * const productImage = await prisma.productImage.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__ProductImageClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first ProductImage that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductImageFindFirstArgs} args - Arguments to find a ProductImage * @example * // Get one ProductImage * const productImage = await prisma.productImage.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__ProductImageClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first ProductImage that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductImageFindFirstOrThrowArgs} args - Arguments to find a ProductImage * @example * // Get one ProductImage * const productImage = await prisma.productImage.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__ProductImageClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more ProductImages that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductImageFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all ProductImages * const productImages = await prisma.productImage.findMany() * * // Get first 10 ProductImages * const productImages = await prisma.productImage.findMany({ take: 10 }) * * // Only select the `id` * const productImageWithIdOnly = await prisma.productImage.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a ProductImage. * @param {ProductImageCreateArgs} args - Arguments to create a ProductImage. * @example * // Create one ProductImage * const ProductImage = await prisma.productImage.create({ * data: { * // ... data to create a ProductImage * } * }) * */ create(args: SelectSubset>): Prisma__ProductImageClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many ProductImages. * @param {ProductImageCreateManyArgs} args - Arguments to create many ProductImages. * @example * // Create many ProductImages * const productImage = await prisma.productImage.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many ProductImages and returns the data saved in the database. * @param {ProductImageCreateManyAndReturnArgs} args - Arguments to create many ProductImages. * @example * // Create many ProductImages * const productImage = await prisma.productImage.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many ProductImages and only return the `id` * const productImageWithIdOnly = await prisma.productImage.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a ProductImage. * @param {ProductImageDeleteArgs} args - Arguments to delete one ProductImage. * @example * // Delete one ProductImage * const ProductImage = await prisma.productImage.delete({ * where: { * // ... filter to delete one ProductImage * } * }) * */ delete(args: SelectSubset>): Prisma__ProductImageClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one ProductImage. * @param {ProductImageUpdateArgs} args - Arguments to update one ProductImage. * @example * // Update one ProductImage * const productImage = await prisma.productImage.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__ProductImageClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more ProductImages. * @param {ProductImageDeleteManyArgs} args - Arguments to filter ProductImages to delete. * @example * // Delete a few ProductImages * const { count } = await prisma.productImage.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more ProductImages. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductImageUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many ProductImages * const productImage = await prisma.productImage.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one ProductImage. * @param {ProductImageUpsertArgs} args - Arguments to update or create a ProductImage. * @example * // Update or create a ProductImage * const productImage = await prisma.productImage.upsert({ * create: { * // ... data to create a ProductImage * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the ProductImage we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__ProductImageClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of ProductImages. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductImageCountArgs} args - Arguments to filter ProductImages to count. * @example * // Count the number of ProductImages * const count = await prisma.productImage.count({ * where: { * // ... the filter for the ProductImages we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a ProductImage. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductImageAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by ProductImage. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductImageGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends ProductImageGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: ProductImageGroupByArgs['orderBy'] } : { orderBy?: ProductImageGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetProductImageGroupByPayload : Prisma.PrismaPromise /** * Fields of the ProductImage model */ readonly fields: ProductImageFieldRefs; } /** * The delegate class that acts as a "Promise-like" for ProductImage. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__ProductImageClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" product = {}>(args?: Subset>): Prisma__ProductClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the ProductImage model */ interface ProductImageFieldRefs { readonly id: FieldRef<"ProductImage", 'String'> readonly productId: FieldRef<"ProductImage", 'String'> readonly url: FieldRef<"ProductImage", 'String'> readonly sortOrder: FieldRef<"ProductImage", 'Int'> } // Custom InputTypes /** * ProductImage findUnique */ export type ProductImageFindUniqueArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * Filter, which ProductImage to fetch. */ where: ProductImageWhereUniqueInput } /** * ProductImage findUniqueOrThrow */ export type ProductImageFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * Filter, which ProductImage to fetch. */ where: ProductImageWhereUniqueInput } /** * ProductImage findFirst */ export type ProductImageFindFirstArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * Filter, which ProductImage to fetch. */ where?: ProductImageWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of ProductImages to fetch. */ orderBy?: ProductImageOrderByWithRelationInput | ProductImageOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for ProductImages. */ cursor?: ProductImageWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` ProductImages from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` ProductImages. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of ProductImages. */ distinct?: ProductImageScalarFieldEnum | ProductImageScalarFieldEnum[] } /** * ProductImage findFirstOrThrow */ export type ProductImageFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * Filter, which ProductImage to fetch. */ where?: ProductImageWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of ProductImages to fetch. */ orderBy?: ProductImageOrderByWithRelationInput | ProductImageOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for ProductImages. */ cursor?: ProductImageWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` ProductImages from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` ProductImages. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of ProductImages. */ distinct?: ProductImageScalarFieldEnum | ProductImageScalarFieldEnum[] } /** * ProductImage findMany */ export type ProductImageFindManyArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * Filter, which ProductImages to fetch. */ where?: ProductImageWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of ProductImages to fetch. */ orderBy?: ProductImageOrderByWithRelationInput | ProductImageOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing ProductImages. */ cursor?: ProductImageWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` ProductImages from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` ProductImages. */ skip?: number distinct?: ProductImageScalarFieldEnum | ProductImageScalarFieldEnum[] } /** * ProductImage create */ export type ProductImageCreateArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * The data needed to create a ProductImage. */ data: XOR } /** * ProductImage createMany */ export type ProductImageCreateManyArgs = { /** * The data used to create many ProductImages. */ data: ProductImageCreateManyInput | ProductImageCreateManyInput[] skipDuplicates?: boolean } /** * ProductImage createManyAndReturn */ export type ProductImageCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelectCreateManyAndReturn | null /** * The data used to create many ProductImages. */ data: ProductImageCreateManyInput | ProductImageCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: ProductImageIncludeCreateManyAndReturn | null } /** * ProductImage update */ export type ProductImageUpdateArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * The data needed to update a ProductImage. */ data: XOR /** * Choose, which ProductImage to update. */ where: ProductImageWhereUniqueInput } /** * ProductImage updateMany */ export type ProductImageUpdateManyArgs = { /** * The data used to update ProductImages. */ data: XOR /** * Filter which ProductImages to update */ where?: ProductImageWhereInput } /** * ProductImage upsert */ export type ProductImageUpsertArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * The filter to search for the ProductImage to update in case it exists. */ where: ProductImageWhereUniqueInput /** * In case the ProductImage found by the `where` argument doesn't exist, create a new ProductImage with this data. */ create: XOR /** * In case the ProductImage was found with the provided `where` argument, update it with this data. */ update: XOR } /** * ProductImage delete */ export type ProductImageDeleteArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null /** * Filter which ProductImage to delete. */ where: ProductImageWhereUniqueInput } /** * ProductImage deleteMany */ export type ProductImageDeleteManyArgs = { /** * Filter which ProductImages to delete */ where?: ProductImageWhereInput } /** * ProductImage without action */ export type ProductImageDefaultArgs = { /** * Select specific fields to fetch from the ProductImage */ select?: ProductImageSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductImageInclude | null } /** * Model ProductVariant */ export type AggregateProductVariant = { _count: ProductVariantCountAggregateOutputType | null _avg: ProductVariantAvgAggregateOutputType | null _sum: ProductVariantSumAggregateOutputType | null _min: ProductVariantMinAggregateOutputType | null _max: ProductVariantMaxAggregateOutputType | null } export type ProductVariantAvgAggregateOutputType = { rashWeightGrams: Decimal | null defaultWagePercent: Decimal | null } export type ProductVariantSumAggregateOutputType = { rashWeightGrams: Decimal | null defaultWagePercent: Decimal | null } export type ProductVariantMinAggregateOutputType = { id: string | null productId: string | null title: string | null sku: string | null rashWeightGrams: Decimal | null defaultWagePercent: Decimal | null isActive: boolean | null } export type ProductVariantMaxAggregateOutputType = { id: string | null productId: string | null title: string | null sku: string | null rashWeightGrams: Decimal | null defaultWagePercent: Decimal | null isActive: boolean | null } export type ProductVariantCountAggregateOutputType = { id: number productId: number title: number sku: number rashWeightGrams: number defaultWagePercent: number isActive: number _all: number } export type ProductVariantAvgAggregateInputType = { rashWeightGrams?: true defaultWagePercent?: true } export type ProductVariantSumAggregateInputType = { rashWeightGrams?: true defaultWagePercent?: true } export type ProductVariantMinAggregateInputType = { id?: true productId?: true title?: true sku?: true rashWeightGrams?: true defaultWagePercent?: true isActive?: true } export type ProductVariantMaxAggregateInputType = { id?: true productId?: true title?: true sku?: true rashWeightGrams?: true defaultWagePercent?: true isActive?: true } export type ProductVariantCountAggregateInputType = { id?: true productId?: true title?: true sku?: true rashWeightGrams?: true defaultWagePercent?: true isActive?: true _all?: true } export type ProductVariantAggregateArgs = { /** * Filter which ProductVariant to aggregate. */ where?: ProductVariantWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of ProductVariants to fetch. */ orderBy?: ProductVariantOrderByWithRelationInput | ProductVariantOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: ProductVariantWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` ProductVariants from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` ProductVariants. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned ProductVariants **/ _count?: true | ProductVariantCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: ProductVariantAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: ProductVariantSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: ProductVariantMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: ProductVariantMaxAggregateInputType } export type GetProductVariantAggregateType = { [P in keyof T & keyof AggregateProductVariant]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type ProductVariantGroupByArgs = { where?: ProductVariantWhereInput orderBy?: ProductVariantOrderByWithAggregationInput | ProductVariantOrderByWithAggregationInput[] by: ProductVariantScalarFieldEnum[] | ProductVariantScalarFieldEnum having?: ProductVariantScalarWhereWithAggregatesInput take?: number skip?: number _count?: ProductVariantCountAggregateInputType | true _avg?: ProductVariantAvgAggregateInputType _sum?: ProductVariantSumAggregateInputType _min?: ProductVariantMinAggregateInputType _max?: ProductVariantMaxAggregateInputType } export type ProductVariantGroupByOutputType = { id: string productId: string title: string sku: string | null rashWeightGrams: Decimal defaultWagePercent: Decimal isActive: boolean _count: ProductVariantCountAggregateOutputType | null _avg: ProductVariantAvgAggregateOutputType | null _sum: ProductVariantSumAggregateOutputType | null _min: ProductVariantMinAggregateOutputType | null _max: ProductVariantMaxAggregateOutputType | null } type GetProductVariantGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof ProductVariantGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type ProductVariantSelect = $Extensions.GetSelect<{ id?: boolean productId?: boolean title?: boolean sku?: boolean rashWeightGrams?: boolean defaultWagePercent?: boolean isActive?: boolean product?: boolean | ProductDefaultArgs orderItems?: boolean | ProductVariant$orderItemsArgs _count?: boolean | ProductVariantCountOutputTypeDefaultArgs }, ExtArgs["result"]["productVariant"]> export type ProductVariantSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean productId?: boolean title?: boolean sku?: boolean rashWeightGrams?: boolean defaultWagePercent?: boolean isActive?: boolean product?: boolean | ProductDefaultArgs }, ExtArgs["result"]["productVariant"]> export type ProductVariantSelectScalar = { id?: boolean productId?: boolean title?: boolean sku?: boolean rashWeightGrams?: boolean defaultWagePercent?: boolean isActive?: boolean } export type ProductVariantInclude = { product?: boolean | ProductDefaultArgs orderItems?: boolean | ProductVariant$orderItemsArgs _count?: boolean | ProductVariantCountOutputTypeDefaultArgs } export type ProductVariantIncludeCreateManyAndReturn = { product?: boolean | ProductDefaultArgs } export type $ProductVariantPayload = { name: "ProductVariant" objects: { product: Prisma.$ProductPayload orderItems: Prisma.$OrderItemPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string productId: string title: string sku: string | null /** * Base/raw weight before making charge ("rash weight"). */ rashWeightGrams: Prisma.Decimal /** * Default making-charge percentage applied on top of rash weight. */ defaultWagePercent: Prisma.Decimal isActive: boolean }, ExtArgs["result"]["productVariant"]> composites: {} } type ProductVariantGetPayload = $Result.GetResult type ProductVariantCountArgs = Omit & { select?: ProductVariantCountAggregateInputType | true } export interface ProductVariantDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['ProductVariant'], meta: { name: 'ProductVariant' } } /** * Find zero or one ProductVariant that matches the filter. * @param {ProductVariantFindUniqueArgs} args - Arguments to find a ProductVariant * @example * // Get one ProductVariant * const productVariant = await prisma.productVariant.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__ProductVariantClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one ProductVariant that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {ProductVariantFindUniqueOrThrowArgs} args - Arguments to find a ProductVariant * @example * // Get one ProductVariant * const productVariant = await prisma.productVariant.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__ProductVariantClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first ProductVariant that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductVariantFindFirstArgs} args - Arguments to find a ProductVariant * @example * // Get one ProductVariant * const productVariant = await prisma.productVariant.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__ProductVariantClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first ProductVariant that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductVariantFindFirstOrThrowArgs} args - Arguments to find a ProductVariant * @example * // Get one ProductVariant * const productVariant = await prisma.productVariant.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__ProductVariantClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more ProductVariants that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductVariantFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all ProductVariants * const productVariants = await prisma.productVariant.findMany() * * // Get first 10 ProductVariants * const productVariants = await prisma.productVariant.findMany({ take: 10 }) * * // Only select the `id` * const productVariantWithIdOnly = await prisma.productVariant.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a ProductVariant. * @param {ProductVariantCreateArgs} args - Arguments to create a ProductVariant. * @example * // Create one ProductVariant * const ProductVariant = await prisma.productVariant.create({ * data: { * // ... data to create a ProductVariant * } * }) * */ create(args: SelectSubset>): Prisma__ProductVariantClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many ProductVariants. * @param {ProductVariantCreateManyArgs} args - Arguments to create many ProductVariants. * @example * // Create many ProductVariants * const productVariant = await prisma.productVariant.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many ProductVariants and returns the data saved in the database. * @param {ProductVariantCreateManyAndReturnArgs} args - Arguments to create many ProductVariants. * @example * // Create many ProductVariants * const productVariant = await prisma.productVariant.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many ProductVariants and only return the `id` * const productVariantWithIdOnly = await prisma.productVariant.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a ProductVariant. * @param {ProductVariantDeleteArgs} args - Arguments to delete one ProductVariant. * @example * // Delete one ProductVariant * const ProductVariant = await prisma.productVariant.delete({ * where: { * // ... filter to delete one ProductVariant * } * }) * */ delete(args: SelectSubset>): Prisma__ProductVariantClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one ProductVariant. * @param {ProductVariantUpdateArgs} args - Arguments to update one ProductVariant. * @example * // Update one ProductVariant * const productVariant = await prisma.productVariant.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__ProductVariantClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more ProductVariants. * @param {ProductVariantDeleteManyArgs} args - Arguments to filter ProductVariants to delete. * @example * // Delete a few ProductVariants * const { count } = await prisma.productVariant.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more ProductVariants. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductVariantUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many ProductVariants * const productVariant = await prisma.productVariant.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one ProductVariant. * @param {ProductVariantUpsertArgs} args - Arguments to update or create a ProductVariant. * @example * // Update or create a ProductVariant * const productVariant = await prisma.productVariant.upsert({ * create: { * // ... data to create a ProductVariant * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the ProductVariant we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__ProductVariantClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of ProductVariants. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductVariantCountArgs} args - Arguments to filter ProductVariants to count. * @example * // Count the number of ProductVariants * const count = await prisma.productVariant.count({ * where: { * // ... the filter for the ProductVariants we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a ProductVariant. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductVariantAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by ProductVariant. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {ProductVariantGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends ProductVariantGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: ProductVariantGroupByArgs['orderBy'] } : { orderBy?: ProductVariantGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetProductVariantGroupByPayload : Prisma.PrismaPromise /** * Fields of the ProductVariant model */ readonly fields: ProductVariantFieldRefs; } /** * The delegate class that acts as a "Promise-like" for ProductVariant. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__ProductVariantClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" product = {}>(args?: Subset>): Prisma__ProductClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> orderItems = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the ProductVariant model */ interface ProductVariantFieldRefs { readonly id: FieldRef<"ProductVariant", 'String'> readonly productId: FieldRef<"ProductVariant", 'String'> readonly title: FieldRef<"ProductVariant", 'String'> readonly sku: FieldRef<"ProductVariant", 'String'> readonly rashWeightGrams: FieldRef<"ProductVariant", 'Decimal'> readonly defaultWagePercent: FieldRef<"ProductVariant", 'Decimal'> readonly isActive: FieldRef<"ProductVariant", 'Boolean'> } // Custom InputTypes /** * ProductVariant findUnique */ export type ProductVariantFindUniqueArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * Filter, which ProductVariant to fetch. */ where: ProductVariantWhereUniqueInput } /** * ProductVariant findUniqueOrThrow */ export type ProductVariantFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * Filter, which ProductVariant to fetch. */ where: ProductVariantWhereUniqueInput } /** * ProductVariant findFirst */ export type ProductVariantFindFirstArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * Filter, which ProductVariant to fetch. */ where?: ProductVariantWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of ProductVariants to fetch. */ orderBy?: ProductVariantOrderByWithRelationInput | ProductVariantOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for ProductVariants. */ cursor?: ProductVariantWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` ProductVariants from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` ProductVariants. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of ProductVariants. */ distinct?: ProductVariantScalarFieldEnum | ProductVariantScalarFieldEnum[] } /** * ProductVariant findFirstOrThrow */ export type ProductVariantFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * Filter, which ProductVariant to fetch. */ where?: ProductVariantWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of ProductVariants to fetch. */ orderBy?: ProductVariantOrderByWithRelationInput | ProductVariantOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for ProductVariants. */ cursor?: ProductVariantWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` ProductVariants from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` ProductVariants. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of ProductVariants. */ distinct?: ProductVariantScalarFieldEnum | ProductVariantScalarFieldEnum[] } /** * ProductVariant findMany */ export type ProductVariantFindManyArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * Filter, which ProductVariants to fetch. */ where?: ProductVariantWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of ProductVariants to fetch. */ orderBy?: ProductVariantOrderByWithRelationInput | ProductVariantOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing ProductVariants. */ cursor?: ProductVariantWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` ProductVariants from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` ProductVariants. */ skip?: number distinct?: ProductVariantScalarFieldEnum | ProductVariantScalarFieldEnum[] } /** * ProductVariant create */ export type ProductVariantCreateArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * The data needed to create a ProductVariant. */ data: XOR } /** * ProductVariant createMany */ export type ProductVariantCreateManyArgs = { /** * The data used to create many ProductVariants. */ data: ProductVariantCreateManyInput | ProductVariantCreateManyInput[] skipDuplicates?: boolean } /** * ProductVariant createManyAndReturn */ export type ProductVariantCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelectCreateManyAndReturn | null /** * The data used to create many ProductVariants. */ data: ProductVariantCreateManyInput | ProductVariantCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: ProductVariantIncludeCreateManyAndReturn | null } /** * ProductVariant update */ export type ProductVariantUpdateArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * The data needed to update a ProductVariant. */ data: XOR /** * Choose, which ProductVariant to update. */ where: ProductVariantWhereUniqueInput } /** * ProductVariant updateMany */ export type ProductVariantUpdateManyArgs = { /** * The data used to update ProductVariants. */ data: XOR /** * Filter which ProductVariants to update */ where?: ProductVariantWhereInput } /** * ProductVariant upsert */ export type ProductVariantUpsertArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * The filter to search for the ProductVariant to update in case it exists. */ where: ProductVariantWhereUniqueInput /** * In case the ProductVariant found by the `where` argument doesn't exist, create a new ProductVariant with this data. */ create: XOR /** * In case the ProductVariant was found with the provided `where` argument, update it with this data. */ update: XOR } /** * ProductVariant delete */ export type ProductVariantDeleteArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null /** * Filter which ProductVariant to delete. */ where: ProductVariantWhereUniqueInput } /** * ProductVariant deleteMany */ export type ProductVariantDeleteManyArgs = { /** * Filter which ProductVariants to delete */ where?: ProductVariantWhereInput } /** * ProductVariant.orderItems */ export type ProductVariant$orderItemsArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null where?: OrderItemWhereInput orderBy?: OrderItemOrderByWithRelationInput | OrderItemOrderByWithRelationInput[] cursor?: OrderItemWhereUniqueInput take?: number skip?: number distinct?: OrderItemScalarFieldEnum | OrderItemScalarFieldEnum[] } /** * ProductVariant without action */ export type ProductVariantDefaultArgs = { /** * Select specific fields to fetch from the ProductVariant */ select?: ProductVariantSelect | null /** * Choose, which related nodes to fetch as well */ include?: ProductVariantInclude | null } /** * Model Order */ export type AggregateOrder = { _count: OrderCountAggregateOutputType | null _avg: OrderAvgAggregateOutputType | null _sum: OrderSumAggregateOutputType | null _min: OrderMinAggregateOutputType | null _max: OrderMaxAggregateOutputType | null } export type OrderAvgAggregateOutputType = { totalGoldWeightGrams: Decimal | null wageWeightGrams: Decimal | null flatRialCharge: Decimal | null } export type OrderSumAggregateOutputType = { totalGoldWeightGrams: Decimal | null wageWeightGrams: Decimal | null flatRialCharge: Decimal | null } export type OrderMinAggregateOutputType = { id: string | null orderNumber: string | null customerId: string | null branchId: string | null status: $Enums.OrderStatus | null totalGoldWeightGrams: Decimal | null wageWeightGrams: Decimal | null flatRialCharge: Decimal | null isSuspendedOverCreditLimit: boolean | null deliveredAt: Date | null createdAt: Date | null updatedAt: Date | null } export type OrderMaxAggregateOutputType = { id: string | null orderNumber: string | null customerId: string | null branchId: string | null status: $Enums.OrderStatus | null totalGoldWeightGrams: Decimal | null wageWeightGrams: Decimal | null flatRialCharge: Decimal | null isSuspendedOverCreditLimit: boolean | null deliveredAt: Date | null createdAt: Date | null updatedAt: Date | null } export type OrderCountAggregateOutputType = { id: number orderNumber: number customerId: number branchId: number status: number totalGoldWeightGrams: number wageWeightGrams: number flatRialCharge: number isSuspendedOverCreditLimit: number deliveredAt: number createdAt: number updatedAt: number _all: number } export type OrderAvgAggregateInputType = { totalGoldWeightGrams?: true wageWeightGrams?: true flatRialCharge?: true } export type OrderSumAggregateInputType = { totalGoldWeightGrams?: true wageWeightGrams?: true flatRialCharge?: true } export type OrderMinAggregateInputType = { id?: true orderNumber?: true customerId?: true branchId?: true status?: true totalGoldWeightGrams?: true wageWeightGrams?: true flatRialCharge?: true isSuspendedOverCreditLimit?: true deliveredAt?: true createdAt?: true updatedAt?: true } export type OrderMaxAggregateInputType = { id?: true orderNumber?: true customerId?: true branchId?: true status?: true totalGoldWeightGrams?: true wageWeightGrams?: true flatRialCharge?: true isSuspendedOverCreditLimit?: true deliveredAt?: true createdAt?: true updatedAt?: true } export type OrderCountAggregateInputType = { id?: true orderNumber?: true customerId?: true branchId?: true status?: true totalGoldWeightGrams?: true wageWeightGrams?: true flatRialCharge?: true isSuspendedOverCreditLimit?: true deliveredAt?: true createdAt?: true updatedAt?: true _all?: true } export type OrderAggregateArgs = { /** * Filter which Order to aggregate. */ where?: OrderWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Orders to fetch. */ orderBy?: OrderOrderByWithRelationInput | OrderOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: OrderWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Orders from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Orders. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned Orders **/ _count?: true | OrderCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: OrderAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: OrderSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: OrderMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: OrderMaxAggregateInputType } export type GetOrderAggregateType = { [P in keyof T & keyof AggregateOrder]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type OrderGroupByArgs = { where?: OrderWhereInput orderBy?: OrderOrderByWithAggregationInput | OrderOrderByWithAggregationInput[] by: OrderScalarFieldEnum[] | OrderScalarFieldEnum having?: OrderScalarWhereWithAggregatesInput take?: number skip?: number _count?: OrderCountAggregateInputType | true _avg?: OrderAvgAggregateInputType _sum?: OrderSumAggregateInputType _min?: OrderMinAggregateInputType _max?: OrderMaxAggregateInputType } export type OrderGroupByOutputType = { id: string orderNumber: string customerId: string branchId: string | null status: $Enums.OrderStatus totalGoldWeightGrams: Decimal wageWeightGrams: Decimal flatRialCharge: Decimal isSuspendedOverCreditLimit: boolean deliveredAt: Date | null createdAt: Date updatedAt: Date _count: OrderCountAggregateOutputType | null _avg: OrderAvgAggregateOutputType | null _sum: OrderSumAggregateOutputType | null _min: OrderMinAggregateOutputType | null _max: OrderMaxAggregateOutputType | null } type GetOrderGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof OrderGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type OrderSelect = $Extensions.GetSelect<{ id?: boolean orderNumber?: boolean customerId?: boolean branchId?: boolean status?: boolean totalGoldWeightGrams?: boolean wageWeightGrams?: boolean flatRialCharge?: boolean isSuspendedOverCreditLimit?: boolean deliveredAt?: boolean createdAt?: boolean updatedAt?: boolean customer?: boolean | CustomerDefaultArgs branch?: boolean | Order$branchArgs items?: boolean | Order$itemsArgs statusEvents?: boolean | Order$statusEventsArgs ledgerEntries?: boolean | Order$ledgerEntriesArgs convertedFromPreOrder?: boolean | Order$convertedFromPreOrderArgs _count?: boolean | OrderCountOutputTypeDefaultArgs }, ExtArgs["result"]["order"]> export type OrderSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean orderNumber?: boolean customerId?: boolean branchId?: boolean status?: boolean totalGoldWeightGrams?: boolean wageWeightGrams?: boolean flatRialCharge?: boolean isSuspendedOverCreditLimit?: boolean deliveredAt?: boolean createdAt?: boolean updatedAt?: boolean customer?: boolean | CustomerDefaultArgs branch?: boolean | Order$branchArgs }, ExtArgs["result"]["order"]> export type OrderSelectScalar = { id?: boolean orderNumber?: boolean customerId?: boolean branchId?: boolean status?: boolean totalGoldWeightGrams?: boolean wageWeightGrams?: boolean flatRialCharge?: boolean isSuspendedOverCreditLimit?: boolean deliveredAt?: boolean createdAt?: boolean updatedAt?: boolean } export type OrderInclude = { customer?: boolean | CustomerDefaultArgs branch?: boolean | Order$branchArgs items?: boolean | Order$itemsArgs statusEvents?: boolean | Order$statusEventsArgs ledgerEntries?: boolean | Order$ledgerEntriesArgs convertedFromPreOrder?: boolean | Order$convertedFromPreOrderArgs _count?: boolean | OrderCountOutputTypeDefaultArgs } export type OrderIncludeCreateManyAndReturn = { customer?: boolean | CustomerDefaultArgs branch?: boolean | Order$branchArgs } export type $OrderPayload = { name: "Order" objects: { customer: Prisma.$CustomerPayload branch: Prisma.$BranchPayload | null items: Prisma.$OrderItemPayload[] statusEvents: Prisma.$OrderStatusEventPayload[] ledgerEntries: Prisma.$LedgerEntryPayload[] convertedFromPreOrder: Prisma.$PreOrderPayload | null } scalars: $Extensions.GetPayloadResult<{ id: string orderNumber: string customerId: string branchId: string | null status: $Enums.OrderStatus /** * Total gold weight incl. wage across all items ("allGram" / order.w). */ totalGoldWeightGrams: Prisma.Decimal /** * Pure making-charge weight component (totalGoldWeightGrams minus raw weight sum). */ wageWeightGrams: Prisma.Decimal /** * Flat Rial charge independent of gold price (e.g. stones) — legacy rial_input. */ flatRialCharge: Prisma.Decimal isSuspendedOverCreditLimit: boolean deliveredAt: Date | null createdAt: Date updatedAt: Date }, ExtArgs["result"]["order"]> composites: {} } type OrderGetPayload = $Result.GetResult type OrderCountArgs = Omit & { select?: OrderCountAggregateInputType | true } export interface OrderDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['Order'], meta: { name: 'Order' } } /** * Find zero or one Order that matches the filter. * @param {OrderFindUniqueArgs} args - Arguments to find a Order * @example * // Get one Order * const order = await prisma.order.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__OrderClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one Order that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {OrderFindUniqueOrThrowArgs} args - Arguments to find a Order * @example * // Get one Order * const order = await prisma.order.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__OrderClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first Order that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderFindFirstArgs} args - Arguments to find a Order * @example * // Get one Order * const order = await prisma.order.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__OrderClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first Order that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderFindFirstOrThrowArgs} args - Arguments to find a Order * @example * // Get one Order * const order = await prisma.order.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__OrderClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more Orders that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all Orders * const orders = await prisma.order.findMany() * * // Get first 10 Orders * const orders = await prisma.order.findMany({ take: 10 }) * * // Only select the `id` * const orderWithIdOnly = await prisma.order.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a Order. * @param {OrderCreateArgs} args - Arguments to create a Order. * @example * // Create one Order * const Order = await prisma.order.create({ * data: { * // ... data to create a Order * } * }) * */ create(args: SelectSubset>): Prisma__OrderClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many Orders. * @param {OrderCreateManyArgs} args - Arguments to create many Orders. * @example * // Create many Orders * const order = await prisma.order.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many Orders and returns the data saved in the database. * @param {OrderCreateManyAndReturnArgs} args - Arguments to create many Orders. * @example * // Create many Orders * const order = await prisma.order.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many Orders and only return the `id` * const orderWithIdOnly = await prisma.order.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a Order. * @param {OrderDeleteArgs} args - Arguments to delete one Order. * @example * // Delete one Order * const Order = await prisma.order.delete({ * where: { * // ... filter to delete one Order * } * }) * */ delete(args: SelectSubset>): Prisma__OrderClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one Order. * @param {OrderUpdateArgs} args - Arguments to update one Order. * @example * // Update one Order * const order = await prisma.order.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__OrderClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more Orders. * @param {OrderDeleteManyArgs} args - Arguments to filter Orders to delete. * @example * // Delete a few Orders * const { count } = await prisma.order.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more Orders. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many Orders * const order = await prisma.order.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one Order. * @param {OrderUpsertArgs} args - Arguments to update or create a Order. * @example * // Update or create a Order * const order = await prisma.order.upsert({ * create: { * // ... data to create a Order * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the Order we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__OrderClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of Orders. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderCountArgs} args - Arguments to filter Orders to count. * @example * // Count the number of Orders * const count = await prisma.order.count({ * where: { * // ... the filter for the Orders we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a Order. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by Order. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends OrderGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: OrderGroupByArgs['orderBy'] } : { orderBy?: OrderGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetOrderGroupByPayload : Prisma.PrismaPromise /** * Fields of the Order model */ readonly fields: OrderFieldRefs; } /** * The delegate class that acts as a "Promise-like" for Order. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__OrderClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" customer = {}>(args?: Subset>): Prisma__CustomerClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> branch = {}>(args?: Subset>): Prisma__BranchClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> items = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> statusEvents = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> ledgerEntries = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> convertedFromPreOrder = {}>(args?: Subset>): Prisma__PreOrderClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the Order model */ interface OrderFieldRefs { readonly id: FieldRef<"Order", 'String'> readonly orderNumber: FieldRef<"Order", 'String'> readonly customerId: FieldRef<"Order", 'String'> readonly branchId: FieldRef<"Order", 'String'> readonly status: FieldRef<"Order", 'OrderStatus'> readonly totalGoldWeightGrams: FieldRef<"Order", 'Decimal'> readonly wageWeightGrams: FieldRef<"Order", 'Decimal'> readonly flatRialCharge: FieldRef<"Order", 'Decimal'> readonly isSuspendedOverCreditLimit: FieldRef<"Order", 'Boolean'> readonly deliveredAt: FieldRef<"Order", 'DateTime'> readonly createdAt: FieldRef<"Order", 'DateTime'> readonly updatedAt: FieldRef<"Order", 'DateTime'> } // Custom InputTypes /** * Order findUnique */ export type OrderFindUniqueArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * Filter, which Order to fetch. */ where: OrderWhereUniqueInput } /** * Order findUniqueOrThrow */ export type OrderFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * Filter, which Order to fetch. */ where: OrderWhereUniqueInput } /** * Order findFirst */ export type OrderFindFirstArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * Filter, which Order to fetch. */ where?: OrderWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Orders to fetch. */ orderBy?: OrderOrderByWithRelationInput | OrderOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Orders. */ cursor?: OrderWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Orders from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Orders. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Orders. */ distinct?: OrderScalarFieldEnum | OrderScalarFieldEnum[] } /** * Order findFirstOrThrow */ export type OrderFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * Filter, which Order to fetch. */ where?: OrderWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Orders to fetch. */ orderBy?: OrderOrderByWithRelationInput | OrderOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for Orders. */ cursor?: OrderWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Orders from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Orders. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of Orders. */ distinct?: OrderScalarFieldEnum | OrderScalarFieldEnum[] } /** * Order findMany */ export type OrderFindManyArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * Filter, which Orders to fetch. */ where?: OrderWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of Orders to fetch. */ orderBy?: OrderOrderByWithRelationInput | OrderOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing Orders. */ cursor?: OrderWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` Orders from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` Orders. */ skip?: number distinct?: OrderScalarFieldEnum | OrderScalarFieldEnum[] } /** * Order create */ export type OrderCreateArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * The data needed to create a Order. */ data: XOR } /** * Order createMany */ export type OrderCreateManyArgs = { /** * The data used to create many Orders. */ data: OrderCreateManyInput | OrderCreateManyInput[] skipDuplicates?: boolean } /** * Order createManyAndReturn */ export type OrderCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelectCreateManyAndReturn | null /** * The data used to create many Orders. */ data: OrderCreateManyInput | OrderCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: OrderIncludeCreateManyAndReturn | null } /** * Order update */ export type OrderUpdateArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * The data needed to update a Order. */ data: XOR /** * Choose, which Order to update. */ where: OrderWhereUniqueInput } /** * Order updateMany */ export type OrderUpdateManyArgs = { /** * The data used to update Orders. */ data: XOR /** * Filter which Orders to update */ where?: OrderWhereInput } /** * Order upsert */ export type OrderUpsertArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * The filter to search for the Order to update in case it exists. */ where: OrderWhereUniqueInput /** * In case the Order found by the `where` argument doesn't exist, create a new Order with this data. */ create: XOR /** * In case the Order was found with the provided `where` argument, update it with this data. */ update: XOR } /** * Order delete */ export type OrderDeleteArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null /** * Filter which Order to delete. */ where: OrderWhereUniqueInput } /** * Order deleteMany */ export type OrderDeleteManyArgs = { /** * Filter which Orders to delete */ where?: OrderWhereInput } /** * Order.branch */ export type Order$branchArgs = { /** * Select specific fields to fetch from the Branch */ select?: BranchSelect | null /** * Choose, which related nodes to fetch as well */ include?: BranchInclude | null where?: BranchWhereInput } /** * Order.items */ export type Order$itemsArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null where?: OrderItemWhereInput orderBy?: OrderItemOrderByWithRelationInput | OrderItemOrderByWithRelationInput[] cursor?: OrderItemWhereUniqueInput take?: number skip?: number distinct?: OrderItemScalarFieldEnum | OrderItemScalarFieldEnum[] } /** * Order.statusEvents */ export type Order$statusEventsArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null where?: OrderStatusEventWhereInput orderBy?: OrderStatusEventOrderByWithRelationInput | OrderStatusEventOrderByWithRelationInput[] cursor?: OrderStatusEventWhereUniqueInput take?: number skip?: number distinct?: OrderStatusEventScalarFieldEnum | OrderStatusEventScalarFieldEnum[] } /** * Order.ledgerEntries */ export type Order$ledgerEntriesArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null where?: LedgerEntryWhereInput orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[] cursor?: LedgerEntryWhereUniqueInput take?: number skip?: number distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[] } /** * Order.convertedFromPreOrder */ export type Order$convertedFromPreOrderArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null where?: PreOrderWhereInput } /** * Order without action */ export type OrderDefaultArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null } /** * Model OrderItem */ export type AggregateOrderItem = { _count: OrderItemCountAggregateOutputType | null _avg: OrderItemAvgAggregateOutputType | null _sum: OrderItemSumAggregateOutputType | null _min: OrderItemMinAggregateOutputType | null _max: OrderItemMaxAggregateOutputType | null } export type OrderItemAvgAggregateOutputType = { quantity: number | null rashWeightGramsSnapshot: Decimal | null wagePercentSnapshot: Decimal | null discountPercentSnapshot: Decimal | null computedWeightGrams: Decimal | null flatRialCharge: Decimal | null } export type OrderItemSumAggregateOutputType = { quantity: number | null rashWeightGramsSnapshot: Decimal | null wagePercentSnapshot: Decimal | null discountPercentSnapshot: Decimal | null computedWeightGrams: Decimal | null flatRialCharge: Decimal | null } export type OrderItemMinAggregateOutputType = { id: string | null orderId: string | null productVariantId: string | null quantity: number | null rashWeightGramsSnapshot: Decimal | null wagePercentSnapshot: Decimal | null discountPercentSnapshot: Decimal | null computedWeightGrams: Decimal | null flatRialCharge: Decimal | null } export type OrderItemMaxAggregateOutputType = { id: string | null orderId: string | null productVariantId: string | null quantity: number | null rashWeightGramsSnapshot: Decimal | null wagePercentSnapshot: Decimal | null discountPercentSnapshot: Decimal | null computedWeightGrams: Decimal | null flatRialCharge: Decimal | null } export type OrderItemCountAggregateOutputType = { id: number orderId: number productVariantId: number quantity: number rashWeightGramsSnapshot: number wagePercentSnapshot: number discountPercentSnapshot: number computedWeightGrams: number flatRialCharge: number _all: number } export type OrderItemAvgAggregateInputType = { quantity?: true rashWeightGramsSnapshot?: true wagePercentSnapshot?: true discountPercentSnapshot?: true computedWeightGrams?: true flatRialCharge?: true } export type OrderItemSumAggregateInputType = { quantity?: true rashWeightGramsSnapshot?: true wagePercentSnapshot?: true discountPercentSnapshot?: true computedWeightGrams?: true flatRialCharge?: true } export type OrderItemMinAggregateInputType = { id?: true orderId?: true productVariantId?: true quantity?: true rashWeightGramsSnapshot?: true wagePercentSnapshot?: true discountPercentSnapshot?: true computedWeightGrams?: true flatRialCharge?: true } export type OrderItemMaxAggregateInputType = { id?: true orderId?: true productVariantId?: true quantity?: true rashWeightGramsSnapshot?: true wagePercentSnapshot?: true discountPercentSnapshot?: true computedWeightGrams?: true flatRialCharge?: true } export type OrderItemCountAggregateInputType = { id?: true orderId?: true productVariantId?: true quantity?: true rashWeightGramsSnapshot?: true wagePercentSnapshot?: true discountPercentSnapshot?: true computedWeightGrams?: true flatRialCharge?: true _all?: true } export type OrderItemAggregateArgs = { /** * Filter which OrderItem to aggregate. */ where?: OrderItemWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of OrderItems to fetch. */ orderBy?: OrderItemOrderByWithRelationInput | OrderItemOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: OrderItemWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` OrderItems from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` OrderItems. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned OrderItems **/ _count?: true | OrderItemCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: OrderItemAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: OrderItemSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: OrderItemMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: OrderItemMaxAggregateInputType } export type GetOrderItemAggregateType = { [P in keyof T & keyof AggregateOrderItem]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type OrderItemGroupByArgs = { where?: OrderItemWhereInput orderBy?: OrderItemOrderByWithAggregationInput | OrderItemOrderByWithAggregationInput[] by: OrderItemScalarFieldEnum[] | OrderItemScalarFieldEnum having?: OrderItemScalarWhereWithAggregatesInput take?: number skip?: number _count?: OrderItemCountAggregateInputType | true _avg?: OrderItemAvgAggregateInputType _sum?: OrderItemSumAggregateInputType _min?: OrderItemMinAggregateInputType _max?: OrderItemMaxAggregateInputType } export type OrderItemGroupByOutputType = { id: string orderId: string productVariantId: string quantity: number rashWeightGramsSnapshot: Decimal wagePercentSnapshot: Decimal discountPercentSnapshot: Decimal computedWeightGrams: Decimal flatRialCharge: Decimal _count: OrderItemCountAggregateOutputType | null _avg: OrderItemAvgAggregateOutputType | null _sum: OrderItemSumAggregateOutputType | null _min: OrderItemMinAggregateOutputType | null _max: OrderItemMaxAggregateOutputType | null } type GetOrderItemGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof OrderItemGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type OrderItemSelect = $Extensions.GetSelect<{ id?: boolean orderId?: boolean productVariantId?: boolean quantity?: boolean rashWeightGramsSnapshot?: boolean wagePercentSnapshot?: boolean discountPercentSnapshot?: boolean computedWeightGrams?: boolean flatRialCharge?: boolean order?: boolean | OrderDefaultArgs productVariant?: boolean | ProductVariantDefaultArgs }, ExtArgs["result"]["orderItem"]> export type OrderItemSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean orderId?: boolean productVariantId?: boolean quantity?: boolean rashWeightGramsSnapshot?: boolean wagePercentSnapshot?: boolean discountPercentSnapshot?: boolean computedWeightGrams?: boolean flatRialCharge?: boolean order?: boolean | OrderDefaultArgs productVariant?: boolean | ProductVariantDefaultArgs }, ExtArgs["result"]["orderItem"]> export type OrderItemSelectScalar = { id?: boolean orderId?: boolean productVariantId?: boolean quantity?: boolean rashWeightGramsSnapshot?: boolean wagePercentSnapshot?: boolean discountPercentSnapshot?: boolean computedWeightGrams?: boolean flatRialCharge?: boolean } export type OrderItemInclude = { order?: boolean | OrderDefaultArgs productVariant?: boolean | ProductVariantDefaultArgs } export type OrderItemIncludeCreateManyAndReturn = { order?: boolean | OrderDefaultArgs productVariant?: boolean | ProductVariantDefaultArgs } export type $OrderItemPayload = { name: "OrderItem" objects: { order: Prisma.$OrderPayload productVariant: Prisma.$ProductVariantPayload } scalars: $Extensions.GetPayloadResult<{ id: string orderId: string productVariantId: string quantity: number rashWeightGramsSnapshot: Prisma.Decimal wagePercentSnapshot: Prisma.Decimal discountPercentSnapshot: Prisma.Decimal /** * computed: rash*(1 + (wagePercent-discount)/100) */ computedWeightGrams: Prisma.Decimal flatRialCharge: Prisma.Decimal }, ExtArgs["result"]["orderItem"]> composites: {} } type OrderItemGetPayload = $Result.GetResult type OrderItemCountArgs = Omit & { select?: OrderItemCountAggregateInputType | true } export interface OrderItemDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['OrderItem'], meta: { name: 'OrderItem' } } /** * Find zero or one OrderItem that matches the filter. * @param {OrderItemFindUniqueArgs} args - Arguments to find a OrderItem * @example * // Get one OrderItem * const orderItem = await prisma.orderItem.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__OrderItemClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one OrderItem that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {OrderItemFindUniqueOrThrowArgs} args - Arguments to find a OrderItem * @example * // Get one OrderItem * const orderItem = await prisma.orderItem.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__OrderItemClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first OrderItem that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderItemFindFirstArgs} args - Arguments to find a OrderItem * @example * // Get one OrderItem * const orderItem = await prisma.orderItem.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__OrderItemClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first OrderItem that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderItemFindFirstOrThrowArgs} args - Arguments to find a OrderItem * @example * // Get one OrderItem * const orderItem = await prisma.orderItem.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__OrderItemClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more OrderItems that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderItemFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all OrderItems * const orderItems = await prisma.orderItem.findMany() * * // Get first 10 OrderItems * const orderItems = await prisma.orderItem.findMany({ take: 10 }) * * // Only select the `id` * const orderItemWithIdOnly = await prisma.orderItem.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a OrderItem. * @param {OrderItemCreateArgs} args - Arguments to create a OrderItem. * @example * // Create one OrderItem * const OrderItem = await prisma.orderItem.create({ * data: { * // ... data to create a OrderItem * } * }) * */ create(args: SelectSubset>): Prisma__OrderItemClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many OrderItems. * @param {OrderItemCreateManyArgs} args - Arguments to create many OrderItems. * @example * // Create many OrderItems * const orderItem = await prisma.orderItem.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many OrderItems and returns the data saved in the database. * @param {OrderItemCreateManyAndReturnArgs} args - Arguments to create many OrderItems. * @example * // Create many OrderItems * const orderItem = await prisma.orderItem.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many OrderItems and only return the `id` * const orderItemWithIdOnly = await prisma.orderItem.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a OrderItem. * @param {OrderItemDeleteArgs} args - Arguments to delete one OrderItem. * @example * // Delete one OrderItem * const OrderItem = await prisma.orderItem.delete({ * where: { * // ... filter to delete one OrderItem * } * }) * */ delete(args: SelectSubset>): Prisma__OrderItemClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one OrderItem. * @param {OrderItemUpdateArgs} args - Arguments to update one OrderItem. * @example * // Update one OrderItem * const orderItem = await prisma.orderItem.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__OrderItemClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more OrderItems. * @param {OrderItemDeleteManyArgs} args - Arguments to filter OrderItems to delete. * @example * // Delete a few OrderItems * const { count } = await prisma.orderItem.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more OrderItems. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderItemUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many OrderItems * const orderItem = await prisma.orderItem.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one OrderItem. * @param {OrderItemUpsertArgs} args - Arguments to update or create a OrderItem. * @example * // Update or create a OrderItem * const orderItem = await prisma.orderItem.upsert({ * create: { * // ... data to create a OrderItem * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the OrderItem we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__OrderItemClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of OrderItems. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderItemCountArgs} args - Arguments to filter OrderItems to count. * @example * // Count the number of OrderItems * const count = await prisma.orderItem.count({ * where: { * // ... the filter for the OrderItems we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a OrderItem. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderItemAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by OrderItem. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderItemGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends OrderItemGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: OrderItemGroupByArgs['orderBy'] } : { orderBy?: OrderItemGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetOrderItemGroupByPayload : Prisma.PrismaPromise /** * Fields of the OrderItem model */ readonly fields: OrderItemFieldRefs; } /** * The delegate class that acts as a "Promise-like" for OrderItem. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__OrderItemClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" order = {}>(args?: Subset>): Prisma__OrderClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> productVariant = {}>(args?: Subset>): Prisma__ProductVariantClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the OrderItem model */ interface OrderItemFieldRefs { readonly id: FieldRef<"OrderItem", 'String'> readonly orderId: FieldRef<"OrderItem", 'String'> readonly productVariantId: FieldRef<"OrderItem", 'String'> readonly quantity: FieldRef<"OrderItem", 'Int'> readonly rashWeightGramsSnapshot: FieldRef<"OrderItem", 'Decimal'> readonly wagePercentSnapshot: FieldRef<"OrderItem", 'Decimal'> readonly discountPercentSnapshot: FieldRef<"OrderItem", 'Decimal'> readonly computedWeightGrams: FieldRef<"OrderItem", 'Decimal'> readonly flatRialCharge: FieldRef<"OrderItem", 'Decimal'> } // Custom InputTypes /** * OrderItem findUnique */ export type OrderItemFindUniqueArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * Filter, which OrderItem to fetch. */ where: OrderItemWhereUniqueInput } /** * OrderItem findUniqueOrThrow */ export type OrderItemFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * Filter, which OrderItem to fetch. */ where: OrderItemWhereUniqueInput } /** * OrderItem findFirst */ export type OrderItemFindFirstArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * Filter, which OrderItem to fetch. */ where?: OrderItemWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of OrderItems to fetch. */ orderBy?: OrderItemOrderByWithRelationInput | OrderItemOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for OrderItems. */ cursor?: OrderItemWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` OrderItems from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` OrderItems. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of OrderItems. */ distinct?: OrderItemScalarFieldEnum | OrderItemScalarFieldEnum[] } /** * OrderItem findFirstOrThrow */ export type OrderItemFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * Filter, which OrderItem to fetch. */ where?: OrderItemWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of OrderItems to fetch. */ orderBy?: OrderItemOrderByWithRelationInput | OrderItemOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for OrderItems. */ cursor?: OrderItemWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` OrderItems from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` OrderItems. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of OrderItems. */ distinct?: OrderItemScalarFieldEnum | OrderItemScalarFieldEnum[] } /** * OrderItem findMany */ export type OrderItemFindManyArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * Filter, which OrderItems to fetch. */ where?: OrderItemWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of OrderItems to fetch. */ orderBy?: OrderItemOrderByWithRelationInput | OrderItemOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing OrderItems. */ cursor?: OrderItemWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` OrderItems from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` OrderItems. */ skip?: number distinct?: OrderItemScalarFieldEnum | OrderItemScalarFieldEnum[] } /** * OrderItem create */ export type OrderItemCreateArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * The data needed to create a OrderItem. */ data: XOR } /** * OrderItem createMany */ export type OrderItemCreateManyArgs = { /** * The data used to create many OrderItems. */ data: OrderItemCreateManyInput | OrderItemCreateManyInput[] skipDuplicates?: boolean } /** * OrderItem createManyAndReturn */ export type OrderItemCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelectCreateManyAndReturn | null /** * The data used to create many OrderItems. */ data: OrderItemCreateManyInput | OrderItemCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: OrderItemIncludeCreateManyAndReturn | null } /** * OrderItem update */ export type OrderItemUpdateArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * The data needed to update a OrderItem. */ data: XOR /** * Choose, which OrderItem to update. */ where: OrderItemWhereUniqueInput } /** * OrderItem updateMany */ export type OrderItemUpdateManyArgs = { /** * The data used to update OrderItems. */ data: XOR /** * Filter which OrderItems to update */ where?: OrderItemWhereInput } /** * OrderItem upsert */ export type OrderItemUpsertArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * The filter to search for the OrderItem to update in case it exists. */ where: OrderItemWhereUniqueInput /** * In case the OrderItem found by the `where` argument doesn't exist, create a new OrderItem with this data. */ create: XOR /** * In case the OrderItem was found with the provided `where` argument, update it with this data. */ update: XOR } /** * OrderItem delete */ export type OrderItemDeleteArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null /** * Filter which OrderItem to delete. */ where: OrderItemWhereUniqueInput } /** * OrderItem deleteMany */ export type OrderItemDeleteManyArgs = { /** * Filter which OrderItems to delete */ where?: OrderItemWhereInput } /** * OrderItem without action */ export type OrderItemDefaultArgs = { /** * Select specific fields to fetch from the OrderItem */ select?: OrderItemSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderItemInclude | null } /** * Model OrderStatusEvent */ export type AggregateOrderStatusEvent = { _count: OrderStatusEventCountAggregateOutputType | null _min: OrderStatusEventMinAggregateOutputType | null _max: OrderStatusEventMaxAggregateOutputType | null } export type OrderStatusEventMinAggregateOutputType = { id: string | null orderId: string | null fromStatus: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus | null note: string | null actorAdminUserId: string | null createdAt: Date | null } export type OrderStatusEventMaxAggregateOutputType = { id: string | null orderId: string | null fromStatus: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus | null note: string | null actorAdminUserId: string | null createdAt: Date | null } export type OrderStatusEventCountAggregateOutputType = { id: number orderId: number fromStatus: number toStatus: number note: number actorAdminUserId: number createdAt: number _all: number } export type OrderStatusEventMinAggregateInputType = { id?: true orderId?: true fromStatus?: true toStatus?: true note?: true actorAdminUserId?: true createdAt?: true } export type OrderStatusEventMaxAggregateInputType = { id?: true orderId?: true fromStatus?: true toStatus?: true note?: true actorAdminUserId?: true createdAt?: true } export type OrderStatusEventCountAggregateInputType = { id?: true orderId?: true fromStatus?: true toStatus?: true note?: true actorAdminUserId?: true createdAt?: true _all?: true } export type OrderStatusEventAggregateArgs = { /** * Filter which OrderStatusEvent to aggregate. */ where?: OrderStatusEventWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of OrderStatusEvents to fetch. */ orderBy?: OrderStatusEventOrderByWithRelationInput | OrderStatusEventOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: OrderStatusEventWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` OrderStatusEvents from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` OrderStatusEvents. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned OrderStatusEvents **/ _count?: true | OrderStatusEventCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: OrderStatusEventMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: OrderStatusEventMaxAggregateInputType } export type GetOrderStatusEventAggregateType = { [P in keyof T & keyof AggregateOrderStatusEvent]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type OrderStatusEventGroupByArgs = { where?: OrderStatusEventWhereInput orderBy?: OrderStatusEventOrderByWithAggregationInput | OrderStatusEventOrderByWithAggregationInput[] by: OrderStatusEventScalarFieldEnum[] | OrderStatusEventScalarFieldEnum having?: OrderStatusEventScalarWhereWithAggregatesInput take?: number skip?: number _count?: OrderStatusEventCountAggregateInputType | true _min?: OrderStatusEventMinAggregateInputType _max?: OrderStatusEventMaxAggregateInputType } export type OrderStatusEventGroupByOutputType = { id: string orderId: string fromStatus: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note: string | null actorAdminUserId: string | null createdAt: Date _count: OrderStatusEventCountAggregateOutputType | null _min: OrderStatusEventMinAggregateOutputType | null _max: OrderStatusEventMaxAggregateOutputType | null } type GetOrderStatusEventGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof OrderStatusEventGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type OrderStatusEventSelect = $Extensions.GetSelect<{ id?: boolean orderId?: boolean fromStatus?: boolean toStatus?: boolean note?: boolean actorAdminUserId?: boolean createdAt?: boolean order?: boolean | OrderDefaultArgs actorAdminUser?: boolean | OrderStatusEvent$actorAdminUserArgs }, ExtArgs["result"]["orderStatusEvent"]> export type OrderStatusEventSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean orderId?: boolean fromStatus?: boolean toStatus?: boolean note?: boolean actorAdminUserId?: boolean createdAt?: boolean order?: boolean | OrderDefaultArgs actorAdminUser?: boolean | OrderStatusEvent$actorAdminUserArgs }, ExtArgs["result"]["orderStatusEvent"]> export type OrderStatusEventSelectScalar = { id?: boolean orderId?: boolean fromStatus?: boolean toStatus?: boolean note?: boolean actorAdminUserId?: boolean createdAt?: boolean } export type OrderStatusEventInclude = { order?: boolean | OrderDefaultArgs actorAdminUser?: boolean | OrderStatusEvent$actorAdminUserArgs } export type OrderStatusEventIncludeCreateManyAndReturn = { order?: boolean | OrderDefaultArgs actorAdminUser?: boolean | OrderStatusEvent$actorAdminUserArgs } export type $OrderStatusEventPayload = { name: "OrderStatusEvent" objects: { order: Prisma.$OrderPayload actorAdminUser: Prisma.$AdminUserPayload | null } scalars: $Extensions.GetPayloadResult<{ id: string orderId: string fromStatus: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note: string | null actorAdminUserId: string | null createdAt: Date }, ExtArgs["result"]["orderStatusEvent"]> composites: {} } type OrderStatusEventGetPayload = $Result.GetResult type OrderStatusEventCountArgs = Omit & { select?: OrderStatusEventCountAggregateInputType | true } export interface OrderStatusEventDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['OrderStatusEvent'], meta: { name: 'OrderStatusEvent' } } /** * Find zero or one OrderStatusEvent that matches the filter. * @param {OrderStatusEventFindUniqueArgs} args - Arguments to find a OrderStatusEvent * @example * // Get one OrderStatusEvent * const orderStatusEvent = await prisma.orderStatusEvent.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__OrderStatusEventClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one OrderStatusEvent that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {OrderStatusEventFindUniqueOrThrowArgs} args - Arguments to find a OrderStatusEvent * @example * // Get one OrderStatusEvent * const orderStatusEvent = await prisma.orderStatusEvent.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__OrderStatusEventClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first OrderStatusEvent that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderStatusEventFindFirstArgs} args - Arguments to find a OrderStatusEvent * @example * // Get one OrderStatusEvent * const orderStatusEvent = await prisma.orderStatusEvent.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__OrderStatusEventClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first OrderStatusEvent that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderStatusEventFindFirstOrThrowArgs} args - Arguments to find a OrderStatusEvent * @example * // Get one OrderStatusEvent * const orderStatusEvent = await prisma.orderStatusEvent.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__OrderStatusEventClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more OrderStatusEvents that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderStatusEventFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all OrderStatusEvents * const orderStatusEvents = await prisma.orderStatusEvent.findMany() * * // Get first 10 OrderStatusEvents * const orderStatusEvents = await prisma.orderStatusEvent.findMany({ take: 10 }) * * // Only select the `id` * const orderStatusEventWithIdOnly = await prisma.orderStatusEvent.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a OrderStatusEvent. * @param {OrderStatusEventCreateArgs} args - Arguments to create a OrderStatusEvent. * @example * // Create one OrderStatusEvent * const OrderStatusEvent = await prisma.orderStatusEvent.create({ * data: { * // ... data to create a OrderStatusEvent * } * }) * */ create(args: SelectSubset>): Prisma__OrderStatusEventClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many OrderStatusEvents. * @param {OrderStatusEventCreateManyArgs} args - Arguments to create many OrderStatusEvents. * @example * // Create many OrderStatusEvents * const orderStatusEvent = await prisma.orderStatusEvent.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many OrderStatusEvents and returns the data saved in the database. * @param {OrderStatusEventCreateManyAndReturnArgs} args - Arguments to create many OrderStatusEvents. * @example * // Create many OrderStatusEvents * const orderStatusEvent = await prisma.orderStatusEvent.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many OrderStatusEvents and only return the `id` * const orderStatusEventWithIdOnly = await prisma.orderStatusEvent.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a OrderStatusEvent. * @param {OrderStatusEventDeleteArgs} args - Arguments to delete one OrderStatusEvent. * @example * // Delete one OrderStatusEvent * const OrderStatusEvent = await prisma.orderStatusEvent.delete({ * where: { * // ... filter to delete one OrderStatusEvent * } * }) * */ delete(args: SelectSubset>): Prisma__OrderStatusEventClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one OrderStatusEvent. * @param {OrderStatusEventUpdateArgs} args - Arguments to update one OrderStatusEvent. * @example * // Update one OrderStatusEvent * const orderStatusEvent = await prisma.orderStatusEvent.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__OrderStatusEventClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more OrderStatusEvents. * @param {OrderStatusEventDeleteManyArgs} args - Arguments to filter OrderStatusEvents to delete. * @example * // Delete a few OrderStatusEvents * const { count } = await prisma.orderStatusEvent.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more OrderStatusEvents. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderStatusEventUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many OrderStatusEvents * const orderStatusEvent = await prisma.orderStatusEvent.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one OrderStatusEvent. * @param {OrderStatusEventUpsertArgs} args - Arguments to update or create a OrderStatusEvent. * @example * // Update or create a OrderStatusEvent * const orderStatusEvent = await prisma.orderStatusEvent.upsert({ * create: { * // ... data to create a OrderStatusEvent * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the OrderStatusEvent we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__OrderStatusEventClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of OrderStatusEvents. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderStatusEventCountArgs} args - Arguments to filter OrderStatusEvents to count. * @example * // Count the number of OrderStatusEvents * const count = await prisma.orderStatusEvent.count({ * where: { * // ... the filter for the OrderStatusEvents we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a OrderStatusEvent. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderStatusEventAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by OrderStatusEvent. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {OrderStatusEventGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends OrderStatusEventGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: OrderStatusEventGroupByArgs['orderBy'] } : { orderBy?: OrderStatusEventGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetOrderStatusEventGroupByPayload : Prisma.PrismaPromise /** * Fields of the OrderStatusEvent model */ readonly fields: OrderStatusEventFieldRefs; } /** * The delegate class that acts as a "Promise-like" for OrderStatusEvent. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__OrderStatusEventClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" order = {}>(args?: Subset>): Prisma__OrderClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> actorAdminUser = {}>(args?: Subset>): Prisma__AdminUserClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the OrderStatusEvent model */ interface OrderStatusEventFieldRefs { readonly id: FieldRef<"OrderStatusEvent", 'String'> readonly orderId: FieldRef<"OrderStatusEvent", 'String'> readonly fromStatus: FieldRef<"OrderStatusEvent", 'OrderStatus'> readonly toStatus: FieldRef<"OrderStatusEvent", 'OrderStatus'> readonly note: FieldRef<"OrderStatusEvent", 'String'> readonly actorAdminUserId: FieldRef<"OrderStatusEvent", 'String'> readonly createdAt: FieldRef<"OrderStatusEvent", 'DateTime'> } // Custom InputTypes /** * OrderStatusEvent findUnique */ export type OrderStatusEventFindUniqueArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * Filter, which OrderStatusEvent to fetch. */ where: OrderStatusEventWhereUniqueInput } /** * OrderStatusEvent findUniqueOrThrow */ export type OrderStatusEventFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * Filter, which OrderStatusEvent to fetch. */ where: OrderStatusEventWhereUniqueInput } /** * OrderStatusEvent findFirst */ export type OrderStatusEventFindFirstArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * Filter, which OrderStatusEvent to fetch. */ where?: OrderStatusEventWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of OrderStatusEvents to fetch. */ orderBy?: OrderStatusEventOrderByWithRelationInput | OrderStatusEventOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for OrderStatusEvents. */ cursor?: OrderStatusEventWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` OrderStatusEvents from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` OrderStatusEvents. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of OrderStatusEvents. */ distinct?: OrderStatusEventScalarFieldEnum | OrderStatusEventScalarFieldEnum[] } /** * OrderStatusEvent findFirstOrThrow */ export type OrderStatusEventFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * Filter, which OrderStatusEvent to fetch. */ where?: OrderStatusEventWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of OrderStatusEvents to fetch. */ orderBy?: OrderStatusEventOrderByWithRelationInput | OrderStatusEventOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for OrderStatusEvents. */ cursor?: OrderStatusEventWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` OrderStatusEvents from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` OrderStatusEvents. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of OrderStatusEvents. */ distinct?: OrderStatusEventScalarFieldEnum | OrderStatusEventScalarFieldEnum[] } /** * OrderStatusEvent findMany */ export type OrderStatusEventFindManyArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * Filter, which OrderStatusEvents to fetch. */ where?: OrderStatusEventWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of OrderStatusEvents to fetch. */ orderBy?: OrderStatusEventOrderByWithRelationInput | OrderStatusEventOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing OrderStatusEvents. */ cursor?: OrderStatusEventWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` OrderStatusEvents from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` OrderStatusEvents. */ skip?: number distinct?: OrderStatusEventScalarFieldEnum | OrderStatusEventScalarFieldEnum[] } /** * OrderStatusEvent create */ export type OrderStatusEventCreateArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * The data needed to create a OrderStatusEvent. */ data: XOR } /** * OrderStatusEvent createMany */ export type OrderStatusEventCreateManyArgs = { /** * The data used to create many OrderStatusEvents. */ data: OrderStatusEventCreateManyInput | OrderStatusEventCreateManyInput[] skipDuplicates?: boolean } /** * OrderStatusEvent createManyAndReturn */ export type OrderStatusEventCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelectCreateManyAndReturn | null /** * The data used to create many OrderStatusEvents. */ data: OrderStatusEventCreateManyInput | OrderStatusEventCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventIncludeCreateManyAndReturn | null } /** * OrderStatusEvent update */ export type OrderStatusEventUpdateArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * The data needed to update a OrderStatusEvent. */ data: XOR /** * Choose, which OrderStatusEvent to update. */ where: OrderStatusEventWhereUniqueInput } /** * OrderStatusEvent updateMany */ export type OrderStatusEventUpdateManyArgs = { /** * The data used to update OrderStatusEvents. */ data: XOR /** * Filter which OrderStatusEvents to update */ where?: OrderStatusEventWhereInput } /** * OrderStatusEvent upsert */ export type OrderStatusEventUpsertArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * The filter to search for the OrderStatusEvent to update in case it exists. */ where: OrderStatusEventWhereUniqueInput /** * In case the OrderStatusEvent found by the `where` argument doesn't exist, create a new OrderStatusEvent with this data. */ create: XOR /** * In case the OrderStatusEvent was found with the provided `where` argument, update it with this data. */ update: XOR } /** * OrderStatusEvent delete */ export type OrderStatusEventDeleteArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null /** * Filter which OrderStatusEvent to delete. */ where: OrderStatusEventWhereUniqueInput } /** * OrderStatusEvent deleteMany */ export type OrderStatusEventDeleteManyArgs = { /** * Filter which OrderStatusEvents to delete */ where?: OrderStatusEventWhereInput } /** * OrderStatusEvent.actorAdminUser */ export type OrderStatusEvent$actorAdminUserArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null where?: AdminUserWhereInput } /** * OrderStatusEvent without action */ export type OrderStatusEventDefaultArgs = { /** * Select specific fields to fetch from the OrderStatusEvent */ select?: OrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderStatusEventInclude | null } /** * Model PreOrder */ export type AggregatePreOrder = { _count: PreOrderCountAggregateOutputType | null _avg: PreOrderAvgAggregateOutputType | null _sum: PreOrderSumAggregateOutputType | null _min: PreOrderMinAggregateOutputType | null _max: PreOrderMaxAggregateOutputType | null } export type PreOrderAvgAggregateOutputType = { estimatedWeightGrams: Decimal | null estimatedPriceRial: Decimal | null } export type PreOrderSumAggregateOutputType = { estimatedWeightGrams: Decimal | null estimatedPriceRial: Decimal | null } export type PreOrderMinAggregateOutputType = { id: string | null customerId: string | null cityId: string | null workshopId: string | null status: $Enums.PreOrderStatus | null designImageUrl: string | null colorName: string | null sizeSpec: string | null stoneColor: string | null minaColor: string | null estimatedWeightGrams: Decimal | null estimatedPriceRial: Decimal | null description: string | null convertedOrderId: string | null createdAt: Date | null updatedAt: Date | null } export type PreOrderMaxAggregateOutputType = { id: string | null customerId: string | null cityId: string | null workshopId: string | null status: $Enums.PreOrderStatus | null designImageUrl: string | null colorName: string | null sizeSpec: string | null stoneColor: string | null minaColor: string | null estimatedWeightGrams: Decimal | null estimatedPriceRial: Decimal | null description: string | null convertedOrderId: string | null createdAt: Date | null updatedAt: Date | null } export type PreOrderCountAggregateOutputType = { id: number customerId: number cityId: number workshopId: number status: number designImageUrl: number colorName: number sizeSpec: number stoneColor: number minaColor: number estimatedWeightGrams: number estimatedPriceRial: number description: number convertedOrderId: number createdAt: number updatedAt: number _all: number } export type PreOrderAvgAggregateInputType = { estimatedWeightGrams?: true estimatedPriceRial?: true } export type PreOrderSumAggregateInputType = { estimatedWeightGrams?: true estimatedPriceRial?: true } export type PreOrderMinAggregateInputType = { id?: true customerId?: true cityId?: true workshopId?: true status?: true designImageUrl?: true colorName?: true sizeSpec?: true stoneColor?: true minaColor?: true estimatedWeightGrams?: true estimatedPriceRial?: true description?: true convertedOrderId?: true createdAt?: true updatedAt?: true } export type PreOrderMaxAggregateInputType = { id?: true customerId?: true cityId?: true workshopId?: true status?: true designImageUrl?: true colorName?: true sizeSpec?: true stoneColor?: true minaColor?: true estimatedWeightGrams?: true estimatedPriceRial?: true description?: true convertedOrderId?: true createdAt?: true updatedAt?: true } export type PreOrderCountAggregateInputType = { id?: true customerId?: true cityId?: true workshopId?: true status?: true designImageUrl?: true colorName?: true sizeSpec?: true stoneColor?: true minaColor?: true estimatedWeightGrams?: true estimatedPriceRial?: true description?: true convertedOrderId?: true createdAt?: true updatedAt?: true _all?: true } export type PreOrderAggregateArgs = { /** * Filter which PreOrder to aggregate. */ where?: PreOrderWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of PreOrders to fetch. */ orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: PreOrderWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` PreOrders from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` PreOrders. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned PreOrders **/ _count?: true | PreOrderCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: PreOrderAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: PreOrderSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: PreOrderMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: PreOrderMaxAggregateInputType } export type GetPreOrderAggregateType = { [P in keyof T & keyof AggregatePreOrder]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type PreOrderGroupByArgs = { where?: PreOrderWhereInput orderBy?: PreOrderOrderByWithAggregationInput | PreOrderOrderByWithAggregationInput[] by: PreOrderScalarFieldEnum[] | PreOrderScalarFieldEnum having?: PreOrderScalarWhereWithAggregatesInput take?: number skip?: number _count?: PreOrderCountAggregateInputType | true _avg?: PreOrderAvgAggregateInputType _sum?: PreOrderSumAggregateInputType _min?: PreOrderMinAggregateInputType _max?: PreOrderMaxAggregateInputType } export type PreOrderGroupByOutputType = { id: string customerId: string cityId: string | null workshopId: string | null status: $Enums.PreOrderStatus designImageUrl: string | null colorName: string | null sizeSpec: string | null stoneColor: string | null minaColor: string | null estimatedWeightGrams: Decimal | null estimatedPriceRial: Decimal | null description: string | null convertedOrderId: string | null createdAt: Date updatedAt: Date _count: PreOrderCountAggregateOutputType | null _avg: PreOrderAvgAggregateOutputType | null _sum: PreOrderSumAggregateOutputType | null _min: PreOrderMinAggregateOutputType | null _max: PreOrderMaxAggregateOutputType | null } type GetPreOrderGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof PreOrderGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type PreOrderSelect = $Extensions.GetSelect<{ id?: boolean customerId?: boolean cityId?: boolean workshopId?: boolean status?: boolean designImageUrl?: boolean colorName?: boolean sizeSpec?: boolean stoneColor?: boolean minaColor?: boolean estimatedWeightGrams?: boolean estimatedPriceRial?: boolean description?: boolean convertedOrderId?: boolean createdAt?: boolean updatedAt?: boolean customer?: boolean | CustomerDefaultArgs city?: boolean | PreOrder$cityArgs workshop?: boolean | PreOrder$workshopArgs convertedOrder?: boolean | PreOrder$convertedOrderArgs statusEvents?: boolean | PreOrder$statusEventsArgs _count?: boolean | PreOrderCountOutputTypeDefaultArgs }, ExtArgs["result"]["preOrder"]> export type PreOrderSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean customerId?: boolean cityId?: boolean workshopId?: boolean status?: boolean designImageUrl?: boolean colorName?: boolean sizeSpec?: boolean stoneColor?: boolean minaColor?: boolean estimatedWeightGrams?: boolean estimatedPriceRial?: boolean description?: boolean convertedOrderId?: boolean createdAt?: boolean updatedAt?: boolean customer?: boolean | CustomerDefaultArgs city?: boolean | PreOrder$cityArgs workshop?: boolean | PreOrder$workshopArgs convertedOrder?: boolean | PreOrder$convertedOrderArgs }, ExtArgs["result"]["preOrder"]> export type PreOrderSelectScalar = { id?: boolean customerId?: boolean cityId?: boolean workshopId?: boolean status?: boolean designImageUrl?: boolean colorName?: boolean sizeSpec?: boolean stoneColor?: boolean minaColor?: boolean estimatedWeightGrams?: boolean estimatedPriceRial?: boolean description?: boolean convertedOrderId?: boolean createdAt?: boolean updatedAt?: boolean } export type PreOrderInclude = { customer?: boolean | CustomerDefaultArgs city?: boolean | PreOrder$cityArgs workshop?: boolean | PreOrder$workshopArgs convertedOrder?: boolean | PreOrder$convertedOrderArgs statusEvents?: boolean | PreOrder$statusEventsArgs _count?: boolean | PreOrderCountOutputTypeDefaultArgs } export type PreOrderIncludeCreateManyAndReturn = { customer?: boolean | CustomerDefaultArgs city?: boolean | PreOrder$cityArgs workshop?: boolean | PreOrder$workshopArgs convertedOrder?: boolean | PreOrder$convertedOrderArgs } export type $PreOrderPayload = { name: "PreOrder" objects: { customer: Prisma.$CustomerPayload city: Prisma.$CityPayload | null workshop: Prisma.$WorkshopPayload | null convertedOrder: Prisma.$OrderPayload | null statusEvents: Prisma.$PreOrderStatusEventPayload[] } scalars: $Extensions.GetPayloadResult<{ id: string customerId: string cityId: string | null workshopId: string | null status: $Enums.PreOrderStatus designImageUrl: string | null colorName: string | null sizeSpec: string | null stoneColor: string | null minaColor: string | null estimatedWeightGrams: Prisma.Decimal | null estimatedPriceRial: Prisma.Decimal | null description: string | null /** * Once priced, an admin converts this into a real (debt-bearing) Order. */ convertedOrderId: string | null createdAt: Date updatedAt: Date }, ExtArgs["result"]["preOrder"]> composites: {} } type PreOrderGetPayload = $Result.GetResult type PreOrderCountArgs = Omit & { select?: PreOrderCountAggregateInputType | true } export interface PreOrderDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['PreOrder'], meta: { name: 'PreOrder' } } /** * Find zero or one PreOrder that matches the filter. * @param {PreOrderFindUniqueArgs} args - Arguments to find a PreOrder * @example * // Get one PreOrder * const preOrder = await prisma.preOrder.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__PreOrderClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one PreOrder that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {PreOrderFindUniqueOrThrowArgs} args - Arguments to find a PreOrder * @example * // Get one PreOrder * const preOrder = await prisma.preOrder.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__PreOrderClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first PreOrder that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderFindFirstArgs} args - Arguments to find a PreOrder * @example * // Get one PreOrder * const preOrder = await prisma.preOrder.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__PreOrderClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first PreOrder that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderFindFirstOrThrowArgs} args - Arguments to find a PreOrder * @example * // Get one PreOrder * const preOrder = await prisma.preOrder.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__PreOrderClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more PreOrders that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all PreOrders * const preOrders = await prisma.preOrder.findMany() * * // Get first 10 PreOrders * const preOrders = await prisma.preOrder.findMany({ take: 10 }) * * // Only select the `id` * const preOrderWithIdOnly = await prisma.preOrder.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a PreOrder. * @param {PreOrderCreateArgs} args - Arguments to create a PreOrder. * @example * // Create one PreOrder * const PreOrder = await prisma.preOrder.create({ * data: { * // ... data to create a PreOrder * } * }) * */ create(args: SelectSubset>): Prisma__PreOrderClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many PreOrders. * @param {PreOrderCreateManyArgs} args - Arguments to create many PreOrders. * @example * // Create many PreOrders * const preOrder = await prisma.preOrder.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many PreOrders and returns the data saved in the database. * @param {PreOrderCreateManyAndReturnArgs} args - Arguments to create many PreOrders. * @example * // Create many PreOrders * const preOrder = await prisma.preOrder.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many PreOrders and only return the `id` * const preOrderWithIdOnly = await prisma.preOrder.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a PreOrder. * @param {PreOrderDeleteArgs} args - Arguments to delete one PreOrder. * @example * // Delete one PreOrder * const PreOrder = await prisma.preOrder.delete({ * where: { * // ... filter to delete one PreOrder * } * }) * */ delete(args: SelectSubset>): Prisma__PreOrderClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one PreOrder. * @param {PreOrderUpdateArgs} args - Arguments to update one PreOrder. * @example * // Update one PreOrder * const preOrder = await prisma.preOrder.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__PreOrderClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more PreOrders. * @param {PreOrderDeleteManyArgs} args - Arguments to filter PreOrders to delete. * @example * // Delete a few PreOrders * const { count } = await prisma.preOrder.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more PreOrders. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many PreOrders * const preOrder = await prisma.preOrder.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one PreOrder. * @param {PreOrderUpsertArgs} args - Arguments to update or create a PreOrder. * @example * // Update or create a PreOrder * const preOrder = await prisma.preOrder.upsert({ * create: { * // ... data to create a PreOrder * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the PreOrder we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__PreOrderClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of PreOrders. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderCountArgs} args - Arguments to filter PreOrders to count. * @example * // Count the number of PreOrders * const count = await prisma.preOrder.count({ * where: { * // ... the filter for the PreOrders we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a PreOrder. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by PreOrder. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends PreOrderGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: PreOrderGroupByArgs['orderBy'] } : { orderBy?: PreOrderGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetPreOrderGroupByPayload : Prisma.PrismaPromise /** * Fields of the PreOrder model */ readonly fields: PreOrderFieldRefs; } /** * The delegate class that acts as a "Promise-like" for PreOrder. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__PreOrderClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" customer = {}>(args?: Subset>): Prisma__CustomerClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> city = {}>(args?: Subset>): Prisma__CityClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> workshop = {}>(args?: Subset>): Prisma__WorkshopClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> convertedOrder = {}>(args?: Subset>): Prisma__OrderClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> statusEvents = {}>(args?: Subset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany"> | Null> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the PreOrder model */ interface PreOrderFieldRefs { readonly id: FieldRef<"PreOrder", 'String'> readonly customerId: FieldRef<"PreOrder", 'String'> readonly cityId: FieldRef<"PreOrder", 'String'> readonly workshopId: FieldRef<"PreOrder", 'String'> readonly status: FieldRef<"PreOrder", 'PreOrderStatus'> readonly designImageUrl: FieldRef<"PreOrder", 'String'> readonly colorName: FieldRef<"PreOrder", 'String'> readonly sizeSpec: FieldRef<"PreOrder", 'String'> readonly stoneColor: FieldRef<"PreOrder", 'String'> readonly minaColor: FieldRef<"PreOrder", 'String'> readonly estimatedWeightGrams: FieldRef<"PreOrder", 'Decimal'> readonly estimatedPriceRial: FieldRef<"PreOrder", 'Decimal'> readonly description: FieldRef<"PreOrder", 'String'> readonly convertedOrderId: FieldRef<"PreOrder", 'String'> readonly createdAt: FieldRef<"PreOrder", 'DateTime'> readonly updatedAt: FieldRef<"PreOrder", 'DateTime'> } // Custom InputTypes /** * PreOrder findUnique */ export type PreOrderFindUniqueArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * Filter, which PreOrder to fetch. */ where: PreOrderWhereUniqueInput } /** * PreOrder findUniqueOrThrow */ export type PreOrderFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * Filter, which PreOrder to fetch. */ where: PreOrderWhereUniqueInput } /** * PreOrder findFirst */ export type PreOrderFindFirstArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * Filter, which PreOrder to fetch. */ where?: PreOrderWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of PreOrders to fetch. */ orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for PreOrders. */ cursor?: PreOrderWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` PreOrders from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` PreOrders. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of PreOrders. */ distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[] } /** * PreOrder findFirstOrThrow */ export type PreOrderFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * Filter, which PreOrder to fetch. */ where?: PreOrderWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of PreOrders to fetch. */ orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for PreOrders. */ cursor?: PreOrderWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` PreOrders from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` PreOrders. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of PreOrders. */ distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[] } /** * PreOrder findMany */ export type PreOrderFindManyArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * Filter, which PreOrders to fetch. */ where?: PreOrderWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of PreOrders to fetch. */ orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing PreOrders. */ cursor?: PreOrderWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` PreOrders from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` PreOrders. */ skip?: number distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[] } /** * PreOrder create */ export type PreOrderCreateArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * The data needed to create a PreOrder. */ data: XOR } /** * PreOrder createMany */ export type PreOrderCreateManyArgs = { /** * The data used to create many PreOrders. */ data: PreOrderCreateManyInput | PreOrderCreateManyInput[] skipDuplicates?: boolean } /** * PreOrder createManyAndReturn */ export type PreOrderCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelectCreateManyAndReturn | null /** * The data used to create many PreOrders. */ data: PreOrderCreateManyInput | PreOrderCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: PreOrderIncludeCreateManyAndReturn | null } /** * PreOrder update */ export type PreOrderUpdateArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * The data needed to update a PreOrder. */ data: XOR /** * Choose, which PreOrder to update. */ where: PreOrderWhereUniqueInput } /** * PreOrder updateMany */ export type PreOrderUpdateManyArgs = { /** * The data used to update PreOrders. */ data: XOR /** * Filter which PreOrders to update */ where?: PreOrderWhereInput } /** * PreOrder upsert */ export type PreOrderUpsertArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * The filter to search for the PreOrder to update in case it exists. */ where: PreOrderWhereUniqueInput /** * In case the PreOrder found by the `where` argument doesn't exist, create a new PreOrder with this data. */ create: XOR /** * In case the PreOrder was found with the provided `where` argument, update it with this data. */ update: XOR } /** * PreOrder delete */ export type PreOrderDeleteArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null /** * Filter which PreOrder to delete. */ where: PreOrderWhereUniqueInput } /** * PreOrder deleteMany */ export type PreOrderDeleteManyArgs = { /** * Filter which PreOrders to delete */ where?: PreOrderWhereInput } /** * PreOrder.city */ export type PreOrder$cityArgs = { /** * Select specific fields to fetch from the City */ select?: CitySelect | null /** * Choose, which related nodes to fetch as well */ include?: CityInclude | null where?: CityWhereInput } /** * PreOrder.workshop */ export type PreOrder$workshopArgs = { /** * Select specific fields to fetch from the Workshop */ select?: WorkshopSelect | null /** * Choose, which related nodes to fetch as well */ include?: WorkshopInclude | null where?: WorkshopWhereInput } /** * PreOrder.convertedOrder */ export type PreOrder$convertedOrderArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null where?: OrderWhereInput } /** * PreOrder.statusEvents */ export type PreOrder$statusEventsArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null where?: PreOrderStatusEventWhereInput orderBy?: PreOrderStatusEventOrderByWithRelationInput | PreOrderStatusEventOrderByWithRelationInput[] cursor?: PreOrderStatusEventWhereUniqueInput take?: number skip?: number distinct?: PreOrderStatusEventScalarFieldEnum | PreOrderStatusEventScalarFieldEnum[] } /** * PreOrder without action */ export type PreOrderDefaultArgs = { /** * Select specific fields to fetch from the PreOrder */ select?: PreOrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderInclude | null } /** * Model PreOrderStatusEvent */ export type AggregatePreOrderStatusEvent = { _count: PreOrderStatusEventCountAggregateOutputType | null _min: PreOrderStatusEventMinAggregateOutputType | null _max: PreOrderStatusEventMaxAggregateOutputType | null } export type PreOrderStatusEventMinAggregateOutputType = { id: string | null preOrderId: string | null actorAdminUserId: string | null ipAddress: string | null createdAt: Date | null } export type PreOrderStatusEventMaxAggregateOutputType = { id: string | null preOrderId: string | null actorAdminUserId: string | null ipAddress: string | null createdAt: Date | null } export type PreOrderStatusEventCountAggregateOutputType = { id: number preOrderId: number changes: number actorAdminUserId: number ipAddress: number createdAt: number _all: number } export type PreOrderStatusEventMinAggregateInputType = { id?: true preOrderId?: true actorAdminUserId?: true ipAddress?: true createdAt?: true } export type PreOrderStatusEventMaxAggregateInputType = { id?: true preOrderId?: true actorAdminUserId?: true ipAddress?: true createdAt?: true } export type PreOrderStatusEventCountAggregateInputType = { id?: true preOrderId?: true changes?: true actorAdminUserId?: true ipAddress?: true createdAt?: true _all?: true } export type PreOrderStatusEventAggregateArgs = { /** * Filter which PreOrderStatusEvent to aggregate. */ where?: PreOrderStatusEventWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of PreOrderStatusEvents to fetch. */ orderBy?: PreOrderStatusEventOrderByWithRelationInput | PreOrderStatusEventOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: PreOrderStatusEventWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` PreOrderStatusEvents from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` PreOrderStatusEvents. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned PreOrderStatusEvents **/ _count?: true | PreOrderStatusEventCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: PreOrderStatusEventMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: PreOrderStatusEventMaxAggregateInputType } export type GetPreOrderStatusEventAggregateType = { [P in keyof T & keyof AggregatePreOrderStatusEvent]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type PreOrderStatusEventGroupByArgs = { where?: PreOrderStatusEventWhereInput orderBy?: PreOrderStatusEventOrderByWithAggregationInput | PreOrderStatusEventOrderByWithAggregationInput[] by: PreOrderStatusEventScalarFieldEnum[] | PreOrderStatusEventScalarFieldEnum having?: PreOrderStatusEventScalarWhereWithAggregatesInput take?: number skip?: number _count?: PreOrderStatusEventCountAggregateInputType | true _min?: PreOrderStatusEventMinAggregateInputType _max?: PreOrderStatusEventMaxAggregateInputType } export type PreOrderStatusEventGroupByOutputType = { id: string preOrderId: string changes: JsonValue actorAdminUserId: string | null ipAddress: string | null createdAt: Date _count: PreOrderStatusEventCountAggregateOutputType | null _min: PreOrderStatusEventMinAggregateOutputType | null _max: PreOrderStatusEventMaxAggregateOutputType | null } type GetPreOrderStatusEventGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof PreOrderStatusEventGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type PreOrderStatusEventSelect = $Extensions.GetSelect<{ id?: boolean preOrderId?: boolean changes?: boolean actorAdminUserId?: boolean ipAddress?: boolean createdAt?: boolean preOrder?: boolean | PreOrderDefaultArgs actorAdminUser?: boolean | PreOrderStatusEvent$actorAdminUserArgs }, ExtArgs["result"]["preOrderStatusEvent"]> export type PreOrderStatusEventSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean preOrderId?: boolean changes?: boolean actorAdminUserId?: boolean ipAddress?: boolean createdAt?: boolean preOrder?: boolean | PreOrderDefaultArgs actorAdminUser?: boolean | PreOrderStatusEvent$actorAdminUserArgs }, ExtArgs["result"]["preOrderStatusEvent"]> export type PreOrderStatusEventSelectScalar = { id?: boolean preOrderId?: boolean changes?: boolean actorAdminUserId?: boolean ipAddress?: boolean createdAt?: boolean } export type PreOrderStatusEventInclude = { preOrder?: boolean | PreOrderDefaultArgs actorAdminUser?: boolean | PreOrderStatusEvent$actorAdminUserArgs } export type PreOrderStatusEventIncludeCreateManyAndReturn = { preOrder?: boolean | PreOrderDefaultArgs actorAdminUser?: boolean | PreOrderStatusEvent$actorAdminUserArgs } export type $PreOrderStatusEventPayload = { name: "PreOrderStatusEvent" objects: { preOrder: Prisma.$PreOrderPayload actorAdminUser: Prisma.$AdminUserPayload | null } scalars: $Extensions.GetPayloadResult<{ id: string preOrderId: string /** * Field-level diff, e.g. {"status": {"old": "PLACED", "new": "ADMIN_APPROVED"}} */ changes: Prisma.JsonValue actorAdminUserId: string | null ipAddress: string | null createdAt: Date }, ExtArgs["result"]["preOrderStatusEvent"]> composites: {} } type PreOrderStatusEventGetPayload = $Result.GetResult type PreOrderStatusEventCountArgs = Omit & { select?: PreOrderStatusEventCountAggregateInputType | true } export interface PreOrderStatusEventDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['PreOrderStatusEvent'], meta: { name: 'PreOrderStatusEvent' } } /** * Find zero or one PreOrderStatusEvent that matches the filter. * @param {PreOrderStatusEventFindUniqueArgs} args - Arguments to find a PreOrderStatusEvent * @example * // Get one PreOrderStatusEvent * const preOrderStatusEvent = await prisma.preOrderStatusEvent.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__PreOrderStatusEventClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one PreOrderStatusEvent that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {PreOrderStatusEventFindUniqueOrThrowArgs} args - Arguments to find a PreOrderStatusEvent * @example * // Get one PreOrderStatusEvent * const preOrderStatusEvent = await prisma.preOrderStatusEvent.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__PreOrderStatusEventClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first PreOrderStatusEvent that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderStatusEventFindFirstArgs} args - Arguments to find a PreOrderStatusEvent * @example * // Get one PreOrderStatusEvent * const preOrderStatusEvent = await prisma.preOrderStatusEvent.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__PreOrderStatusEventClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first PreOrderStatusEvent that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderStatusEventFindFirstOrThrowArgs} args - Arguments to find a PreOrderStatusEvent * @example * // Get one PreOrderStatusEvent * const preOrderStatusEvent = await prisma.preOrderStatusEvent.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__PreOrderStatusEventClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more PreOrderStatusEvents that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderStatusEventFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all PreOrderStatusEvents * const preOrderStatusEvents = await prisma.preOrderStatusEvent.findMany() * * // Get first 10 PreOrderStatusEvents * const preOrderStatusEvents = await prisma.preOrderStatusEvent.findMany({ take: 10 }) * * // Only select the `id` * const preOrderStatusEventWithIdOnly = await prisma.preOrderStatusEvent.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a PreOrderStatusEvent. * @param {PreOrderStatusEventCreateArgs} args - Arguments to create a PreOrderStatusEvent. * @example * // Create one PreOrderStatusEvent * const PreOrderStatusEvent = await prisma.preOrderStatusEvent.create({ * data: { * // ... data to create a PreOrderStatusEvent * } * }) * */ create(args: SelectSubset>): Prisma__PreOrderStatusEventClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many PreOrderStatusEvents. * @param {PreOrderStatusEventCreateManyArgs} args - Arguments to create many PreOrderStatusEvents. * @example * // Create many PreOrderStatusEvents * const preOrderStatusEvent = await prisma.preOrderStatusEvent.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many PreOrderStatusEvents and returns the data saved in the database. * @param {PreOrderStatusEventCreateManyAndReturnArgs} args - Arguments to create many PreOrderStatusEvents. * @example * // Create many PreOrderStatusEvents * const preOrderStatusEvent = await prisma.preOrderStatusEvent.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many PreOrderStatusEvents and only return the `id` * const preOrderStatusEventWithIdOnly = await prisma.preOrderStatusEvent.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a PreOrderStatusEvent. * @param {PreOrderStatusEventDeleteArgs} args - Arguments to delete one PreOrderStatusEvent. * @example * // Delete one PreOrderStatusEvent * const PreOrderStatusEvent = await prisma.preOrderStatusEvent.delete({ * where: { * // ... filter to delete one PreOrderStatusEvent * } * }) * */ delete(args: SelectSubset>): Prisma__PreOrderStatusEventClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one PreOrderStatusEvent. * @param {PreOrderStatusEventUpdateArgs} args - Arguments to update one PreOrderStatusEvent. * @example * // Update one PreOrderStatusEvent * const preOrderStatusEvent = await prisma.preOrderStatusEvent.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__PreOrderStatusEventClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more PreOrderStatusEvents. * @param {PreOrderStatusEventDeleteManyArgs} args - Arguments to filter PreOrderStatusEvents to delete. * @example * // Delete a few PreOrderStatusEvents * const { count } = await prisma.preOrderStatusEvent.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more PreOrderStatusEvents. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderStatusEventUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many PreOrderStatusEvents * const preOrderStatusEvent = await prisma.preOrderStatusEvent.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one PreOrderStatusEvent. * @param {PreOrderStatusEventUpsertArgs} args - Arguments to update or create a PreOrderStatusEvent. * @example * // Update or create a PreOrderStatusEvent * const preOrderStatusEvent = await prisma.preOrderStatusEvent.upsert({ * create: { * // ... data to create a PreOrderStatusEvent * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the PreOrderStatusEvent we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__PreOrderStatusEventClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of PreOrderStatusEvents. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderStatusEventCountArgs} args - Arguments to filter PreOrderStatusEvents to count. * @example * // Count the number of PreOrderStatusEvents * const count = await prisma.preOrderStatusEvent.count({ * where: { * // ... the filter for the PreOrderStatusEvents we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a PreOrderStatusEvent. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderStatusEventAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by PreOrderStatusEvent. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {PreOrderStatusEventGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends PreOrderStatusEventGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: PreOrderStatusEventGroupByArgs['orderBy'] } : { orderBy?: PreOrderStatusEventGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetPreOrderStatusEventGroupByPayload : Prisma.PrismaPromise /** * Fields of the PreOrderStatusEvent model */ readonly fields: PreOrderStatusEventFieldRefs; } /** * The delegate class that acts as a "Promise-like" for PreOrderStatusEvent. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__PreOrderStatusEventClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" preOrder = {}>(args?: Subset>): Prisma__PreOrderClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> actorAdminUser = {}>(args?: Subset>): Prisma__AdminUserClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the PreOrderStatusEvent model */ interface PreOrderStatusEventFieldRefs { readonly id: FieldRef<"PreOrderStatusEvent", 'String'> readonly preOrderId: FieldRef<"PreOrderStatusEvent", 'String'> readonly changes: FieldRef<"PreOrderStatusEvent", 'Json'> readonly actorAdminUserId: FieldRef<"PreOrderStatusEvent", 'String'> readonly ipAddress: FieldRef<"PreOrderStatusEvent", 'String'> readonly createdAt: FieldRef<"PreOrderStatusEvent", 'DateTime'> } // Custom InputTypes /** * PreOrderStatusEvent findUnique */ export type PreOrderStatusEventFindUniqueArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * Filter, which PreOrderStatusEvent to fetch. */ where: PreOrderStatusEventWhereUniqueInput } /** * PreOrderStatusEvent findUniqueOrThrow */ export type PreOrderStatusEventFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * Filter, which PreOrderStatusEvent to fetch. */ where: PreOrderStatusEventWhereUniqueInput } /** * PreOrderStatusEvent findFirst */ export type PreOrderStatusEventFindFirstArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * Filter, which PreOrderStatusEvent to fetch. */ where?: PreOrderStatusEventWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of PreOrderStatusEvents to fetch. */ orderBy?: PreOrderStatusEventOrderByWithRelationInput | PreOrderStatusEventOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for PreOrderStatusEvents. */ cursor?: PreOrderStatusEventWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` PreOrderStatusEvents from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` PreOrderStatusEvents. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of PreOrderStatusEvents. */ distinct?: PreOrderStatusEventScalarFieldEnum | PreOrderStatusEventScalarFieldEnum[] } /** * PreOrderStatusEvent findFirstOrThrow */ export type PreOrderStatusEventFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * Filter, which PreOrderStatusEvent to fetch. */ where?: PreOrderStatusEventWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of PreOrderStatusEvents to fetch. */ orderBy?: PreOrderStatusEventOrderByWithRelationInput | PreOrderStatusEventOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for PreOrderStatusEvents. */ cursor?: PreOrderStatusEventWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` PreOrderStatusEvents from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` PreOrderStatusEvents. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of PreOrderStatusEvents. */ distinct?: PreOrderStatusEventScalarFieldEnum | PreOrderStatusEventScalarFieldEnum[] } /** * PreOrderStatusEvent findMany */ export type PreOrderStatusEventFindManyArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * Filter, which PreOrderStatusEvents to fetch. */ where?: PreOrderStatusEventWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of PreOrderStatusEvents to fetch. */ orderBy?: PreOrderStatusEventOrderByWithRelationInput | PreOrderStatusEventOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing PreOrderStatusEvents. */ cursor?: PreOrderStatusEventWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` PreOrderStatusEvents from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` PreOrderStatusEvents. */ skip?: number distinct?: PreOrderStatusEventScalarFieldEnum | PreOrderStatusEventScalarFieldEnum[] } /** * PreOrderStatusEvent create */ export type PreOrderStatusEventCreateArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * The data needed to create a PreOrderStatusEvent. */ data: XOR } /** * PreOrderStatusEvent createMany */ export type PreOrderStatusEventCreateManyArgs = { /** * The data used to create many PreOrderStatusEvents. */ data: PreOrderStatusEventCreateManyInput | PreOrderStatusEventCreateManyInput[] skipDuplicates?: boolean } /** * PreOrderStatusEvent createManyAndReturn */ export type PreOrderStatusEventCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelectCreateManyAndReturn | null /** * The data used to create many PreOrderStatusEvents. */ data: PreOrderStatusEventCreateManyInput | PreOrderStatusEventCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventIncludeCreateManyAndReturn | null } /** * PreOrderStatusEvent update */ export type PreOrderStatusEventUpdateArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * The data needed to update a PreOrderStatusEvent. */ data: XOR /** * Choose, which PreOrderStatusEvent to update. */ where: PreOrderStatusEventWhereUniqueInput } /** * PreOrderStatusEvent updateMany */ export type PreOrderStatusEventUpdateManyArgs = { /** * The data used to update PreOrderStatusEvents. */ data: XOR /** * Filter which PreOrderStatusEvents to update */ where?: PreOrderStatusEventWhereInput } /** * PreOrderStatusEvent upsert */ export type PreOrderStatusEventUpsertArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * The filter to search for the PreOrderStatusEvent to update in case it exists. */ where: PreOrderStatusEventWhereUniqueInput /** * In case the PreOrderStatusEvent found by the `where` argument doesn't exist, create a new PreOrderStatusEvent with this data. */ create: XOR /** * In case the PreOrderStatusEvent was found with the provided `where` argument, update it with this data. */ update: XOR } /** * PreOrderStatusEvent delete */ export type PreOrderStatusEventDeleteArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null /** * Filter which PreOrderStatusEvent to delete. */ where: PreOrderStatusEventWhereUniqueInput } /** * PreOrderStatusEvent deleteMany */ export type PreOrderStatusEventDeleteManyArgs = { /** * Filter which PreOrderStatusEvents to delete */ where?: PreOrderStatusEventWhereInput } /** * PreOrderStatusEvent.actorAdminUser */ export type PreOrderStatusEvent$actorAdminUserArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null where?: AdminUserWhereInput } /** * PreOrderStatusEvent without action */ export type PreOrderStatusEventDefaultArgs = { /** * Select specific fields to fetch from the PreOrderStatusEvent */ select?: PreOrderStatusEventSelect | null /** * Choose, which related nodes to fetch as well */ include?: PreOrderStatusEventInclude | null } /** * Model LedgerEntry */ export type AggregateLedgerEntry = { _count: LedgerEntryCountAggregateOutputType | null _avg: LedgerEntryAvgAggregateOutputType | null _sum: LedgerEntrySumAggregateOutputType | null _min: LedgerEntryMinAggregateOutputType | null _max: LedgerEntryMaxAggregateOutputType | null } export type LedgerEntryAvgAggregateOutputType = { amount: Decimal | null karatPerMille: number | null pricePerGramRialAtEntry: Decimal | null } export type LedgerEntrySumAggregateOutputType = { amount: Decimal | null karatPerMille: number | null pricePerGramRialAtEntry: Decimal | null } export type LedgerEntryMinAggregateOutputType = { id: string | null customerId: string | null currency: $Enums.LedgerCurrency | null direction: $Enums.LedgerDirection | null sourceType: $Enums.LedgerSourceType | null amount: Decimal | null karatPerMille: number | null pricePerGramRialAtEntry: Decimal | null orderId: string | null confirmed: boolean | null confirmedAt: Date | null postedByAdminUserId: string | null note: string | null createdAt: Date | null } export type LedgerEntryMaxAggregateOutputType = { id: string | null customerId: string | null currency: $Enums.LedgerCurrency | null direction: $Enums.LedgerDirection | null sourceType: $Enums.LedgerSourceType | null amount: Decimal | null karatPerMille: number | null pricePerGramRialAtEntry: Decimal | null orderId: string | null confirmed: boolean | null confirmedAt: Date | null postedByAdminUserId: string | null note: string | null createdAt: Date | null } export type LedgerEntryCountAggregateOutputType = { id: number customerId: number currency: number direction: number sourceType: number amount: number karatPerMille: number pricePerGramRialAtEntry: number orderId: number confirmed: number confirmedAt: number postedByAdminUserId: number note: number createdAt: number _all: number } export type LedgerEntryAvgAggregateInputType = { amount?: true karatPerMille?: true pricePerGramRialAtEntry?: true } export type LedgerEntrySumAggregateInputType = { amount?: true karatPerMille?: true pricePerGramRialAtEntry?: true } export type LedgerEntryMinAggregateInputType = { id?: true customerId?: true currency?: true direction?: true sourceType?: true amount?: true karatPerMille?: true pricePerGramRialAtEntry?: true orderId?: true confirmed?: true confirmedAt?: true postedByAdminUserId?: true note?: true createdAt?: true } export type LedgerEntryMaxAggregateInputType = { id?: true customerId?: true currency?: true direction?: true sourceType?: true amount?: true karatPerMille?: true pricePerGramRialAtEntry?: true orderId?: true confirmed?: true confirmedAt?: true postedByAdminUserId?: true note?: true createdAt?: true } export type LedgerEntryCountAggregateInputType = { id?: true customerId?: true currency?: true direction?: true sourceType?: true amount?: true karatPerMille?: true pricePerGramRialAtEntry?: true orderId?: true confirmed?: true confirmedAt?: true postedByAdminUserId?: true note?: true createdAt?: true _all?: true } export type LedgerEntryAggregateArgs = { /** * Filter which LedgerEntry to aggregate. */ where?: LedgerEntryWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of LedgerEntries to fetch. */ orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: LedgerEntryWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` LedgerEntries from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` LedgerEntries. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned LedgerEntries **/ _count?: true | LedgerEntryCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: LedgerEntryAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: LedgerEntrySumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: LedgerEntryMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: LedgerEntryMaxAggregateInputType } export type GetLedgerEntryAggregateType = { [P in keyof T & keyof AggregateLedgerEntry]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type LedgerEntryGroupByArgs = { where?: LedgerEntryWhereInput orderBy?: LedgerEntryOrderByWithAggregationInput | LedgerEntryOrderByWithAggregationInput[] by: LedgerEntryScalarFieldEnum[] | LedgerEntryScalarFieldEnum having?: LedgerEntryScalarWhereWithAggregatesInput take?: number skip?: number _count?: LedgerEntryCountAggregateInputType | true _avg?: LedgerEntryAvgAggregateInputType _sum?: LedgerEntrySumAggregateInputType _min?: LedgerEntryMinAggregateInputType _max?: LedgerEntryMaxAggregateInputType } export type LedgerEntryGroupByOutputType = { id: string customerId: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal karatPerMille: number | null pricePerGramRialAtEntry: Decimal | null orderId: string | null confirmed: boolean confirmedAt: Date | null postedByAdminUserId: string | null note: string | null createdAt: Date _count: LedgerEntryCountAggregateOutputType | null _avg: LedgerEntryAvgAggregateOutputType | null _sum: LedgerEntrySumAggregateOutputType | null _min: LedgerEntryMinAggregateOutputType | null _max: LedgerEntryMaxAggregateOutputType | null } type GetLedgerEntryGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof LedgerEntryGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type LedgerEntrySelect = $Extensions.GetSelect<{ id?: boolean customerId?: boolean currency?: boolean direction?: boolean sourceType?: boolean amount?: boolean karatPerMille?: boolean pricePerGramRialAtEntry?: boolean orderId?: boolean confirmed?: boolean confirmedAt?: boolean postedByAdminUserId?: boolean note?: boolean createdAt?: boolean customer?: boolean | CustomerDefaultArgs order?: boolean | LedgerEntry$orderArgs postedByAdminUser?: boolean | LedgerEntry$postedByAdminUserArgs }, ExtArgs["result"]["ledgerEntry"]> export type LedgerEntrySelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean customerId?: boolean currency?: boolean direction?: boolean sourceType?: boolean amount?: boolean karatPerMille?: boolean pricePerGramRialAtEntry?: boolean orderId?: boolean confirmed?: boolean confirmedAt?: boolean postedByAdminUserId?: boolean note?: boolean createdAt?: boolean customer?: boolean | CustomerDefaultArgs order?: boolean | LedgerEntry$orderArgs postedByAdminUser?: boolean | LedgerEntry$postedByAdminUserArgs }, ExtArgs["result"]["ledgerEntry"]> export type LedgerEntrySelectScalar = { id?: boolean customerId?: boolean currency?: boolean direction?: boolean sourceType?: boolean amount?: boolean karatPerMille?: boolean pricePerGramRialAtEntry?: boolean orderId?: boolean confirmed?: boolean confirmedAt?: boolean postedByAdminUserId?: boolean note?: boolean createdAt?: boolean } export type LedgerEntryInclude = { customer?: boolean | CustomerDefaultArgs order?: boolean | LedgerEntry$orderArgs postedByAdminUser?: boolean | LedgerEntry$postedByAdminUserArgs } export type LedgerEntryIncludeCreateManyAndReturn = { customer?: boolean | CustomerDefaultArgs order?: boolean | LedgerEntry$orderArgs postedByAdminUser?: boolean | LedgerEntry$postedByAdminUserArgs } export type $LedgerEntryPayload = { name: "LedgerEntry" objects: { customer: Prisma.$CustomerPayload order: Prisma.$OrderPayload | null postedByAdminUser: Prisma.$AdminUserPayload | null } scalars: $Extensions.GetPayloadResult<{ id: string customerId: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType /** * Always positive; direction determines the sign applied to the customer balance. */ amount: Prisma.Decimal /** * Purity of the physical instrument, for REPAYMENT_MELTED_GOLD (e.g. 750, 916). */ karatPerMille: number | null /** * Gold price/gram at conversion time, for REPAYMENT_CASH. */ pricePerGramRialAtEntry: Prisma.Decimal | null orderId: string | null /** * Pending entries don't count toward the cached customer balance until confirmed. */ confirmed: boolean confirmedAt: Date | null postedByAdminUserId: string | null note: string | null createdAt: Date }, ExtArgs["result"]["ledgerEntry"]> composites: {} } type LedgerEntryGetPayload = $Result.GetResult type LedgerEntryCountArgs = Omit & { select?: LedgerEntryCountAggregateInputType | true } export interface LedgerEntryDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['LedgerEntry'], meta: { name: 'LedgerEntry' } } /** * Find zero or one LedgerEntry that matches the filter. * @param {LedgerEntryFindUniqueArgs} args - Arguments to find a LedgerEntry * @example * // Get one LedgerEntry * const ledgerEntry = await prisma.ledgerEntry.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__LedgerEntryClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one LedgerEntry that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {LedgerEntryFindUniqueOrThrowArgs} args - Arguments to find a LedgerEntry * @example * // Get one LedgerEntry * const ledgerEntry = await prisma.ledgerEntry.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__LedgerEntryClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first LedgerEntry that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {LedgerEntryFindFirstArgs} args - Arguments to find a LedgerEntry * @example * // Get one LedgerEntry * const ledgerEntry = await prisma.ledgerEntry.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__LedgerEntryClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first LedgerEntry that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {LedgerEntryFindFirstOrThrowArgs} args - Arguments to find a LedgerEntry * @example * // Get one LedgerEntry * const ledgerEntry = await prisma.ledgerEntry.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__LedgerEntryClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more LedgerEntries that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {LedgerEntryFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all LedgerEntries * const ledgerEntries = await prisma.ledgerEntry.findMany() * * // Get first 10 LedgerEntries * const ledgerEntries = await prisma.ledgerEntry.findMany({ take: 10 }) * * // Only select the `id` * const ledgerEntryWithIdOnly = await prisma.ledgerEntry.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a LedgerEntry. * @param {LedgerEntryCreateArgs} args - Arguments to create a LedgerEntry. * @example * // Create one LedgerEntry * const LedgerEntry = await prisma.ledgerEntry.create({ * data: { * // ... data to create a LedgerEntry * } * }) * */ create(args: SelectSubset>): Prisma__LedgerEntryClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many LedgerEntries. * @param {LedgerEntryCreateManyArgs} args - Arguments to create many LedgerEntries. * @example * // Create many LedgerEntries * const ledgerEntry = await prisma.ledgerEntry.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many LedgerEntries and returns the data saved in the database. * @param {LedgerEntryCreateManyAndReturnArgs} args - Arguments to create many LedgerEntries. * @example * // Create many LedgerEntries * const ledgerEntry = await prisma.ledgerEntry.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many LedgerEntries and only return the `id` * const ledgerEntryWithIdOnly = await prisma.ledgerEntry.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a LedgerEntry. * @param {LedgerEntryDeleteArgs} args - Arguments to delete one LedgerEntry. * @example * // Delete one LedgerEntry * const LedgerEntry = await prisma.ledgerEntry.delete({ * where: { * // ... filter to delete one LedgerEntry * } * }) * */ delete(args: SelectSubset>): Prisma__LedgerEntryClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one LedgerEntry. * @param {LedgerEntryUpdateArgs} args - Arguments to update one LedgerEntry. * @example * // Update one LedgerEntry * const ledgerEntry = await prisma.ledgerEntry.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__LedgerEntryClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more LedgerEntries. * @param {LedgerEntryDeleteManyArgs} args - Arguments to filter LedgerEntries to delete. * @example * // Delete a few LedgerEntries * const { count } = await prisma.ledgerEntry.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more LedgerEntries. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {LedgerEntryUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many LedgerEntries * const ledgerEntry = await prisma.ledgerEntry.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one LedgerEntry. * @param {LedgerEntryUpsertArgs} args - Arguments to update or create a LedgerEntry. * @example * // Update or create a LedgerEntry * const ledgerEntry = await prisma.ledgerEntry.upsert({ * create: { * // ... data to create a LedgerEntry * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the LedgerEntry we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__LedgerEntryClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of LedgerEntries. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {LedgerEntryCountArgs} args - Arguments to filter LedgerEntries to count. * @example * // Count the number of LedgerEntries * const count = await prisma.ledgerEntry.count({ * where: { * // ... the filter for the LedgerEntries we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a LedgerEntry. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {LedgerEntryAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by LedgerEntry. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {LedgerEntryGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends LedgerEntryGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: LedgerEntryGroupByArgs['orderBy'] } : { orderBy?: LedgerEntryGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetLedgerEntryGroupByPayload : Prisma.PrismaPromise /** * Fields of the LedgerEntry model */ readonly fields: LedgerEntryFieldRefs; } /** * The delegate class that acts as a "Promise-like" for LedgerEntry. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__LedgerEntryClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" customer = {}>(args?: Subset>): Prisma__CustomerClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> order = {}>(args?: Subset>): Prisma__OrderClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> postedByAdminUser = {}>(args?: Subset>): Prisma__AdminUserClient<$Result.GetResult, T, "findUniqueOrThrow"> | null, null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the LedgerEntry model */ interface LedgerEntryFieldRefs { readonly id: FieldRef<"LedgerEntry", 'String'> readonly customerId: FieldRef<"LedgerEntry", 'String'> readonly currency: FieldRef<"LedgerEntry", 'LedgerCurrency'> readonly direction: FieldRef<"LedgerEntry", 'LedgerDirection'> readonly sourceType: FieldRef<"LedgerEntry", 'LedgerSourceType'> readonly amount: FieldRef<"LedgerEntry", 'Decimal'> readonly karatPerMille: FieldRef<"LedgerEntry", 'Int'> readonly pricePerGramRialAtEntry: FieldRef<"LedgerEntry", 'Decimal'> readonly orderId: FieldRef<"LedgerEntry", 'String'> readonly confirmed: FieldRef<"LedgerEntry", 'Boolean'> readonly confirmedAt: FieldRef<"LedgerEntry", 'DateTime'> readonly postedByAdminUserId: FieldRef<"LedgerEntry", 'String'> readonly note: FieldRef<"LedgerEntry", 'String'> readonly createdAt: FieldRef<"LedgerEntry", 'DateTime'> } // Custom InputTypes /** * LedgerEntry findUnique */ export type LedgerEntryFindUniqueArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * Filter, which LedgerEntry to fetch. */ where: LedgerEntryWhereUniqueInput } /** * LedgerEntry findUniqueOrThrow */ export type LedgerEntryFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * Filter, which LedgerEntry to fetch. */ where: LedgerEntryWhereUniqueInput } /** * LedgerEntry findFirst */ export type LedgerEntryFindFirstArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * Filter, which LedgerEntry to fetch. */ where?: LedgerEntryWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of LedgerEntries to fetch. */ orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for LedgerEntries. */ cursor?: LedgerEntryWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` LedgerEntries from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` LedgerEntries. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of LedgerEntries. */ distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[] } /** * LedgerEntry findFirstOrThrow */ export type LedgerEntryFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * Filter, which LedgerEntry to fetch. */ where?: LedgerEntryWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of LedgerEntries to fetch. */ orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for LedgerEntries. */ cursor?: LedgerEntryWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` LedgerEntries from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` LedgerEntries. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of LedgerEntries. */ distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[] } /** * LedgerEntry findMany */ export type LedgerEntryFindManyArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * Filter, which LedgerEntries to fetch. */ where?: LedgerEntryWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of LedgerEntries to fetch. */ orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing LedgerEntries. */ cursor?: LedgerEntryWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` LedgerEntries from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` LedgerEntries. */ skip?: number distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[] } /** * LedgerEntry create */ export type LedgerEntryCreateArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * The data needed to create a LedgerEntry. */ data: XOR } /** * LedgerEntry createMany */ export type LedgerEntryCreateManyArgs = { /** * The data used to create many LedgerEntries. */ data: LedgerEntryCreateManyInput | LedgerEntryCreateManyInput[] skipDuplicates?: boolean } /** * LedgerEntry createManyAndReturn */ export type LedgerEntryCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelectCreateManyAndReturn | null /** * The data used to create many LedgerEntries. */ data: LedgerEntryCreateManyInput | LedgerEntryCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryIncludeCreateManyAndReturn | null } /** * LedgerEntry update */ export type LedgerEntryUpdateArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * The data needed to update a LedgerEntry. */ data: XOR /** * Choose, which LedgerEntry to update. */ where: LedgerEntryWhereUniqueInput } /** * LedgerEntry updateMany */ export type LedgerEntryUpdateManyArgs = { /** * The data used to update LedgerEntries. */ data: XOR /** * Filter which LedgerEntries to update */ where?: LedgerEntryWhereInput } /** * LedgerEntry upsert */ export type LedgerEntryUpsertArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * The filter to search for the LedgerEntry to update in case it exists. */ where: LedgerEntryWhereUniqueInput /** * In case the LedgerEntry found by the `where` argument doesn't exist, create a new LedgerEntry with this data. */ create: XOR /** * In case the LedgerEntry was found with the provided `where` argument, update it with this data. */ update: XOR } /** * LedgerEntry delete */ export type LedgerEntryDeleteArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null /** * Filter which LedgerEntry to delete. */ where: LedgerEntryWhereUniqueInput } /** * LedgerEntry deleteMany */ export type LedgerEntryDeleteManyArgs = { /** * Filter which LedgerEntries to delete */ where?: LedgerEntryWhereInput } /** * LedgerEntry.order */ export type LedgerEntry$orderArgs = { /** * Select specific fields to fetch from the Order */ select?: OrderSelect | null /** * Choose, which related nodes to fetch as well */ include?: OrderInclude | null where?: OrderWhereInput } /** * LedgerEntry.postedByAdminUser */ export type LedgerEntry$postedByAdminUserArgs = { /** * Select specific fields to fetch from the AdminUser */ select?: AdminUserSelect | null /** * Choose, which related nodes to fetch as well */ include?: AdminUserInclude | null where?: AdminUserWhereInput } /** * LedgerEntry without action */ export type LedgerEntryDefaultArgs = { /** * Select specific fields to fetch from the LedgerEntry */ select?: LedgerEntrySelect | null /** * Choose, which related nodes to fetch as well */ include?: LedgerEntryInclude | null } /** * Model GoldPriceQuote */ export type AggregateGoldPriceQuote = { _count: GoldPriceQuoteCountAggregateOutputType | null _avg: GoldPriceQuoteAvgAggregateOutputType | null _sum: GoldPriceQuoteSumAggregateOutputType | null _min: GoldPriceQuoteMinAggregateOutputType | null _max: GoldPriceQuoteMaxAggregateOutputType | null } export type GoldPriceQuoteAvgAggregateOutputType = { karatPerMille: number | null pricePerGramRial: Decimal | null } export type GoldPriceQuoteSumAggregateOutputType = { karatPerMille: number | null pricePerGramRial: Decimal | null } export type GoldPriceQuoteMinAggregateOutputType = { id: string | null karatPerMille: number | null pricePerGramRial: Decimal | null source: string | null quotedAt: Date | null } export type GoldPriceQuoteMaxAggregateOutputType = { id: string | null karatPerMille: number | null pricePerGramRial: Decimal | null source: string | null quotedAt: Date | null } export type GoldPriceQuoteCountAggregateOutputType = { id: number karatPerMille: number pricePerGramRial: number source: number quotedAt: number _all: number } export type GoldPriceQuoteAvgAggregateInputType = { karatPerMille?: true pricePerGramRial?: true } export type GoldPriceQuoteSumAggregateInputType = { karatPerMille?: true pricePerGramRial?: true } export type GoldPriceQuoteMinAggregateInputType = { id?: true karatPerMille?: true pricePerGramRial?: true source?: true quotedAt?: true } export type GoldPriceQuoteMaxAggregateInputType = { id?: true karatPerMille?: true pricePerGramRial?: true source?: true quotedAt?: true } export type GoldPriceQuoteCountAggregateInputType = { id?: true karatPerMille?: true pricePerGramRial?: true source?: true quotedAt?: true _all?: true } export type GoldPriceQuoteAggregateArgs = { /** * Filter which GoldPriceQuote to aggregate. */ where?: GoldPriceQuoteWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of GoldPriceQuotes to fetch. */ orderBy?: GoldPriceQuoteOrderByWithRelationInput | GoldPriceQuoteOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: GoldPriceQuoteWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` GoldPriceQuotes from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` GoldPriceQuotes. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned GoldPriceQuotes **/ _count?: true | GoldPriceQuoteCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: GoldPriceQuoteAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: GoldPriceQuoteSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: GoldPriceQuoteMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: GoldPriceQuoteMaxAggregateInputType } export type GetGoldPriceQuoteAggregateType = { [P in keyof T & keyof AggregateGoldPriceQuote]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type GoldPriceQuoteGroupByArgs = { where?: GoldPriceQuoteWhereInput orderBy?: GoldPriceQuoteOrderByWithAggregationInput | GoldPriceQuoteOrderByWithAggregationInput[] by: GoldPriceQuoteScalarFieldEnum[] | GoldPriceQuoteScalarFieldEnum having?: GoldPriceQuoteScalarWhereWithAggregatesInput take?: number skip?: number _count?: GoldPriceQuoteCountAggregateInputType | true _avg?: GoldPriceQuoteAvgAggregateInputType _sum?: GoldPriceQuoteSumAggregateInputType _min?: GoldPriceQuoteMinAggregateInputType _max?: GoldPriceQuoteMaxAggregateInputType } export type GoldPriceQuoteGroupByOutputType = { id: string karatPerMille: number pricePerGramRial: Decimal source: string quotedAt: Date _count: GoldPriceQuoteCountAggregateOutputType | null _avg: GoldPriceQuoteAvgAggregateOutputType | null _sum: GoldPriceQuoteSumAggregateOutputType | null _min: GoldPriceQuoteMinAggregateOutputType | null _max: GoldPriceQuoteMaxAggregateOutputType | null } type GetGoldPriceQuoteGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof GoldPriceQuoteGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type GoldPriceQuoteSelect = $Extensions.GetSelect<{ id?: boolean karatPerMille?: boolean pricePerGramRial?: boolean source?: boolean quotedAt?: boolean }, ExtArgs["result"]["goldPriceQuote"]> export type GoldPriceQuoteSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean karatPerMille?: boolean pricePerGramRial?: boolean source?: boolean quotedAt?: boolean }, ExtArgs["result"]["goldPriceQuote"]> export type GoldPriceQuoteSelectScalar = { id?: boolean karatPerMille?: boolean pricePerGramRial?: boolean source?: boolean quotedAt?: boolean } export type $GoldPriceQuotePayload = { name: "GoldPriceQuote" objects: {} scalars: $Extensions.GetPayloadResult<{ id: string karatPerMille: number pricePerGramRial: Prisma.Decimal source: string quotedAt: Date }, ExtArgs["result"]["goldPriceQuote"]> composites: {} } type GoldPriceQuoteGetPayload = $Result.GetResult type GoldPriceQuoteCountArgs = Omit & { select?: GoldPriceQuoteCountAggregateInputType | true } export interface GoldPriceQuoteDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['GoldPriceQuote'], meta: { name: 'GoldPriceQuote' } } /** * Find zero or one GoldPriceQuote that matches the filter. * @param {GoldPriceQuoteFindUniqueArgs} args - Arguments to find a GoldPriceQuote * @example * // Get one GoldPriceQuote * const goldPriceQuote = await prisma.goldPriceQuote.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__GoldPriceQuoteClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one GoldPriceQuote that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {GoldPriceQuoteFindUniqueOrThrowArgs} args - Arguments to find a GoldPriceQuote * @example * // Get one GoldPriceQuote * const goldPriceQuote = await prisma.goldPriceQuote.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__GoldPriceQuoteClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first GoldPriceQuote that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {GoldPriceQuoteFindFirstArgs} args - Arguments to find a GoldPriceQuote * @example * // Get one GoldPriceQuote * const goldPriceQuote = await prisma.goldPriceQuote.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__GoldPriceQuoteClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first GoldPriceQuote that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {GoldPriceQuoteFindFirstOrThrowArgs} args - Arguments to find a GoldPriceQuote * @example * // Get one GoldPriceQuote * const goldPriceQuote = await prisma.goldPriceQuote.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__GoldPriceQuoteClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more GoldPriceQuotes that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {GoldPriceQuoteFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all GoldPriceQuotes * const goldPriceQuotes = await prisma.goldPriceQuote.findMany() * * // Get first 10 GoldPriceQuotes * const goldPriceQuotes = await prisma.goldPriceQuote.findMany({ take: 10 }) * * // Only select the `id` * const goldPriceQuoteWithIdOnly = await prisma.goldPriceQuote.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a GoldPriceQuote. * @param {GoldPriceQuoteCreateArgs} args - Arguments to create a GoldPriceQuote. * @example * // Create one GoldPriceQuote * const GoldPriceQuote = await prisma.goldPriceQuote.create({ * data: { * // ... data to create a GoldPriceQuote * } * }) * */ create(args: SelectSubset>): Prisma__GoldPriceQuoteClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many GoldPriceQuotes. * @param {GoldPriceQuoteCreateManyArgs} args - Arguments to create many GoldPriceQuotes. * @example * // Create many GoldPriceQuotes * const goldPriceQuote = await prisma.goldPriceQuote.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many GoldPriceQuotes and returns the data saved in the database. * @param {GoldPriceQuoteCreateManyAndReturnArgs} args - Arguments to create many GoldPriceQuotes. * @example * // Create many GoldPriceQuotes * const goldPriceQuote = await prisma.goldPriceQuote.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many GoldPriceQuotes and only return the `id` * const goldPriceQuoteWithIdOnly = await prisma.goldPriceQuote.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a GoldPriceQuote. * @param {GoldPriceQuoteDeleteArgs} args - Arguments to delete one GoldPriceQuote. * @example * // Delete one GoldPriceQuote * const GoldPriceQuote = await prisma.goldPriceQuote.delete({ * where: { * // ... filter to delete one GoldPriceQuote * } * }) * */ delete(args: SelectSubset>): Prisma__GoldPriceQuoteClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one GoldPriceQuote. * @param {GoldPriceQuoteUpdateArgs} args - Arguments to update one GoldPriceQuote. * @example * // Update one GoldPriceQuote * const goldPriceQuote = await prisma.goldPriceQuote.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__GoldPriceQuoteClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more GoldPriceQuotes. * @param {GoldPriceQuoteDeleteManyArgs} args - Arguments to filter GoldPriceQuotes to delete. * @example * // Delete a few GoldPriceQuotes * const { count } = await prisma.goldPriceQuote.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more GoldPriceQuotes. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {GoldPriceQuoteUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many GoldPriceQuotes * const goldPriceQuote = await prisma.goldPriceQuote.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one GoldPriceQuote. * @param {GoldPriceQuoteUpsertArgs} args - Arguments to update or create a GoldPriceQuote. * @example * // Update or create a GoldPriceQuote * const goldPriceQuote = await prisma.goldPriceQuote.upsert({ * create: { * // ... data to create a GoldPriceQuote * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the GoldPriceQuote we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__GoldPriceQuoteClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of GoldPriceQuotes. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {GoldPriceQuoteCountArgs} args - Arguments to filter GoldPriceQuotes to count. * @example * // Count the number of GoldPriceQuotes * const count = await prisma.goldPriceQuote.count({ * where: { * // ... the filter for the GoldPriceQuotes we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a GoldPriceQuote. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {GoldPriceQuoteAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by GoldPriceQuote. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {GoldPriceQuoteGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends GoldPriceQuoteGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: GoldPriceQuoteGroupByArgs['orderBy'] } : { orderBy?: GoldPriceQuoteGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetGoldPriceQuoteGroupByPayload : Prisma.PrismaPromise /** * Fields of the GoldPriceQuote model */ readonly fields: GoldPriceQuoteFieldRefs; } /** * The delegate class that acts as a "Promise-like" for GoldPriceQuote. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__GoldPriceQuoteClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the GoldPriceQuote model */ interface GoldPriceQuoteFieldRefs { readonly id: FieldRef<"GoldPriceQuote", 'String'> readonly karatPerMille: FieldRef<"GoldPriceQuote", 'Int'> readonly pricePerGramRial: FieldRef<"GoldPriceQuote", 'Decimal'> readonly source: FieldRef<"GoldPriceQuote", 'String'> readonly quotedAt: FieldRef<"GoldPriceQuote", 'DateTime'> } // Custom InputTypes /** * GoldPriceQuote findUnique */ export type GoldPriceQuoteFindUniqueArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * Filter, which GoldPriceQuote to fetch. */ where: GoldPriceQuoteWhereUniqueInput } /** * GoldPriceQuote findUniqueOrThrow */ export type GoldPriceQuoteFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * Filter, which GoldPriceQuote to fetch. */ where: GoldPriceQuoteWhereUniqueInput } /** * GoldPriceQuote findFirst */ export type GoldPriceQuoteFindFirstArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * Filter, which GoldPriceQuote to fetch. */ where?: GoldPriceQuoteWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of GoldPriceQuotes to fetch. */ orderBy?: GoldPriceQuoteOrderByWithRelationInput | GoldPriceQuoteOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for GoldPriceQuotes. */ cursor?: GoldPriceQuoteWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` GoldPriceQuotes from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` GoldPriceQuotes. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of GoldPriceQuotes. */ distinct?: GoldPriceQuoteScalarFieldEnum | GoldPriceQuoteScalarFieldEnum[] } /** * GoldPriceQuote findFirstOrThrow */ export type GoldPriceQuoteFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * Filter, which GoldPriceQuote to fetch. */ where?: GoldPriceQuoteWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of GoldPriceQuotes to fetch. */ orderBy?: GoldPriceQuoteOrderByWithRelationInput | GoldPriceQuoteOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for GoldPriceQuotes. */ cursor?: GoldPriceQuoteWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` GoldPriceQuotes from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` GoldPriceQuotes. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of GoldPriceQuotes. */ distinct?: GoldPriceQuoteScalarFieldEnum | GoldPriceQuoteScalarFieldEnum[] } /** * GoldPriceQuote findMany */ export type GoldPriceQuoteFindManyArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * Filter, which GoldPriceQuotes to fetch. */ where?: GoldPriceQuoteWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of GoldPriceQuotes to fetch. */ orderBy?: GoldPriceQuoteOrderByWithRelationInput | GoldPriceQuoteOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing GoldPriceQuotes. */ cursor?: GoldPriceQuoteWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` GoldPriceQuotes from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` GoldPriceQuotes. */ skip?: number distinct?: GoldPriceQuoteScalarFieldEnum | GoldPriceQuoteScalarFieldEnum[] } /** * GoldPriceQuote create */ export type GoldPriceQuoteCreateArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * The data needed to create a GoldPriceQuote. */ data: XOR } /** * GoldPriceQuote createMany */ export type GoldPriceQuoteCreateManyArgs = { /** * The data used to create many GoldPriceQuotes. */ data: GoldPriceQuoteCreateManyInput | GoldPriceQuoteCreateManyInput[] skipDuplicates?: boolean } /** * GoldPriceQuote createManyAndReturn */ export type GoldPriceQuoteCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelectCreateManyAndReturn | null /** * The data used to create many GoldPriceQuotes. */ data: GoldPriceQuoteCreateManyInput | GoldPriceQuoteCreateManyInput[] skipDuplicates?: boolean } /** * GoldPriceQuote update */ export type GoldPriceQuoteUpdateArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * The data needed to update a GoldPriceQuote. */ data: XOR /** * Choose, which GoldPriceQuote to update. */ where: GoldPriceQuoteWhereUniqueInput } /** * GoldPriceQuote updateMany */ export type GoldPriceQuoteUpdateManyArgs = { /** * The data used to update GoldPriceQuotes. */ data: XOR /** * Filter which GoldPriceQuotes to update */ where?: GoldPriceQuoteWhereInput } /** * GoldPriceQuote upsert */ export type GoldPriceQuoteUpsertArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * The filter to search for the GoldPriceQuote to update in case it exists. */ where: GoldPriceQuoteWhereUniqueInput /** * In case the GoldPriceQuote found by the `where` argument doesn't exist, create a new GoldPriceQuote with this data. */ create: XOR /** * In case the GoldPriceQuote was found with the provided `where` argument, update it with this data. */ update: XOR } /** * GoldPriceQuote delete */ export type GoldPriceQuoteDeleteArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null /** * Filter which GoldPriceQuote to delete. */ where: GoldPriceQuoteWhereUniqueInput } /** * GoldPriceQuote deleteMany */ export type GoldPriceQuoteDeleteManyArgs = { /** * Filter which GoldPriceQuotes to delete */ where?: GoldPriceQuoteWhereInput } /** * GoldPriceQuote without action */ export type GoldPriceQuoteDefaultArgs = { /** * Select specific fields to fetch from the GoldPriceQuote */ select?: GoldPriceQuoteSelect | null } /** * Model WalletBonus */ export type AggregateWalletBonus = { _count: WalletBonusCountAggregateOutputType | null _avg: WalletBonusAvgAggregateOutputType | null _sum: WalletBonusSumAggregateOutputType | null _min: WalletBonusMinAggregateOutputType | null _max: WalletBonusMaxAggregateOutputType | null } export type WalletBonusAvgAggregateOutputType = { goldGrams: Decimal | null } export type WalletBonusSumAggregateOutputType = { goldGrams: Decimal | null } export type WalletBonusMinAggregateOutputType = { id: string | null customerId: string | null orderId: string | null goldGrams: Decimal | null grantedAt: Date | null expiresAt: Date | null consumedAt: Date | null isActive: boolean | null } export type WalletBonusMaxAggregateOutputType = { id: string | null customerId: string | null orderId: string | null goldGrams: Decimal | null grantedAt: Date | null expiresAt: Date | null consumedAt: Date | null isActive: boolean | null } export type WalletBonusCountAggregateOutputType = { id: number customerId: number orderId: number goldGrams: number grantedAt: number expiresAt: number consumedAt: number isActive: number _all: number } export type WalletBonusAvgAggregateInputType = { goldGrams?: true } export type WalletBonusSumAggregateInputType = { goldGrams?: true } export type WalletBonusMinAggregateInputType = { id?: true customerId?: true orderId?: true goldGrams?: true grantedAt?: true expiresAt?: true consumedAt?: true isActive?: true } export type WalletBonusMaxAggregateInputType = { id?: true customerId?: true orderId?: true goldGrams?: true grantedAt?: true expiresAt?: true consumedAt?: true isActive?: true } export type WalletBonusCountAggregateInputType = { id?: true customerId?: true orderId?: true goldGrams?: true grantedAt?: true expiresAt?: true consumedAt?: true isActive?: true _all?: true } export type WalletBonusAggregateArgs = { /** * Filter which WalletBonus to aggregate. */ where?: WalletBonusWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of WalletBonuses to fetch. */ orderBy?: WalletBonusOrderByWithRelationInput | WalletBonusOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the start position */ cursor?: WalletBonusWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` WalletBonuses from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` WalletBonuses. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Count returned WalletBonuses **/ _count?: true | WalletBonusCountAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to average **/ _avg?: WalletBonusAvgAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to sum **/ _sum?: WalletBonusSumAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the minimum value **/ _min?: WalletBonusMinAggregateInputType /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs} * * Select which fields to find the maximum value **/ _max?: WalletBonusMaxAggregateInputType } export type GetWalletBonusAggregateType = { [P in keyof T & keyof AggregateWalletBonus]: P extends '_count' | 'count' ? T[P] extends true ? number : GetScalarType : GetScalarType } export type WalletBonusGroupByArgs = { where?: WalletBonusWhereInput orderBy?: WalletBonusOrderByWithAggregationInput | WalletBonusOrderByWithAggregationInput[] by: WalletBonusScalarFieldEnum[] | WalletBonusScalarFieldEnum having?: WalletBonusScalarWhereWithAggregatesInput take?: number skip?: number _count?: WalletBonusCountAggregateInputType | true _avg?: WalletBonusAvgAggregateInputType _sum?: WalletBonusSumAggregateInputType _min?: WalletBonusMinAggregateInputType _max?: WalletBonusMaxAggregateInputType } export type WalletBonusGroupByOutputType = { id: string customerId: string orderId: string | null goldGrams: Decimal grantedAt: Date expiresAt: Date consumedAt: Date | null isActive: boolean _count: WalletBonusCountAggregateOutputType | null _avg: WalletBonusAvgAggregateOutputType | null _sum: WalletBonusSumAggregateOutputType | null _min: WalletBonusMinAggregateOutputType | null _max: WalletBonusMaxAggregateOutputType | null } type GetWalletBonusGroupByPayload = Prisma.PrismaPromise< Array< PickEnumerable & { [P in ((keyof T) & (keyof WalletBonusGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : GetScalarType : GetScalarType } > > export type WalletBonusSelect = $Extensions.GetSelect<{ id?: boolean customerId?: boolean orderId?: boolean goldGrams?: boolean grantedAt?: boolean expiresAt?: boolean consumedAt?: boolean isActive?: boolean customer?: boolean | CustomerDefaultArgs }, ExtArgs["result"]["walletBonus"]> export type WalletBonusSelectCreateManyAndReturn = $Extensions.GetSelect<{ id?: boolean customerId?: boolean orderId?: boolean goldGrams?: boolean grantedAt?: boolean expiresAt?: boolean consumedAt?: boolean isActive?: boolean customer?: boolean | CustomerDefaultArgs }, ExtArgs["result"]["walletBonus"]> export type WalletBonusSelectScalar = { id?: boolean customerId?: boolean orderId?: boolean goldGrams?: boolean grantedAt?: boolean expiresAt?: boolean consumedAt?: boolean isActive?: boolean } export type WalletBonusInclude = { customer?: boolean | CustomerDefaultArgs } export type WalletBonusIncludeCreateManyAndReturn = { customer?: boolean | CustomerDefaultArgs } export type $WalletBonusPayload = { name: "WalletBonus" objects: { customer: Prisma.$CustomerPayload } scalars: $Extensions.GetPayloadResult<{ id: string customerId: string orderId: string | null goldGrams: Prisma.Decimal grantedAt: Date expiresAt: Date consumedAt: Date | null isActive: boolean }, ExtArgs["result"]["walletBonus"]> composites: {} } type WalletBonusGetPayload = $Result.GetResult type WalletBonusCountArgs = Omit & { select?: WalletBonusCountAggregateInputType | true } export interface WalletBonusDelegate { [K: symbol]: { types: Prisma.TypeMap['model']['WalletBonus'], meta: { name: 'WalletBonus' } } /** * Find zero or one WalletBonus that matches the filter. * @param {WalletBonusFindUniqueArgs} args - Arguments to find a WalletBonus * @example * // Get one WalletBonus * const walletBonus = await prisma.walletBonus.findUnique({ * where: { * // ... provide filter here * } * }) */ findUnique(args: SelectSubset>): Prisma__WalletBonusClient<$Result.GetResult, T, "findUnique"> | null, null, ExtArgs> /** * Find one WalletBonus that matches the filter or throw an error with `error.code='P2025'` * if no matches were found. * @param {WalletBonusFindUniqueOrThrowArgs} args - Arguments to find a WalletBonus * @example * // Get one WalletBonus * const walletBonus = await prisma.walletBonus.findUniqueOrThrow({ * where: { * // ... provide filter here * } * }) */ findUniqueOrThrow(args: SelectSubset>): Prisma__WalletBonusClient<$Result.GetResult, T, "findUniqueOrThrow">, never, ExtArgs> /** * Find the first WalletBonus that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WalletBonusFindFirstArgs} args - Arguments to find a WalletBonus * @example * // Get one WalletBonus * const walletBonus = await prisma.walletBonus.findFirst({ * where: { * // ... provide filter here * } * }) */ findFirst(args?: SelectSubset>): Prisma__WalletBonusClient<$Result.GetResult, T, "findFirst"> | null, null, ExtArgs> /** * Find the first WalletBonus that matches the filter or * throw `PrismaKnownClientError` with `P2025` code if no matches were found. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WalletBonusFindFirstOrThrowArgs} args - Arguments to find a WalletBonus * @example * // Get one WalletBonus * const walletBonus = await prisma.walletBonus.findFirstOrThrow({ * where: { * // ... provide filter here * } * }) */ findFirstOrThrow(args?: SelectSubset>): Prisma__WalletBonusClient<$Result.GetResult, T, "findFirstOrThrow">, never, ExtArgs> /** * Find zero or more WalletBonuses that matches the filter. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WalletBonusFindManyArgs} args - Arguments to filter and select certain fields only. * @example * // Get all WalletBonuses * const walletBonuses = await prisma.walletBonus.findMany() * * // Get first 10 WalletBonuses * const walletBonuses = await prisma.walletBonus.findMany({ take: 10 }) * * // Only select the `id` * const walletBonusWithIdOnly = await prisma.walletBonus.findMany({ select: { id: true } }) * */ findMany(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "findMany">> /** * Create a WalletBonus. * @param {WalletBonusCreateArgs} args - Arguments to create a WalletBonus. * @example * // Create one WalletBonus * const WalletBonus = await prisma.walletBonus.create({ * data: { * // ... data to create a WalletBonus * } * }) * */ create(args: SelectSubset>): Prisma__WalletBonusClient<$Result.GetResult, T, "create">, never, ExtArgs> /** * Create many WalletBonuses. * @param {WalletBonusCreateManyArgs} args - Arguments to create many WalletBonuses. * @example * // Create many WalletBonuses * const walletBonus = await prisma.walletBonus.createMany({ * data: [ * // ... provide data here * ] * }) * */ createMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Create many WalletBonuses and returns the data saved in the database. * @param {WalletBonusCreateManyAndReturnArgs} args - Arguments to create many WalletBonuses. * @example * // Create many WalletBonuses * const walletBonus = await prisma.walletBonus.createManyAndReturn({ * data: [ * // ... provide data here * ] * }) * * // Create many WalletBonuses and only return the `id` * const walletBonusWithIdOnly = await prisma.walletBonus.createManyAndReturn({ * select: { id: true }, * data: [ * // ... provide data here * ] * }) * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * */ createManyAndReturn(args?: SelectSubset>): Prisma.PrismaPromise<$Result.GetResult, T, "createManyAndReturn">> /** * Delete a WalletBonus. * @param {WalletBonusDeleteArgs} args - Arguments to delete one WalletBonus. * @example * // Delete one WalletBonus * const WalletBonus = await prisma.walletBonus.delete({ * where: { * // ... filter to delete one WalletBonus * } * }) * */ delete(args: SelectSubset>): Prisma__WalletBonusClient<$Result.GetResult, T, "delete">, never, ExtArgs> /** * Update one WalletBonus. * @param {WalletBonusUpdateArgs} args - Arguments to update one WalletBonus. * @example * // Update one WalletBonus * const walletBonus = await prisma.walletBonus.update({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ update(args: SelectSubset>): Prisma__WalletBonusClient<$Result.GetResult, T, "update">, never, ExtArgs> /** * Delete zero or more WalletBonuses. * @param {WalletBonusDeleteManyArgs} args - Arguments to filter WalletBonuses to delete. * @example * // Delete a few WalletBonuses * const { count } = await prisma.walletBonus.deleteMany({ * where: { * // ... provide filter here * } * }) * */ deleteMany(args?: SelectSubset>): Prisma.PrismaPromise /** * Update zero or more WalletBonuses. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WalletBonusUpdateManyArgs} args - Arguments to update one or more rows. * @example * // Update many WalletBonuses * const walletBonus = await prisma.walletBonus.updateMany({ * where: { * // ... provide filter here * }, * data: { * // ... provide data here * } * }) * */ updateMany(args: SelectSubset>): Prisma.PrismaPromise /** * Create or update one WalletBonus. * @param {WalletBonusUpsertArgs} args - Arguments to update or create a WalletBonus. * @example * // Update or create a WalletBonus * const walletBonus = await prisma.walletBonus.upsert({ * create: { * // ... data to create a WalletBonus * }, * update: { * // ... in case it already exists, update * }, * where: { * // ... the filter for the WalletBonus we want to update * } * }) */ upsert(args: SelectSubset>): Prisma__WalletBonusClient<$Result.GetResult, T, "upsert">, never, ExtArgs> /** * Count the number of WalletBonuses. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WalletBonusCountArgs} args - Arguments to filter WalletBonuses to count. * @example * // Count the number of WalletBonuses * const count = await prisma.walletBonus.count({ * where: { * // ... the filter for the WalletBonuses we want to count * } * }) **/ count( args?: Subset, ): Prisma.PrismaPromise< T extends $Utils.Record<'select', any> ? T['select'] extends true ? number : GetScalarType : number > /** * Allows you to perform aggregations operations on a WalletBonus. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WalletBonusAggregateArgs} args - Select which aggregations you would like to apply and on what fields. * @example * // Ordered by age ascending * // Where email contains prisma.io * // Limited to the 10 users * const aggregations = await prisma.user.aggregate({ * _avg: { * age: true, * }, * where: { * email: { * contains: "prisma.io", * }, * }, * orderBy: { * age: "asc", * }, * take: 10, * }) **/ aggregate(args: Subset): Prisma.PrismaPromise> /** * Group by WalletBonus. * Note, that providing `undefined` is treated as the value not being there. * Read more here: https://pris.ly/d/null-undefined * @param {WalletBonusGroupByArgs} args - Group by arguments. * @example * // Group by city, order by createdAt, get count * const result = await prisma.user.groupBy({ * by: ['city', 'createdAt'], * orderBy: { * createdAt: true * }, * _count: { * _all: true * }, * }) * **/ groupBy< T extends WalletBonusGroupByArgs, HasSelectOrTake extends Or< Extends<'skip', Keys>, Extends<'take', Keys> >, OrderByArg extends True extends HasSelectOrTake ? { orderBy: WalletBonusGroupByArgs['orderBy'] } : { orderBy?: WalletBonusGroupByArgs['orderBy'] }, OrderFields extends ExcludeUnderscoreKeys>>, ByFields extends MaybeTupleToUnion, ByValid extends Has, HavingFields extends GetHavingFields, HavingValid extends Has, ByEmpty extends T['by'] extends never[] ? True : False, InputErrors extends ByEmpty extends True ? `Error: "by" must not be empty.` : HavingValid extends False ? { [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [ Error, 'Field ', P, ` in "having" needs to be provided in "by"`, ] }[HavingFields] : 'take' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Keys ? 'orderBy' extends Keys ? ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends True ? {} : { [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"` }[OrderFields] >(args: SubsetIntersection & InputErrors): {} extends InputErrors ? GetWalletBonusGroupByPayload : Prisma.PrismaPromise /** * Fields of the WalletBonus model */ readonly fields: WalletBonusFieldRefs; } /** * The delegate class that acts as a "Promise-like" for WalletBonus. * Why is this prefixed with `Prisma__`? * Because we want to prevent naming conflicts as mentioned in * https://github.com/prisma/prisma-client-js/issues/707 */ export interface Prisma__WalletBonusClient extends Prisma.PrismaPromise { readonly [Symbol.toStringTag]: "PrismaPromise" customer = {}>(args?: Subset>): Prisma__CustomerClient<$Result.GetResult, T, "findUniqueOrThrow"> | Null, Null, ExtArgs> /** * Attaches callbacks for the resolution and/or rejection of the Promise. * @param onfulfilled The callback to execute when the Promise is resolved. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of which ever callback is executed. */ then(onfulfilled?: ((value: T) => TResult1 | PromiseLike) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback for only the rejection of the Promise. * @param onrejected The callback to execute when the Promise is rejected. * @returns A Promise for the completion of the callback. */ catch(onrejected?: ((reason: any) => TResult | PromiseLike) | undefined | null): $Utils.JsPromise /** * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The * resolved value cannot be modified from the callback. * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected). * @returns A Promise for the completion of the callback. */ finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise } /** * Fields of the WalletBonus model */ interface WalletBonusFieldRefs { readonly id: FieldRef<"WalletBonus", 'String'> readonly customerId: FieldRef<"WalletBonus", 'String'> readonly orderId: FieldRef<"WalletBonus", 'String'> readonly goldGrams: FieldRef<"WalletBonus", 'Decimal'> readonly grantedAt: FieldRef<"WalletBonus", 'DateTime'> readonly expiresAt: FieldRef<"WalletBonus", 'DateTime'> readonly consumedAt: FieldRef<"WalletBonus", 'DateTime'> readonly isActive: FieldRef<"WalletBonus", 'Boolean'> } // Custom InputTypes /** * WalletBonus findUnique */ export type WalletBonusFindUniqueArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * Filter, which WalletBonus to fetch. */ where: WalletBonusWhereUniqueInput } /** * WalletBonus findUniqueOrThrow */ export type WalletBonusFindUniqueOrThrowArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * Filter, which WalletBonus to fetch. */ where: WalletBonusWhereUniqueInput } /** * WalletBonus findFirst */ export type WalletBonusFindFirstArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * Filter, which WalletBonus to fetch. */ where?: WalletBonusWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of WalletBonuses to fetch. */ orderBy?: WalletBonusOrderByWithRelationInput | WalletBonusOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for WalletBonuses. */ cursor?: WalletBonusWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` WalletBonuses from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` WalletBonuses. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of WalletBonuses. */ distinct?: WalletBonusScalarFieldEnum | WalletBonusScalarFieldEnum[] } /** * WalletBonus findFirstOrThrow */ export type WalletBonusFindFirstOrThrowArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * Filter, which WalletBonus to fetch. */ where?: WalletBonusWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of WalletBonuses to fetch. */ orderBy?: WalletBonusOrderByWithRelationInput | WalletBonusOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for searching for WalletBonuses. */ cursor?: WalletBonusWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` WalletBonuses from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` WalletBonuses. */ skip?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs} * * Filter by unique combinations of WalletBonuses. */ distinct?: WalletBonusScalarFieldEnum | WalletBonusScalarFieldEnum[] } /** * WalletBonus findMany */ export type WalletBonusFindManyArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * Filter, which WalletBonuses to fetch. */ where?: WalletBonusWhereInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs} * * Determine the order of WalletBonuses to fetch. */ orderBy?: WalletBonusOrderByWithRelationInput | WalletBonusOrderByWithRelationInput[] /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs} * * Sets the position for listing WalletBonuses. */ cursor?: WalletBonusWhereUniqueInput /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Take `±n` WalletBonuses from the position of the cursor. */ take?: number /** * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs} * * Skip the first `n` WalletBonuses. */ skip?: number distinct?: WalletBonusScalarFieldEnum | WalletBonusScalarFieldEnum[] } /** * WalletBonus create */ export type WalletBonusCreateArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * The data needed to create a WalletBonus. */ data: XOR } /** * WalletBonus createMany */ export type WalletBonusCreateManyArgs = { /** * The data used to create many WalletBonuses. */ data: WalletBonusCreateManyInput | WalletBonusCreateManyInput[] skipDuplicates?: boolean } /** * WalletBonus createManyAndReturn */ export type WalletBonusCreateManyAndReturnArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelectCreateManyAndReturn | null /** * The data used to create many WalletBonuses. */ data: WalletBonusCreateManyInput | WalletBonusCreateManyInput[] skipDuplicates?: boolean /** * Choose, which related nodes to fetch as well */ include?: WalletBonusIncludeCreateManyAndReturn | null } /** * WalletBonus update */ export type WalletBonusUpdateArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * The data needed to update a WalletBonus. */ data: XOR /** * Choose, which WalletBonus to update. */ where: WalletBonusWhereUniqueInput } /** * WalletBonus updateMany */ export type WalletBonusUpdateManyArgs = { /** * The data used to update WalletBonuses. */ data: XOR /** * Filter which WalletBonuses to update */ where?: WalletBonusWhereInput } /** * WalletBonus upsert */ export type WalletBonusUpsertArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * The filter to search for the WalletBonus to update in case it exists. */ where: WalletBonusWhereUniqueInput /** * In case the WalletBonus found by the `where` argument doesn't exist, create a new WalletBonus with this data. */ create: XOR /** * In case the WalletBonus was found with the provided `where` argument, update it with this data. */ update: XOR } /** * WalletBonus delete */ export type WalletBonusDeleteArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null /** * Filter which WalletBonus to delete. */ where: WalletBonusWhereUniqueInput } /** * WalletBonus deleteMany */ export type WalletBonusDeleteManyArgs = { /** * Filter which WalletBonuses to delete */ where?: WalletBonusWhereInput } /** * WalletBonus without action */ export type WalletBonusDefaultArgs = { /** * Select specific fields to fetch from the WalletBonus */ select?: WalletBonusSelect | null /** * Choose, which related nodes to fetch as well */ include?: WalletBonusInclude | null } /** * Enums */ export const TransactionIsolationLevel: { ReadUncommitted: 'ReadUncommitted', ReadCommitted: 'ReadCommitted', RepeatableRead: 'RepeatableRead', Serializable: 'Serializable' }; export type TransactionIsolationLevel = (typeof TransactionIsolationLevel)[keyof typeof TransactionIsolationLevel] export const CityScalarFieldEnum: { id: 'id', name: 'name', province: 'province' }; export type CityScalarFieldEnum = (typeof CityScalarFieldEnum)[keyof typeof CityScalarFieldEnum] export const AdminUserScalarFieldEnum: { id: 'id', fullName: 'fullName', mobile: 'mobile', passwordHash: 'passwordHash', role: 'role', branchId: 'branchId', wagePercent: 'wagePercent', isActive: 'isActive', createdAt: 'createdAt' }; export type AdminUserScalarFieldEnum = (typeof AdminUserScalarFieldEnum)[keyof typeof AdminUserScalarFieldEnum] export const CustomerScalarFieldEnum: { id: 'id', fullName: 'fullName', mobile: 'mobile', nationalCode: 'nationalCode', passwordHash: 'passwordHash', cityId: 'cityId', referredByAgentId: 'referredByAgentId', goldCreditLimitGrams: 'goldCreditLimitGrams', goldDebtGrams: 'goldDebtGrams', fiatDebtRial: 'fiatDebtRial', verificationStep: 'verificationStep', nationalIdImageUrl: 'nationalIdImageUrl', businessLicenseUrl: 'businessLicenseUrl', shopImageUrl: 'shopImageUrl', isActive: 'isActive', createdAt: 'createdAt', updatedAt: 'updatedAt' }; export type CustomerScalarFieldEnum = (typeof CustomerScalarFieldEnum)[keyof typeof CustomerScalarFieldEnum] export const CustomerAddressScalarFieldEnum: { id: 'id', customerId: 'customerId', cityId: 'cityId', addressLine: 'addressLine', isDefault: 'isDefault' }; export type CustomerAddressScalarFieldEnum = (typeof CustomerAddressScalarFieldEnum)[keyof typeof CustomerAddressScalarFieldEnum] export const BranchScalarFieldEnum: { id: 'id', name: 'name', cityId: 'cityId' }; export type BranchScalarFieldEnum = (typeof BranchScalarFieldEnum)[keyof typeof BranchScalarFieldEnum] export const WorkshopScalarFieldEnum: { id: 'id', name: 'name', isActive: 'isActive' }; export type WorkshopScalarFieldEnum = (typeof WorkshopScalarFieldEnum)[keyof typeof WorkshopScalarFieldEnum] export const CategoryScalarFieldEnum: { id: 'id', title: 'title', parentId: 'parentId' }; export type CategoryScalarFieldEnum = (typeof CategoryScalarFieldEnum)[keyof typeof CategoryScalarFieldEnum] export const BrandScalarFieldEnum: { id: 'id', title: 'title' }; export type BrandScalarFieldEnum = (typeof BrandScalarFieldEnum)[keyof typeof BrandScalarFieldEnum] export const CollectionScalarFieldEnum: { id: 'id', title: 'title', description: 'description', isActive: 'isActive' }; export type CollectionScalarFieldEnum = (typeof CollectionScalarFieldEnum)[keyof typeof CollectionScalarFieldEnum] export const CollectionProductScalarFieldEnum: { collectionId: 'collectionId', productId: 'productId' }; export type CollectionProductScalarFieldEnum = (typeof CollectionProductScalarFieldEnum)[keyof typeof CollectionProductScalarFieldEnum] export const ProductScalarFieldEnum: { id: 'id', title: 'title', description: 'description', categoryId: 'categoryId', brandId: 'brandId', isActive: 'isActive', createdAt: 'createdAt' }; export type ProductScalarFieldEnum = (typeof ProductScalarFieldEnum)[keyof typeof ProductScalarFieldEnum] export const ProductImageScalarFieldEnum: { id: 'id', productId: 'productId', url: 'url', sortOrder: 'sortOrder' }; export type ProductImageScalarFieldEnum = (typeof ProductImageScalarFieldEnum)[keyof typeof ProductImageScalarFieldEnum] export const ProductVariantScalarFieldEnum: { id: 'id', productId: 'productId', title: 'title', sku: 'sku', rashWeightGrams: 'rashWeightGrams', defaultWagePercent: 'defaultWagePercent', isActive: 'isActive' }; export type ProductVariantScalarFieldEnum = (typeof ProductVariantScalarFieldEnum)[keyof typeof ProductVariantScalarFieldEnum] export const OrderScalarFieldEnum: { id: 'id', orderNumber: 'orderNumber', customerId: 'customerId', branchId: 'branchId', status: 'status', totalGoldWeightGrams: 'totalGoldWeightGrams', wageWeightGrams: 'wageWeightGrams', flatRialCharge: 'flatRialCharge', isSuspendedOverCreditLimit: 'isSuspendedOverCreditLimit', deliveredAt: 'deliveredAt', createdAt: 'createdAt', updatedAt: 'updatedAt' }; export type OrderScalarFieldEnum = (typeof OrderScalarFieldEnum)[keyof typeof OrderScalarFieldEnum] export const OrderItemScalarFieldEnum: { id: 'id', orderId: 'orderId', productVariantId: 'productVariantId', quantity: 'quantity', rashWeightGramsSnapshot: 'rashWeightGramsSnapshot', wagePercentSnapshot: 'wagePercentSnapshot', discountPercentSnapshot: 'discountPercentSnapshot', computedWeightGrams: 'computedWeightGrams', flatRialCharge: 'flatRialCharge' }; export type OrderItemScalarFieldEnum = (typeof OrderItemScalarFieldEnum)[keyof typeof OrderItemScalarFieldEnum] export const OrderStatusEventScalarFieldEnum: { id: 'id', orderId: 'orderId', fromStatus: 'fromStatus', toStatus: 'toStatus', note: 'note', actorAdminUserId: 'actorAdminUserId', createdAt: 'createdAt' }; export type OrderStatusEventScalarFieldEnum = (typeof OrderStatusEventScalarFieldEnum)[keyof typeof OrderStatusEventScalarFieldEnum] export const PreOrderScalarFieldEnum: { id: 'id', customerId: 'customerId', cityId: 'cityId', workshopId: 'workshopId', status: 'status', designImageUrl: 'designImageUrl', colorName: 'colorName', sizeSpec: 'sizeSpec', stoneColor: 'stoneColor', minaColor: 'minaColor', estimatedWeightGrams: 'estimatedWeightGrams', estimatedPriceRial: 'estimatedPriceRial', description: 'description', convertedOrderId: 'convertedOrderId', createdAt: 'createdAt', updatedAt: 'updatedAt' }; export type PreOrderScalarFieldEnum = (typeof PreOrderScalarFieldEnum)[keyof typeof PreOrderScalarFieldEnum] export const PreOrderStatusEventScalarFieldEnum: { id: 'id', preOrderId: 'preOrderId', changes: 'changes', actorAdminUserId: 'actorAdminUserId', ipAddress: 'ipAddress', createdAt: 'createdAt' }; export type PreOrderStatusEventScalarFieldEnum = (typeof PreOrderStatusEventScalarFieldEnum)[keyof typeof PreOrderStatusEventScalarFieldEnum] export const LedgerEntryScalarFieldEnum: { id: 'id', customerId: 'customerId', currency: 'currency', direction: 'direction', sourceType: 'sourceType', amount: 'amount', karatPerMille: 'karatPerMille', pricePerGramRialAtEntry: 'pricePerGramRialAtEntry', orderId: 'orderId', confirmed: 'confirmed', confirmedAt: 'confirmedAt', postedByAdminUserId: 'postedByAdminUserId', note: 'note', createdAt: 'createdAt' }; export type LedgerEntryScalarFieldEnum = (typeof LedgerEntryScalarFieldEnum)[keyof typeof LedgerEntryScalarFieldEnum] export const GoldPriceQuoteScalarFieldEnum: { id: 'id', karatPerMille: 'karatPerMille', pricePerGramRial: 'pricePerGramRial', source: 'source', quotedAt: 'quotedAt' }; export type GoldPriceQuoteScalarFieldEnum = (typeof GoldPriceQuoteScalarFieldEnum)[keyof typeof GoldPriceQuoteScalarFieldEnum] export const WalletBonusScalarFieldEnum: { id: 'id', customerId: 'customerId', orderId: 'orderId', goldGrams: 'goldGrams', grantedAt: 'grantedAt', expiresAt: 'expiresAt', consumedAt: 'consumedAt', isActive: 'isActive' }; export type WalletBonusScalarFieldEnum = (typeof WalletBonusScalarFieldEnum)[keyof typeof WalletBonusScalarFieldEnum] export const SortOrder: { asc: 'asc', desc: 'desc' }; export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder] export const JsonNullValueInput: { JsonNull: typeof JsonNull }; export type JsonNullValueInput = (typeof JsonNullValueInput)[keyof typeof JsonNullValueInput] export const QueryMode: { default: 'default', insensitive: 'insensitive' }; export type QueryMode = (typeof QueryMode)[keyof typeof QueryMode] export const NullsOrder: { first: 'first', last: 'last' }; export type NullsOrder = (typeof NullsOrder)[keyof typeof NullsOrder] export const JsonNullValueFilter: { DbNull: typeof DbNull, JsonNull: typeof JsonNull, AnyNull: typeof AnyNull }; export type JsonNullValueFilter = (typeof JsonNullValueFilter)[keyof typeof JsonNullValueFilter] /** * Field references */ /** * Reference to a field of type 'String' */ export type StringFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'String'> /** * Reference to a field of type 'String[]' */ export type ListStringFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'String[]'> /** * Reference to a field of type 'AdminRole' */ export type EnumAdminRoleFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'AdminRole'> /** * Reference to a field of type 'AdminRole[]' */ export type ListEnumAdminRoleFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'AdminRole[]'> /** * Reference to a field of type 'Decimal' */ export type DecimalFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Decimal'> /** * Reference to a field of type 'Decimal[]' */ export type ListDecimalFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Decimal[]'> /** * Reference to a field of type 'Boolean' */ export type BooleanFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Boolean'> /** * Reference to a field of type 'DateTime' */ export type DateTimeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'DateTime'> /** * Reference to a field of type 'DateTime[]' */ export type ListDateTimeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'DateTime[]'> /** * Reference to a field of type 'VerificationStep' */ export type EnumVerificationStepFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'VerificationStep'> /** * Reference to a field of type 'VerificationStep[]' */ export type ListEnumVerificationStepFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'VerificationStep[]'> /** * Reference to a field of type 'Int' */ export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'> /** * Reference to a field of type 'Int[]' */ export type ListIntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int[]'> /** * Reference to a field of type 'OrderStatus' */ export type EnumOrderStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'OrderStatus'> /** * Reference to a field of type 'OrderStatus[]' */ export type ListEnumOrderStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'OrderStatus[]'> /** * Reference to a field of type 'PreOrderStatus' */ export type EnumPreOrderStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'PreOrderStatus'> /** * Reference to a field of type 'PreOrderStatus[]' */ export type ListEnumPreOrderStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'PreOrderStatus[]'> /** * Reference to a field of type 'Json' */ export type JsonFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Json'> /** * Reference to a field of type 'LedgerCurrency' */ export type EnumLedgerCurrencyFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'LedgerCurrency'> /** * Reference to a field of type 'LedgerCurrency[]' */ export type ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'LedgerCurrency[]'> /** * Reference to a field of type 'LedgerDirection' */ export type EnumLedgerDirectionFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'LedgerDirection'> /** * Reference to a field of type 'LedgerDirection[]' */ export type ListEnumLedgerDirectionFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'LedgerDirection[]'> /** * Reference to a field of type 'LedgerSourceType' */ export type EnumLedgerSourceTypeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'LedgerSourceType'> /** * Reference to a field of type 'LedgerSourceType[]' */ export type ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'LedgerSourceType[]'> /** * Reference to a field of type 'Float' */ export type FloatFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Float'> /** * Reference to a field of type 'Float[]' */ export type ListFloatFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Float[]'> /** * Deep Input Types */ export type CityWhereInput = { AND?: CityWhereInput | CityWhereInput[] OR?: CityWhereInput[] NOT?: CityWhereInput | CityWhereInput[] id?: StringFilter<"City"> | string name?: StringFilter<"City"> | string province?: StringNullableFilter<"City"> | string | null customers?: CustomerListRelationFilter addresses?: CustomerAddressListRelationFilter branches?: BranchListRelationFilter preOrders?: PreOrderListRelationFilter } export type CityOrderByWithRelationInput = { id?: SortOrder name?: SortOrder province?: SortOrderInput | SortOrder customers?: CustomerOrderByRelationAggregateInput addresses?: CustomerAddressOrderByRelationAggregateInput branches?: BranchOrderByRelationAggregateInput preOrders?: PreOrderOrderByRelationAggregateInput } export type CityWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: CityWhereInput | CityWhereInput[] OR?: CityWhereInput[] NOT?: CityWhereInput | CityWhereInput[] name?: StringFilter<"City"> | string province?: StringNullableFilter<"City"> | string | null customers?: CustomerListRelationFilter addresses?: CustomerAddressListRelationFilter branches?: BranchListRelationFilter preOrders?: PreOrderListRelationFilter }, "id"> export type CityOrderByWithAggregationInput = { id?: SortOrder name?: SortOrder province?: SortOrderInput | SortOrder _count?: CityCountOrderByAggregateInput _max?: CityMaxOrderByAggregateInput _min?: CityMinOrderByAggregateInput } export type CityScalarWhereWithAggregatesInput = { AND?: CityScalarWhereWithAggregatesInput | CityScalarWhereWithAggregatesInput[] OR?: CityScalarWhereWithAggregatesInput[] NOT?: CityScalarWhereWithAggregatesInput | CityScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"City"> | string name?: StringWithAggregatesFilter<"City"> | string province?: StringNullableWithAggregatesFilter<"City"> | string | null } export type AdminUserWhereInput = { AND?: AdminUserWhereInput | AdminUserWhereInput[] OR?: AdminUserWhereInput[] NOT?: AdminUserWhereInput | AdminUserWhereInput[] id?: StringFilter<"AdminUser"> | string fullName?: StringFilter<"AdminUser"> | string mobile?: StringFilter<"AdminUser"> | string passwordHash?: StringFilter<"AdminUser"> | string role?: EnumAdminRoleFilter<"AdminUser"> | $Enums.AdminRole branchId?: StringNullableFilter<"AdminUser"> | string | null wagePercent?: DecimalNullableFilter<"AdminUser"> | Decimal | DecimalJsLike | number | string | null isActive?: BoolFilter<"AdminUser"> | boolean createdAt?: DateTimeFilter<"AdminUser"> | Date | string branch?: XOR | null referredCustomers?: CustomerListRelationFilter postedLedgerEntries?: LedgerEntryListRelationFilter orderStatusEvents?: OrderStatusEventListRelationFilter preOrderStatusEvents?: PreOrderStatusEventListRelationFilter } export type AdminUserOrderByWithRelationInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder passwordHash?: SortOrder role?: SortOrder branchId?: SortOrderInput | SortOrder wagePercent?: SortOrderInput | SortOrder isActive?: SortOrder createdAt?: SortOrder branch?: BranchOrderByWithRelationInput referredCustomers?: CustomerOrderByRelationAggregateInput postedLedgerEntries?: LedgerEntryOrderByRelationAggregateInput orderStatusEvents?: OrderStatusEventOrderByRelationAggregateInput preOrderStatusEvents?: PreOrderStatusEventOrderByRelationAggregateInput } export type AdminUserWhereUniqueInput = Prisma.AtLeast<{ id?: string mobile?: string AND?: AdminUserWhereInput | AdminUserWhereInput[] OR?: AdminUserWhereInput[] NOT?: AdminUserWhereInput | AdminUserWhereInput[] fullName?: StringFilter<"AdminUser"> | string passwordHash?: StringFilter<"AdminUser"> | string role?: EnumAdminRoleFilter<"AdminUser"> | $Enums.AdminRole branchId?: StringNullableFilter<"AdminUser"> | string | null wagePercent?: DecimalNullableFilter<"AdminUser"> | Decimal | DecimalJsLike | number | string | null isActive?: BoolFilter<"AdminUser"> | boolean createdAt?: DateTimeFilter<"AdminUser"> | Date | string branch?: XOR | null referredCustomers?: CustomerListRelationFilter postedLedgerEntries?: LedgerEntryListRelationFilter orderStatusEvents?: OrderStatusEventListRelationFilter preOrderStatusEvents?: PreOrderStatusEventListRelationFilter }, "id" | "mobile"> export type AdminUserOrderByWithAggregationInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder passwordHash?: SortOrder role?: SortOrder branchId?: SortOrderInput | SortOrder wagePercent?: SortOrderInput | SortOrder isActive?: SortOrder createdAt?: SortOrder _count?: AdminUserCountOrderByAggregateInput _avg?: AdminUserAvgOrderByAggregateInput _max?: AdminUserMaxOrderByAggregateInput _min?: AdminUserMinOrderByAggregateInput _sum?: AdminUserSumOrderByAggregateInput } export type AdminUserScalarWhereWithAggregatesInput = { AND?: AdminUserScalarWhereWithAggregatesInput | AdminUserScalarWhereWithAggregatesInput[] OR?: AdminUserScalarWhereWithAggregatesInput[] NOT?: AdminUserScalarWhereWithAggregatesInput | AdminUserScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"AdminUser"> | string fullName?: StringWithAggregatesFilter<"AdminUser"> | string mobile?: StringWithAggregatesFilter<"AdminUser"> | string passwordHash?: StringWithAggregatesFilter<"AdminUser"> | string role?: EnumAdminRoleWithAggregatesFilter<"AdminUser"> | $Enums.AdminRole branchId?: StringNullableWithAggregatesFilter<"AdminUser"> | string | null wagePercent?: DecimalNullableWithAggregatesFilter<"AdminUser"> | Decimal | DecimalJsLike | number | string | null isActive?: BoolWithAggregatesFilter<"AdminUser"> | boolean createdAt?: DateTimeWithAggregatesFilter<"AdminUser"> | Date | string } export type CustomerWhereInput = { AND?: CustomerWhereInput | CustomerWhereInput[] OR?: CustomerWhereInput[] NOT?: CustomerWhereInput | CustomerWhereInput[] id?: StringFilter<"Customer"> | string fullName?: StringFilter<"Customer"> | string mobile?: StringFilter<"Customer"> | string nationalCode?: StringFilter<"Customer"> | string passwordHash?: StringFilter<"Customer"> | string cityId?: StringNullableFilter<"Customer"> | string | null referredByAgentId?: StringNullableFilter<"Customer"> | string | null goldCreditLimitGrams?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFilter<"Customer"> | $Enums.VerificationStep nationalIdImageUrl?: StringNullableFilter<"Customer"> | string | null businessLicenseUrl?: StringNullableFilter<"Customer"> | string | null shopImageUrl?: StringNullableFilter<"Customer"> | string | null isActive?: BoolFilter<"Customer"> | boolean createdAt?: DateTimeFilter<"Customer"> | Date | string updatedAt?: DateTimeFilter<"Customer"> | Date | string city?: XOR | null referredByAgent?: XOR | null addresses?: CustomerAddressListRelationFilter orders?: OrderListRelationFilter preOrders?: PreOrderListRelationFilter ledgerEntries?: LedgerEntryListRelationFilter walletBonuses?: WalletBonusListRelationFilter } export type CustomerOrderByWithRelationInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder nationalCode?: SortOrder passwordHash?: SortOrder cityId?: SortOrderInput | SortOrder referredByAgentId?: SortOrderInput | SortOrder goldCreditLimitGrams?: SortOrder goldDebtGrams?: SortOrder fiatDebtRial?: SortOrder verificationStep?: SortOrder nationalIdImageUrl?: SortOrderInput | SortOrder businessLicenseUrl?: SortOrderInput | SortOrder shopImageUrl?: SortOrderInput | SortOrder isActive?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder city?: CityOrderByWithRelationInput referredByAgent?: AdminUserOrderByWithRelationInput addresses?: CustomerAddressOrderByRelationAggregateInput orders?: OrderOrderByRelationAggregateInput preOrders?: PreOrderOrderByRelationAggregateInput ledgerEntries?: LedgerEntryOrderByRelationAggregateInput walletBonuses?: WalletBonusOrderByRelationAggregateInput } export type CustomerWhereUniqueInput = Prisma.AtLeast<{ id?: string mobile?: string nationalCode?: string AND?: CustomerWhereInput | CustomerWhereInput[] OR?: CustomerWhereInput[] NOT?: CustomerWhereInput | CustomerWhereInput[] fullName?: StringFilter<"Customer"> | string passwordHash?: StringFilter<"Customer"> | string cityId?: StringNullableFilter<"Customer"> | string | null referredByAgentId?: StringNullableFilter<"Customer"> | string | null goldCreditLimitGrams?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFilter<"Customer"> | $Enums.VerificationStep nationalIdImageUrl?: StringNullableFilter<"Customer"> | string | null businessLicenseUrl?: StringNullableFilter<"Customer"> | string | null shopImageUrl?: StringNullableFilter<"Customer"> | string | null isActive?: BoolFilter<"Customer"> | boolean createdAt?: DateTimeFilter<"Customer"> | Date | string updatedAt?: DateTimeFilter<"Customer"> | Date | string city?: XOR | null referredByAgent?: XOR | null addresses?: CustomerAddressListRelationFilter orders?: OrderListRelationFilter preOrders?: PreOrderListRelationFilter ledgerEntries?: LedgerEntryListRelationFilter walletBonuses?: WalletBonusListRelationFilter }, "id" | "mobile" | "nationalCode"> export type CustomerOrderByWithAggregationInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder nationalCode?: SortOrder passwordHash?: SortOrder cityId?: SortOrderInput | SortOrder referredByAgentId?: SortOrderInput | SortOrder goldCreditLimitGrams?: SortOrder goldDebtGrams?: SortOrder fiatDebtRial?: SortOrder verificationStep?: SortOrder nationalIdImageUrl?: SortOrderInput | SortOrder businessLicenseUrl?: SortOrderInput | SortOrder shopImageUrl?: SortOrderInput | SortOrder isActive?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder _count?: CustomerCountOrderByAggregateInput _avg?: CustomerAvgOrderByAggregateInput _max?: CustomerMaxOrderByAggregateInput _min?: CustomerMinOrderByAggregateInput _sum?: CustomerSumOrderByAggregateInput } export type CustomerScalarWhereWithAggregatesInput = { AND?: CustomerScalarWhereWithAggregatesInput | CustomerScalarWhereWithAggregatesInput[] OR?: CustomerScalarWhereWithAggregatesInput[] NOT?: CustomerScalarWhereWithAggregatesInput | CustomerScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"Customer"> | string fullName?: StringWithAggregatesFilter<"Customer"> | string mobile?: StringWithAggregatesFilter<"Customer"> | string nationalCode?: StringWithAggregatesFilter<"Customer"> | string passwordHash?: StringWithAggregatesFilter<"Customer"> | string cityId?: StringNullableWithAggregatesFilter<"Customer"> | string | null referredByAgentId?: StringNullableWithAggregatesFilter<"Customer"> | string | null goldCreditLimitGrams?: DecimalWithAggregatesFilter<"Customer"> | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalWithAggregatesFilter<"Customer"> | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalWithAggregatesFilter<"Customer"> | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepWithAggregatesFilter<"Customer"> | $Enums.VerificationStep nationalIdImageUrl?: StringNullableWithAggregatesFilter<"Customer"> | string | null businessLicenseUrl?: StringNullableWithAggregatesFilter<"Customer"> | string | null shopImageUrl?: StringNullableWithAggregatesFilter<"Customer"> | string | null isActive?: BoolWithAggregatesFilter<"Customer"> | boolean createdAt?: DateTimeWithAggregatesFilter<"Customer"> | Date | string updatedAt?: DateTimeWithAggregatesFilter<"Customer"> | Date | string } export type CustomerAddressWhereInput = { AND?: CustomerAddressWhereInput | CustomerAddressWhereInput[] OR?: CustomerAddressWhereInput[] NOT?: CustomerAddressWhereInput | CustomerAddressWhereInput[] id?: StringFilter<"CustomerAddress"> | string customerId?: StringFilter<"CustomerAddress"> | string cityId?: StringNullableFilter<"CustomerAddress"> | string | null addressLine?: StringFilter<"CustomerAddress"> | string isDefault?: BoolFilter<"CustomerAddress"> | boolean customer?: XOR city?: XOR | null } export type CustomerAddressOrderByWithRelationInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrderInput | SortOrder addressLine?: SortOrder isDefault?: SortOrder customer?: CustomerOrderByWithRelationInput city?: CityOrderByWithRelationInput } export type CustomerAddressWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: CustomerAddressWhereInput | CustomerAddressWhereInput[] OR?: CustomerAddressWhereInput[] NOT?: CustomerAddressWhereInput | CustomerAddressWhereInput[] customerId?: StringFilter<"CustomerAddress"> | string cityId?: StringNullableFilter<"CustomerAddress"> | string | null addressLine?: StringFilter<"CustomerAddress"> | string isDefault?: BoolFilter<"CustomerAddress"> | boolean customer?: XOR city?: XOR | null }, "id"> export type CustomerAddressOrderByWithAggregationInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrderInput | SortOrder addressLine?: SortOrder isDefault?: SortOrder _count?: CustomerAddressCountOrderByAggregateInput _max?: CustomerAddressMaxOrderByAggregateInput _min?: CustomerAddressMinOrderByAggregateInput } export type CustomerAddressScalarWhereWithAggregatesInput = { AND?: CustomerAddressScalarWhereWithAggregatesInput | CustomerAddressScalarWhereWithAggregatesInput[] OR?: CustomerAddressScalarWhereWithAggregatesInput[] NOT?: CustomerAddressScalarWhereWithAggregatesInput | CustomerAddressScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"CustomerAddress"> | string customerId?: StringWithAggregatesFilter<"CustomerAddress"> | string cityId?: StringNullableWithAggregatesFilter<"CustomerAddress"> | string | null addressLine?: StringWithAggregatesFilter<"CustomerAddress"> | string isDefault?: BoolWithAggregatesFilter<"CustomerAddress"> | boolean } export type BranchWhereInput = { AND?: BranchWhereInput | BranchWhereInput[] OR?: BranchWhereInput[] NOT?: BranchWhereInput | BranchWhereInput[] id?: StringFilter<"Branch"> | string name?: StringFilter<"Branch"> | string cityId?: StringNullableFilter<"Branch"> | string | null city?: XOR | null adminUsers?: AdminUserListRelationFilter orders?: OrderListRelationFilter } export type BranchOrderByWithRelationInput = { id?: SortOrder name?: SortOrder cityId?: SortOrderInput | SortOrder city?: CityOrderByWithRelationInput adminUsers?: AdminUserOrderByRelationAggregateInput orders?: OrderOrderByRelationAggregateInput } export type BranchWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: BranchWhereInput | BranchWhereInput[] OR?: BranchWhereInput[] NOT?: BranchWhereInput | BranchWhereInput[] name?: StringFilter<"Branch"> | string cityId?: StringNullableFilter<"Branch"> | string | null city?: XOR | null adminUsers?: AdminUserListRelationFilter orders?: OrderListRelationFilter }, "id"> export type BranchOrderByWithAggregationInput = { id?: SortOrder name?: SortOrder cityId?: SortOrderInput | SortOrder _count?: BranchCountOrderByAggregateInput _max?: BranchMaxOrderByAggregateInput _min?: BranchMinOrderByAggregateInput } export type BranchScalarWhereWithAggregatesInput = { AND?: BranchScalarWhereWithAggregatesInput | BranchScalarWhereWithAggregatesInput[] OR?: BranchScalarWhereWithAggregatesInput[] NOT?: BranchScalarWhereWithAggregatesInput | BranchScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"Branch"> | string name?: StringWithAggregatesFilter<"Branch"> | string cityId?: StringNullableWithAggregatesFilter<"Branch"> | string | null } export type WorkshopWhereInput = { AND?: WorkshopWhereInput | WorkshopWhereInput[] OR?: WorkshopWhereInput[] NOT?: WorkshopWhereInput | WorkshopWhereInput[] id?: StringFilter<"Workshop"> | string name?: StringFilter<"Workshop"> | string isActive?: BoolFilter<"Workshop"> | boolean preOrders?: PreOrderListRelationFilter } export type WorkshopOrderByWithRelationInput = { id?: SortOrder name?: SortOrder isActive?: SortOrder preOrders?: PreOrderOrderByRelationAggregateInput } export type WorkshopWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: WorkshopWhereInput | WorkshopWhereInput[] OR?: WorkshopWhereInput[] NOT?: WorkshopWhereInput | WorkshopWhereInput[] name?: StringFilter<"Workshop"> | string isActive?: BoolFilter<"Workshop"> | boolean preOrders?: PreOrderListRelationFilter }, "id"> export type WorkshopOrderByWithAggregationInput = { id?: SortOrder name?: SortOrder isActive?: SortOrder _count?: WorkshopCountOrderByAggregateInput _max?: WorkshopMaxOrderByAggregateInput _min?: WorkshopMinOrderByAggregateInput } export type WorkshopScalarWhereWithAggregatesInput = { AND?: WorkshopScalarWhereWithAggregatesInput | WorkshopScalarWhereWithAggregatesInput[] OR?: WorkshopScalarWhereWithAggregatesInput[] NOT?: WorkshopScalarWhereWithAggregatesInput | WorkshopScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"Workshop"> | string name?: StringWithAggregatesFilter<"Workshop"> | string isActive?: BoolWithAggregatesFilter<"Workshop"> | boolean } export type CategoryWhereInput = { AND?: CategoryWhereInput | CategoryWhereInput[] OR?: CategoryWhereInput[] NOT?: CategoryWhereInput | CategoryWhereInput[] id?: StringFilter<"Category"> | string title?: StringFilter<"Category"> | string parentId?: StringNullableFilter<"Category"> | string | null parent?: XOR | null children?: CategoryListRelationFilter products?: ProductListRelationFilter } export type CategoryOrderByWithRelationInput = { id?: SortOrder title?: SortOrder parentId?: SortOrderInput | SortOrder parent?: CategoryOrderByWithRelationInput children?: CategoryOrderByRelationAggregateInput products?: ProductOrderByRelationAggregateInput } export type CategoryWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: CategoryWhereInput | CategoryWhereInput[] OR?: CategoryWhereInput[] NOT?: CategoryWhereInput | CategoryWhereInput[] title?: StringFilter<"Category"> | string parentId?: StringNullableFilter<"Category"> | string | null parent?: XOR | null children?: CategoryListRelationFilter products?: ProductListRelationFilter }, "id"> export type CategoryOrderByWithAggregationInput = { id?: SortOrder title?: SortOrder parentId?: SortOrderInput | SortOrder _count?: CategoryCountOrderByAggregateInput _max?: CategoryMaxOrderByAggregateInput _min?: CategoryMinOrderByAggregateInput } export type CategoryScalarWhereWithAggregatesInput = { AND?: CategoryScalarWhereWithAggregatesInput | CategoryScalarWhereWithAggregatesInput[] OR?: CategoryScalarWhereWithAggregatesInput[] NOT?: CategoryScalarWhereWithAggregatesInput | CategoryScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"Category"> | string title?: StringWithAggregatesFilter<"Category"> | string parentId?: StringNullableWithAggregatesFilter<"Category"> | string | null } export type BrandWhereInput = { AND?: BrandWhereInput | BrandWhereInput[] OR?: BrandWhereInput[] NOT?: BrandWhereInput | BrandWhereInput[] id?: StringFilter<"Brand"> | string title?: StringFilter<"Brand"> | string products?: ProductListRelationFilter } export type BrandOrderByWithRelationInput = { id?: SortOrder title?: SortOrder products?: ProductOrderByRelationAggregateInput } export type BrandWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: BrandWhereInput | BrandWhereInput[] OR?: BrandWhereInput[] NOT?: BrandWhereInput | BrandWhereInput[] title?: StringFilter<"Brand"> | string products?: ProductListRelationFilter }, "id"> export type BrandOrderByWithAggregationInput = { id?: SortOrder title?: SortOrder _count?: BrandCountOrderByAggregateInput _max?: BrandMaxOrderByAggregateInput _min?: BrandMinOrderByAggregateInput } export type BrandScalarWhereWithAggregatesInput = { AND?: BrandScalarWhereWithAggregatesInput | BrandScalarWhereWithAggregatesInput[] OR?: BrandScalarWhereWithAggregatesInput[] NOT?: BrandScalarWhereWithAggregatesInput | BrandScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"Brand"> | string title?: StringWithAggregatesFilter<"Brand"> | string } export type CollectionWhereInput = { AND?: CollectionWhereInput | CollectionWhereInput[] OR?: CollectionWhereInput[] NOT?: CollectionWhereInput | CollectionWhereInput[] id?: StringFilter<"Collection"> | string title?: StringFilter<"Collection"> | string description?: StringNullableFilter<"Collection"> | string | null isActive?: BoolFilter<"Collection"> | boolean products?: CollectionProductListRelationFilter } export type CollectionOrderByWithRelationInput = { id?: SortOrder title?: SortOrder description?: SortOrderInput | SortOrder isActive?: SortOrder products?: CollectionProductOrderByRelationAggregateInput } export type CollectionWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: CollectionWhereInput | CollectionWhereInput[] OR?: CollectionWhereInput[] NOT?: CollectionWhereInput | CollectionWhereInput[] title?: StringFilter<"Collection"> | string description?: StringNullableFilter<"Collection"> | string | null isActive?: BoolFilter<"Collection"> | boolean products?: CollectionProductListRelationFilter }, "id"> export type CollectionOrderByWithAggregationInput = { id?: SortOrder title?: SortOrder description?: SortOrderInput | SortOrder isActive?: SortOrder _count?: CollectionCountOrderByAggregateInput _max?: CollectionMaxOrderByAggregateInput _min?: CollectionMinOrderByAggregateInput } export type CollectionScalarWhereWithAggregatesInput = { AND?: CollectionScalarWhereWithAggregatesInput | CollectionScalarWhereWithAggregatesInput[] OR?: CollectionScalarWhereWithAggregatesInput[] NOT?: CollectionScalarWhereWithAggregatesInput | CollectionScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"Collection"> | string title?: StringWithAggregatesFilter<"Collection"> | string description?: StringNullableWithAggregatesFilter<"Collection"> | string | null isActive?: BoolWithAggregatesFilter<"Collection"> | boolean } export type CollectionProductWhereInput = { AND?: CollectionProductWhereInput | CollectionProductWhereInput[] OR?: CollectionProductWhereInput[] NOT?: CollectionProductWhereInput | CollectionProductWhereInput[] collectionId?: StringFilter<"CollectionProduct"> | string productId?: StringFilter<"CollectionProduct"> | string collection?: XOR product?: XOR } export type CollectionProductOrderByWithRelationInput = { collectionId?: SortOrder productId?: SortOrder collection?: CollectionOrderByWithRelationInput product?: ProductOrderByWithRelationInput } export type CollectionProductWhereUniqueInput = Prisma.AtLeast<{ collectionId_productId?: CollectionProductCollectionIdProductIdCompoundUniqueInput AND?: CollectionProductWhereInput | CollectionProductWhereInput[] OR?: CollectionProductWhereInput[] NOT?: CollectionProductWhereInput | CollectionProductWhereInput[] collectionId?: StringFilter<"CollectionProduct"> | string productId?: StringFilter<"CollectionProduct"> | string collection?: XOR product?: XOR }, "collectionId_productId"> export type CollectionProductOrderByWithAggregationInput = { collectionId?: SortOrder productId?: SortOrder _count?: CollectionProductCountOrderByAggregateInput _max?: CollectionProductMaxOrderByAggregateInput _min?: CollectionProductMinOrderByAggregateInput } export type CollectionProductScalarWhereWithAggregatesInput = { AND?: CollectionProductScalarWhereWithAggregatesInput | CollectionProductScalarWhereWithAggregatesInput[] OR?: CollectionProductScalarWhereWithAggregatesInput[] NOT?: CollectionProductScalarWhereWithAggregatesInput | CollectionProductScalarWhereWithAggregatesInput[] collectionId?: StringWithAggregatesFilter<"CollectionProduct"> | string productId?: StringWithAggregatesFilter<"CollectionProduct"> | string } export type ProductWhereInput = { AND?: ProductWhereInput | ProductWhereInput[] OR?: ProductWhereInput[] NOT?: ProductWhereInput | ProductWhereInput[] id?: StringFilter<"Product"> | string title?: StringFilter<"Product"> | string description?: StringNullableFilter<"Product"> | string | null categoryId?: StringNullableFilter<"Product"> | string | null brandId?: StringNullableFilter<"Product"> | string | null isActive?: BoolFilter<"Product"> | boolean createdAt?: DateTimeFilter<"Product"> | Date | string category?: XOR | null brand?: XOR | null variants?: ProductVariantListRelationFilter images?: ProductImageListRelationFilter collections?: CollectionProductListRelationFilter } export type ProductOrderByWithRelationInput = { id?: SortOrder title?: SortOrder description?: SortOrderInput | SortOrder categoryId?: SortOrderInput | SortOrder brandId?: SortOrderInput | SortOrder isActive?: SortOrder createdAt?: SortOrder category?: CategoryOrderByWithRelationInput brand?: BrandOrderByWithRelationInput variants?: ProductVariantOrderByRelationAggregateInput images?: ProductImageOrderByRelationAggregateInput collections?: CollectionProductOrderByRelationAggregateInput } export type ProductWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: ProductWhereInput | ProductWhereInput[] OR?: ProductWhereInput[] NOT?: ProductWhereInput | ProductWhereInput[] title?: StringFilter<"Product"> | string description?: StringNullableFilter<"Product"> | string | null categoryId?: StringNullableFilter<"Product"> | string | null brandId?: StringNullableFilter<"Product"> | string | null isActive?: BoolFilter<"Product"> | boolean createdAt?: DateTimeFilter<"Product"> | Date | string category?: XOR | null brand?: XOR | null variants?: ProductVariantListRelationFilter images?: ProductImageListRelationFilter collections?: CollectionProductListRelationFilter }, "id"> export type ProductOrderByWithAggregationInput = { id?: SortOrder title?: SortOrder description?: SortOrderInput | SortOrder categoryId?: SortOrderInput | SortOrder brandId?: SortOrderInput | SortOrder isActive?: SortOrder createdAt?: SortOrder _count?: ProductCountOrderByAggregateInput _max?: ProductMaxOrderByAggregateInput _min?: ProductMinOrderByAggregateInput } export type ProductScalarWhereWithAggregatesInput = { AND?: ProductScalarWhereWithAggregatesInput | ProductScalarWhereWithAggregatesInput[] OR?: ProductScalarWhereWithAggregatesInput[] NOT?: ProductScalarWhereWithAggregatesInput | ProductScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"Product"> | string title?: StringWithAggregatesFilter<"Product"> | string description?: StringNullableWithAggregatesFilter<"Product"> | string | null categoryId?: StringNullableWithAggregatesFilter<"Product"> | string | null brandId?: StringNullableWithAggregatesFilter<"Product"> | string | null isActive?: BoolWithAggregatesFilter<"Product"> | boolean createdAt?: DateTimeWithAggregatesFilter<"Product"> | Date | string } export type ProductImageWhereInput = { AND?: ProductImageWhereInput | ProductImageWhereInput[] OR?: ProductImageWhereInput[] NOT?: ProductImageWhereInput | ProductImageWhereInput[] id?: StringFilter<"ProductImage"> | string productId?: StringFilter<"ProductImage"> | string url?: StringFilter<"ProductImage"> | string sortOrder?: IntFilter<"ProductImage"> | number product?: XOR } export type ProductImageOrderByWithRelationInput = { id?: SortOrder productId?: SortOrder url?: SortOrder sortOrder?: SortOrder product?: ProductOrderByWithRelationInput } export type ProductImageWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: ProductImageWhereInput | ProductImageWhereInput[] OR?: ProductImageWhereInput[] NOT?: ProductImageWhereInput | ProductImageWhereInput[] productId?: StringFilter<"ProductImage"> | string url?: StringFilter<"ProductImage"> | string sortOrder?: IntFilter<"ProductImage"> | number product?: XOR }, "id"> export type ProductImageOrderByWithAggregationInput = { id?: SortOrder productId?: SortOrder url?: SortOrder sortOrder?: SortOrder _count?: ProductImageCountOrderByAggregateInput _avg?: ProductImageAvgOrderByAggregateInput _max?: ProductImageMaxOrderByAggregateInput _min?: ProductImageMinOrderByAggregateInput _sum?: ProductImageSumOrderByAggregateInput } export type ProductImageScalarWhereWithAggregatesInput = { AND?: ProductImageScalarWhereWithAggregatesInput | ProductImageScalarWhereWithAggregatesInput[] OR?: ProductImageScalarWhereWithAggregatesInput[] NOT?: ProductImageScalarWhereWithAggregatesInput | ProductImageScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"ProductImage"> | string productId?: StringWithAggregatesFilter<"ProductImage"> | string url?: StringWithAggregatesFilter<"ProductImage"> | string sortOrder?: IntWithAggregatesFilter<"ProductImage"> | number } export type ProductVariantWhereInput = { AND?: ProductVariantWhereInput | ProductVariantWhereInput[] OR?: ProductVariantWhereInput[] NOT?: ProductVariantWhereInput | ProductVariantWhereInput[] id?: StringFilter<"ProductVariant"> | string productId?: StringFilter<"ProductVariant"> | string title?: StringFilter<"ProductVariant"> | string sku?: StringNullableFilter<"ProductVariant"> | string | null rashWeightGrams?: DecimalFilter<"ProductVariant"> | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFilter<"ProductVariant"> | Decimal | DecimalJsLike | number | string isActive?: BoolFilter<"ProductVariant"> | boolean product?: XOR orderItems?: OrderItemListRelationFilter } export type ProductVariantOrderByWithRelationInput = { id?: SortOrder productId?: SortOrder title?: SortOrder sku?: SortOrderInput | SortOrder rashWeightGrams?: SortOrder defaultWagePercent?: SortOrder isActive?: SortOrder product?: ProductOrderByWithRelationInput orderItems?: OrderItemOrderByRelationAggregateInput } export type ProductVariantWhereUniqueInput = Prisma.AtLeast<{ id?: string sku?: string AND?: ProductVariantWhereInput | ProductVariantWhereInput[] OR?: ProductVariantWhereInput[] NOT?: ProductVariantWhereInput | ProductVariantWhereInput[] productId?: StringFilter<"ProductVariant"> | string title?: StringFilter<"ProductVariant"> | string rashWeightGrams?: DecimalFilter<"ProductVariant"> | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFilter<"ProductVariant"> | Decimal | DecimalJsLike | number | string isActive?: BoolFilter<"ProductVariant"> | boolean product?: XOR orderItems?: OrderItemListRelationFilter }, "id" | "sku"> export type ProductVariantOrderByWithAggregationInput = { id?: SortOrder productId?: SortOrder title?: SortOrder sku?: SortOrderInput | SortOrder rashWeightGrams?: SortOrder defaultWagePercent?: SortOrder isActive?: SortOrder _count?: ProductVariantCountOrderByAggregateInput _avg?: ProductVariantAvgOrderByAggregateInput _max?: ProductVariantMaxOrderByAggregateInput _min?: ProductVariantMinOrderByAggregateInput _sum?: ProductVariantSumOrderByAggregateInput } export type ProductVariantScalarWhereWithAggregatesInput = { AND?: ProductVariantScalarWhereWithAggregatesInput | ProductVariantScalarWhereWithAggregatesInput[] OR?: ProductVariantScalarWhereWithAggregatesInput[] NOT?: ProductVariantScalarWhereWithAggregatesInput | ProductVariantScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"ProductVariant"> | string productId?: StringWithAggregatesFilter<"ProductVariant"> | string title?: StringWithAggregatesFilter<"ProductVariant"> | string sku?: StringNullableWithAggregatesFilter<"ProductVariant"> | string | null rashWeightGrams?: DecimalWithAggregatesFilter<"ProductVariant"> | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalWithAggregatesFilter<"ProductVariant"> | Decimal | DecimalJsLike | number | string isActive?: BoolWithAggregatesFilter<"ProductVariant"> | boolean } export type OrderWhereInput = { AND?: OrderWhereInput | OrderWhereInput[] OR?: OrderWhereInput[] NOT?: OrderWhereInput | OrderWhereInput[] id?: StringFilter<"Order"> | string orderNumber?: StringFilter<"Order"> | string customerId?: StringFilter<"Order"> | string branchId?: StringNullableFilter<"Order"> | string | null status?: EnumOrderStatusFilter<"Order"> | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFilter<"Order"> | boolean deliveredAt?: DateTimeNullableFilter<"Order"> | Date | string | null createdAt?: DateTimeFilter<"Order"> | Date | string updatedAt?: DateTimeFilter<"Order"> | Date | string customer?: XOR branch?: XOR | null items?: OrderItemListRelationFilter statusEvents?: OrderStatusEventListRelationFilter ledgerEntries?: LedgerEntryListRelationFilter convertedFromPreOrder?: XOR | null } export type OrderOrderByWithRelationInput = { id?: SortOrder orderNumber?: SortOrder customerId?: SortOrder branchId?: SortOrderInput | SortOrder status?: SortOrder totalGoldWeightGrams?: SortOrder wageWeightGrams?: SortOrder flatRialCharge?: SortOrder isSuspendedOverCreditLimit?: SortOrder deliveredAt?: SortOrderInput | SortOrder createdAt?: SortOrder updatedAt?: SortOrder customer?: CustomerOrderByWithRelationInput branch?: BranchOrderByWithRelationInput items?: OrderItemOrderByRelationAggregateInput statusEvents?: OrderStatusEventOrderByRelationAggregateInput ledgerEntries?: LedgerEntryOrderByRelationAggregateInput convertedFromPreOrder?: PreOrderOrderByWithRelationInput } export type OrderWhereUniqueInput = Prisma.AtLeast<{ id?: string orderNumber?: string AND?: OrderWhereInput | OrderWhereInput[] OR?: OrderWhereInput[] NOT?: OrderWhereInput | OrderWhereInput[] customerId?: StringFilter<"Order"> | string branchId?: StringNullableFilter<"Order"> | string | null status?: EnumOrderStatusFilter<"Order"> | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFilter<"Order"> | boolean deliveredAt?: DateTimeNullableFilter<"Order"> | Date | string | null createdAt?: DateTimeFilter<"Order"> | Date | string updatedAt?: DateTimeFilter<"Order"> | Date | string customer?: XOR branch?: XOR | null items?: OrderItemListRelationFilter statusEvents?: OrderStatusEventListRelationFilter ledgerEntries?: LedgerEntryListRelationFilter convertedFromPreOrder?: XOR | null }, "id" | "orderNumber"> export type OrderOrderByWithAggregationInput = { id?: SortOrder orderNumber?: SortOrder customerId?: SortOrder branchId?: SortOrderInput | SortOrder status?: SortOrder totalGoldWeightGrams?: SortOrder wageWeightGrams?: SortOrder flatRialCharge?: SortOrder isSuspendedOverCreditLimit?: SortOrder deliveredAt?: SortOrderInput | SortOrder createdAt?: SortOrder updatedAt?: SortOrder _count?: OrderCountOrderByAggregateInput _avg?: OrderAvgOrderByAggregateInput _max?: OrderMaxOrderByAggregateInput _min?: OrderMinOrderByAggregateInput _sum?: OrderSumOrderByAggregateInput } export type OrderScalarWhereWithAggregatesInput = { AND?: OrderScalarWhereWithAggregatesInput | OrderScalarWhereWithAggregatesInput[] OR?: OrderScalarWhereWithAggregatesInput[] NOT?: OrderScalarWhereWithAggregatesInput | OrderScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"Order"> | string orderNumber?: StringWithAggregatesFilter<"Order"> | string customerId?: StringWithAggregatesFilter<"Order"> | string branchId?: StringNullableWithAggregatesFilter<"Order"> | string | null status?: EnumOrderStatusWithAggregatesFilter<"Order"> | $Enums.OrderStatus totalGoldWeightGrams?: DecimalWithAggregatesFilter<"Order"> | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalWithAggregatesFilter<"Order"> | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalWithAggregatesFilter<"Order"> | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolWithAggregatesFilter<"Order"> | boolean deliveredAt?: DateTimeNullableWithAggregatesFilter<"Order"> | Date | string | null createdAt?: DateTimeWithAggregatesFilter<"Order"> | Date | string updatedAt?: DateTimeWithAggregatesFilter<"Order"> | Date | string } export type OrderItemWhereInput = { AND?: OrderItemWhereInput | OrderItemWhereInput[] OR?: OrderItemWhereInput[] NOT?: OrderItemWhereInput | OrderItemWhereInput[] id?: StringFilter<"OrderItem"> | string orderId?: StringFilter<"OrderItem"> | string productVariantId?: StringFilter<"OrderItem"> | string quantity?: IntFilter<"OrderItem"> | number rashWeightGramsSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string order?: XOR productVariant?: XOR } export type OrderItemOrderByWithRelationInput = { id?: SortOrder orderId?: SortOrder productVariantId?: SortOrder quantity?: SortOrder rashWeightGramsSnapshot?: SortOrder wagePercentSnapshot?: SortOrder discountPercentSnapshot?: SortOrder computedWeightGrams?: SortOrder flatRialCharge?: SortOrder order?: OrderOrderByWithRelationInput productVariant?: ProductVariantOrderByWithRelationInput } export type OrderItemWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: OrderItemWhereInput | OrderItemWhereInput[] OR?: OrderItemWhereInput[] NOT?: OrderItemWhereInput | OrderItemWhereInput[] orderId?: StringFilter<"OrderItem"> | string productVariantId?: StringFilter<"OrderItem"> | string quantity?: IntFilter<"OrderItem"> | number rashWeightGramsSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string order?: XOR productVariant?: XOR }, "id"> export type OrderItemOrderByWithAggregationInput = { id?: SortOrder orderId?: SortOrder productVariantId?: SortOrder quantity?: SortOrder rashWeightGramsSnapshot?: SortOrder wagePercentSnapshot?: SortOrder discountPercentSnapshot?: SortOrder computedWeightGrams?: SortOrder flatRialCharge?: SortOrder _count?: OrderItemCountOrderByAggregateInput _avg?: OrderItemAvgOrderByAggregateInput _max?: OrderItemMaxOrderByAggregateInput _min?: OrderItemMinOrderByAggregateInput _sum?: OrderItemSumOrderByAggregateInput } export type OrderItemScalarWhereWithAggregatesInput = { AND?: OrderItemScalarWhereWithAggregatesInput | OrderItemScalarWhereWithAggregatesInput[] OR?: OrderItemScalarWhereWithAggregatesInput[] NOT?: OrderItemScalarWhereWithAggregatesInput | OrderItemScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"OrderItem"> | string orderId?: StringWithAggregatesFilter<"OrderItem"> | string productVariantId?: StringWithAggregatesFilter<"OrderItem"> | string quantity?: IntWithAggregatesFilter<"OrderItem"> | number rashWeightGramsSnapshot?: DecimalWithAggregatesFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalWithAggregatesFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalWithAggregatesFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalWithAggregatesFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalWithAggregatesFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string } export type OrderStatusEventWhereInput = { AND?: OrderStatusEventWhereInput | OrderStatusEventWhereInput[] OR?: OrderStatusEventWhereInput[] NOT?: OrderStatusEventWhereInput | OrderStatusEventWhereInput[] id?: StringFilter<"OrderStatusEvent"> | string orderId?: StringFilter<"OrderStatusEvent"> | string fromStatus?: EnumOrderStatusNullableFilter<"OrderStatusEvent"> | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFilter<"OrderStatusEvent"> | $Enums.OrderStatus note?: StringNullableFilter<"OrderStatusEvent"> | string | null actorAdminUserId?: StringNullableFilter<"OrderStatusEvent"> | string | null createdAt?: DateTimeFilter<"OrderStatusEvent"> | Date | string order?: XOR actorAdminUser?: XOR | null } export type OrderStatusEventOrderByWithRelationInput = { id?: SortOrder orderId?: SortOrder fromStatus?: SortOrderInput | SortOrder toStatus?: SortOrder note?: SortOrderInput | SortOrder actorAdminUserId?: SortOrderInput | SortOrder createdAt?: SortOrder order?: OrderOrderByWithRelationInput actorAdminUser?: AdminUserOrderByWithRelationInput } export type OrderStatusEventWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: OrderStatusEventWhereInput | OrderStatusEventWhereInput[] OR?: OrderStatusEventWhereInput[] NOT?: OrderStatusEventWhereInput | OrderStatusEventWhereInput[] orderId?: StringFilter<"OrderStatusEvent"> | string fromStatus?: EnumOrderStatusNullableFilter<"OrderStatusEvent"> | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFilter<"OrderStatusEvent"> | $Enums.OrderStatus note?: StringNullableFilter<"OrderStatusEvent"> | string | null actorAdminUserId?: StringNullableFilter<"OrderStatusEvent"> | string | null createdAt?: DateTimeFilter<"OrderStatusEvent"> | Date | string order?: XOR actorAdminUser?: XOR | null }, "id"> export type OrderStatusEventOrderByWithAggregationInput = { id?: SortOrder orderId?: SortOrder fromStatus?: SortOrderInput | SortOrder toStatus?: SortOrder note?: SortOrderInput | SortOrder actorAdminUserId?: SortOrderInput | SortOrder createdAt?: SortOrder _count?: OrderStatusEventCountOrderByAggregateInput _max?: OrderStatusEventMaxOrderByAggregateInput _min?: OrderStatusEventMinOrderByAggregateInput } export type OrderStatusEventScalarWhereWithAggregatesInput = { AND?: OrderStatusEventScalarWhereWithAggregatesInput | OrderStatusEventScalarWhereWithAggregatesInput[] OR?: OrderStatusEventScalarWhereWithAggregatesInput[] NOT?: OrderStatusEventScalarWhereWithAggregatesInput | OrderStatusEventScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"OrderStatusEvent"> | string orderId?: StringWithAggregatesFilter<"OrderStatusEvent"> | string fromStatus?: EnumOrderStatusNullableWithAggregatesFilter<"OrderStatusEvent"> | $Enums.OrderStatus | null toStatus?: EnumOrderStatusWithAggregatesFilter<"OrderStatusEvent"> | $Enums.OrderStatus note?: StringNullableWithAggregatesFilter<"OrderStatusEvent"> | string | null actorAdminUserId?: StringNullableWithAggregatesFilter<"OrderStatusEvent"> | string | null createdAt?: DateTimeWithAggregatesFilter<"OrderStatusEvent"> | Date | string } export type PreOrderWhereInput = { AND?: PreOrderWhereInput | PreOrderWhereInput[] OR?: PreOrderWhereInput[] NOT?: PreOrderWhereInput | PreOrderWhereInput[] id?: StringFilter<"PreOrder"> | string customerId?: StringFilter<"PreOrder"> | string cityId?: StringNullableFilter<"PreOrder"> | string | null workshopId?: StringNullableFilter<"PreOrder"> | string | null status?: EnumPreOrderStatusFilter<"PreOrder"> | $Enums.PreOrderStatus designImageUrl?: StringNullableFilter<"PreOrder"> | string | null colorName?: StringNullableFilter<"PreOrder"> | string | null sizeSpec?: StringNullableFilter<"PreOrder"> | string | null stoneColor?: StringNullableFilter<"PreOrder"> | string | null minaColor?: StringNullableFilter<"PreOrder"> | string | null estimatedWeightGrams?: DecimalNullableFilter<"PreOrder"> | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: DecimalNullableFilter<"PreOrder"> | Decimal | DecimalJsLike | number | string | null description?: StringNullableFilter<"PreOrder"> | string | null convertedOrderId?: StringNullableFilter<"PreOrder"> | string | null createdAt?: DateTimeFilter<"PreOrder"> | Date | string updatedAt?: DateTimeFilter<"PreOrder"> | Date | string customer?: XOR city?: XOR | null workshop?: XOR | null convertedOrder?: XOR | null statusEvents?: PreOrderStatusEventListRelationFilter } export type PreOrderOrderByWithRelationInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrderInput | SortOrder workshopId?: SortOrderInput | SortOrder status?: SortOrder designImageUrl?: SortOrderInput | SortOrder colorName?: SortOrderInput | SortOrder sizeSpec?: SortOrderInput | SortOrder stoneColor?: SortOrderInput | SortOrder minaColor?: SortOrderInput | SortOrder estimatedWeightGrams?: SortOrderInput | SortOrder estimatedPriceRial?: SortOrderInput | SortOrder description?: SortOrderInput | SortOrder convertedOrderId?: SortOrderInput | SortOrder createdAt?: SortOrder updatedAt?: SortOrder customer?: CustomerOrderByWithRelationInput city?: CityOrderByWithRelationInput workshop?: WorkshopOrderByWithRelationInput convertedOrder?: OrderOrderByWithRelationInput statusEvents?: PreOrderStatusEventOrderByRelationAggregateInput } export type PreOrderWhereUniqueInput = Prisma.AtLeast<{ id?: string convertedOrderId?: string AND?: PreOrderWhereInput | PreOrderWhereInput[] OR?: PreOrderWhereInput[] NOT?: PreOrderWhereInput | PreOrderWhereInput[] customerId?: StringFilter<"PreOrder"> | string cityId?: StringNullableFilter<"PreOrder"> | string | null workshopId?: StringNullableFilter<"PreOrder"> | string | null status?: EnumPreOrderStatusFilter<"PreOrder"> | $Enums.PreOrderStatus designImageUrl?: StringNullableFilter<"PreOrder"> | string | null colorName?: StringNullableFilter<"PreOrder"> | string | null sizeSpec?: StringNullableFilter<"PreOrder"> | string | null stoneColor?: StringNullableFilter<"PreOrder"> | string | null minaColor?: StringNullableFilter<"PreOrder"> | string | null estimatedWeightGrams?: DecimalNullableFilter<"PreOrder"> | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: DecimalNullableFilter<"PreOrder"> | Decimal | DecimalJsLike | number | string | null description?: StringNullableFilter<"PreOrder"> | string | null createdAt?: DateTimeFilter<"PreOrder"> | Date | string updatedAt?: DateTimeFilter<"PreOrder"> | Date | string customer?: XOR city?: XOR | null workshop?: XOR | null convertedOrder?: XOR | null statusEvents?: PreOrderStatusEventListRelationFilter }, "id" | "convertedOrderId"> export type PreOrderOrderByWithAggregationInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrderInput | SortOrder workshopId?: SortOrderInput | SortOrder status?: SortOrder designImageUrl?: SortOrderInput | SortOrder colorName?: SortOrderInput | SortOrder sizeSpec?: SortOrderInput | SortOrder stoneColor?: SortOrderInput | SortOrder minaColor?: SortOrderInput | SortOrder estimatedWeightGrams?: SortOrderInput | SortOrder estimatedPriceRial?: SortOrderInput | SortOrder description?: SortOrderInput | SortOrder convertedOrderId?: SortOrderInput | SortOrder createdAt?: SortOrder updatedAt?: SortOrder _count?: PreOrderCountOrderByAggregateInput _avg?: PreOrderAvgOrderByAggregateInput _max?: PreOrderMaxOrderByAggregateInput _min?: PreOrderMinOrderByAggregateInput _sum?: PreOrderSumOrderByAggregateInput } export type PreOrderScalarWhereWithAggregatesInput = { AND?: PreOrderScalarWhereWithAggregatesInput | PreOrderScalarWhereWithAggregatesInput[] OR?: PreOrderScalarWhereWithAggregatesInput[] NOT?: PreOrderScalarWhereWithAggregatesInput | PreOrderScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"PreOrder"> | string customerId?: StringWithAggregatesFilter<"PreOrder"> | string cityId?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null workshopId?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null status?: EnumPreOrderStatusWithAggregatesFilter<"PreOrder"> | $Enums.PreOrderStatus designImageUrl?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null colorName?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null sizeSpec?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null stoneColor?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null minaColor?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null estimatedWeightGrams?: DecimalNullableWithAggregatesFilter<"PreOrder"> | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: DecimalNullableWithAggregatesFilter<"PreOrder"> | Decimal | DecimalJsLike | number | string | null description?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null convertedOrderId?: StringNullableWithAggregatesFilter<"PreOrder"> | string | null createdAt?: DateTimeWithAggregatesFilter<"PreOrder"> | Date | string updatedAt?: DateTimeWithAggregatesFilter<"PreOrder"> | Date | string } export type PreOrderStatusEventWhereInput = { AND?: PreOrderStatusEventWhereInput | PreOrderStatusEventWhereInput[] OR?: PreOrderStatusEventWhereInput[] NOT?: PreOrderStatusEventWhereInput | PreOrderStatusEventWhereInput[] id?: StringFilter<"PreOrderStatusEvent"> | string preOrderId?: StringFilter<"PreOrderStatusEvent"> | string changes?: JsonFilter<"PreOrderStatusEvent"> actorAdminUserId?: StringNullableFilter<"PreOrderStatusEvent"> | string | null ipAddress?: StringNullableFilter<"PreOrderStatusEvent"> | string | null createdAt?: DateTimeFilter<"PreOrderStatusEvent"> | Date | string preOrder?: XOR actorAdminUser?: XOR | null } export type PreOrderStatusEventOrderByWithRelationInput = { id?: SortOrder preOrderId?: SortOrder changes?: SortOrder actorAdminUserId?: SortOrderInput | SortOrder ipAddress?: SortOrderInput | SortOrder createdAt?: SortOrder preOrder?: PreOrderOrderByWithRelationInput actorAdminUser?: AdminUserOrderByWithRelationInput } export type PreOrderStatusEventWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: PreOrderStatusEventWhereInput | PreOrderStatusEventWhereInput[] OR?: PreOrderStatusEventWhereInput[] NOT?: PreOrderStatusEventWhereInput | PreOrderStatusEventWhereInput[] preOrderId?: StringFilter<"PreOrderStatusEvent"> | string changes?: JsonFilter<"PreOrderStatusEvent"> actorAdminUserId?: StringNullableFilter<"PreOrderStatusEvent"> | string | null ipAddress?: StringNullableFilter<"PreOrderStatusEvent"> | string | null createdAt?: DateTimeFilter<"PreOrderStatusEvent"> | Date | string preOrder?: XOR actorAdminUser?: XOR | null }, "id"> export type PreOrderStatusEventOrderByWithAggregationInput = { id?: SortOrder preOrderId?: SortOrder changes?: SortOrder actorAdminUserId?: SortOrderInput | SortOrder ipAddress?: SortOrderInput | SortOrder createdAt?: SortOrder _count?: PreOrderStatusEventCountOrderByAggregateInput _max?: PreOrderStatusEventMaxOrderByAggregateInput _min?: PreOrderStatusEventMinOrderByAggregateInput } export type PreOrderStatusEventScalarWhereWithAggregatesInput = { AND?: PreOrderStatusEventScalarWhereWithAggregatesInput | PreOrderStatusEventScalarWhereWithAggregatesInput[] OR?: PreOrderStatusEventScalarWhereWithAggregatesInput[] NOT?: PreOrderStatusEventScalarWhereWithAggregatesInput | PreOrderStatusEventScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"PreOrderStatusEvent"> | string preOrderId?: StringWithAggregatesFilter<"PreOrderStatusEvent"> | string changes?: JsonWithAggregatesFilter<"PreOrderStatusEvent"> actorAdminUserId?: StringNullableWithAggregatesFilter<"PreOrderStatusEvent"> | string | null ipAddress?: StringNullableWithAggregatesFilter<"PreOrderStatusEvent"> | string | null createdAt?: DateTimeWithAggregatesFilter<"PreOrderStatusEvent"> | Date | string } export type LedgerEntryWhereInput = { AND?: LedgerEntryWhereInput | LedgerEntryWhereInput[] OR?: LedgerEntryWhereInput[] NOT?: LedgerEntryWhereInput | LedgerEntryWhereInput[] id?: StringFilter<"LedgerEntry"> | string customerId?: StringFilter<"LedgerEntry"> | string currency?: EnumLedgerCurrencyFilter<"LedgerEntry"> | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFilter<"LedgerEntry"> | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFilter<"LedgerEntry"> | $Enums.LedgerSourceType amount?: DecimalFilter<"LedgerEntry"> | Decimal | DecimalJsLike | number | string karatPerMille?: IntNullableFilter<"LedgerEntry"> | number | null pricePerGramRialAtEntry?: DecimalNullableFilter<"LedgerEntry"> | Decimal | DecimalJsLike | number | string | null orderId?: StringNullableFilter<"LedgerEntry"> | string | null confirmed?: BoolFilter<"LedgerEntry"> | boolean confirmedAt?: DateTimeNullableFilter<"LedgerEntry"> | Date | string | null postedByAdminUserId?: StringNullableFilter<"LedgerEntry"> | string | null note?: StringNullableFilter<"LedgerEntry"> | string | null createdAt?: DateTimeFilter<"LedgerEntry"> | Date | string customer?: XOR order?: XOR | null postedByAdminUser?: XOR | null } export type LedgerEntryOrderByWithRelationInput = { id?: SortOrder customerId?: SortOrder currency?: SortOrder direction?: SortOrder sourceType?: SortOrder amount?: SortOrder karatPerMille?: SortOrderInput | SortOrder pricePerGramRialAtEntry?: SortOrderInput | SortOrder orderId?: SortOrderInput | SortOrder confirmed?: SortOrder confirmedAt?: SortOrderInput | SortOrder postedByAdminUserId?: SortOrderInput | SortOrder note?: SortOrderInput | SortOrder createdAt?: SortOrder customer?: CustomerOrderByWithRelationInput order?: OrderOrderByWithRelationInput postedByAdminUser?: AdminUserOrderByWithRelationInput } export type LedgerEntryWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: LedgerEntryWhereInput | LedgerEntryWhereInput[] OR?: LedgerEntryWhereInput[] NOT?: LedgerEntryWhereInput | LedgerEntryWhereInput[] customerId?: StringFilter<"LedgerEntry"> | string currency?: EnumLedgerCurrencyFilter<"LedgerEntry"> | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFilter<"LedgerEntry"> | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFilter<"LedgerEntry"> | $Enums.LedgerSourceType amount?: DecimalFilter<"LedgerEntry"> | Decimal | DecimalJsLike | number | string karatPerMille?: IntNullableFilter<"LedgerEntry"> | number | null pricePerGramRialAtEntry?: DecimalNullableFilter<"LedgerEntry"> | Decimal | DecimalJsLike | number | string | null orderId?: StringNullableFilter<"LedgerEntry"> | string | null confirmed?: BoolFilter<"LedgerEntry"> | boolean confirmedAt?: DateTimeNullableFilter<"LedgerEntry"> | Date | string | null postedByAdminUserId?: StringNullableFilter<"LedgerEntry"> | string | null note?: StringNullableFilter<"LedgerEntry"> | string | null createdAt?: DateTimeFilter<"LedgerEntry"> | Date | string customer?: XOR order?: XOR | null postedByAdminUser?: XOR | null }, "id"> export type LedgerEntryOrderByWithAggregationInput = { id?: SortOrder customerId?: SortOrder currency?: SortOrder direction?: SortOrder sourceType?: SortOrder amount?: SortOrder karatPerMille?: SortOrderInput | SortOrder pricePerGramRialAtEntry?: SortOrderInput | SortOrder orderId?: SortOrderInput | SortOrder confirmed?: SortOrder confirmedAt?: SortOrderInput | SortOrder postedByAdminUserId?: SortOrderInput | SortOrder note?: SortOrderInput | SortOrder createdAt?: SortOrder _count?: LedgerEntryCountOrderByAggregateInput _avg?: LedgerEntryAvgOrderByAggregateInput _max?: LedgerEntryMaxOrderByAggregateInput _min?: LedgerEntryMinOrderByAggregateInput _sum?: LedgerEntrySumOrderByAggregateInput } export type LedgerEntryScalarWhereWithAggregatesInput = { AND?: LedgerEntryScalarWhereWithAggregatesInput | LedgerEntryScalarWhereWithAggregatesInput[] OR?: LedgerEntryScalarWhereWithAggregatesInput[] NOT?: LedgerEntryScalarWhereWithAggregatesInput | LedgerEntryScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"LedgerEntry"> | string customerId?: StringWithAggregatesFilter<"LedgerEntry"> | string currency?: EnumLedgerCurrencyWithAggregatesFilter<"LedgerEntry"> | $Enums.LedgerCurrency direction?: EnumLedgerDirectionWithAggregatesFilter<"LedgerEntry"> | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeWithAggregatesFilter<"LedgerEntry"> | $Enums.LedgerSourceType amount?: DecimalWithAggregatesFilter<"LedgerEntry"> | Decimal | DecimalJsLike | number | string karatPerMille?: IntNullableWithAggregatesFilter<"LedgerEntry"> | number | null pricePerGramRialAtEntry?: DecimalNullableWithAggregatesFilter<"LedgerEntry"> | Decimal | DecimalJsLike | number | string | null orderId?: StringNullableWithAggregatesFilter<"LedgerEntry"> | string | null confirmed?: BoolWithAggregatesFilter<"LedgerEntry"> | boolean confirmedAt?: DateTimeNullableWithAggregatesFilter<"LedgerEntry"> | Date | string | null postedByAdminUserId?: StringNullableWithAggregatesFilter<"LedgerEntry"> | string | null note?: StringNullableWithAggregatesFilter<"LedgerEntry"> | string | null createdAt?: DateTimeWithAggregatesFilter<"LedgerEntry"> | Date | string } export type GoldPriceQuoteWhereInput = { AND?: GoldPriceQuoteWhereInput | GoldPriceQuoteWhereInput[] OR?: GoldPriceQuoteWhereInput[] NOT?: GoldPriceQuoteWhereInput | GoldPriceQuoteWhereInput[] id?: StringFilter<"GoldPriceQuote"> | string karatPerMille?: IntFilter<"GoldPriceQuote"> | number pricePerGramRial?: DecimalFilter<"GoldPriceQuote"> | Decimal | DecimalJsLike | number | string source?: StringFilter<"GoldPriceQuote"> | string quotedAt?: DateTimeFilter<"GoldPriceQuote"> | Date | string } export type GoldPriceQuoteOrderByWithRelationInput = { id?: SortOrder karatPerMille?: SortOrder pricePerGramRial?: SortOrder source?: SortOrder quotedAt?: SortOrder } export type GoldPriceQuoteWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: GoldPriceQuoteWhereInput | GoldPriceQuoteWhereInput[] OR?: GoldPriceQuoteWhereInput[] NOT?: GoldPriceQuoteWhereInput | GoldPriceQuoteWhereInput[] karatPerMille?: IntFilter<"GoldPriceQuote"> | number pricePerGramRial?: DecimalFilter<"GoldPriceQuote"> | Decimal | DecimalJsLike | number | string source?: StringFilter<"GoldPriceQuote"> | string quotedAt?: DateTimeFilter<"GoldPriceQuote"> | Date | string }, "id"> export type GoldPriceQuoteOrderByWithAggregationInput = { id?: SortOrder karatPerMille?: SortOrder pricePerGramRial?: SortOrder source?: SortOrder quotedAt?: SortOrder _count?: GoldPriceQuoteCountOrderByAggregateInput _avg?: GoldPriceQuoteAvgOrderByAggregateInput _max?: GoldPriceQuoteMaxOrderByAggregateInput _min?: GoldPriceQuoteMinOrderByAggregateInput _sum?: GoldPriceQuoteSumOrderByAggregateInput } export type GoldPriceQuoteScalarWhereWithAggregatesInput = { AND?: GoldPriceQuoteScalarWhereWithAggregatesInput | GoldPriceQuoteScalarWhereWithAggregatesInput[] OR?: GoldPriceQuoteScalarWhereWithAggregatesInput[] NOT?: GoldPriceQuoteScalarWhereWithAggregatesInput | GoldPriceQuoteScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"GoldPriceQuote"> | string karatPerMille?: IntWithAggregatesFilter<"GoldPriceQuote"> | number pricePerGramRial?: DecimalWithAggregatesFilter<"GoldPriceQuote"> | Decimal | DecimalJsLike | number | string source?: StringWithAggregatesFilter<"GoldPriceQuote"> | string quotedAt?: DateTimeWithAggregatesFilter<"GoldPriceQuote"> | Date | string } export type WalletBonusWhereInput = { AND?: WalletBonusWhereInput | WalletBonusWhereInput[] OR?: WalletBonusWhereInput[] NOT?: WalletBonusWhereInput | WalletBonusWhereInput[] id?: StringFilter<"WalletBonus"> | string customerId?: StringFilter<"WalletBonus"> | string orderId?: StringNullableFilter<"WalletBonus"> | string | null goldGrams?: DecimalFilter<"WalletBonus"> | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFilter<"WalletBonus"> | Date | string expiresAt?: DateTimeFilter<"WalletBonus"> | Date | string consumedAt?: DateTimeNullableFilter<"WalletBonus"> | Date | string | null isActive?: BoolFilter<"WalletBonus"> | boolean customer?: XOR } export type WalletBonusOrderByWithRelationInput = { id?: SortOrder customerId?: SortOrder orderId?: SortOrderInput | SortOrder goldGrams?: SortOrder grantedAt?: SortOrder expiresAt?: SortOrder consumedAt?: SortOrderInput | SortOrder isActive?: SortOrder customer?: CustomerOrderByWithRelationInput } export type WalletBonusWhereUniqueInput = Prisma.AtLeast<{ id?: string AND?: WalletBonusWhereInput | WalletBonusWhereInput[] OR?: WalletBonusWhereInput[] NOT?: WalletBonusWhereInput | WalletBonusWhereInput[] customerId?: StringFilter<"WalletBonus"> | string orderId?: StringNullableFilter<"WalletBonus"> | string | null goldGrams?: DecimalFilter<"WalletBonus"> | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFilter<"WalletBonus"> | Date | string expiresAt?: DateTimeFilter<"WalletBonus"> | Date | string consumedAt?: DateTimeNullableFilter<"WalletBonus"> | Date | string | null isActive?: BoolFilter<"WalletBonus"> | boolean customer?: XOR }, "id"> export type WalletBonusOrderByWithAggregationInput = { id?: SortOrder customerId?: SortOrder orderId?: SortOrderInput | SortOrder goldGrams?: SortOrder grantedAt?: SortOrder expiresAt?: SortOrder consumedAt?: SortOrderInput | SortOrder isActive?: SortOrder _count?: WalletBonusCountOrderByAggregateInput _avg?: WalletBonusAvgOrderByAggregateInput _max?: WalletBonusMaxOrderByAggregateInput _min?: WalletBonusMinOrderByAggregateInput _sum?: WalletBonusSumOrderByAggregateInput } export type WalletBonusScalarWhereWithAggregatesInput = { AND?: WalletBonusScalarWhereWithAggregatesInput | WalletBonusScalarWhereWithAggregatesInput[] OR?: WalletBonusScalarWhereWithAggregatesInput[] NOT?: WalletBonusScalarWhereWithAggregatesInput | WalletBonusScalarWhereWithAggregatesInput[] id?: StringWithAggregatesFilter<"WalletBonus"> | string customerId?: StringWithAggregatesFilter<"WalletBonus"> | string orderId?: StringNullableWithAggregatesFilter<"WalletBonus"> | string | null goldGrams?: DecimalWithAggregatesFilter<"WalletBonus"> | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeWithAggregatesFilter<"WalletBonus"> | Date | string expiresAt?: DateTimeWithAggregatesFilter<"WalletBonus"> | Date | string consumedAt?: DateTimeNullableWithAggregatesFilter<"WalletBonus"> | Date | string | null isActive?: BoolWithAggregatesFilter<"WalletBonus"> | boolean } export type CityCreateInput = { id?: string name: string province?: string | null customers?: CustomerCreateNestedManyWithoutCityInput addresses?: CustomerAddressCreateNestedManyWithoutCityInput branches?: BranchCreateNestedManyWithoutCityInput preOrders?: PreOrderCreateNestedManyWithoutCityInput } export type CityUncheckedCreateInput = { id?: string name: string province?: string | null customers?: CustomerUncheckedCreateNestedManyWithoutCityInput addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCityInput branches?: BranchUncheckedCreateNestedManyWithoutCityInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCityInput } export type CityUpdateInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null customers?: CustomerUpdateManyWithoutCityNestedInput addresses?: CustomerAddressUpdateManyWithoutCityNestedInput branches?: BranchUpdateManyWithoutCityNestedInput preOrders?: PreOrderUpdateManyWithoutCityNestedInput } export type CityUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null customers?: CustomerUncheckedUpdateManyWithoutCityNestedInput addresses?: CustomerAddressUncheckedUpdateManyWithoutCityNestedInput branches?: BranchUncheckedUpdateManyWithoutCityNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCityNestedInput } export type CityCreateManyInput = { id?: string name: string province?: string | null } export type CityUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null } export type CityUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null } export type AdminUserCreateInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string branch?: BranchCreateNestedOneWithoutAdminUsersInput referredCustomers?: CustomerCreateNestedManyWithoutReferredByAgentInput postedLedgerEntries?: LedgerEntryCreateNestedManyWithoutPostedByAdminUserInput orderStatusEvents?: OrderStatusEventCreateNestedManyWithoutActorAdminUserInput preOrderStatusEvents?: PreOrderStatusEventCreateNestedManyWithoutActorAdminUserInput } export type AdminUserUncheckedCreateInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole branchId?: string | null wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string referredCustomers?: CustomerUncheckedCreateNestedManyWithoutReferredByAgentInput postedLedgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutPostedByAdminUserInput orderStatusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput preOrderStatusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput } export type AdminUserUpdateInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string branch?: BranchUpdateOneWithoutAdminUsersNestedInput referredCustomers?: CustomerUpdateManyWithoutReferredByAgentNestedInput postedLedgerEntries?: LedgerEntryUpdateManyWithoutPostedByAdminUserNestedInput orderStatusEvents?: OrderStatusEventUpdateManyWithoutActorAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUpdateManyWithoutActorAdminUserNestedInput } export type AdminUserUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole branchId?: NullableStringFieldUpdateOperationsInput | string | null wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string referredCustomers?: CustomerUncheckedUpdateManyWithoutReferredByAgentNestedInput postedLedgerEntries?: LedgerEntryUncheckedUpdateManyWithoutPostedByAdminUserNestedInput orderStatusEvents?: OrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput } export type AdminUserCreateManyInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole branchId?: string | null wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string } export type AdminUserUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type AdminUserUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole branchId?: NullableStringFieldUpdateOperationsInput | string | null wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type CustomerCreateInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string city?: CityCreateNestedOneWithoutCustomersInput referredByAgent?: AdminUserCreateNestedOneWithoutReferredCustomersInput addresses?: CustomerAddressCreateNestedManyWithoutCustomerInput orders?: OrderCreateNestedManyWithoutCustomerInput preOrders?: PreOrderCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusCreateNestedManyWithoutCustomerInput } export type CustomerUncheckedCreateInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput orders?: OrderUncheckedCreateNestedManyWithoutCustomerInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusUncheckedCreateNestedManyWithoutCustomerInput } export type CustomerUpdateInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string city?: CityUpdateOneWithoutCustomersNestedInput referredByAgent?: AdminUserUpdateOneWithoutReferredCustomersNestedInput addresses?: CustomerAddressUpdateManyWithoutCustomerNestedInput orders?: OrderUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string addresses?: CustomerAddressUncheckedUpdateManyWithoutCustomerNestedInput orders?: OrderUncheckedUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUncheckedUpdateManyWithoutCustomerNestedInput } export type CustomerCreateManyInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string } export type CustomerUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type CustomerUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type CustomerAddressCreateInput = { id?: string addressLine: string isDefault?: boolean customer: CustomerCreateNestedOneWithoutAddressesInput city?: CityCreateNestedOneWithoutAddressesInput } export type CustomerAddressUncheckedCreateInput = { id?: string customerId: string cityId?: string | null addressLine: string isDefault?: boolean } export type CustomerAddressUpdateInput = { id?: StringFieldUpdateOperationsInput | string addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean customer?: CustomerUpdateOneRequiredWithoutAddressesNestedInput city?: CityUpdateOneWithoutAddressesNestedInput } export type CustomerAddressUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean } export type CustomerAddressCreateManyInput = { id?: string customerId: string cityId?: string | null addressLine: string isDefault?: boolean } export type CustomerAddressUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean } export type CustomerAddressUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean } export type BranchCreateInput = { id?: string name: string city?: CityCreateNestedOneWithoutBranchesInput adminUsers?: AdminUserCreateNestedManyWithoutBranchInput orders?: OrderCreateNestedManyWithoutBranchInput } export type BranchUncheckedCreateInput = { id?: string name: string cityId?: string | null adminUsers?: AdminUserUncheckedCreateNestedManyWithoutBranchInput orders?: OrderUncheckedCreateNestedManyWithoutBranchInput } export type BranchUpdateInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string city?: CityUpdateOneWithoutBranchesNestedInput adminUsers?: AdminUserUpdateManyWithoutBranchNestedInput orders?: OrderUpdateManyWithoutBranchNestedInput } export type BranchUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null adminUsers?: AdminUserUncheckedUpdateManyWithoutBranchNestedInput orders?: OrderUncheckedUpdateManyWithoutBranchNestedInput } export type BranchCreateManyInput = { id?: string name: string cityId?: string | null } export type BranchUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string } export type BranchUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null } export type WorkshopCreateInput = { id?: string name: string isActive?: boolean preOrders?: PreOrderCreateNestedManyWithoutWorkshopInput } export type WorkshopUncheckedCreateInput = { id?: string name: string isActive?: boolean preOrders?: PreOrderUncheckedCreateNestedManyWithoutWorkshopInput } export type WorkshopUpdateInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string isActive?: BoolFieldUpdateOperationsInput | boolean preOrders?: PreOrderUpdateManyWithoutWorkshopNestedInput } export type WorkshopUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string isActive?: BoolFieldUpdateOperationsInput | boolean preOrders?: PreOrderUncheckedUpdateManyWithoutWorkshopNestedInput } export type WorkshopCreateManyInput = { id?: string name: string isActive?: boolean } export type WorkshopUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string isActive?: BoolFieldUpdateOperationsInput | boolean } export type WorkshopUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string isActive?: BoolFieldUpdateOperationsInput | boolean } export type CategoryCreateInput = { id?: string title: string parent?: CategoryCreateNestedOneWithoutChildrenInput children?: CategoryCreateNestedManyWithoutParentInput products?: ProductCreateNestedManyWithoutCategoryInput } export type CategoryUncheckedCreateInput = { id?: string title: string parentId?: string | null children?: CategoryUncheckedCreateNestedManyWithoutParentInput products?: ProductUncheckedCreateNestedManyWithoutCategoryInput } export type CategoryUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string parent?: CategoryUpdateOneWithoutChildrenNestedInput children?: CategoryUpdateManyWithoutParentNestedInput products?: ProductUpdateManyWithoutCategoryNestedInput } export type CategoryUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string parentId?: NullableStringFieldUpdateOperationsInput | string | null children?: CategoryUncheckedUpdateManyWithoutParentNestedInput products?: ProductUncheckedUpdateManyWithoutCategoryNestedInput } export type CategoryCreateManyInput = { id?: string title: string parentId?: string | null } export type CategoryUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string } export type CategoryUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string parentId?: NullableStringFieldUpdateOperationsInput | string | null } export type BrandCreateInput = { id?: string title: string products?: ProductCreateNestedManyWithoutBrandInput } export type BrandUncheckedCreateInput = { id?: string title: string products?: ProductUncheckedCreateNestedManyWithoutBrandInput } export type BrandUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string products?: ProductUpdateManyWithoutBrandNestedInput } export type BrandUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string products?: ProductUncheckedUpdateManyWithoutBrandNestedInput } export type BrandCreateManyInput = { id?: string title: string } export type BrandUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string } export type BrandUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string } export type CollectionCreateInput = { id?: string title: string description?: string | null isActive?: boolean products?: CollectionProductCreateNestedManyWithoutCollectionInput } export type CollectionUncheckedCreateInput = { id?: string title: string description?: string | null isActive?: boolean products?: CollectionProductUncheckedCreateNestedManyWithoutCollectionInput } export type CollectionUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean products?: CollectionProductUpdateManyWithoutCollectionNestedInput } export type CollectionUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean products?: CollectionProductUncheckedUpdateManyWithoutCollectionNestedInput } export type CollectionCreateManyInput = { id?: string title: string description?: string | null isActive?: boolean } export type CollectionUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type CollectionUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type CollectionProductCreateInput = { collection: CollectionCreateNestedOneWithoutProductsInput product: ProductCreateNestedOneWithoutCollectionsInput } export type CollectionProductUncheckedCreateInput = { collectionId: string productId: string } export type CollectionProductUpdateInput = { collection?: CollectionUpdateOneRequiredWithoutProductsNestedInput product?: ProductUpdateOneRequiredWithoutCollectionsNestedInput } export type CollectionProductUncheckedUpdateInput = { collectionId?: StringFieldUpdateOperationsInput | string productId?: StringFieldUpdateOperationsInput | string } export type CollectionProductCreateManyInput = { collectionId: string productId: string } export type CollectionProductUpdateManyMutationInput = { } export type CollectionProductUncheckedUpdateManyInput = { collectionId?: StringFieldUpdateOperationsInput | string productId?: StringFieldUpdateOperationsInput | string } export type ProductCreateInput = { id?: string title: string description?: string | null isActive?: boolean createdAt?: Date | string category?: CategoryCreateNestedOneWithoutProductsInput brand?: BrandCreateNestedOneWithoutProductsInput variants?: ProductVariantCreateNestedManyWithoutProductInput images?: ProductImageCreateNestedManyWithoutProductInput collections?: CollectionProductCreateNestedManyWithoutProductInput } export type ProductUncheckedCreateInput = { id?: string title: string description?: string | null categoryId?: string | null brandId?: string | null isActive?: boolean createdAt?: Date | string variants?: ProductVariantUncheckedCreateNestedManyWithoutProductInput images?: ProductImageUncheckedCreateNestedManyWithoutProductInput collections?: CollectionProductUncheckedCreateNestedManyWithoutProductInput } export type ProductUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string category?: CategoryUpdateOneWithoutProductsNestedInput brand?: BrandUpdateOneWithoutProductsNestedInput variants?: ProductVariantUpdateManyWithoutProductNestedInput images?: ProductImageUpdateManyWithoutProductNestedInput collections?: CollectionProductUpdateManyWithoutProductNestedInput } export type ProductUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null categoryId?: NullableStringFieldUpdateOperationsInput | string | null brandId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string variants?: ProductVariantUncheckedUpdateManyWithoutProductNestedInput images?: ProductImageUncheckedUpdateManyWithoutProductNestedInput collections?: CollectionProductUncheckedUpdateManyWithoutProductNestedInput } export type ProductCreateManyInput = { id?: string title: string description?: string | null categoryId?: string | null brandId?: string | null isActive?: boolean createdAt?: Date | string } export type ProductUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type ProductUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null categoryId?: NullableStringFieldUpdateOperationsInput | string | null brandId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type ProductImageCreateInput = { id?: string url: string sortOrder?: number product: ProductCreateNestedOneWithoutImagesInput } export type ProductImageUncheckedCreateInput = { id?: string productId: string url: string sortOrder?: number } export type ProductImageUpdateInput = { id?: StringFieldUpdateOperationsInput | string url?: StringFieldUpdateOperationsInput | string sortOrder?: IntFieldUpdateOperationsInput | number product?: ProductUpdateOneRequiredWithoutImagesNestedInput } export type ProductImageUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string productId?: StringFieldUpdateOperationsInput | string url?: StringFieldUpdateOperationsInput | string sortOrder?: IntFieldUpdateOperationsInput | number } export type ProductImageCreateManyInput = { id?: string productId: string url: string sortOrder?: number } export type ProductImageUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string url?: StringFieldUpdateOperationsInput | string sortOrder?: IntFieldUpdateOperationsInput | number } export type ProductImageUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string productId?: StringFieldUpdateOperationsInput | string url?: StringFieldUpdateOperationsInput | string sortOrder?: IntFieldUpdateOperationsInput | number } export type ProductVariantCreateInput = { id?: string title: string sku?: string | null rashWeightGrams: Decimal | DecimalJsLike | number | string defaultWagePercent: Decimal | DecimalJsLike | number | string isActive?: boolean product: ProductCreateNestedOneWithoutVariantsInput orderItems?: OrderItemCreateNestedManyWithoutProductVariantInput } export type ProductVariantUncheckedCreateInput = { id?: string productId: string title: string sku?: string | null rashWeightGrams: Decimal | DecimalJsLike | number | string defaultWagePercent: Decimal | DecimalJsLike | number | string isActive?: boolean orderItems?: OrderItemUncheckedCreateNestedManyWithoutProductVariantInput } export type ProductVariantUpdateInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean product?: ProductUpdateOneRequiredWithoutVariantsNestedInput orderItems?: OrderItemUpdateManyWithoutProductVariantNestedInput } export type ProductVariantUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string productId?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean orderItems?: OrderItemUncheckedUpdateManyWithoutProductVariantNestedInput } export type ProductVariantCreateManyInput = { id?: string productId: string title: string sku?: string | null rashWeightGrams: Decimal | DecimalJsLike | number | string defaultWagePercent: Decimal | DecimalJsLike | number | string isActive?: boolean } export type ProductVariantUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean } export type ProductVariantUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string productId?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean } export type OrderCreateInput = { id?: string orderNumber: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutOrdersInput branch?: BranchCreateNestedOneWithoutOrdersInput items?: OrderItemCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderCreateNestedOneWithoutConvertedOrderInput } export type OrderUncheckedCreateInput = { id?: string orderNumber: string customerId: string branchId?: string | null status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string items?: OrderItemUncheckedCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderUncheckedCreateNestedOneWithoutConvertedOrderInput } export type OrderUpdateInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutOrdersNestedInput branch?: BranchUpdateOneWithoutOrdersNestedInput items?: OrderItemUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUpdateOneWithoutConvertedOrderNestedInput } export type OrderUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string branchId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string items?: OrderItemUncheckedUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUncheckedUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUncheckedUpdateOneWithoutConvertedOrderNestedInput } export type OrderCreateManyInput = { id?: string orderNumber: string customerId: string branchId?: string | null status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string } export type OrderUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type OrderUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string branchId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type OrderItemCreateInput = { id?: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string order: OrderCreateNestedOneWithoutItemsInput productVariant: ProductVariantCreateNestedOneWithoutOrderItemsInput } export type OrderItemUncheckedCreateInput = { id?: string orderId: string productVariantId: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string } export type OrderItemUpdateInput = { id?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string order?: OrderUpdateOneRequiredWithoutItemsNestedInput productVariant?: ProductVariantUpdateOneRequiredWithoutOrderItemsNestedInput } export type OrderItemUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string orderId?: StringFieldUpdateOperationsInput | string productVariantId?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string } export type OrderItemCreateManyInput = { id?: string orderId: string productVariantId: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string } export type OrderItemUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string } export type OrderItemUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string orderId?: StringFieldUpdateOperationsInput | string productVariantId?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string } export type OrderStatusEventCreateInput = { id?: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null createdAt?: Date | string order: OrderCreateNestedOneWithoutStatusEventsInput actorAdminUser?: AdminUserCreateNestedOneWithoutOrderStatusEventsInput } export type OrderStatusEventUncheckedCreateInput = { id?: string orderId: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null actorAdminUserId?: string | null createdAt?: Date | string } export type OrderStatusEventUpdateInput = { id?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string order?: OrderUpdateOneRequiredWithoutStatusEventsNestedInput actorAdminUser?: AdminUserUpdateOneWithoutOrderStatusEventsNestedInput } export type OrderStatusEventUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string orderId?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null actorAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type OrderStatusEventCreateManyInput = { id?: string orderId: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null actorAdminUserId?: string | null createdAt?: Date | string } export type OrderStatusEventUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type OrderStatusEventUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string orderId?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null actorAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderCreateInput = { id?: string status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutPreOrdersInput city?: CityCreateNestedOneWithoutPreOrdersInput workshop?: WorkshopCreateNestedOneWithoutPreOrdersInput convertedOrder?: OrderCreateNestedOneWithoutConvertedFromPreOrderInput statusEvents?: PreOrderStatusEventCreateNestedManyWithoutPreOrderInput } export type PreOrderUncheckedCreateInput = { id?: string customerId: string cityId?: string | null workshopId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string statusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutPreOrderInput } export type PreOrderUpdateInput = { id?: StringFieldUpdateOperationsInput | string status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutPreOrdersNestedInput city?: CityUpdateOneWithoutPreOrdersNestedInput workshop?: WorkshopUpdateOneWithoutPreOrdersNestedInput convertedOrder?: OrderUpdateOneWithoutConvertedFromPreOrderNestedInput statusEvents?: PreOrderStatusEventUpdateManyWithoutPreOrderNestedInput } export type PreOrderUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null workshopId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string statusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutPreOrderNestedInput } export type PreOrderCreateManyInput = { id?: string customerId: string cityId?: string | null workshopId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string } export type PreOrderUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null workshopId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderStatusEventCreateInput = { id?: string changes: JsonNullValueInput | InputJsonValue ipAddress?: string | null createdAt?: Date | string preOrder: PreOrderCreateNestedOneWithoutStatusEventsInput actorAdminUser?: AdminUserCreateNestedOneWithoutPreOrderStatusEventsInput } export type PreOrderStatusEventUncheckedCreateInput = { id?: string preOrderId: string changes: JsonNullValueInput | InputJsonValue actorAdminUserId?: string | null ipAddress?: string | null createdAt?: Date | string } export type PreOrderStatusEventUpdateInput = { id?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string preOrder?: PreOrderUpdateOneRequiredWithoutStatusEventsNestedInput actorAdminUser?: AdminUserUpdateOneWithoutPreOrderStatusEventsNestedInput } export type PreOrderStatusEventUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string preOrderId?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue actorAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderStatusEventCreateManyInput = { id?: string preOrderId: string changes: JsonNullValueInput | InputJsonValue actorAdminUserId?: string | null ipAddress?: string | null createdAt?: Date | string } export type PreOrderStatusEventUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderStatusEventUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string preOrderId?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue actorAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryCreateInput = { id?: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null confirmed?: boolean confirmedAt?: Date | string | null note?: string | null createdAt?: Date | string customer: CustomerCreateNestedOneWithoutLedgerEntriesInput order?: OrderCreateNestedOneWithoutLedgerEntriesInput postedByAdminUser?: AdminUserCreateNestedOneWithoutPostedLedgerEntriesInput } export type LedgerEntryUncheckedCreateInput = { id?: string customerId: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null orderId?: string | null confirmed?: boolean confirmedAt?: Date | string | null postedByAdminUserId?: string | null note?: string | null createdAt?: Date | string } export type LedgerEntryUpdateInput = { id?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutLedgerEntriesNestedInput order?: OrderUpdateOneWithoutLedgerEntriesNestedInput postedByAdminUser?: AdminUserUpdateOneWithoutPostedLedgerEntriesNestedInput } export type LedgerEntryUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null orderId?: NullableStringFieldUpdateOperationsInput | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null postedByAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryCreateManyInput = { id?: string customerId: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null orderId?: string | null confirmed?: boolean confirmedAt?: Date | string | null postedByAdminUserId?: string | null note?: string | null createdAt?: Date | string } export type LedgerEntryUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null orderId?: NullableStringFieldUpdateOperationsInput | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null postedByAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type GoldPriceQuoteCreateInput = { id?: string karatPerMille: number pricePerGramRial: Decimal | DecimalJsLike | number | string source: string quotedAt?: Date | string } export type GoldPriceQuoteUncheckedCreateInput = { id?: string karatPerMille: number pricePerGramRial: Decimal | DecimalJsLike | number | string source: string quotedAt?: Date | string } export type GoldPriceQuoteUpdateInput = { id?: StringFieldUpdateOperationsInput | string karatPerMille?: IntFieldUpdateOperationsInput | number pricePerGramRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string source?: StringFieldUpdateOperationsInput | string quotedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type GoldPriceQuoteUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string karatPerMille?: IntFieldUpdateOperationsInput | number pricePerGramRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string source?: StringFieldUpdateOperationsInput | string quotedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type GoldPriceQuoteCreateManyInput = { id?: string karatPerMille: number pricePerGramRial: Decimal | DecimalJsLike | number | string source: string quotedAt?: Date | string } export type GoldPriceQuoteUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string karatPerMille?: IntFieldUpdateOperationsInput | number pricePerGramRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string source?: StringFieldUpdateOperationsInput | string quotedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type GoldPriceQuoteUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string karatPerMille?: IntFieldUpdateOperationsInput | number pricePerGramRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string source?: StringFieldUpdateOperationsInput | string quotedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type WalletBonusCreateInput = { id?: string orderId?: string | null goldGrams: Decimal | DecimalJsLike | number | string grantedAt?: Date | string expiresAt: Date | string consumedAt?: Date | string | null isActive?: boolean customer: CustomerCreateNestedOneWithoutWalletBonusesInput } export type WalletBonusUncheckedCreateInput = { id?: string customerId: string orderId?: string | null goldGrams: Decimal | DecimalJsLike | number | string grantedAt?: Date | string expiresAt: Date | string consumedAt?: Date | string | null isActive?: boolean } export type WalletBonusUpdateInput = { id?: StringFieldUpdateOperationsInput | string orderId?: NullableStringFieldUpdateOperationsInput | string | null goldGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFieldUpdateOperationsInput | Date | string expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string consumedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null isActive?: BoolFieldUpdateOperationsInput | boolean customer?: CustomerUpdateOneRequiredWithoutWalletBonusesNestedInput } export type WalletBonusUncheckedUpdateInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string orderId?: NullableStringFieldUpdateOperationsInput | string | null goldGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFieldUpdateOperationsInput | Date | string expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string consumedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type WalletBonusCreateManyInput = { id?: string customerId: string orderId?: string | null goldGrams: Decimal | DecimalJsLike | number | string grantedAt?: Date | string expiresAt: Date | string consumedAt?: Date | string | null isActive?: boolean } export type WalletBonusUpdateManyMutationInput = { id?: StringFieldUpdateOperationsInput | string orderId?: NullableStringFieldUpdateOperationsInput | string | null goldGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFieldUpdateOperationsInput | Date | string expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string consumedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type WalletBonusUncheckedUpdateManyInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string orderId?: NullableStringFieldUpdateOperationsInput | string | null goldGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFieldUpdateOperationsInput | Date | string expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string consumedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type StringFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> in?: string[] | ListStringFieldRefInput<$PrismaModel> notIn?: string[] | ListStringFieldRefInput<$PrismaModel> lt?: string | StringFieldRefInput<$PrismaModel> lte?: string | StringFieldRefInput<$PrismaModel> gt?: string | StringFieldRefInput<$PrismaModel> gte?: string | StringFieldRefInput<$PrismaModel> contains?: string | StringFieldRefInput<$PrismaModel> startsWith?: string | StringFieldRefInput<$PrismaModel> endsWith?: string | StringFieldRefInput<$PrismaModel> mode?: QueryMode not?: NestedStringFilter<$PrismaModel> | string } export type StringNullableFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> | null in?: string[] | ListStringFieldRefInput<$PrismaModel> | null notIn?: string[] | ListStringFieldRefInput<$PrismaModel> | null lt?: string | StringFieldRefInput<$PrismaModel> lte?: string | StringFieldRefInput<$PrismaModel> gt?: string | StringFieldRefInput<$PrismaModel> gte?: string | StringFieldRefInput<$PrismaModel> contains?: string | StringFieldRefInput<$PrismaModel> startsWith?: string | StringFieldRefInput<$PrismaModel> endsWith?: string | StringFieldRefInput<$PrismaModel> mode?: QueryMode not?: NestedStringNullableFilter<$PrismaModel> | string | null } export type CustomerListRelationFilter = { every?: CustomerWhereInput some?: CustomerWhereInput none?: CustomerWhereInput } export type CustomerAddressListRelationFilter = { every?: CustomerAddressWhereInput some?: CustomerAddressWhereInput none?: CustomerAddressWhereInput } export type BranchListRelationFilter = { every?: BranchWhereInput some?: BranchWhereInput none?: BranchWhereInput } export type PreOrderListRelationFilter = { every?: PreOrderWhereInput some?: PreOrderWhereInput none?: PreOrderWhereInput } export type SortOrderInput = { sort: SortOrder nulls?: NullsOrder } export type CustomerOrderByRelationAggregateInput = { _count?: SortOrder } export type CustomerAddressOrderByRelationAggregateInput = { _count?: SortOrder } export type BranchOrderByRelationAggregateInput = { _count?: SortOrder } export type PreOrderOrderByRelationAggregateInput = { _count?: SortOrder } export type CityCountOrderByAggregateInput = { id?: SortOrder name?: SortOrder province?: SortOrder } export type CityMaxOrderByAggregateInput = { id?: SortOrder name?: SortOrder province?: SortOrder } export type CityMinOrderByAggregateInput = { id?: SortOrder name?: SortOrder province?: SortOrder } export type StringWithAggregatesFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> in?: string[] | ListStringFieldRefInput<$PrismaModel> notIn?: string[] | ListStringFieldRefInput<$PrismaModel> lt?: string | StringFieldRefInput<$PrismaModel> lte?: string | StringFieldRefInput<$PrismaModel> gt?: string | StringFieldRefInput<$PrismaModel> gte?: string | StringFieldRefInput<$PrismaModel> contains?: string | StringFieldRefInput<$PrismaModel> startsWith?: string | StringFieldRefInput<$PrismaModel> endsWith?: string | StringFieldRefInput<$PrismaModel> mode?: QueryMode not?: NestedStringWithAggregatesFilter<$PrismaModel> | string _count?: NestedIntFilter<$PrismaModel> _min?: NestedStringFilter<$PrismaModel> _max?: NestedStringFilter<$PrismaModel> } export type StringNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> | null in?: string[] | ListStringFieldRefInput<$PrismaModel> | null notIn?: string[] | ListStringFieldRefInput<$PrismaModel> | null lt?: string | StringFieldRefInput<$PrismaModel> lte?: string | StringFieldRefInput<$PrismaModel> gt?: string | StringFieldRefInput<$PrismaModel> gte?: string | StringFieldRefInput<$PrismaModel> contains?: string | StringFieldRefInput<$PrismaModel> startsWith?: string | StringFieldRefInput<$PrismaModel> endsWith?: string | StringFieldRefInput<$PrismaModel> mode?: QueryMode not?: NestedStringNullableWithAggregatesFilter<$PrismaModel> | string | null _count?: NestedIntNullableFilter<$PrismaModel> _min?: NestedStringNullableFilter<$PrismaModel> _max?: NestedStringNullableFilter<$PrismaModel> } export type EnumAdminRoleFilter<$PrismaModel = never> = { equals?: $Enums.AdminRole | EnumAdminRoleFieldRefInput<$PrismaModel> in?: $Enums.AdminRole[] | ListEnumAdminRoleFieldRefInput<$PrismaModel> notIn?: $Enums.AdminRole[] | ListEnumAdminRoleFieldRefInput<$PrismaModel> not?: NestedEnumAdminRoleFilter<$PrismaModel> | $Enums.AdminRole } export type DecimalNullableFilter<$PrismaModel = never> = { equals?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> | null in?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> | null notIn?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> | null lt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> lte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> not?: NestedDecimalNullableFilter<$PrismaModel> | Decimal | DecimalJsLike | number | string | null } export type BoolFilter<$PrismaModel = never> = { equals?: boolean | BooleanFieldRefInput<$PrismaModel> not?: NestedBoolFilter<$PrismaModel> | boolean } export type DateTimeFilter<$PrismaModel = never> = { equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> not?: NestedDateTimeFilter<$PrismaModel> | Date | string } export type BranchNullableRelationFilter = { is?: BranchWhereInput | null isNot?: BranchWhereInput | null } export type LedgerEntryListRelationFilter = { every?: LedgerEntryWhereInput some?: LedgerEntryWhereInput none?: LedgerEntryWhereInput } export type OrderStatusEventListRelationFilter = { every?: OrderStatusEventWhereInput some?: OrderStatusEventWhereInput none?: OrderStatusEventWhereInput } export type PreOrderStatusEventListRelationFilter = { every?: PreOrderStatusEventWhereInput some?: PreOrderStatusEventWhereInput none?: PreOrderStatusEventWhereInput } export type LedgerEntryOrderByRelationAggregateInput = { _count?: SortOrder } export type OrderStatusEventOrderByRelationAggregateInput = { _count?: SortOrder } export type PreOrderStatusEventOrderByRelationAggregateInput = { _count?: SortOrder } export type AdminUserCountOrderByAggregateInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder passwordHash?: SortOrder role?: SortOrder branchId?: SortOrder wagePercent?: SortOrder isActive?: SortOrder createdAt?: SortOrder } export type AdminUserAvgOrderByAggregateInput = { wagePercent?: SortOrder } export type AdminUserMaxOrderByAggregateInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder passwordHash?: SortOrder role?: SortOrder branchId?: SortOrder wagePercent?: SortOrder isActive?: SortOrder createdAt?: SortOrder } export type AdminUserMinOrderByAggregateInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder passwordHash?: SortOrder role?: SortOrder branchId?: SortOrder wagePercent?: SortOrder isActive?: SortOrder createdAt?: SortOrder } export type AdminUserSumOrderByAggregateInput = { wagePercent?: SortOrder } export type EnumAdminRoleWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.AdminRole | EnumAdminRoleFieldRefInput<$PrismaModel> in?: $Enums.AdminRole[] | ListEnumAdminRoleFieldRefInput<$PrismaModel> notIn?: $Enums.AdminRole[] | ListEnumAdminRoleFieldRefInput<$PrismaModel> not?: NestedEnumAdminRoleWithAggregatesFilter<$PrismaModel> | $Enums.AdminRole _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumAdminRoleFilter<$PrismaModel> _max?: NestedEnumAdminRoleFilter<$PrismaModel> } export type DecimalNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> | null in?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> | null notIn?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> | null lt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> lte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> not?: NestedDecimalNullableWithAggregatesFilter<$PrismaModel> | Decimal | DecimalJsLike | number | string | null _count?: NestedIntNullableFilter<$PrismaModel> _avg?: NestedDecimalNullableFilter<$PrismaModel> _sum?: NestedDecimalNullableFilter<$PrismaModel> _min?: NestedDecimalNullableFilter<$PrismaModel> _max?: NestedDecimalNullableFilter<$PrismaModel> } export type BoolWithAggregatesFilter<$PrismaModel = never> = { equals?: boolean | BooleanFieldRefInput<$PrismaModel> not?: NestedBoolWithAggregatesFilter<$PrismaModel> | boolean _count?: NestedIntFilter<$PrismaModel> _min?: NestedBoolFilter<$PrismaModel> _max?: NestedBoolFilter<$PrismaModel> } export type DateTimeWithAggregatesFilter<$PrismaModel = never> = { equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> not?: NestedDateTimeWithAggregatesFilter<$PrismaModel> | Date | string _count?: NestedIntFilter<$PrismaModel> _min?: NestedDateTimeFilter<$PrismaModel> _max?: NestedDateTimeFilter<$PrismaModel> } export type DecimalFilter<$PrismaModel = never> = { equals?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> in?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> notIn?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> lt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> lte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> not?: NestedDecimalFilter<$PrismaModel> | Decimal | DecimalJsLike | number | string } export type EnumVerificationStepFilter<$PrismaModel = never> = { equals?: $Enums.VerificationStep | EnumVerificationStepFieldRefInput<$PrismaModel> in?: $Enums.VerificationStep[] | ListEnumVerificationStepFieldRefInput<$PrismaModel> notIn?: $Enums.VerificationStep[] | ListEnumVerificationStepFieldRefInput<$PrismaModel> not?: NestedEnumVerificationStepFilter<$PrismaModel> | $Enums.VerificationStep } export type CityNullableRelationFilter = { is?: CityWhereInput | null isNot?: CityWhereInput | null } export type AdminUserNullableRelationFilter = { is?: AdminUserWhereInput | null isNot?: AdminUserWhereInput | null } export type OrderListRelationFilter = { every?: OrderWhereInput some?: OrderWhereInput none?: OrderWhereInput } export type WalletBonusListRelationFilter = { every?: WalletBonusWhereInput some?: WalletBonusWhereInput none?: WalletBonusWhereInput } export type OrderOrderByRelationAggregateInput = { _count?: SortOrder } export type WalletBonusOrderByRelationAggregateInput = { _count?: SortOrder } export type CustomerCountOrderByAggregateInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder nationalCode?: SortOrder passwordHash?: SortOrder cityId?: SortOrder referredByAgentId?: SortOrder goldCreditLimitGrams?: SortOrder goldDebtGrams?: SortOrder fiatDebtRial?: SortOrder verificationStep?: SortOrder nationalIdImageUrl?: SortOrder businessLicenseUrl?: SortOrder shopImageUrl?: SortOrder isActive?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CustomerAvgOrderByAggregateInput = { goldCreditLimitGrams?: SortOrder goldDebtGrams?: SortOrder fiatDebtRial?: SortOrder } export type CustomerMaxOrderByAggregateInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder nationalCode?: SortOrder passwordHash?: SortOrder cityId?: SortOrder referredByAgentId?: SortOrder goldCreditLimitGrams?: SortOrder goldDebtGrams?: SortOrder fiatDebtRial?: SortOrder verificationStep?: SortOrder nationalIdImageUrl?: SortOrder businessLicenseUrl?: SortOrder shopImageUrl?: SortOrder isActive?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CustomerMinOrderByAggregateInput = { id?: SortOrder fullName?: SortOrder mobile?: SortOrder nationalCode?: SortOrder passwordHash?: SortOrder cityId?: SortOrder referredByAgentId?: SortOrder goldCreditLimitGrams?: SortOrder goldDebtGrams?: SortOrder fiatDebtRial?: SortOrder verificationStep?: SortOrder nationalIdImageUrl?: SortOrder businessLicenseUrl?: SortOrder shopImageUrl?: SortOrder isActive?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type CustomerSumOrderByAggregateInput = { goldCreditLimitGrams?: SortOrder goldDebtGrams?: SortOrder fiatDebtRial?: SortOrder } export type DecimalWithAggregatesFilter<$PrismaModel = never> = { equals?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> in?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> notIn?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> lt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> lte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> not?: NestedDecimalWithAggregatesFilter<$PrismaModel> | Decimal | DecimalJsLike | number | string _count?: NestedIntFilter<$PrismaModel> _avg?: NestedDecimalFilter<$PrismaModel> _sum?: NestedDecimalFilter<$PrismaModel> _min?: NestedDecimalFilter<$PrismaModel> _max?: NestedDecimalFilter<$PrismaModel> } export type EnumVerificationStepWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.VerificationStep | EnumVerificationStepFieldRefInput<$PrismaModel> in?: $Enums.VerificationStep[] | ListEnumVerificationStepFieldRefInput<$PrismaModel> notIn?: $Enums.VerificationStep[] | ListEnumVerificationStepFieldRefInput<$PrismaModel> not?: NestedEnumVerificationStepWithAggregatesFilter<$PrismaModel> | $Enums.VerificationStep _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumVerificationStepFilter<$PrismaModel> _max?: NestedEnumVerificationStepFilter<$PrismaModel> } export type CustomerRelationFilter = { is?: CustomerWhereInput isNot?: CustomerWhereInput } export type CustomerAddressCountOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrder addressLine?: SortOrder isDefault?: SortOrder } export type CustomerAddressMaxOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrder addressLine?: SortOrder isDefault?: SortOrder } export type CustomerAddressMinOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrder addressLine?: SortOrder isDefault?: SortOrder } export type AdminUserListRelationFilter = { every?: AdminUserWhereInput some?: AdminUserWhereInput none?: AdminUserWhereInput } export type AdminUserOrderByRelationAggregateInput = { _count?: SortOrder } export type BranchCountOrderByAggregateInput = { id?: SortOrder name?: SortOrder cityId?: SortOrder } export type BranchMaxOrderByAggregateInput = { id?: SortOrder name?: SortOrder cityId?: SortOrder } export type BranchMinOrderByAggregateInput = { id?: SortOrder name?: SortOrder cityId?: SortOrder } export type WorkshopCountOrderByAggregateInput = { id?: SortOrder name?: SortOrder isActive?: SortOrder } export type WorkshopMaxOrderByAggregateInput = { id?: SortOrder name?: SortOrder isActive?: SortOrder } export type WorkshopMinOrderByAggregateInput = { id?: SortOrder name?: SortOrder isActive?: SortOrder } export type CategoryNullableRelationFilter = { is?: CategoryWhereInput | null isNot?: CategoryWhereInput | null } export type CategoryListRelationFilter = { every?: CategoryWhereInput some?: CategoryWhereInput none?: CategoryWhereInput } export type ProductListRelationFilter = { every?: ProductWhereInput some?: ProductWhereInput none?: ProductWhereInput } export type CategoryOrderByRelationAggregateInput = { _count?: SortOrder } export type ProductOrderByRelationAggregateInput = { _count?: SortOrder } export type CategoryCountOrderByAggregateInput = { id?: SortOrder title?: SortOrder parentId?: SortOrder } export type CategoryMaxOrderByAggregateInput = { id?: SortOrder title?: SortOrder parentId?: SortOrder } export type CategoryMinOrderByAggregateInput = { id?: SortOrder title?: SortOrder parentId?: SortOrder } export type BrandCountOrderByAggregateInput = { id?: SortOrder title?: SortOrder } export type BrandMaxOrderByAggregateInput = { id?: SortOrder title?: SortOrder } export type BrandMinOrderByAggregateInput = { id?: SortOrder title?: SortOrder } export type CollectionProductListRelationFilter = { every?: CollectionProductWhereInput some?: CollectionProductWhereInput none?: CollectionProductWhereInput } export type CollectionProductOrderByRelationAggregateInput = { _count?: SortOrder } export type CollectionCountOrderByAggregateInput = { id?: SortOrder title?: SortOrder description?: SortOrder isActive?: SortOrder } export type CollectionMaxOrderByAggregateInput = { id?: SortOrder title?: SortOrder description?: SortOrder isActive?: SortOrder } export type CollectionMinOrderByAggregateInput = { id?: SortOrder title?: SortOrder description?: SortOrder isActive?: SortOrder } export type CollectionRelationFilter = { is?: CollectionWhereInput isNot?: CollectionWhereInput } export type ProductRelationFilter = { is?: ProductWhereInput isNot?: ProductWhereInput } export type CollectionProductCollectionIdProductIdCompoundUniqueInput = { collectionId: string productId: string } export type CollectionProductCountOrderByAggregateInput = { collectionId?: SortOrder productId?: SortOrder } export type CollectionProductMaxOrderByAggregateInput = { collectionId?: SortOrder productId?: SortOrder } export type CollectionProductMinOrderByAggregateInput = { collectionId?: SortOrder productId?: SortOrder } export type BrandNullableRelationFilter = { is?: BrandWhereInput | null isNot?: BrandWhereInput | null } export type ProductVariantListRelationFilter = { every?: ProductVariantWhereInput some?: ProductVariantWhereInput none?: ProductVariantWhereInput } export type ProductImageListRelationFilter = { every?: ProductImageWhereInput some?: ProductImageWhereInput none?: ProductImageWhereInput } export type ProductVariantOrderByRelationAggregateInput = { _count?: SortOrder } export type ProductImageOrderByRelationAggregateInput = { _count?: SortOrder } export type ProductCountOrderByAggregateInput = { id?: SortOrder title?: SortOrder description?: SortOrder categoryId?: SortOrder brandId?: SortOrder isActive?: SortOrder createdAt?: SortOrder } export type ProductMaxOrderByAggregateInput = { id?: SortOrder title?: SortOrder description?: SortOrder categoryId?: SortOrder brandId?: SortOrder isActive?: SortOrder createdAt?: SortOrder } export type ProductMinOrderByAggregateInput = { id?: SortOrder title?: SortOrder description?: SortOrder categoryId?: SortOrder brandId?: SortOrder isActive?: SortOrder createdAt?: SortOrder } export type IntFilter<$PrismaModel = never> = { equals?: number | IntFieldRefInput<$PrismaModel> in?: number[] | ListIntFieldRefInput<$PrismaModel> notIn?: number[] | ListIntFieldRefInput<$PrismaModel> lt?: number | IntFieldRefInput<$PrismaModel> lte?: number | IntFieldRefInput<$PrismaModel> gt?: number | IntFieldRefInput<$PrismaModel> gte?: number | IntFieldRefInput<$PrismaModel> not?: NestedIntFilter<$PrismaModel> | number } export type ProductImageCountOrderByAggregateInput = { id?: SortOrder productId?: SortOrder url?: SortOrder sortOrder?: SortOrder } export type ProductImageAvgOrderByAggregateInput = { sortOrder?: SortOrder } export type ProductImageMaxOrderByAggregateInput = { id?: SortOrder productId?: SortOrder url?: SortOrder sortOrder?: SortOrder } export type ProductImageMinOrderByAggregateInput = { id?: SortOrder productId?: SortOrder url?: SortOrder sortOrder?: SortOrder } export type ProductImageSumOrderByAggregateInput = { sortOrder?: SortOrder } export type IntWithAggregatesFilter<$PrismaModel = never> = { equals?: number | IntFieldRefInput<$PrismaModel> in?: number[] | ListIntFieldRefInput<$PrismaModel> notIn?: number[] | ListIntFieldRefInput<$PrismaModel> lt?: number | IntFieldRefInput<$PrismaModel> lte?: number | IntFieldRefInput<$PrismaModel> gt?: number | IntFieldRefInput<$PrismaModel> gte?: number | IntFieldRefInput<$PrismaModel> not?: NestedIntWithAggregatesFilter<$PrismaModel> | number _count?: NestedIntFilter<$PrismaModel> _avg?: NestedFloatFilter<$PrismaModel> _sum?: NestedIntFilter<$PrismaModel> _min?: NestedIntFilter<$PrismaModel> _max?: NestedIntFilter<$PrismaModel> } export type OrderItemListRelationFilter = { every?: OrderItemWhereInput some?: OrderItemWhereInput none?: OrderItemWhereInput } export type OrderItemOrderByRelationAggregateInput = { _count?: SortOrder } export type ProductVariantCountOrderByAggregateInput = { id?: SortOrder productId?: SortOrder title?: SortOrder sku?: SortOrder rashWeightGrams?: SortOrder defaultWagePercent?: SortOrder isActive?: SortOrder } export type ProductVariantAvgOrderByAggregateInput = { rashWeightGrams?: SortOrder defaultWagePercent?: SortOrder } export type ProductVariantMaxOrderByAggregateInput = { id?: SortOrder productId?: SortOrder title?: SortOrder sku?: SortOrder rashWeightGrams?: SortOrder defaultWagePercent?: SortOrder isActive?: SortOrder } export type ProductVariantMinOrderByAggregateInput = { id?: SortOrder productId?: SortOrder title?: SortOrder sku?: SortOrder rashWeightGrams?: SortOrder defaultWagePercent?: SortOrder isActive?: SortOrder } export type ProductVariantSumOrderByAggregateInput = { rashWeightGrams?: SortOrder defaultWagePercent?: SortOrder } export type EnumOrderStatusFilter<$PrismaModel = never> = { equals?: $Enums.OrderStatus | EnumOrderStatusFieldRefInput<$PrismaModel> in?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> notIn?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> not?: NestedEnumOrderStatusFilter<$PrismaModel> | $Enums.OrderStatus } export type DateTimeNullableFilter<$PrismaModel = never> = { equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> | null in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> | null notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> | null lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> not?: NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null } export type PreOrderNullableRelationFilter = { is?: PreOrderWhereInput | null isNot?: PreOrderWhereInput | null } export type OrderCountOrderByAggregateInput = { id?: SortOrder orderNumber?: SortOrder customerId?: SortOrder branchId?: SortOrder status?: SortOrder totalGoldWeightGrams?: SortOrder wageWeightGrams?: SortOrder flatRialCharge?: SortOrder isSuspendedOverCreditLimit?: SortOrder deliveredAt?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type OrderAvgOrderByAggregateInput = { totalGoldWeightGrams?: SortOrder wageWeightGrams?: SortOrder flatRialCharge?: SortOrder } export type OrderMaxOrderByAggregateInput = { id?: SortOrder orderNumber?: SortOrder customerId?: SortOrder branchId?: SortOrder status?: SortOrder totalGoldWeightGrams?: SortOrder wageWeightGrams?: SortOrder flatRialCharge?: SortOrder isSuspendedOverCreditLimit?: SortOrder deliveredAt?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type OrderMinOrderByAggregateInput = { id?: SortOrder orderNumber?: SortOrder customerId?: SortOrder branchId?: SortOrder status?: SortOrder totalGoldWeightGrams?: SortOrder wageWeightGrams?: SortOrder flatRialCharge?: SortOrder isSuspendedOverCreditLimit?: SortOrder deliveredAt?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type OrderSumOrderByAggregateInput = { totalGoldWeightGrams?: SortOrder wageWeightGrams?: SortOrder flatRialCharge?: SortOrder } export type EnumOrderStatusWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.OrderStatus | EnumOrderStatusFieldRefInput<$PrismaModel> in?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> notIn?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> not?: NestedEnumOrderStatusWithAggregatesFilter<$PrismaModel> | $Enums.OrderStatus _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumOrderStatusFilter<$PrismaModel> _max?: NestedEnumOrderStatusFilter<$PrismaModel> } export type DateTimeNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> | null in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> | null notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> | null lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> not?: NestedDateTimeNullableWithAggregatesFilter<$PrismaModel> | Date | string | null _count?: NestedIntNullableFilter<$PrismaModel> _min?: NestedDateTimeNullableFilter<$PrismaModel> _max?: NestedDateTimeNullableFilter<$PrismaModel> } export type OrderRelationFilter = { is?: OrderWhereInput isNot?: OrderWhereInput } export type ProductVariantRelationFilter = { is?: ProductVariantWhereInput isNot?: ProductVariantWhereInput } export type OrderItemCountOrderByAggregateInput = { id?: SortOrder orderId?: SortOrder productVariantId?: SortOrder quantity?: SortOrder rashWeightGramsSnapshot?: SortOrder wagePercentSnapshot?: SortOrder discountPercentSnapshot?: SortOrder computedWeightGrams?: SortOrder flatRialCharge?: SortOrder } export type OrderItemAvgOrderByAggregateInput = { quantity?: SortOrder rashWeightGramsSnapshot?: SortOrder wagePercentSnapshot?: SortOrder discountPercentSnapshot?: SortOrder computedWeightGrams?: SortOrder flatRialCharge?: SortOrder } export type OrderItemMaxOrderByAggregateInput = { id?: SortOrder orderId?: SortOrder productVariantId?: SortOrder quantity?: SortOrder rashWeightGramsSnapshot?: SortOrder wagePercentSnapshot?: SortOrder discountPercentSnapshot?: SortOrder computedWeightGrams?: SortOrder flatRialCharge?: SortOrder } export type OrderItemMinOrderByAggregateInput = { id?: SortOrder orderId?: SortOrder productVariantId?: SortOrder quantity?: SortOrder rashWeightGramsSnapshot?: SortOrder wagePercentSnapshot?: SortOrder discountPercentSnapshot?: SortOrder computedWeightGrams?: SortOrder flatRialCharge?: SortOrder } export type OrderItemSumOrderByAggregateInput = { quantity?: SortOrder rashWeightGramsSnapshot?: SortOrder wagePercentSnapshot?: SortOrder discountPercentSnapshot?: SortOrder computedWeightGrams?: SortOrder flatRialCharge?: SortOrder } export type EnumOrderStatusNullableFilter<$PrismaModel = never> = { equals?: $Enums.OrderStatus | EnumOrderStatusFieldRefInput<$PrismaModel> | null in?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> | null notIn?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> | null not?: NestedEnumOrderStatusNullableFilter<$PrismaModel> | $Enums.OrderStatus | null } export type OrderStatusEventCountOrderByAggregateInput = { id?: SortOrder orderId?: SortOrder fromStatus?: SortOrder toStatus?: SortOrder note?: SortOrder actorAdminUserId?: SortOrder createdAt?: SortOrder } export type OrderStatusEventMaxOrderByAggregateInput = { id?: SortOrder orderId?: SortOrder fromStatus?: SortOrder toStatus?: SortOrder note?: SortOrder actorAdminUserId?: SortOrder createdAt?: SortOrder } export type OrderStatusEventMinOrderByAggregateInput = { id?: SortOrder orderId?: SortOrder fromStatus?: SortOrder toStatus?: SortOrder note?: SortOrder actorAdminUserId?: SortOrder createdAt?: SortOrder } export type EnumOrderStatusNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.OrderStatus | EnumOrderStatusFieldRefInput<$PrismaModel> | null in?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> | null notIn?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> | null not?: NestedEnumOrderStatusNullableWithAggregatesFilter<$PrismaModel> | $Enums.OrderStatus | null _count?: NestedIntNullableFilter<$PrismaModel> _min?: NestedEnumOrderStatusNullableFilter<$PrismaModel> _max?: NestedEnumOrderStatusNullableFilter<$PrismaModel> } export type EnumPreOrderStatusFilter<$PrismaModel = never> = { equals?: $Enums.PreOrderStatus | EnumPreOrderStatusFieldRefInput<$PrismaModel> in?: $Enums.PreOrderStatus[] | ListEnumPreOrderStatusFieldRefInput<$PrismaModel> notIn?: $Enums.PreOrderStatus[] | ListEnumPreOrderStatusFieldRefInput<$PrismaModel> not?: NestedEnumPreOrderStatusFilter<$PrismaModel> | $Enums.PreOrderStatus } export type WorkshopNullableRelationFilter = { is?: WorkshopWhereInput | null isNot?: WorkshopWhereInput | null } export type OrderNullableRelationFilter = { is?: OrderWhereInput | null isNot?: OrderWhereInput | null } export type PreOrderCountOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrder workshopId?: SortOrder status?: SortOrder designImageUrl?: SortOrder colorName?: SortOrder sizeSpec?: SortOrder stoneColor?: SortOrder minaColor?: SortOrder estimatedWeightGrams?: SortOrder estimatedPriceRial?: SortOrder description?: SortOrder convertedOrderId?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type PreOrderAvgOrderByAggregateInput = { estimatedWeightGrams?: SortOrder estimatedPriceRial?: SortOrder } export type PreOrderMaxOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrder workshopId?: SortOrder status?: SortOrder designImageUrl?: SortOrder colorName?: SortOrder sizeSpec?: SortOrder stoneColor?: SortOrder minaColor?: SortOrder estimatedWeightGrams?: SortOrder estimatedPriceRial?: SortOrder description?: SortOrder convertedOrderId?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type PreOrderMinOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder cityId?: SortOrder workshopId?: SortOrder status?: SortOrder designImageUrl?: SortOrder colorName?: SortOrder sizeSpec?: SortOrder stoneColor?: SortOrder minaColor?: SortOrder estimatedWeightGrams?: SortOrder estimatedPriceRial?: SortOrder description?: SortOrder convertedOrderId?: SortOrder createdAt?: SortOrder updatedAt?: SortOrder } export type PreOrderSumOrderByAggregateInput = { estimatedWeightGrams?: SortOrder estimatedPriceRial?: SortOrder } export type EnumPreOrderStatusWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.PreOrderStatus | EnumPreOrderStatusFieldRefInput<$PrismaModel> in?: $Enums.PreOrderStatus[] | ListEnumPreOrderStatusFieldRefInput<$PrismaModel> notIn?: $Enums.PreOrderStatus[] | ListEnumPreOrderStatusFieldRefInput<$PrismaModel> not?: NestedEnumPreOrderStatusWithAggregatesFilter<$PrismaModel> | $Enums.PreOrderStatus _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumPreOrderStatusFilter<$PrismaModel> _max?: NestedEnumPreOrderStatusFilter<$PrismaModel> } export type JsonFilter<$PrismaModel = never> = | PatchUndefined< Either>, Exclude>, 'path'>>, Required> > | OptionalFlat>, 'path'>> export type JsonFilterBase<$PrismaModel = never> = { equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter path?: string[] string_contains?: string | StringFieldRefInput<$PrismaModel> string_starts_with?: string | StringFieldRefInput<$PrismaModel> string_ends_with?: string | StringFieldRefInput<$PrismaModel> array_contains?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null lt?: InputJsonValue | JsonFieldRefInput<$PrismaModel> lte?: InputJsonValue | JsonFieldRefInput<$PrismaModel> gt?: InputJsonValue | JsonFieldRefInput<$PrismaModel> gte?: InputJsonValue | JsonFieldRefInput<$PrismaModel> not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter } export type PreOrderRelationFilter = { is?: PreOrderWhereInput isNot?: PreOrderWhereInput } export type PreOrderStatusEventCountOrderByAggregateInput = { id?: SortOrder preOrderId?: SortOrder changes?: SortOrder actorAdminUserId?: SortOrder ipAddress?: SortOrder createdAt?: SortOrder } export type PreOrderStatusEventMaxOrderByAggregateInput = { id?: SortOrder preOrderId?: SortOrder actorAdminUserId?: SortOrder ipAddress?: SortOrder createdAt?: SortOrder } export type PreOrderStatusEventMinOrderByAggregateInput = { id?: SortOrder preOrderId?: SortOrder actorAdminUserId?: SortOrder ipAddress?: SortOrder createdAt?: SortOrder } export type JsonWithAggregatesFilter<$PrismaModel = never> = | PatchUndefined< Either>, Exclude>, 'path'>>, Required> > | OptionalFlat>, 'path'>> export type JsonWithAggregatesFilterBase<$PrismaModel = never> = { equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter path?: string[] string_contains?: string | StringFieldRefInput<$PrismaModel> string_starts_with?: string | StringFieldRefInput<$PrismaModel> string_ends_with?: string | StringFieldRefInput<$PrismaModel> array_contains?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null lt?: InputJsonValue | JsonFieldRefInput<$PrismaModel> lte?: InputJsonValue | JsonFieldRefInput<$PrismaModel> gt?: InputJsonValue | JsonFieldRefInput<$PrismaModel> gte?: InputJsonValue | JsonFieldRefInput<$PrismaModel> not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter _count?: NestedIntFilter<$PrismaModel> _min?: NestedJsonFilter<$PrismaModel> _max?: NestedJsonFilter<$PrismaModel> } export type EnumLedgerCurrencyFilter<$PrismaModel = never> = { equals?: $Enums.LedgerCurrency | EnumLedgerCurrencyFieldRefInput<$PrismaModel> in?: $Enums.LedgerCurrency[] | ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerCurrency[] | ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> not?: NestedEnumLedgerCurrencyFilter<$PrismaModel> | $Enums.LedgerCurrency } export type EnumLedgerDirectionFilter<$PrismaModel = never> = { equals?: $Enums.LedgerDirection | EnumLedgerDirectionFieldRefInput<$PrismaModel> in?: $Enums.LedgerDirection[] | ListEnumLedgerDirectionFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerDirection[] | ListEnumLedgerDirectionFieldRefInput<$PrismaModel> not?: NestedEnumLedgerDirectionFilter<$PrismaModel> | $Enums.LedgerDirection } export type EnumLedgerSourceTypeFilter<$PrismaModel = never> = { equals?: $Enums.LedgerSourceType | EnumLedgerSourceTypeFieldRefInput<$PrismaModel> in?: $Enums.LedgerSourceType[] | ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerSourceType[] | ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> not?: NestedEnumLedgerSourceTypeFilter<$PrismaModel> | $Enums.LedgerSourceType } export type IntNullableFilter<$PrismaModel = never> = { equals?: number | IntFieldRefInput<$PrismaModel> | null in?: number[] | ListIntFieldRefInput<$PrismaModel> | null notIn?: number[] | ListIntFieldRefInput<$PrismaModel> | null lt?: number | IntFieldRefInput<$PrismaModel> lte?: number | IntFieldRefInput<$PrismaModel> gt?: number | IntFieldRefInput<$PrismaModel> gte?: number | IntFieldRefInput<$PrismaModel> not?: NestedIntNullableFilter<$PrismaModel> | number | null } export type LedgerEntryCountOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder currency?: SortOrder direction?: SortOrder sourceType?: SortOrder amount?: SortOrder karatPerMille?: SortOrder pricePerGramRialAtEntry?: SortOrder orderId?: SortOrder confirmed?: SortOrder confirmedAt?: SortOrder postedByAdminUserId?: SortOrder note?: SortOrder createdAt?: SortOrder } export type LedgerEntryAvgOrderByAggregateInput = { amount?: SortOrder karatPerMille?: SortOrder pricePerGramRialAtEntry?: SortOrder } export type LedgerEntryMaxOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder currency?: SortOrder direction?: SortOrder sourceType?: SortOrder amount?: SortOrder karatPerMille?: SortOrder pricePerGramRialAtEntry?: SortOrder orderId?: SortOrder confirmed?: SortOrder confirmedAt?: SortOrder postedByAdminUserId?: SortOrder note?: SortOrder createdAt?: SortOrder } export type LedgerEntryMinOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder currency?: SortOrder direction?: SortOrder sourceType?: SortOrder amount?: SortOrder karatPerMille?: SortOrder pricePerGramRialAtEntry?: SortOrder orderId?: SortOrder confirmed?: SortOrder confirmedAt?: SortOrder postedByAdminUserId?: SortOrder note?: SortOrder createdAt?: SortOrder } export type LedgerEntrySumOrderByAggregateInput = { amount?: SortOrder karatPerMille?: SortOrder pricePerGramRialAtEntry?: SortOrder } export type EnumLedgerCurrencyWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.LedgerCurrency | EnumLedgerCurrencyFieldRefInput<$PrismaModel> in?: $Enums.LedgerCurrency[] | ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerCurrency[] | ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> not?: NestedEnumLedgerCurrencyWithAggregatesFilter<$PrismaModel> | $Enums.LedgerCurrency _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumLedgerCurrencyFilter<$PrismaModel> _max?: NestedEnumLedgerCurrencyFilter<$PrismaModel> } export type EnumLedgerDirectionWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.LedgerDirection | EnumLedgerDirectionFieldRefInput<$PrismaModel> in?: $Enums.LedgerDirection[] | ListEnumLedgerDirectionFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerDirection[] | ListEnumLedgerDirectionFieldRefInput<$PrismaModel> not?: NestedEnumLedgerDirectionWithAggregatesFilter<$PrismaModel> | $Enums.LedgerDirection _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumLedgerDirectionFilter<$PrismaModel> _max?: NestedEnumLedgerDirectionFilter<$PrismaModel> } export type EnumLedgerSourceTypeWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.LedgerSourceType | EnumLedgerSourceTypeFieldRefInput<$PrismaModel> in?: $Enums.LedgerSourceType[] | ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerSourceType[] | ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> not?: NestedEnumLedgerSourceTypeWithAggregatesFilter<$PrismaModel> | $Enums.LedgerSourceType _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumLedgerSourceTypeFilter<$PrismaModel> _max?: NestedEnumLedgerSourceTypeFilter<$PrismaModel> } export type IntNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: number | IntFieldRefInput<$PrismaModel> | null in?: number[] | ListIntFieldRefInput<$PrismaModel> | null notIn?: number[] | ListIntFieldRefInput<$PrismaModel> | null lt?: number | IntFieldRefInput<$PrismaModel> lte?: number | IntFieldRefInput<$PrismaModel> gt?: number | IntFieldRefInput<$PrismaModel> gte?: number | IntFieldRefInput<$PrismaModel> not?: NestedIntNullableWithAggregatesFilter<$PrismaModel> | number | null _count?: NestedIntNullableFilter<$PrismaModel> _avg?: NestedFloatNullableFilter<$PrismaModel> _sum?: NestedIntNullableFilter<$PrismaModel> _min?: NestedIntNullableFilter<$PrismaModel> _max?: NestedIntNullableFilter<$PrismaModel> } export type GoldPriceQuoteCountOrderByAggregateInput = { id?: SortOrder karatPerMille?: SortOrder pricePerGramRial?: SortOrder source?: SortOrder quotedAt?: SortOrder } export type GoldPriceQuoteAvgOrderByAggregateInput = { karatPerMille?: SortOrder pricePerGramRial?: SortOrder } export type GoldPriceQuoteMaxOrderByAggregateInput = { id?: SortOrder karatPerMille?: SortOrder pricePerGramRial?: SortOrder source?: SortOrder quotedAt?: SortOrder } export type GoldPriceQuoteMinOrderByAggregateInput = { id?: SortOrder karatPerMille?: SortOrder pricePerGramRial?: SortOrder source?: SortOrder quotedAt?: SortOrder } export type GoldPriceQuoteSumOrderByAggregateInput = { karatPerMille?: SortOrder pricePerGramRial?: SortOrder } export type WalletBonusCountOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder orderId?: SortOrder goldGrams?: SortOrder grantedAt?: SortOrder expiresAt?: SortOrder consumedAt?: SortOrder isActive?: SortOrder } export type WalletBonusAvgOrderByAggregateInput = { goldGrams?: SortOrder } export type WalletBonusMaxOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder orderId?: SortOrder goldGrams?: SortOrder grantedAt?: SortOrder expiresAt?: SortOrder consumedAt?: SortOrder isActive?: SortOrder } export type WalletBonusMinOrderByAggregateInput = { id?: SortOrder customerId?: SortOrder orderId?: SortOrder goldGrams?: SortOrder grantedAt?: SortOrder expiresAt?: SortOrder consumedAt?: SortOrder isActive?: SortOrder } export type WalletBonusSumOrderByAggregateInput = { goldGrams?: SortOrder } export type CustomerCreateNestedManyWithoutCityInput = { create?: XOR | CustomerCreateWithoutCityInput[] | CustomerUncheckedCreateWithoutCityInput[] connectOrCreate?: CustomerCreateOrConnectWithoutCityInput | CustomerCreateOrConnectWithoutCityInput[] createMany?: CustomerCreateManyCityInputEnvelope connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] } export type CustomerAddressCreateNestedManyWithoutCityInput = { create?: XOR | CustomerAddressCreateWithoutCityInput[] | CustomerAddressUncheckedCreateWithoutCityInput[] connectOrCreate?: CustomerAddressCreateOrConnectWithoutCityInput | CustomerAddressCreateOrConnectWithoutCityInput[] createMany?: CustomerAddressCreateManyCityInputEnvelope connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] } export type BranchCreateNestedManyWithoutCityInput = { create?: XOR | BranchCreateWithoutCityInput[] | BranchUncheckedCreateWithoutCityInput[] connectOrCreate?: BranchCreateOrConnectWithoutCityInput | BranchCreateOrConnectWithoutCityInput[] createMany?: BranchCreateManyCityInputEnvelope connect?: BranchWhereUniqueInput | BranchWhereUniqueInput[] } export type PreOrderCreateNestedManyWithoutCityInput = { create?: XOR | PreOrderCreateWithoutCityInput[] | PreOrderUncheckedCreateWithoutCityInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutCityInput | PreOrderCreateOrConnectWithoutCityInput[] createMany?: PreOrderCreateManyCityInputEnvelope connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] } export type CustomerUncheckedCreateNestedManyWithoutCityInput = { create?: XOR | CustomerCreateWithoutCityInput[] | CustomerUncheckedCreateWithoutCityInput[] connectOrCreate?: CustomerCreateOrConnectWithoutCityInput | CustomerCreateOrConnectWithoutCityInput[] createMany?: CustomerCreateManyCityInputEnvelope connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] } export type CustomerAddressUncheckedCreateNestedManyWithoutCityInput = { create?: XOR | CustomerAddressCreateWithoutCityInput[] | CustomerAddressUncheckedCreateWithoutCityInput[] connectOrCreate?: CustomerAddressCreateOrConnectWithoutCityInput | CustomerAddressCreateOrConnectWithoutCityInput[] createMany?: CustomerAddressCreateManyCityInputEnvelope connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] } export type BranchUncheckedCreateNestedManyWithoutCityInput = { create?: XOR | BranchCreateWithoutCityInput[] | BranchUncheckedCreateWithoutCityInput[] connectOrCreate?: BranchCreateOrConnectWithoutCityInput | BranchCreateOrConnectWithoutCityInput[] createMany?: BranchCreateManyCityInputEnvelope connect?: BranchWhereUniqueInput | BranchWhereUniqueInput[] } export type PreOrderUncheckedCreateNestedManyWithoutCityInput = { create?: XOR | PreOrderCreateWithoutCityInput[] | PreOrderUncheckedCreateWithoutCityInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutCityInput | PreOrderCreateOrConnectWithoutCityInput[] createMany?: PreOrderCreateManyCityInputEnvelope connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] } export type StringFieldUpdateOperationsInput = { set?: string } export type NullableStringFieldUpdateOperationsInput = { set?: string | null } export type CustomerUpdateManyWithoutCityNestedInput = { create?: XOR | CustomerCreateWithoutCityInput[] | CustomerUncheckedCreateWithoutCityInput[] connectOrCreate?: CustomerCreateOrConnectWithoutCityInput | CustomerCreateOrConnectWithoutCityInput[] upsert?: CustomerUpsertWithWhereUniqueWithoutCityInput | CustomerUpsertWithWhereUniqueWithoutCityInput[] createMany?: CustomerCreateManyCityInputEnvelope set?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] disconnect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] delete?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] update?: CustomerUpdateWithWhereUniqueWithoutCityInput | CustomerUpdateWithWhereUniqueWithoutCityInput[] updateMany?: CustomerUpdateManyWithWhereWithoutCityInput | CustomerUpdateManyWithWhereWithoutCityInput[] deleteMany?: CustomerScalarWhereInput | CustomerScalarWhereInput[] } export type CustomerAddressUpdateManyWithoutCityNestedInput = { create?: XOR | CustomerAddressCreateWithoutCityInput[] | CustomerAddressUncheckedCreateWithoutCityInput[] connectOrCreate?: CustomerAddressCreateOrConnectWithoutCityInput | CustomerAddressCreateOrConnectWithoutCityInput[] upsert?: CustomerAddressUpsertWithWhereUniqueWithoutCityInput | CustomerAddressUpsertWithWhereUniqueWithoutCityInput[] createMany?: CustomerAddressCreateManyCityInputEnvelope set?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] disconnect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] delete?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] update?: CustomerAddressUpdateWithWhereUniqueWithoutCityInput | CustomerAddressUpdateWithWhereUniqueWithoutCityInput[] updateMany?: CustomerAddressUpdateManyWithWhereWithoutCityInput | CustomerAddressUpdateManyWithWhereWithoutCityInput[] deleteMany?: CustomerAddressScalarWhereInput | CustomerAddressScalarWhereInput[] } export type BranchUpdateManyWithoutCityNestedInput = { create?: XOR | BranchCreateWithoutCityInput[] | BranchUncheckedCreateWithoutCityInput[] connectOrCreate?: BranchCreateOrConnectWithoutCityInput | BranchCreateOrConnectWithoutCityInput[] upsert?: BranchUpsertWithWhereUniqueWithoutCityInput | BranchUpsertWithWhereUniqueWithoutCityInput[] createMany?: BranchCreateManyCityInputEnvelope set?: BranchWhereUniqueInput | BranchWhereUniqueInput[] disconnect?: BranchWhereUniqueInput | BranchWhereUniqueInput[] delete?: BranchWhereUniqueInput | BranchWhereUniqueInput[] connect?: BranchWhereUniqueInput | BranchWhereUniqueInput[] update?: BranchUpdateWithWhereUniqueWithoutCityInput | BranchUpdateWithWhereUniqueWithoutCityInput[] updateMany?: BranchUpdateManyWithWhereWithoutCityInput | BranchUpdateManyWithWhereWithoutCityInput[] deleteMany?: BranchScalarWhereInput | BranchScalarWhereInput[] } export type PreOrderUpdateManyWithoutCityNestedInput = { create?: XOR | PreOrderCreateWithoutCityInput[] | PreOrderUncheckedCreateWithoutCityInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutCityInput | PreOrderCreateOrConnectWithoutCityInput[] upsert?: PreOrderUpsertWithWhereUniqueWithoutCityInput | PreOrderUpsertWithWhereUniqueWithoutCityInput[] createMany?: PreOrderCreateManyCityInputEnvelope set?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] disconnect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] delete?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] update?: PreOrderUpdateWithWhereUniqueWithoutCityInput | PreOrderUpdateWithWhereUniqueWithoutCityInput[] updateMany?: PreOrderUpdateManyWithWhereWithoutCityInput | PreOrderUpdateManyWithWhereWithoutCityInput[] deleteMany?: PreOrderScalarWhereInput | PreOrderScalarWhereInput[] } export type CustomerUncheckedUpdateManyWithoutCityNestedInput = { create?: XOR | CustomerCreateWithoutCityInput[] | CustomerUncheckedCreateWithoutCityInput[] connectOrCreate?: CustomerCreateOrConnectWithoutCityInput | CustomerCreateOrConnectWithoutCityInput[] upsert?: CustomerUpsertWithWhereUniqueWithoutCityInput | CustomerUpsertWithWhereUniqueWithoutCityInput[] createMany?: CustomerCreateManyCityInputEnvelope set?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] disconnect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] delete?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] update?: CustomerUpdateWithWhereUniqueWithoutCityInput | CustomerUpdateWithWhereUniqueWithoutCityInput[] updateMany?: CustomerUpdateManyWithWhereWithoutCityInput | CustomerUpdateManyWithWhereWithoutCityInput[] deleteMany?: CustomerScalarWhereInput | CustomerScalarWhereInput[] } export type CustomerAddressUncheckedUpdateManyWithoutCityNestedInput = { create?: XOR | CustomerAddressCreateWithoutCityInput[] | CustomerAddressUncheckedCreateWithoutCityInput[] connectOrCreate?: CustomerAddressCreateOrConnectWithoutCityInput | CustomerAddressCreateOrConnectWithoutCityInput[] upsert?: CustomerAddressUpsertWithWhereUniqueWithoutCityInput | CustomerAddressUpsertWithWhereUniqueWithoutCityInput[] createMany?: CustomerAddressCreateManyCityInputEnvelope set?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] disconnect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] delete?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] update?: CustomerAddressUpdateWithWhereUniqueWithoutCityInput | CustomerAddressUpdateWithWhereUniqueWithoutCityInput[] updateMany?: CustomerAddressUpdateManyWithWhereWithoutCityInput | CustomerAddressUpdateManyWithWhereWithoutCityInput[] deleteMany?: CustomerAddressScalarWhereInput | CustomerAddressScalarWhereInput[] } export type BranchUncheckedUpdateManyWithoutCityNestedInput = { create?: XOR | BranchCreateWithoutCityInput[] | BranchUncheckedCreateWithoutCityInput[] connectOrCreate?: BranchCreateOrConnectWithoutCityInput | BranchCreateOrConnectWithoutCityInput[] upsert?: BranchUpsertWithWhereUniqueWithoutCityInput | BranchUpsertWithWhereUniqueWithoutCityInput[] createMany?: BranchCreateManyCityInputEnvelope set?: BranchWhereUniqueInput | BranchWhereUniqueInput[] disconnect?: BranchWhereUniqueInput | BranchWhereUniqueInput[] delete?: BranchWhereUniqueInput | BranchWhereUniqueInput[] connect?: BranchWhereUniqueInput | BranchWhereUniqueInput[] update?: BranchUpdateWithWhereUniqueWithoutCityInput | BranchUpdateWithWhereUniqueWithoutCityInput[] updateMany?: BranchUpdateManyWithWhereWithoutCityInput | BranchUpdateManyWithWhereWithoutCityInput[] deleteMany?: BranchScalarWhereInput | BranchScalarWhereInput[] } export type PreOrderUncheckedUpdateManyWithoutCityNestedInput = { create?: XOR | PreOrderCreateWithoutCityInput[] | PreOrderUncheckedCreateWithoutCityInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutCityInput | PreOrderCreateOrConnectWithoutCityInput[] upsert?: PreOrderUpsertWithWhereUniqueWithoutCityInput | PreOrderUpsertWithWhereUniqueWithoutCityInput[] createMany?: PreOrderCreateManyCityInputEnvelope set?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] disconnect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] delete?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] update?: PreOrderUpdateWithWhereUniqueWithoutCityInput | PreOrderUpdateWithWhereUniqueWithoutCityInput[] updateMany?: PreOrderUpdateManyWithWhereWithoutCityInput | PreOrderUpdateManyWithWhereWithoutCityInput[] deleteMany?: PreOrderScalarWhereInput | PreOrderScalarWhereInput[] } export type BranchCreateNestedOneWithoutAdminUsersInput = { create?: XOR connectOrCreate?: BranchCreateOrConnectWithoutAdminUsersInput connect?: BranchWhereUniqueInput } export type CustomerCreateNestedManyWithoutReferredByAgentInput = { create?: XOR | CustomerCreateWithoutReferredByAgentInput[] | CustomerUncheckedCreateWithoutReferredByAgentInput[] connectOrCreate?: CustomerCreateOrConnectWithoutReferredByAgentInput | CustomerCreateOrConnectWithoutReferredByAgentInput[] createMany?: CustomerCreateManyReferredByAgentInputEnvelope connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] } export type LedgerEntryCreateNestedManyWithoutPostedByAdminUserInput = { create?: XOR | LedgerEntryCreateWithoutPostedByAdminUserInput[] | LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput | LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput[] createMany?: LedgerEntryCreateManyPostedByAdminUserInputEnvelope connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] } export type OrderStatusEventCreateNestedManyWithoutActorAdminUserInput = { create?: XOR | OrderStatusEventCreateWithoutActorAdminUserInput[] | OrderStatusEventUncheckedCreateWithoutActorAdminUserInput[] connectOrCreate?: OrderStatusEventCreateOrConnectWithoutActorAdminUserInput | OrderStatusEventCreateOrConnectWithoutActorAdminUserInput[] createMany?: OrderStatusEventCreateManyActorAdminUserInputEnvelope connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] } export type PreOrderStatusEventCreateNestedManyWithoutActorAdminUserInput = { create?: XOR | PreOrderStatusEventCreateWithoutActorAdminUserInput[] | PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput[] connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput | PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput[] createMany?: PreOrderStatusEventCreateManyActorAdminUserInputEnvelope connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] } export type CustomerUncheckedCreateNestedManyWithoutReferredByAgentInput = { create?: XOR | CustomerCreateWithoutReferredByAgentInput[] | CustomerUncheckedCreateWithoutReferredByAgentInput[] connectOrCreate?: CustomerCreateOrConnectWithoutReferredByAgentInput | CustomerCreateOrConnectWithoutReferredByAgentInput[] createMany?: CustomerCreateManyReferredByAgentInputEnvelope connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] } export type LedgerEntryUncheckedCreateNestedManyWithoutPostedByAdminUserInput = { create?: XOR | LedgerEntryCreateWithoutPostedByAdminUserInput[] | LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput | LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput[] createMany?: LedgerEntryCreateManyPostedByAdminUserInputEnvelope connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] } export type OrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput = { create?: XOR | OrderStatusEventCreateWithoutActorAdminUserInput[] | OrderStatusEventUncheckedCreateWithoutActorAdminUserInput[] connectOrCreate?: OrderStatusEventCreateOrConnectWithoutActorAdminUserInput | OrderStatusEventCreateOrConnectWithoutActorAdminUserInput[] createMany?: OrderStatusEventCreateManyActorAdminUserInputEnvelope connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] } export type PreOrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput = { create?: XOR | PreOrderStatusEventCreateWithoutActorAdminUserInput[] | PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput[] connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput | PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput[] createMany?: PreOrderStatusEventCreateManyActorAdminUserInputEnvelope connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] } export type EnumAdminRoleFieldUpdateOperationsInput = { set?: $Enums.AdminRole } export type NullableDecimalFieldUpdateOperationsInput = { set?: Decimal | DecimalJsLike | number | string | null increment?: Decimal | DecimalJsLike | number | string decrement?: Decimal | DecimalJsLike | number | string multiply?: Decimal | DecimalJsLike | number | string divide?: Decimal | DecimalJsLike | number | string } export type BoolFieldUpdateOperationsInput = { set?: boolean } export type DateTimeFieldUpdateOperationsInput = { set?: Date | string } export type BranchUpdateOneWithoutAdminUsersNestedInput = { create?: XOR connectOrCreate?: BranchCreateOrConnectWithoutAdminUsersInput upsert?: BranchUpsertWithoutAdminUsersInput disconnect?: BranchWhereInput | boolean delete?: BranchWhereInput | boolean connect?: BranchWhereUniqueInput update?: XOR, BranchUncheckedUpdateWithoutAdminUsersInput> } export type CustomerUpdateManyWithoutReferredByAgentNestedInput = { create?: XOR | CustomerCreateWithoutReferredByAgentInput[] | CustomerUncheckedCreateWithoutReferredByAgentInput[] connectOrCreate?: CustomerCreateOrConnectWithoutReferredByAgentInput | CustomerCreateOrConnectWithoutReferredByAgentInput[] upsert?: CustomerUpsertWithWhereUniqueWithoutReferredByAgentInput | CustomerUpsertWithWhereUniqueWithoutReferredByAgentInput[] createMany?: CustomerCreateManyReferredByAgentInputEnvelope set?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] disconnect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] delete?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] update?: CustomerUpdateWithWhereUniqueWithoutReferredByAgentInput | CustomerUpdateWithWhereUniqueWithoutReferredByAgentInput[] updateMany?: CustomerUpdateManyWithWhereWithoutReferredByAgentInput | CustomerUpdateManyWithWhereWithoutReferredByAgentInput[] deleteMany?: CustomerScalarWhereInput | CustomerScalarWhereInput[] } export type LedgerEntryUpdateManyWithoutPostedByAdminUserNestedInput = { create?: XOR | LedgerEntryCreateWithoutPostedByAdminUserInput[] | LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput | LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput[] upsert?: LedgerEntryUpsertWithWhereUniqueWithoutPostedByAdminUserInput | LedgerEntryUpsertWithWhereUniqueWithoutPostedByAdminUserInput[] createMany?: LedgerEntryCreateManyPostedByAdminUserInputEnvelope set?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] disconnect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] delete?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] update?: LedgerEntryUpdateWithWhereUniqueWithoutPostedByAdminUserInput | LedgerEntryUpdateWithWhereUniqueWithoutPostedByAdminUserInput[] updateMany?: LedgerEntryUpdateManyWithWhereWithoutPostedByAdminUserInput | LedgerEntryUpdateManyWithWhereWithoutPostedByAdminUserInput[] deleteMany?: LedgerEntryScalarWhereInput | LedgerEntryScalarWhereInput[] } export type OrderStatusEventUpdateManyWithoutActorAdminUserNestedInput = { create?: XOR | OrderStatusEventCreateWithoutActorAdminUserInput[] | OrderStatusEventUncheckedCreateWithoutActorAdminUserInput[] connectOrCreate?: OrderStatusEventCreateOrConnectWithoutActorAdminUserInput | OrderStatusEventCreateOrConnectWithoutActorAdminUserInput[] upsert?: OrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput | OrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput[] createMany?: OrderStatusEventCreateManyActorAdminUserInputEnvelope set?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] disconnect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] delete?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] update?: OrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput | OrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput[] updateMany?: OrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput | OrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput[] deleteMany?: OrderStatusEventScalarWhereInput | OrderStatusEventScalarWhereInput[] } export type PreOrderStatusEventUpdateManyWithoutActorAdminUserNestedInput = { create?: XOR | PreOrderStatusEventCreateWithoutActorAdminUserInput[] | PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput[] connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput | PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput[] upsert?: PreOrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput | PreOrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput[] createMany?: PreOrderStatusEventCreateManyActorAdminUserInputEnvelope set?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] disconnect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] delete?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] update?: PreOrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput | PreOrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput[] updateMany?: PreOrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput | PreOrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput[] deleteMany?: PreOrderStatusEventScalarWhereInput | PreOrderStatusEventScalarWhereInput[] } export type CustomerUncheckedUpdateManyWithoutReferredByAgentNestedInput = { create?: XOR | CustomerCreateWithoutReferredByAgentInput[] | CustomerUncheckedCreateWithoutReferredByAgentInput[] connectOrCreate?: CustomerCreateOrConnectWithoutReferredByAgentInput | CustomerCreateOrConnectWithoutReferredByAgentInput[] upsert?: CustomerUpsertWithWhereUniqueWithoutReferredByAgentInput | CustomerUpsertWithWhereUniqueWithoutReferredByAgentInput[] createMany?: CustomerCreateManyReferredByAgentInputEnvelope set?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] disconnect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] delete?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[] update?: CustomerUpdateWithWhereUniqueWithoutReferredByAgentInput | CustomerUpdateWithWhereUniqueWithoutReferredByAgentInput[] updateMany?: CustomerUpdateManyWithWhereWithoutReferredByAgentInput | CustomerUpdateManyWithWhereWithoutReferredByAgentInput[] deleteMany?: CustomerScalarWhereInput | CustomerScalarWhereInput[] } export type LedgerEntryUncheckedUpdateManyWithoutPostedByAdminUserNestedInput = { create?: XOR | LedgerEntryCreateWithoutPostedByAdminUserInput[] | LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput | LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput[] upsert?: LedgerEntryUpsertWithWhereUniqueWithoutPostedByAdminUserInput | LedgerEntryUpsertWithWhereUniqueWithoutPostedByAdminUserInput[] createMany?: LedgerEntryCreateManyPostedByAdminUserInputEnvelope set?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] disconnect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] delete?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] update?: LedgerEntryUpdateWithWhereUniqueWithoutPostedByAdminUserInput | LedgerEntryUpdateWithWhereUniqueWithoutPostedByAdminUserInput[] updateMany?: LedgerEntryUpdateManyWithWhereWithoutPostedByAdminUserInput | LedgerEntryUpdateManyWithWhereWithoutPostedByAdminUserInput[] deleteMany?: LedgerEntryScalarWhereInput | LedgerEntryScalarWhereInput[] } export type OrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput = { create?: XOR | OrderStatusEventCreateWithoutActorAdminUserInput[] | OrderStatusEventUncheckedCreateWithoutActorAdminUserInput[] connectOrCreate?: OrderStatusEventCreateOrConnectWithoutActorAdminUserInput | OrderStatusEventCreateOrConnectWithoutActorAdminUserInput[] upsert?: OrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput | OrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput[] createMany?: OrderStatusEventCreateManyActorAdminUserInputEnvelope set?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] disconnect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] delete?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] update?: OrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput | OrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput[] updateMany?: OrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput | OrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput[] deleteMany?: OrderStatusEventScalarWhereInput | OrderStatusEventScalarWhereInput[] } export type PreOrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput = { create?: XOR | PreOrderStatusEventCreateWithoutActorAdminUserInput[] | PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput[] connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput | PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput[] upsert?: PreOrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput | PreOrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput[] createMany?: PreOrderStatusEventCreateManyActorAdminUserInputEnvelope set?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] disconnect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] delete?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] update?: PreOrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput | PreOrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput[] updateMany?: PreOrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput | PreOrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput[] deleteMany?: PreOrderStatusEventScalarWhereInput | PreOrderStatusEventScalarWhereInput[] } export type CityCreateNestedOneWithoutCustomersInput = { create?: XOR connectOrCreate?: CityCreateOrConnectWithoutCustomersInput connect?: CityWhereUniqueInput } export type AdminUserCreateNestedOneWithoutReferredCustomersInput = { create?: XOR connectOrCreate?: AdminUserCreateOrConnectWithoutReferredCustomersInput connect?: AdminUserWhereUniqueInput } export type CustomerAddressCreateNestedManyWithoutCustomerInput = { create?: XOR | CustomerAddressCreateWithoutCustomerInput[] | CustomerAddressUncheckedCreateWithoutCustomerInput[] connectOrCreate?: CustomerAddressCreateOrConnectWithoutCustomerInput | CustomerAddressCreateOrConnectWithoutCustomerInput[] createMany?: CustomerAddressCreateManyCustomerInputEnvelope connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] } export type OrderCreateNestedManyWithoutCustomerInput = { create?: XOR | OrderCreateWithoutCustomerInput[] | OrderUncheckedCreateWithoutCustomerInput[] connectOrCreate?: OrderCreateOrConnectWithoutCustomerInput | OrderCreateOrConnectWithoutCustomerInput[] createMany?: OrderCreateManyCustomerInputEnvelope connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] } export type PreOrderCreateNestedManyWithoutCustomerInput = { create?: XOR | PreOrderCreateWithoutCustomerInput[] | PreOrderUncheckedCreateWithoutCustomerInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutCustomerInput | PreOrderCreateOrConnectWithoutCustomerInput[] createMany?: PreOrderCreateManyCustomerInputEnvelope connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] } export type LedgerEntryCreateNestedManyWithoutCustomerInput = { create?: XOR | LedgerEntryCreateWithoutCustomerInput[] | LedgerEntryUncheckedCreateWithoutCustomerInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutCustomerInput | LedgerEntryCreateOrConnectWithoutCustomerInput[] createMany?: LedgerEntryCreateManyCustomerInputEnvelope connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] } export type WalletBonusCreateNestedManyWithoutCustomerInput = { create?: XOR | WalletBonusCreateWithoutCustomerInput[] | WalletBonusUncheckedCreateWithoutCustomerInput[] connectOrCreate?: WalletBonusCreateOrConnectWithoutCustomerInput | WalletBonusCreateOrConnectWithoutCustomerInput[] createMany?: WalletBonusCreateManyCustomerInputEnvelope connect?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] } export type CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput = { create?: XOR | CustomerAddressCreateWithoutCustomerInput[] | CustomerAddressUncheckedCreateWithoutCustomerInput[] connectOrCreate?: CustomerAddressCreateOrConnectWithoutCustomerInput | CustomerAddressCreateOrConnectWithoutCustomerInput[] createMany?: CustomerAddressCreateManyCustomerInputEnvelope connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] } export type OrderUncheckedCreateNestedManyWithoutCustomerInput = { create?: XOR | OrderCreateWithoutCustomerInput[] | OrderUncheckedCreateWithoutCustomerInput[] connectOrCreate?: OrderCreateOrConnectWithoutCustomerInput | OrderCreateOrConnectWithoutCustomerInput[] createMany?: OrderCreateManyCustomerInputEnvelope connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] } export type PreOrderUncheckedCreateNestedManyWithoutCustomerInput = { create?: XOR | PreOrderCreateWithoutCustomerInput[] | PreOrderUncheckedCreateWithoutCustomerInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutCustomerInput | PreOrderCreateOrConnectWithoutCustomerInput[] createMany?: PreOrderCreateManyCustomerInputEnvelope connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] } export type LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput = { create?: XOR | LedgerEntryCreateWithoutCustomerInput[] | LedgerEntryUncheckedCreateWithoutCustomerInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutCustomerInput | LedgerEntryCreateOrConnectWithoutCustomerInput[] createMany?: LedgerEntryCreateManyCustomerInputEnvelope connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] } export type WalletBonusUncheckedCreateNestedManyWithoutCustomerInput = { create?: XOR | WalletBonusCreateWithoutCustomerInput[] | WalletBonusUncheckedCreateWithoutCustomerInput[] connectOrCreate?: WalletBonusCreateOrConnectWithoutCustomerInput | WalletBonusCreateOrConnectWithoutCustomerInput[] createMany?: WalletBonusCreateManyCustomerInputEnvelope connect?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] } export type DecimalFieldUpdateOperationsInput = { set?: Decimal | DecimalJsLike | number | string increment?: Decimal | DecimalJsLike | number | string decrement?: Decimal | DecimalJsLike | number | string multiply?: Decimal | DecimalJsLike | number | string divide?: Decimal | DecimalJsLike | number | string } export type EnumVerificationStepFieldUpdateOperationsInput = { set?: $Enums.VerificationStep } export type CityUpdateOneWithoutCustomersNestedInput = { create?: XOR connectOrCreate?: CityCreateOrConnectWithoutCustomersInput upsert?: CityUpsertWithoutCustomersInput disconnect?: CityWhereInput | boolean delete?: CityWhereInput | boolean connect?: CityWhereUniqueInput update?: XOR, CityUncheckedUpdateWithoutCustomersInput> } export type AdminUserUpdateOneWithoutReferredCustomersNestedInput = { create?: XOR connectOrCreate?: AdminUserCreateOrConnectWithoutReferredCustomersInput upsert?: AdminUserUpsertWithoutReferredCustomersInput disconnect?: AdminUserWhereInput | boolean delete?: AdminUserWhereInput | boolean connect?: AdminUserWhereUniqueInput update?: XOR, AdminUserUncheckedUpdateWithoutReferredCustomersInput> } export type CustomerAddressUpdateManyWithoutCustomerNestedInput = { create?: XOR | CustomerAddressCreateWithoutCustomerInput[] | CustomerAddressUncheckedCreateWithoutCustomerInput[] connectOrCreate?: CustomerAddressCreateOrConnectWithoutCustomerInput | CustomerAddressCreateOrConnectWithoutCustomerInput[] upsert?: CustomerAddressUpsertWithWhereUniqueWithoutCustomerInput | CustomerAddressUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: CustomerAddressCreateManyCustomerInputEnvelope set?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] disconnect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] delete?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] update?: CustomerAddressUpdateWithWhereUniqueWithoutCustomerInput | CustomerAddressUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: CustomerAddressUpdateManyWithWhereWithoutCustomerInput | CustomerAddressUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: CustomerAddressScalarWhereInput | CustomerAddressScalarWhereInput[] } export type OrderUpdateManyWithoutCustomerNestedInput = { create?: XOR | OrderCreateWithoutCustomerInput[] | OrderUncheckedCreateWithoutCustomerInput[] connectOrCreate?: OrderCreateOrConnectWithoutCustomerInput | OrderCreateOrConnectWithoutCustomerInput[] upsert?: OrderUpsertWithWhereUniqueWithoutCustomerInput | OrderUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: OrderCreateManyCustomerInputEnvelope set?: OrderWhereUniqueInput | OrderWhereUniqueInput[] disconnect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] delete?: OrderWhereUniqueInput | OrderWhereUniqueInput[] connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] update?: OrderUpdateWithWhereUniqueWithoutCustomerInput | OrderUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: OrderUpdateManyWithWhereWithoutCustomerInput | OrderUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: OrderScalarWhereInput | OrderScalarWhereInput[] } export type PreOrderUpdateManyWithoutCustomerNestedInput = { create?: XOR | PreOrderCreateWithoutCustomerInput[] | PreOrderUncheckedCreateWithoutCustomerInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutCustomerInput | PreOrderCreateOrConnectWithoutCustomerInput[] upsert?: PreOrderUpsertWithWhereUniqueWithoutCustomerInput | PreOrderUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: PreOrderCreateManyCustomerInputEnvelope set?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] disconnect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] delete?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] update?: PreOrderUpdateWithWhereUniqueWithoutCustomerInput | PreOrderUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: PreOrderUpdateManyWithWhereWithoutCustomerInput | PreOrderUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: PreOrderScalarWhereInput | PreOrderScalarWhereInput[] } export type LedgerEntryUpdateManyWithoutCustomerNestedInput = { create?: XOR | LedgerEntryCreateWithoutCustomerInput[] | LedgerEntryUncheckedCreateWithoutCustomerInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutCustomerInput | LedgerEntryCreateOrConnectWithoutCustomerInput[] upsert?: LedgerEntryUpsertWithWhereUniqueWithoutCustomerInput | LedgerEntryUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: LedgerEntryCreateManyCustomerInputEnvelope set?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] disconnect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] delete?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] update?: LedgerEntryUpdateWithWhereUniqueWithoutCustomerInput | LedgerEntryUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: LedgerEntryUpdateManyWithWhereWithoutCustomerInput | LedgerEntryUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: LedgerEntryScalarWhereInput | LedgerEntryScalarWhereInput[] } export type WalletBonusUpdateManyWithoutCustomerNestedInput = { create?: XOR | WalletBonusCreateWithoutCustomerInput[] | WalletBonusUncheckedCreateWithoutCustomerInput[] connectOrCreate?: WalletBonusCreateOrConnectWithoutCustomerInput | WalletBonusCreateOrConnectWithoutCustomerInput[] upsert?: WalletBonusUpsertWithWhereUniqueWithoutCustomerInput | WalletBonusUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: WalletBonusCreateManyCustomerInputEnvelope set?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] disconnect?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] delete?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] connect?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] update?: WalletBonusUpdateWithWhereUniqueWithoutCustomerInput | WalletBonusUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: WalletBonusUpdateManyWithWhereWithoutCustomerInput | WalletBonusUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: WalletBonusScalarWhereInput | WalletBonusScalarWhereInput[] } export type CustomerAddressUncheckedUpdateManyWithoutCustomerNestedInput = { create?: XOR | CustomerAddressCreateWithoutCustomerInput[] | CustomerAddressUncheckedCreateWithoutCustomerInput[] connectOrCreate?: CustomerAddressCreateOrConnectWithoutCustomerInput | CustomerAddressCreateOrConnectWithoutCustomerInput[] upsert?: CustomerAddressUpsertWithWhereUniqueWithoutCustomerInput | CustomerAddressUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: CustomerAddressCreateManyCustomerInputEnvelope set?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] disconnect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] delete?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[] update?: CustomerAddressUpdateWithWhereUniqueWithoutCustomerInput | CustomerAddressUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: CustomerAddressUpdateManyWithWhereWithoutCustomerInput | CustomerAddressUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: CustomerAddressScalarWhereInput | CustomerAddressScalarWhereInput[] } export type OrderUncheckedUpdateManyWithoutCustomerNestedInput = { create?: XOR | OrderCreateWithoutCustomerInput[] | OrderUncheckedCreateWithoutCustomerInput[] connectOrCreate?: OrderCreateOrConnectWithoutCustomerInput | OrderCreateOrConnectWithoutCustomerInput[] upsert?: OrderUpsertWithWhereUniqueWithoutCustomerInput | OrderUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: OrderCreateManyCustomerInputEnvelope set?: OrderWhereUniqueInput | OrderWhereUniqueInput[] disconnect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] delete?: OrderWhereUniqueInput | OrderWhereUniqueInput[] connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] update?: OrderUpdateWithWhereUniqueWithoutCustomerInput | OrderUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: OrderUpdateManyWithWhereWithoutCustomerInput | OrderUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: OrderScalarWhereInput | OrderScalarWhereInput[] } export type PreOrderUncheckedUpdateManyWithoutCustomerNestedInput = { create?: XOR | PreOrderCreateWithoutCustomerInput[] | PreOrderUncheckedCreateWithoutCustomerInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutCustomerInput | PreOrderCreateOrConnectWithoutCustomerInput[] upsert?: PreOrderUpsertWithWhereUniqueWithoutCustomerInput | PreOrderUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: PreOrderCreateManyCustomerInputEnvelope set?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] disconnect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] delete?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] update?: PreOrderUpdateWithWhereUniqueWithoutCustomerInput | PreOrderUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: PreOrderUpdateManyWithWhereWithoutCustomerInput | PreOrderUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: PreOrderScalarWhereInput | PreOrderScalarWhereInput[] } export type LedgerEntryUncheckedUpdateManyWithoutCustomerNestedInput = { create?: XOR | LedgerEntryCreateWithoutCustomerInput[] | LedgerEntryUncheckedCreateWithoutCustomerInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutCustomerInput | LedgerEntryCreateOrConnectWithoutCustomerInput[] upsert?: LedgerEntryUpsertWithWhereUniqueWithoutCustomerInput | LedgerEntryUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: LedgerEntryCreateManyCustomerInputEnvelope set?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] disconnect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] delete?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] update?: LedgerEntryUpdateWithWhereUniqueWithoutCustomerInput | LedgerEntryUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: LedgerEntryUpdateManyWithWhereWithoutCustomerInput | LedgerEntryUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: LedgerEntryScalarWhereInput | LedgerEntryScalarWhereInput[] } export type WalletBonusUncheckedUpdateManyWithoutCustomerNestedInput = { create?: XOR | WalletBonusCreateWithoutCustomerInput[] | WalletBonusUncheckedCreateWithoutCustomerInput[] connectOrCreate?: WalletBonusCreateOrConnectWithoutCustomerInput | WalletBonusCreateOrConnectWithoutCustomerInput[] upsert?: WalletBonusUpsertWithWhereUniqueWithoutCustomerInput | WalletBonusUpsertWithWhereUniqueWithoutCustomerInput[] createMany?: WalletBonusCreateManyCustomerInputEnvelope set?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] disconnect?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] delete?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] connect?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[] update?: WalletBonusUpdateWithWhereUniqueWithoutCustomerInput | WalletBonusUpdateWithWhereUniqueWithoutCustomerInput[] updateMany?: WalletBonusUpdateManyWithWhereWithoutCustomerInput | WalletBonusUpdateManyWithWhereWithoutCustomerInput[] deleteMany?: WalletBonusScalarWhereInput | WalletBonusScalarWhereInput[] } export type CustomerCreateNestedOneWithoutAddressesInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutAddressesInput connect?: CustomerWhereUniqueInput } export type CityCreateNestedOneWithoutAddressesInput = { create?: XOR connectOrCreate?: CityCreateOrConnectWithoutAddressesInput connect?: CityWhereUniqueInput } export type CustomerUpdateOneRequiredWithoutAddressesNestedInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutAddressesInput upsert?: CustomerUpsertWithoutAddressesInput connect?: CustomerWhereUniqueInput update?: XOR, CustomerUncheckedUpdateWithoutAddressesInput> } export type CityUpdateOneWithoutAddressesNestedInput = { create?: XOR connectOrCreate?: CityCreateOrConnectWithoutAddressesInput upsert?: CityUpsertWithoutAddressesInput disconnect?: CityWhereInput | boolean delete?: CityWhereInput | boolean connect?: CityWhereUniqueInput update?: XOR, CityUncheckedUpdateWithoutAddressesInput> } export type CityCreateNestedOneWithoutBranchesInput = { create?: XOR connectOrCreate?: CityCreateOrConnectWithoutBranchesInput connect?: CityWhereUniqueInput } export type AdminUserCreateNestedManyWithoutBranchInput = { create?: XOR | AdminUserCreateWithoutBranchInput[] | AdminUserUncheckedCreateWithoutBranchInput[] connectOrCreate?: AdminUserCreateOrConnectWithoutBranchInput | AdminUserCreateOrConnectWithoutBranchInput[] createMany?: AdminUserCreateManyBranchInputEnvelope connect?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] } export type OrderCreateNestedManyWithoutBranchInput = { create?: XOR | OrderCreateWithoutBranchInput[] | OrderUncheckedCreateWithoutBranchInput[] connectOrCreate?: OrderCreateOrConnectWithoutBranchInput | OrderCreateOrConnectWithoutBranchInput[] createMany?: OrderCreateManyBranchInputEnvelope connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] } export type AdminUserUncheckedCreateNestedManyWithoutBranchInput = { create?: XOR | AdminUserCreateWithoutBranchInput[] | AdminUserUncheckedCreateWithoutBranchInput[] connectOrCreate?: AdminUserCreateOrConnectWithoutBranchInput | AdminUserCreateOrConnectWithoutBranchInput[] createMany?: AdminUserCreateManyBranchInputEnvelope connect?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] } export type OrderUncheckedCreateNestedManyWithoutBranchInput = { create?: XOR | OrderCreateWithoutBranchInput[] | OrderUncheckedCreateWithoutBranchInput[] connectOrCreate?: OrderCreateOrConnectWithoutBranchInput | OrderCreateOrConnectWithoutBranchInput[] createMany?: OrderCreateManyBranchInputEnvelope connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] } export type CityUpdateOneWithoutBranchesNestedInput = { create?: XOR connectOrCreate?: CityCreateOrConnectWithoutBranchesInput upsert?: CityUpsertWithoutBranchesInput disconnect?: CityWhereInput | boolean delete?: CityWhereInput | boolean connect?: CityWhereUniqueInput update?: XOR, CityUncheckedUpdateWithoutBranchesInput> } export type AdminUserUpdateManyWithoutBranchNestedInput = { create?: XOR | AdminUserCreateWithoutBranchInput[] | AdminUserUncheckedCreateWithoutBranchInput[] connectOrCreate?: AdminUserCreateOrConnectWithoutBranchInput | AdminUserCreateOrConnectWithoutBranchInput[] upsert?: AdminUserUpsertWithWhereUniqueWithoutBranchInput | AdminUserUpsertWithWhereUniqueWithoutBranchInput[] createMany?: AdminUserCreateManyBranchInputEnvelope set?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] disconnect?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] delete?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] connect?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] update?: AdminUserUpdateWithWhereUniqueWithoutBranchInput | AdminUserUpdateWithWhereUniqueWithoutBranchInput[] updateMany?: AdminUserUpdateManyWithWhereWithoutBranchInput | AdminUserUpdateManyWithWhereWithoutBranchInput[] deleteMany?: AdminUserScalarWhereInput | AdminUserScalarWhereInput[] } export type OrderUpdateManyWithoutBranchNestedInput = { create?: XOR | OrderCreateWithoutBranchInput[] | OrderUncheckedCreateWithoutBranchInput[] connectOrCreate?: OrderCreateOrConnectWithoutBranchInput | OrderCreateOrConnectWithoutBranchInput[] upsert?: OrderUpsertWithWhereUniqueWithoutBranchInput | OrderUpsertWithWhereUniqueWithoutBranchInput[] createMany?: OrderCreateManyBranchInputEnvelope set?: OrderWhereUniqueInput | OrderWhereUniqueInput[] disconnect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] delete?: OrderWhereUniqueInput | OrderWhereUniqueInput[] connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] update?: OrderUpdateWithWhereUniqueWithoutBranchInput | OrderUpdateWithWhereUniqueWithoutBranchInput[] updateMany?: OrderUpdateManyWithWhereWithoutBranchInput | OrderUpdateManyWithWhereWithoutBranchInput[] deleteMany?: OrderScalarWhereInput | OrderScalarWhereInput[] } export type AdminUserUncheckedUpdateManyWithoutBranchNestedInput = { create?: XOR | AdminUserCreateWithoutBranchInput[] | AdminUserUncheckedCreateWithoutBranchInput[] connectOrCreate?: AdminUserCreateOrConnectWithoutBranchInput | AdminUserCreateOrConnectWithoutBranchInput[] upsert?: AdminUserUpsertWithWhereUniqueWithoutBranchInput | AdminUserUpsertWithWhereUniqueWithoutBranchInput[] createMany?: AdminUserCreateManyBranchInputEnvelope set?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] disconnect?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] delete?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] connect?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[] update?: AdminUserUpdateWithWhereUniqueWithoutBranchInput | AdminUserUpdateWithWhereUniqueWithoutBranchInput[] updateMany?: AdminUserUpdateManyWithWhereWithoutBranchInput | AdminUserUpdateManyWithWhereWithoutBranchInput[] deleteMany?: AdminUserScalarWhereInput | AdminUserScalarWhereInput[] } export type OrderUncheckedUpdateManyWithoutBranchNestedInput = { create?: XOR | OrderCreateWithoutBranchInput[] | OrderUncheckedCreateWithoutBranchInput[] connectOrCreate?: OrderCreateOrConnectWithoutBranchInput | OrderCreateOrConnectWithoutBranchInput[] upsert?: OrderUpsertWithWhereUniqueWithoutBranchInput | OrderUpsertWithWhereUniqueWithoutBranchInput[] createMany?: OrderCreateManyBranchInputEnvelope set?: OrderWhereUniqueInput | OrderWhereUniqueInput[] disconnect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] delete?: OrderWhereUniqueInput | OrderWhereUniqueInput[] connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[] update?: OrderUpdateWithWhereUniqueWithoutBranchInput | OrderUpdateWithWhereUniqueWithoutBranchInput[] updateMany?: OrderUpdateManyWithWhereWithoutBranchInput | OrderUpdateManyWithWhereWithoutBranchInput[] deleteMany?: OrderScalarWhereInput | OrderScalarWhereInput[] } export type PreOrderCreateNestedManyWithoutWorkshopInput = { create?: XOR | PreOrderCreateWithoutWorkshopInput[] | PreOrderUncheckedCreateWithoutWorkshopInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutWorkshopInput | PreOrderCreateOrConnectWithoutWorkshopInput[] createMany?: PreOrderCreateManyWorkshopInputEnvelope connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] } export type PreOrderUncheckedCreateNestedManyWithoutWorkshopInput = { create?: XOR | PreOrderCreateWithoutWorkshopInput[] | PreOrderUncheckedCreateWithoutWorkshopInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutWorkshopInput | PreOrderCreateOrConnectWithoutWorkshopInput[] createMany?: PreOrderCreateManyWorkshopInputEnvelope connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] } export type PreOrderUpdateManyWithoutWorkshopNestedInput = { create?: XOR | PreOrderCreateWithoutWorkshopInput[] | PreOrderUncheckedCreateWithoutWorkshopInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutWorkshopInput | PreOrderCreateOrConnectWithoutWorkshopInput[] upsert?: PreOrderUpsertWithWhereUniqueWithoutWorkshopInput | PreOrderUpsertWithWhereUniqueWithoutWorkshopInput[] createMany?: PreOrderCreateManyWorkshopInputEnvelope set?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] disconnect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] delete?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] update?: PreOrderUpdateWithWhereUniqueWithoutWorkshopInput | PreOrderUpdateWithWhereUniqueWithoutWorkshopInput[] updateMany?: PreOrderUpdateManyWithWhereWithoutWorkshopInput | PreOrderUpdateManyWithWhereWithoutWorkshopInput[] deleteMany?: PreOrderScalarWhereInput | PreOrderScalarWhereInput[] } export type PreOrderUncheckedUpdateManyWithoutWorkshopNestedInput = { create?: XOR | PreOrderCreateWithoutWorkshopInput[] | PreOrderUncheckedCreateWithoutWorkshopInput[] connectOrCreate?: PreOrderCreateOrConnectWithoutWorkshopInput | PreOrderCreateOrConnectWithoutWorkshopInput[] upsert?: PreOrderUpsertWithWhereUniqueWithoutWorkshopInput | PreOrderUpsertWithWhereUniqueWithoutWorkshopInput[] createMany?: PreOrderCreateManyWorkshopInputEnvelope set?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] disconnect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] delete?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[] update?: PreOrderUpdateWithWhereUniqueWithoutWorkshopInput | PreOrderUpdateWithWhereUniqueWithoutWorkshopInput[] updateMany?: PreOrderUpdateManyWithWhereWithoutWorkshopInput | PreOrderUpdateManyWithWhereWithoutWorkshopInput[] deleteMany?: PreOrderScalarWhereInput | PreOrderScalarWhereInput[] } export type CategoryCreateNestedOneWithoutChildrenInput = { create?: XOR connectOrCreate?: CategoryCreateOrConnectWithoutChildrenInput connect?: CategoryWhereUniqueInput } export type CategoryCreateNestedManyWithoutParentInput = { create?: XOR | CategoryCreateWithoutParentInput[] | CategoryUncheckedCreateWithoutParentInput[] connectOrCreate?: CategoryCreateOrConnectWithoutParentInput | CategoryCreateOrConnectWithoutParentInput[] createMany?: CategoryCreateManyParentInputEnvelope connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] } export type ProductCreateNestedManyWithoutCategoryInput = { create?: XOR | ProductCreateWithoutCategoryInput[] | ProductUncheckedCreateWithoutCategoryInput[] connectOrCreate?: ProductCreateOrConnectWithoutCategoryInput | ProductCreateOrConnectWithoutCategoryInput[] createMany?: ProductCreateManyCategoryInputEnvelope connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] } export type CategoryUncheckedCreateNestedManyWithoutParentInput = { create?: XOR | CategoryCreateWithoutParentInput[] | CategoryUncheckedCreateWithoutParentInput[] connectOrCreate?: CategoryCreateOrConnectWithoutParentInput | CategoryCreateOrConnectWithoutParentInput[] createMany?: CategoryCreateManyParentInputEnvelope connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] } export type ProductUncheckedCreateNestedManyWithoutCategoryInput = { create?: XOR | ProductCreateWithoutCategoryInput[] | ProductUncheckedCreateWithoutCategoryInput[] connectOrCreate?: ProductCreateOrConnectWithoutCategoryInput | ProductCreateOrConnectWithoutCategoryInput[] createMany?: ProductCreateManyCategoryInputEnvelope connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] } export type CategoryUpdateOneWithoutChildrenNestedInput = { create?: XOR connectOrCreate?: CategoryCreateOrConnectWithoutChildrenInput upsert?: CategoryUpsertWithoutChildrenInput disconnect?: CategoryWhereInput | boolean delete?: CategoryWhereInput | boolean connect?: CategoryWhereUniqueInput update?: XOR, CategoryUncheckedUpdateWithoutChildrenInput> } export type CategoryUpdateManyWithoutParentNestedInput = { create?: XOR | CategoryCreateWithoutParentInput[] | CategoryUncheckedCreateWithoutParentInput[] connectOrCreate?: CategoryCreateOrConnectWithoutParentInput | CategoryCreateOrConnectWithoutParentInput[] upsert?: CategoryUpsertWithWhereUniqueWithoutParentInput | CategoryUpsertWithWhereUniqueWithoutParentInput[] createMany?: CategoryCreateManyParentInputEnvelope set?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] disconnect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] delete?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] update?: CategoryUpdateWithWhereUniqueWithoutParentInput | CategoryUpdateWithWhereUniqueWithoutParentInput[] updateMany?: CategoryUpdateManyWithWhereWithoutParentInput | CategoryUpdateManyWithWhereWithoutParentInput[] deleteMany?: CategoryScalarWhereInput | CategoryScalarWhereInput[] } export type ProductUpdateManyWithoutCategoryNestedInput = { create?: XOR | ProductCreateWithoutCategoryInput[] | ProductUncheckedCreateWithoutCategoryInput[] connectOrCreate?: ProductCreateOrConnectWithoutCategoryInput | ProductCreateOrConnectWithoutCategoryInput[] upsert?: ProductUpsertWithWhereUniqueWithoutCategoryInput | ProductUpsertWithWhereUniqueWithoutCategoryInput[] createMany?: ProductCreateManyCategoryInputEnvelope set?: ProductWhereUniqueInput | ProductWhereUniqueInput[] disconnect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] delete?: ProductWhereUniqueInput | ProductWhereUniqueInput[] connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] update?: ProductUpdateWithWhereUniqueWithoutCategoryInput | ProductUpdateWithWhereUniqueWithoutCategoryInput[] updateMany?: ProductUpdateManyWithWhereWithoutCategoryInput | ProductUpdateManyWithWhereWithoutCategoryInput[] deleteMany?: ProductScalarWhereInput | ProductScalarWhereInput[] } export type CategoryUncheckedUpdateManyWithoutParentNestedInput = { create?: XOR | CategoryCreateWithoutParentInput[] | CategoryUncheckedCreateWithoutParentInput[] connectOrCreate?: CategoryCreateOrConnectWithoutParentInput | CategoryCreateOrConnectWithoutParentInput[] upsert?: CategoryUpsertWithWhereUniqueWithoutParentInput | CategoryUpsertWithWhereUniqueWithoutParentInput[] createMany?: CategoryCreateManyParentInputEnvelope set?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] disconnect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] delete?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[] update?: CategoryUpdateWithWhereUniqueWithoutParentInput | CategoryUpdateWithWhereUniqueWithoutParentInput[] updateMany?: CategoryUpdateManyWithWhereWithoutParentInput | CategoryUpdateManyWithWhereWithoutParentInput[] deleteMany?: CategoryScalarWhereInput | CategoryScalarWhereInput[] } export type ProductUncheckedUpdateManyWithoutCategoryNestedInput = { create?: XOR | ProductCreateWithoutCategoryInput[] | ProductUncheckedCreateWithoutCategoryInput[] connectOrCreate?: ProductCreateOrConnectWithoutCategoryInput | ProductCreateOrConnectWithoutCategoryInput[] upsert?: ProductUpsertWithWhereUniqueWithoutCategoryInput | ProductUpsertWithWhereUniqueWithoutCategoryInput[] createMany?: ProductCreateManyCategoryInputEnvelope set?: ProductWhereUniqueInput | ProductWhereUniqueInput[] disconnect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] delete?: ProductWhereUniqueInput | ProductWhereUniqueInput[] connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] update?: ProductUpdateWithWhereUniqueWithoutCategoryInput | ProductUpdateWithWhereUniqueWithoutCategoryInput[] updateMany?: ProductUpdateManyWithWhereWithoutCategoryInput | ProductUpdateManyWithWhereWithoutCategoryInput[] deleteMany?: ProductScalarWhereInput | ProductScalarWhereInput[] } export type ProductCreateNestedManyWithoutBrandInput = { create?: XOR | ProductCreateWithoutBrandInput[] | ProductUncheckedCreateWithoutBrandInput[] connectOrCreate?: ProductCreateOrConnectWithoutBrandInput | ProductCreateOrConnectWithoutBrandInput[] createMany?: ProductCreateManyBrandInputEnvelope connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] } export type ProductUncheckedCreateNestedManyWithoutBrandInput = { create?: XOR | ProductCreateWithoutBrandInput[] | ProductUncheckedCreateWithoutBrandInput[] connectOrCreate?: ProductCreateOrConnectWithoutBrandInput | ProductCreateOrConnectWithoutBrandInput[] createMany?: ProductCreateManyBrandInputEnvelope connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] } export type ProductUpdateManyWithoutBrandNestedInput = { create?: XOR | ProductCreateWithoutBrandInput[] | ProductUncheckedCreateWithoutBrandInput[] connectOrCreate?: ProductCreateOrConnectWithoutBrandInput | ProductCreateOrConnectWithoutBrandInput[] upsert?: ProductUpsertWithWhereUniqueWithoutBrandInput | ProductUpsertWithWhereUniqueWithoutBrandInput[] createMany?: ProductCreateManyBrandInputEnvelope set?: ProductWhereUniqueInput | ProductWhereUniqueInput[] disconnect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] delete?: ProductWhereUniqueInput | ProductWhereUniqueInput[] connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] update?: ProductUpdateWithWhereUniqueWithoutBrandInput | ProductUpdateWithWhereUniqueWithoutBrandInput[] updateMany?: ProductUpdateManyWithWhereWithoutBrandInput | ProductUpdateManyWithWhereWithoutBrandInput[] deleteMany?: ProductScalarWhereInput | ProductScalarWhereInput[] } export type ProductUncheckedUpdateManyWithoutBrandNestedInput = { create?: XOR | ProductCreateWithoutBrandInput[] | ProductUncheckedCreateWithoutBrandInput[] connectOrCreate?: ProductCreateOrConnectWithoutBrandInput | ProductCreateOrConnectWithoutBrandInput[] upsert?: ProductUpsertWithWhereUniqueWithoutBrandInput | ProductUpsertWithWhereUniqueWithoutBrandInput[] createMany?: ProductCreateManyBrandInputEnvelope set?: ProductWhereUniqueInput | ProductWhereUniqueInput[] disconnect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] delete?: ProductWhereUniqueInput | ProductWhereUniqueInput[] connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[] update?: ProductUpdateWithWhereUniqueWithoutBrandInput | ProductUpdateWithWhereUniqueWithoutBrandInput[] updateMany?: ProductUpdateManyWithWhereWithoutBrandInput | ProductUpdateManyWithWhereWithoutBrandInput[] deleteMany?: ProductScalarWhereInput | ProductScalarWhereInput[] } export type CollectionProductCreateNestedManyWithoutCollectionInput = { create?: XOR | CollectionProductCreateWithoutCollectionInput[] | CollectionProductUncheckedCreateWithoutCollectionInput[] connectOrCreate?: CollectionProductCreateOrConnectWithoutCollectionInput | CollectionProductCreateOrConnectWithoutCollectionInput[] createMany?: CollectionProductCreateManyCollectionInputEnvelope connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] } export type CollectionProductUncheckedCreateNestedManyWithoutCollectionInput = { create?: XOR | CollectionProductCreateWithoutCollectionInput[] | CollectionProductUncheckedCreateWithoutCollectionInput[] connectOrCreate?: CollectionProductCreateOrConnectWithoutCollectionInput | CollectionProductCreateOrConnectWithoutCollectionInput[] createMany?: CollectionProductCreateManyCollectionInputEnvelope connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] } export type CollectionProductUpdateManyWithoutCollectionNestedInput = { create?: XOR | CollectionProductCreateWithoutCollectionInput[] | CollectionProductUncheckedCreateWithoutCollectionInput[] connectOrCreate?: CollectionProductCreateOrConnectWithoutCollectionInput | CollectionProductCreateOrConnectWithoutCollectionInput[] upsert?: CollectionProductUpsertWithWhereUniqueWithoutCollectionInput | CollectionProductUpsertWithWhereUniqueWithoutCollectionInput[] createMany?: CollectionProductCreateManyCollectionInputEnvelope set?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] disconnect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] delete?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] update?: CollectionProductUpdateWithWhereUniqueWithoutCollectionInput | CollectionProductUpdateWithWhereUniqueWithoutCollectionInput[] updateMany?: CollectionProductUpdateManyWithWhereWithoutCollectionInput | CollectionProductUpdateManyWithWhereWithoutCollectionInput[] deleteMany?: CollectionProductScalarWhereInput | CollectionProductScalarWhereInput[] } export type CollectionProductUncheckedUpdateManyWithoutCollectionNestedInput = { create?: XOR | CollectionProductCreateWithoutCollectionInput[] | CollectionProductUncheckedCreateWithoutCollectionInput[] connectOrCreate?: CollectionProductCreateOrConnectWithoutCollectionInput | CollectionProductCreateOrConnectWithoutCollectionInput[] upsert?: CollectionProductUpsertWithWhereUniqueWithoutCollectionInput | CollectionProductUpsertWithWhereUniqueWithoutCollectionInput[] createMany?: CollectionProductCreateManyCollectionInputEnvelope set?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] disconnect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] delete?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] update?: CollectionProductUpdateWithWhereUniqueWithoutCollectionInput | CollectionProductUpdateWithWhereUniqueWithoutCollectionInput[] updateMany?: CollectionProductUpdateManyWithWhereWithoutCollectionInput | CollectionProductUpdateManyWithWhereWithoutCollectionInput[] deleteMany?: CollectionProductScalarWhereInput | CollectionProductScalarWhereInput[] } export type CollectionCreateNestedOneWithoutProductsInput = { create?: XOR connectOrCreate?: CollectionCreateOrConnectWithoutProductsInput connect?: CollectionWhereUniqueInput } export type ProductCreateNestedOneWithoutCollectionsInput = { create?: XOR connectOrCreate?: ProductCreateOrConnectWithoutCollectionsInput connect?: ProductWhereUniqueInput } export type CollectionUpdateOneRequiredWithoutProductsNestedInput = { create?: XOR connectOrCreate?: CollectionCreateOrConnectWithoutProductsInput upsert?: CollectionUpsertWithoutProductsInput connect?: CollectionWhereUniqueInput update?: XOR, CollectionUncheckedUpdateWithoutProductsInput> } export type ProductUpdateOneRequiredWithoutCollectionsNestedInput = { create?: XOR connectOrCreate?: ProductCreateOrConnectWithoutCollectionsInput upsert?: ProductUpsertWithoutCollectionsInput connect?: ProductWhereUniqueInput update?: XOR, ProductUncheckedUpdateWithoutCollectionsInput> } export type CategoryCreateNestedOneWithoutProductsInput = { create?: XOR connectOrCreate?: CategoryCreateOrConnectWithoutProductsInput connect?: CategoryWhereUniqueInput } export type BrandCreateNestedOneWithoutProductsInput = { create?: XOR connectOrCreate?: BrandCreateOrConnectWithoutProductsInput connect?: BrandWhereUniqueInput } export type ProductVariantCreateNestedManyWithoutProductInput = { create?: XOR | ProductVariantCreateWithoutProductInput[] | ProductVariantUncheckedCreateWithoutProductInput[] connectOrCreate?: ProductVariantCreateOrConnectWithoutProductInput | ProductVariantCreateOrConnectWithoutProductInput[] createMany?: ProductVariantCreateManyProductInputEnvelope connect?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] } export type ProductImageCreateNestedManyWithoutProductInput = { create?: XOR | ProductImageCreateWithoutProductInput[] | ProductImageUncheckedCreateWithoutProductInput[] connectOrCreate?: ProductImageCreateOrConnectWithoutProductInput | ProductImageCreateOrConnectWithoutProductInput[] createMany?: ProductImageCreateManyProductInputEnvelope connect?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] } export type CollectionProductCreateNestedManyWithoutProductInput = { create?: XOR | CollectionProductCreateWithoutProductInput[] | CollectionProductUncheckedCreateWithoutProductInput[] connectOrCreate?: CollectionProductCreateOrConnectWithoutProductInput | CollectionProductCreateOrConnectWithoutProductInput[] createMany?: CollectionProductCreateManyProductInputEnvelope connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] } export type ProductVariantUncheckedCreateNestedManyWithoutProductInput = { create?: XOR | ProductVariantCreateWithoutProductInput[] | ProductVariantUncheckedCreateWithoutProductInput[] connectOrCreate?: ProductVariantCreateOrConnectWithoutProductInput | ProductVariantCreateOrConnectWithoutProductInput[] createMany?: ProductVariantCreateManyProductInputEnvelope connect?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] } export type ProductImageUncheckedCreateNestedManyWithoutProductInput = { create?: XOR | ProductImageCreateWithoutProductInput[] | ProductImageUncheckedCreateWithoutProductInput[] connectOrCreate?: ProductImageCreateOrConnectWithoutProductInput | ProductImageCreateOrConnectWithoutProductInput[] createMany?: ProductImageCreateManyProductInputEnvelope connect?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] } export type CollectionProductUncheckedCreateNestedManyWithoutProductInput = { create?: XOR | CollectionProductCreateWithoutProductInput[] | CollectionProductUncheckedCreateWithoutProductInput[] connectOrCreate?: CollectionProductCreateOrConnectWithoutProductInput | CollectionProductCreateOrConnectWithoutProductInput[] createMany?: CollectionProductCreateManyProductInputEnvelope connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] } export type CategoryUpdateOneWithoutProductsNestedInput = { create?: XOR connectOrCreate?: CategoryCreateOrConnectWithoutProductsInput upsert?: CategoryUpsertWithoutProductsInput disconnect?: CategoryWhereInput | boolean delete?: CategoryWhereInput | boolean connect?: CategoryWhereUniqueInput update?: XOR, CategoryUncheckedUpdateWithoutProductsInput> } export type BrandUpdateOneWithoutProductsNestedInput = { create?: XOR connectOrCreate?: BrandCreateOrConnectWithoutProductsInput upsert?: BrandUpsertWithoutProductsInput disconnect?: BrandWhereInput | boolean delete?: BrandWhereInput | boolean connect?: BrandWhereUniqueInput update?: XOR, BrandUncheckedUpdateWithoutProductsInput> } export type ProductVariantUpdateManyWithoutProductNestedInput = { create?: XOR | ProductVariantCreateWithoutProductInput[] | ProductVariantUncheckedCreateWithoutProductInput[] connectOrCreate?: ProductVariantCreateOrConnectWithoutProductInput | ProductVariantCreateOrConnectWithoutProductInput[] upsert?: ProductVariantUpsertWithWhereUniqueWithoutProductInput | ProductVariantUpsertWithWhereUniqueWithoutProductInput[] createMany?: ProductVariantCreateManyProductInputEnvelope set?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] disconnect?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] delete?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] connect?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] update?: ProductVariantUpdateWithWhereUniqueWithoutProductInput | ProductVariantUpdateWithWhereUniqueWithoutProductInput[] updateMany?: ProductVariantUpdateManyWithWhereWithoutProductInput | ProductVariantUpdateManyWithWhereWithoutProductInput[] deleteMany?: ProductVariantScalarWhereInput | ProductVariantScalarWhereInput[] } export type ProductImageUpdateManyWithoutProductNestedInput = { create?: XOR | ProductImageCreateWithoutProductInput[] | ProductImageUncheckedCreateWithoutProductInput[] connectOrCreate?: ProductImageCreateOrConnectWithoutProductInput | ProductImageCreateOrConnectWithoutProductInput[] upsert?: ProductImageUpsertWithWhereUniqueWithoutProductInput | ProductImageUpsertWithWhereUniqueWithoutProductInput[] createMany?: ProductImageCreateManyProductInputEnvelope set?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] disconnect?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] delete?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] connect?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] update?: ProductImageUpdateWithWhereUniqueWithoutProductInput | ProductImageUpdateWithWhereUniqueWithoutProductInput[] updateMany?: ProductImageUpdateManyWithWhereWithoutProductInput | ProductImageUpdateManyWithWhereWithoutProductInput[] deleteMany?: ProductImageScalarWhereInput | ProductImageScalarWhereInput[] } export type CollectionProductUpdateManyWithoutProductNestedInput = { create?: XOR | CollectionProductCreateWithoutProductInput[] | CollectionProductUncheckedCreateWithoutProductInput[] connectOrCreate?: CollectionProductCreateOrConnectWithoutProductInput | CollectionProductCreateOrConnectWithoutProductInput[] upsert?: CollectionProductUpsertWithWhereUniqueWithoutProductInput | CollectionProductUpsertWithWhereUniqueWithoutProductInput[] createMany?: CollectionProductCreateManyProductInputEnvelope set?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] disconnect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] delete?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] update?: CollectionProductUpdateWithWhereUniqueWithoutProductInput | CollectionProductUpdateWithWhereUniqueWithoutProductInput[] updateMany?: CollectionProductUpdateManyWithWhereWithoutProductInput | CollectionProductUpdateManyWithWhereWithoutProductInput[] deleteMany?: CollectionProductScalarWhereInput | CollectionProductScalarWhereInput[] } export type ProductVariantUncheckedUpdateManyWithoutProductNestedInput = { create?: XOR | ProductVariantCreateWithoutProductInput[] | ProductVariantUncheckedCreateWithoutProductInput[] connectOrCreate?: ProductVariantCreateOrConnectWithoutProductInput | ProductVariantCreateOrConnectWithoutProductInput[] upsert?: ProductVariantUpsertWithWhereUniqueWithoutProductInput | ProductVariantUpsertWithWhereUniqueWithoutProductInput[] createMany?: ProductVariantCreateManyProductInputEnvelope set?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] disconnect?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] delete?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] connect?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[] update?: ProductVariantUpdateWithWhereUniqueWithoutProductInput | ProductVariantUpdateWithWhereUniqueWithoutProductInput[] updateMany?: ProductVariantUpdateManyWithWhereWithoutProductInput | ProductVariantUpdateManyWithWhereWithoutProductInput[] deleteMany?: ProductVariantScalarWhereInput | ProductVariantScalarWhereInput[] } export type ProductImageUncheckedUpdateManyWithoutProductNestedInput = { create?: XOR | ProductImageCreateWithoutProductInput[] | ProductImageUncheckedCreateWithoutProductInput[] connectOrCreate?: ProductImageCreateOrConnectWithoutProductInput | ProductImageCreateOrConnectWithoutProductInput[] upsert?: ProductImageUpsertWithWhereUniqueWithoutProductInput | ProductImageUpsertWithWhereUniqueWithoutProductInput[] createMany?: ProductImageCreateManyProductInputEnvelope set?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] disconnect?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] delete?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] connect?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[] update?: ProductImageUpdateWithWhereUniqueWithoutProductInput | ProductImageUpdateWithWhereUniqueWithoutProductInput[] updateMany?: ProductImageUpdateManyWithWhereWithoutProductInput | ProductImageUpdateManyWithWhereWithoutProductInput[] deleteMany?: ProductImageScalarWhereInput | ProductImageScalarWhereInput[] } export type CollectionProductUncheckedUpdateManyWithoutProductNestedInput = { create?: XOR | CollectionProductCreateWithoutProductInput[] | CollectionProductUncheckedCreateWithoutProductInput[] connectOrCreate?: CollectionProductCreateOrConnectWithoutProductInput | CollectionProductCreateOrConnectWithoutProductInput[] upsert?: CollectionProductUpsertWithWhereUniqueWithoutProductInput | CollectionProductUpsertWithWhereUniqueWithoutProductInput[] createMany?: CollectionProductCreateManyProductInputEnvelope set?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] disconnect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] delete?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[] update?: CollectionProductUpdateWithWhereUniqueWithoutProductInput | CollectionProductUpdateWithWhereUniqueWithoutProductInput[] updateMany?: CollectionProductUpdateManyWithWhereWithoutProductInput | CollectionProductUpdateManyWithWhereWithoutProductInput[] deleteMany?: CollectionProductScalarWhereInput | CollectionProductScalarWhereInput[] } export type ProductCreateNestedOneWithoutImagesInput = { create?: XOR connectOrCreate?: ProductCreateOrConnectWithoutImagesInput connect?: ProductWhereUniqueInput } export type IntFieldUpdateOperationsInput = { set?: number increment?: number decrement?: number multiply?: number divide?: number } export type ProductUpdateOneRequiredWithoutImagesNestedInput = { create?: XOR connectOrCreate?: ProductCreateOrConnectWithoutImagesInput upsert?: ProductUpsertWithoutImagesInput connect?: ProductWhereUniqueInput update?: XOR, ProductUncheckedUpdateWithoutImagesInput> } export type ProductCreateNestedOneWithoutVariantsInput = { create?: XOR connectOrCreate?: ProductCreateOrConnectWithoutVariantsInput connect?: ProductWhereUniqueInput } export type OrderItemCreateNestedManyWithoutProductVariantInput = { create?: XOR | OrderItemCreateWithoutProductVariantInput[] | OrderItemUncheckedCreateWithoutProductVariantInput[] connectOrCreate?: OrderItemCreateOrConnectWithoutProductVariantInput | OrderItemCreateOrConnectWithoutProductVariantInput[] createMany?: OrderItemCreateManyProductVariantInputEnvelope connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] } export type OrderItemUncheckedCreateNestedManyWithoutProductVariantInput = { create?: XOR | OrderItemCreateWithoutProductVariantInput[] | OrderItemUncheckedCreateWithoutProductVariantInput[] connectOrCreate?: OrderItemCreateOrConnectWithoutProductVariantInput | OrderItemCreateOrConnectWithoutProductVariantInput[] createMany?: OrderItemCreateManyProductVariantInputEnvelope connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] } export type ProductUpdateOneRequiredWithoutVariantsNestedInput = { create?: XOR connectOrCreate?: ProductCreateOrConnectWithoutVariantsInput upsert?: ProductUpsertWithoutVariantsInput connect?: ProductWhereUniqueInput update?: XOR, ProductUncheckedUpdateWithoutVariantsInput> } export type OrderItemUpdateManyWithoutProductVariantNestedInput = { create?: XOR | OrderItemCreateWithoutProductVariantInput[] | OrderItemUncheckedCreateWithoutProductVariantInput[] connectOrCreate?: OrderItemCreateOrConnectWithoutProductVariantInput | OrderItemCreateOrConnectWithoutProductVariantInput[] upsert?: OrderItemUpsertWithWhereUniqueWithoutProductVariantInput | OrderItemUpsertWithWhereUniqueWithoutProductVariantInput[] createMany?: OrderItemCreateManyProductVariantInputEnvelope set?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] disconnect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] delete?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] update?: OrderItemUpdateWithWhereUniqueWithoutProductVariantInput | OrderItemUpdateWithWhereUniqueWithoutProductVariantInput[] updateMany?: OrderItemUpdateManyWithWhereWithoutProductVariantInput | OrderItemUpdateManyWithWhereWithoutProductVariantInput[] deleteMany?: OrderItemScalarWhereInput | OrderItemScalarWhereInput[] } export type OrderItemUncheckedUpdateManyWithoutProductVariantNestedInput = { create?: XOR | OrderItemCreateWithoutProductVariantInput[] | OrderItemUncheckedCreateWithoutProductVariantInput[] connectOrCreate?: OrderItemCreateOrConnectWithoutProductVariantInput | OrderItemCreateOrConnectWithoutProductVariantInput[] upsert?: OrderItemUpsertWithWhereUniqueWithoutProductVariantInput | OrderItemUpsertWithWhereUniqueWithoutProductVariantInput[] createMany?: OrderItemCreateManyProductVariantInputEnvelope set?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] disconnect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] delete?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] update?: OrderItemUpdateWithWhereUniqueWithoutProductVariantInput | OrderItemUpdateWithWhereUniqueWithoutProductVariantInput[] updateMany?: OrderItemUpdateManyWithWhereWithoutProductVariantInput | OrderItemUpdateManyWithWhereWithoutProductVariantInput[] deleteMany?: OrderItemScalarWhereInput | OrderItemScalarWhereInput[] } export type CustomerCreateNestedOneWithoutOrdersInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutOrdersInput connect?: CustomerWhereUniqueInput } export type BranchCreateNestedOneWithoutOrdersInput = { create?: XOR connectOrCreate?: BranchCreateOrConnectWithoutOrdersInput connect?: BranchWhereUniqueInput } export type OrderItemCreateNestedManyWithoutOrderInput = { create?: XOR | OrderItemCreateWithoutOrderInput[] | OrderItemUncheckedCreateWithoutOrderInput[] connectOrCreate?: OrderItemCreateOrConnectWithoutOrderInput | OrderItemCreateOrConnectWithoutOrderInput[] createMany?: OrderItemCreateManyOrderInputEnvelope connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] } export type OrderStatusEventCreateNestedManyWithoutOrderInput = { create?: XOR | OrderStatusEventCreateWithoutOrderInput[] | OrderStatusEventUncheckedCreateWithoutOrderInput[] connectOrCreate?: OrderStatusEventCreateOrConnectWithoutOrderInput | OrderStatusEventCreateOrConnectWithoutOrderInput[] createMany?: OrderStatusEventCreateManyOrderInputEnvelope connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] } export type LedgerEntryCreateNestedManyWithoutOrderInput = { create?: XOR | LedgerEntryCreateWithoutOrderInput[] | LedgerEntryUncheckedCreateWithoutOrderInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutOrderInput | LedgerEntryCreateOrConnectWithoutOrderInput[] createMany?: LedgerEntryCreateManyOrderInputEnvelope connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] } export type PreOrderCreateNestedOneWithoutConvertedOrderInput = { create?: XOR connectOrCreate?: PreOrderCreateOrConnectWithoutConvertedOrderInput connect?: PreOrderWhereUniqueInput } export type OrderItemUncheckedCreateNestedManyWithoutOrderInput = { create?: XOR | OrderItemCreateWithoutOrderInput[] | OrderItemUncheckedCreateWithoutOrderInput[] connectOrCreate?: OrderItemCreateOrConnectWithoutOrderInput | OrderItemCreateOrConnectWithoutOrderInput[] createMany?: OrderItemCreateManyOrderInputEnvelope connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] } export type OrderStatusEventUncheckedCreateNestedManyWithoutOrderInput = { create?: XOR | OrderStatusEventCreateWithoutOrderInput[] | OrderStatusEventUncheckedCreateWithoutOrderInput[] connectOrCreate?: OrderStatusEventCreateOrConnectWithoutOrderInput | OrderStatusEventCreateOrConnectWithoutOrderInput[] createMany?: OrderStatusEventCreateManyOrderInputEnvelope connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] } export type LedgerEntryUncheckedCreateNestedManyWithoutOrderInput = { create?: XOR | LedgerEntryCreateWithoutOrderInput[] | LedgerEntryUncheckedCreateWithoutOrderInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutOrderInput | LedgerEntryCreateOrConnectWithoutOrderInput[] createMany?: LedgerEntryCreateManyOrderInputEnvelope connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] } export type PreOrderUncheckedCreateNestedOneWithoutConvertedOrderInput = { create?: XOR connectOrCreate?: PreOrderCreateOrConnectWithoutConvertedOrderInput connect?: PreOrderWhereUniqueInput } export type EnumOrderStatusFieldUpdateOperationsInput = { set?: $Enums.OrderStatus } export type NullableDateTimeFieldUpdateOperationsInput = { set?: Date | string | null } export type CustomerUpdateOneRequiredWithoutOrdersNestedInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutOrdersInput upsert?: CustomerUpsertWithoutOrdersInput connect?: CustomerWhereUniqueInput update?: XOR, CustomerUncheckedUpdateWithoutOrdersInput> } export type BranchUpdateOneWithoutOrdersNestedInput = { create?: XOR connectOrCreate?: BranchCreateOrConnectWithoutOrdersInput upsert?: BranchUpsertWithoutOrdersInput disconnect?: BranchWhereInput | boolean delete?: BranchWhereInput | boolean connect?: BranchWhereUniqueInput update?: XOR, BranchUncheckedUpdateWithoutOrdersInput> } export type OrderItemUpdateManyWithoutOrderNestedInput = { create?: XOR | OrderItemCreateWithoutOrderInput[] | OrderItemUncheckedCreateWithoutOrderInput[] connectOrCreate?: OrderItemCreateOrConnectWithoutOrderInput | OrderItemCreateOrConnectWithoutOrderInput[] upsert?: OrderItemUpsertWithWhereUniqueWithoutOrderInput | OrderItemUpsertWithWhereUniqueWithoutOrderInput[] createMany?: OrderItemCreateManyOrderInputEnvelope set?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] disconnect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] delete?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] update?: OrderItemUpdateWithWhereUniqueWithoutOrderInput | OrderItemUpdateWithWhereUniqueWithoutOrderInput[] updateMany?: OrderItemUpdateManyWithWhereWithoutOrderInput | OrderItemUpdateManyWithWhereWithoutOrderInput[] deleteMany?: OrderItemScalarWhereInput | OrderItemScalarWhereInput[] } export type OrderStatusEventUpdateManyWithoutOrderNestedInput = { create?: XOR | OrderStatusEventCreateWithoutOrderInput[] | OrderStatusEventUncheckedCreateWithoutOrderInput[] connectOrCreate?: OrderStatusEventCreateOrConnectWithoutOrderInput | OrderStatusEventCreateOrConnectWithoutOrderInput[] upsert?: OrderStatusEventUpsertWithWhereUniqueWithoutOrderInput | OrderStatusEventUpsertWithWhereUniqueWithoutOrderInput[] createMany?: OrderStatusEventCreateManyOrderInputEnvelope set?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] disconnect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] delete?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] update?: OrderStatusEventUpdateWithWhereUniqueWithoutOrderInput | OrderStatusEventUpdateWithWhereUniqueWithoutOrderInput[] updateMany?: OrderStatusEventUpdateManyWithWhereWithoutOrderInput | OrderStatusEventUpdateManyWithWhereWithoutOrderInput[] deleteMany?: OrderStatusEventScalarWhereInput | OrderStatusEventScalarWhereInput[] } export type LedgerEntryUpdateManyWithoutOrderNestedInput = { create?: XOR | LedgerEntryCreateWithoutOrderInput[] | LedgerEntryUncheckedCreateWithoutOrderInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutOrderInput | LedgerEntryCreateOrConnectWithoutOrderInput[] upsert?: LedgerEntryUpsertWithWhereUniqueWithoutOrderInput | LedgerEntryUpsertWithWhereUniqueWithoutOrderInput[] createMany?: LedgerEntryCreateManyOrderInputEnvelope set?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] disconnect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] delete?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] update?: LedgerEntryUpdateWithWhereUniqueWithoutOrderInput | LedgerEntryUpdateWithWhereUniqueWithoutOrderInput[] updateMany?: LedgerEntryUpdateManyWithWhereWithoutOrderInput | LedgerEntryUpdateManyWithWhereWithoutOrderInput[] deleteMany?: LedgerEntryScalarWhereInput | LedgerEntryScalarWhereInput[] } export type PreOrderUpdateOneWithoutConvertedOrderNestedInput = { create?: XOR connectOrCreate?: PreOrderCreateOrConnectWithoutConvertedOrderInput upsert?: PreOrderUpsertWithoutConvertedOrderInput disconnect?: PreOrderWhereInput | boolean delete?: PreOrderWhereInput | boolean connect?: PreOrderWhereUniqueInput update?: XOR, PreOrderUncheckedUpdateWithoutConvertedOrderInput> } export type OrderItemUncheckedUpdateManyWithoutOrderNestedInput = { create?: XOR | OrderItemCreateWithoutOrderInput[] | OrderItemUncheckedCreateWithoutOrderInput[] connectOrCreate?: OrderItemCreateOrConnectWithoutOrderInput | OrderItemCreateOrConnectWithoutOrderInput[] upsert?: OrderItemUpsertWithWhereUniqueWithoutOrderInput | OrderItemUpsertWithWhereUniqueWithoutOrderInput[] createMany?: OrderItemCreateManyOrderInputEnvelope set?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] disconnect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] delete?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[] update?: OrderItemUpdateWithWhereUniqueWithoutOrderInput | OrderItemUpdateWithWhereUniqueWithoutOrderInput[] updateMany?: OrderItemUpdateManyWithWhereWithoutOrderInput | OrderItemUpdateManyWithWhereWithoutOrderInput[] deleteMany?: OrderItemScalarWhereInput | OrderItemScalarWhereInput[] } export type OrderStatusEventUncheckedUpdateManyWithoutOrderNestedInput = { create?: XOR | OrderStatusEventCreateWithoutOrderInput[] | OrderStatusEventUncheckedCreateWithoutOrderInput[] connectOrCreate?: OrderStatusEventCreateOrConnectWithoutOrderInput | OrderStatusEventCreateOrConnectWithoutOrderInput[] upsert?: OrderStatusEventUpsertWithWhereUniqueWithoutOrderInput | OrderStatusEventUpsertWithWhereUniqueWithoutOrderInput[] createMany?: OrderStatusEventCreateManyOrderInputEnvelope set?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] disconnect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] delete?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[] update?: OrderStatusEventUpdateWithWhereUniqueWithoutOrderInput | OrderStatusEventUpdateWithWhereUniqueWithoutOrderInput[] updateMany?: OrderStatusEventUpdateManyWithWhereWithoutOrderInput | OrderStatusEventUpdateManyWithWhereWithoutOrderInput[] deleteMany?: OrderStatusEventScalarWhereInput | OrderStatusEventScalarWhereInput[] } export type LedgerEntryUncheckedUpdateManyWithoutOrderNestedInput = { create?: XOR | LedgerEntryCreateWithoutOrderInput[] | LedgerEntryUncheckedCreateWithoutOrderInput[] connectOrCreate?: LedgerEntryCreateOrConnectWithoutOrderInput | LedgerEntryCreateOrConnectWithoutOrderInput[] upsert?: LedgerEntryUpsertWithWhereUniqueWithoutOrderInput | LedgerEntryUpsertWithWhereUniqueWithoutOrderInput[] createMany?: LedgerEntryCreateManyOrderInputEnvelope set?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] disconnect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] delete?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[] update?: LedgerEntryUpdateWithWhereUniqueWithoutOrderInput | LedgerEntryUpdateWithWhereUniqueWithoutOrderInput[] updateMany?: LedgerEntryUpdateManyWithWhereWithoutOrderInput | LedgerEntryUpdateManyWithWhereWithoutOrderInput[] deleteMany?: LedgerEntryScalarWhereInput | LedgerEntryScalarWhereInput[] } export type PreOrderUncheckedUpdateOneWithoutConvertedOrderNestedInput = { create?: XOR connectOrCreate?: PreOrderCreateOrConnectWithoutConvertedOrderInput upsert?: PreOrderUpsertWithoutConvertedOrderInput disconnect?: PreOrderWhereInput | boolean delete?: PreOrderWhereInput | boolean connect?: PreOrderWhereUniqueInput update?: XOR, PreOrderUncheckedUpdateWithoutConvertedOrderInput> } export type OrderCreateNestedOneWithoutItemsInput = { create?: XOR connectOrCreate?: OrderCreateOrConnectWithoutItemsInput connect?: OrderWhereUniqueInput } export type ProductVariantCreateNestedOneWithoutOrderItemsInput = { create?: XOR connectOrCreate?: ProductVariantCreateOrConnectWithoutOrderItemsInput connect?: ProductVariantWhereUniqueInput } export type OrderUpdateOneRequiredWithoutItemsNestedInput = { create?: XOR connectOrCreate?: OrderCreateOrConnectWithoutItemsInput upsert?: OrderUpsertWithoutItemsInput connect?: OrderWhereUniqueInput update?: XOR, OrderUncheckedUpdateWithoutItemsInput> } export type ProductVariantUpdateOneRequiredWithoutOrderItemsNestedInput = { create?: XOR connectOrCreate?: ProductVariantCreateOrConnectWithoutOrderItemsInput upsert?: ProductVariantUpsertWithoutOrderItemsInput connect?: ProductVariantWhereUniqueInput update?: XOR, ProductVariantUncheckedUpdateWithoutOrderItemsInput> } export type OrderCreateNestedOneWithoutStatusEventsInput = { create?: XOR connectOrCreate?: OrderCreateOrConnectWithoutStatusEventsInput connect?: OrderWhereUniqueInput } export type AdminUserCreateNestedOneWithoutOrderStatusEventsInput = { create?: XOR connectOrCreate?: AdminUserCreateOrConnectWithoutOrderStatusEventsInput connect?: AdminUserWhereUniqueInput } export type NullableEnumOrderStatusFieldUpdateOperationsInput = { set?: $Enums.OrderStatus | null } export type OrderUpdateOneRequiredWithoutStatusEventsNestedInput = { create?: XOR connectOrCreate?: OrderCreateOrConnectWithoutStatusEventsInput upsert?: OrderUpsertWithoutStatusEventsInput connect?: OrderWhereUniqueInput update?: XOR, OrderUncheckedUpdateWithoutStatusEventsInput> } export type AdminUserUpdateOneWithoutOrderStatusEventsNestedInput = { create?: XOR connectOrCreate?: AdminUserCreateOrConnectWithoutOrderStatusEventsInput upsert?: AdminUserUpsertWithoutOrderStatusEventsInput disconnect?: AdminUserWhereInput | boolean delete?: AdminUserWhereInput | boolean connect?: AdminUserWhereUniqueInput update?: XOR, AdminUserUncheckedUpdateWithoutOrderStatusEventsInput> } export type CustomerCreateNestedOneWithoutPreOrdersInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutPreOrdersInput connect?: CustomerWhereUniqueInput } export type CityCreateNestedOneWithoutPreOrdersInput = { create?: XOR connectOrCreate?: CityCreateOrConnectWithoutPreOrdersInput connect?: CityWhereUniqueInput } export type WorkshopCreateNestedOneWithoutPreOrdersInput = { create?: XOR connectOrCreate?: WorkshopCreateOrConnectWithoutPreOrdersInput connect?: WorkshopWhereUniqueInput } export type OrderCreateNestedOneWithoutConvertedFromPreOrderInput = { create?: XOR connectOrCreate?: OrderCreateOrConnectWithoutConvertedFromPreOrderInput connect?: OrderWhereUniqueInput } export type PreOrderStatusEventCreateNestedManyWithoutPreOrderInput = { create?: XOR | PreOrderStatusEventCreateWithoutPreOrderInput[] | PreOrderStatusEventUncheckedCreateWithoutPreOrderInput[] connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutPreOrderInput | PreOrderStatusEventCreateOrConnectWithoutPreOrderInput[] createMany?: PreOrderStatusEventCreateManyPreOrderInputEnvelope connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] } export type PreOrderStatusEventUncheckedCreateNestedManyWithoutPreOrderInput = { create?: XOR | PreOrderStatusEventCreateWithoutPreOrderInput[] | PreOrderStatusEventUncheckedCreateWithoutPreOrderInput[] connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutPreOrderInput | PreOrderStatusEventCreateOrConnectWithoutPreOrderInput[] createMany?: PreOrderStatusEventCreateManyPreOrderInputEnvelope connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] } export type EnumPreOrderStatusFieldUpdateOperationsInput = { set?: $Enums.PreOrderStatus } export type CustomerUpdateOneRequiredWithoutPreOrdersNestedInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutPreOrdersInput upsert?: CustomerUpsertWithoutPreOrdersInput connect?: CustomerWhereUniqueInput update?: XOR, CustomerUncheckedUpdateWithoutPreOrdersInput> } export type CityUpdateOneWithoutPreOrdersNestedInput = { create?: XOR connectOrCreate?: CityCreateOrConnectWithoutPreOrdersInput upsert?: CityUpsertWithoutPreOrdersInput disconnect?: CityWhereInput | boolean delete?: CityWhereInput | boolean connect?: CityWhereUniqueInput update?: XOR, CityUncheckedUpdateWithoutPreOrdersInput> } export type WorkshopUpdateOneWithoutPreOrdersNestedInput = { create?: XOR connectOrCreate?: WorkshopCreateOrConnectWithoutPreOrdersInput upsert?: WorkshopUpsertWithoutPreOrdersInput disconnect?: WorkshopWhereInput | boolean delete?: WorkshopWhereInput | boolean connect?: WorkshopWhereUniqueInput update?: XOR, WorkshopUncheckedUpdateWithoutPreOrdersInput> } export type OrderUpdateOneWithoutConvertedFromPreOrderNestedInput = { create?: XOR connectOrCreate?: OrderCreateOrConnectWithoutConvertedFromPreOrderInput upsert?: OrderUpsertWithoutConvertedFromPreOrderInput disconnect?: OrderWhereInput | boolean delete?: OrderWhereInput | boolean connect?: OrderWhereUniqueInput update?: XOR, OrderUncheckedUpdateWithoutConvertedFromPreOrderInput> } export type PreOrderStatusEventUpdateManyWithoutPreOrderNestedInput = { create?: XOR | PreOrderStatusEventCreateWithoutPreOrderInput[] | PreOrderStatusEventUncheckedCreateWithoutPreOrderInput[] connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutPreOrderInput | PreOrderStatusEventCreateOrConnectWithoutPreOrderInput[] upsert?: PreOrderStatusEventUpsertWithWhereUniqueWithoutPreOrderInput | PreOrderStatusEventUpsertWithWhereUniqueWithoutPreOrderInput[] createMany?: PreOrderStatusEventCreateManyPreOrderInputEnvelope set?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] disconnect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] delete?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] update?: PreOrderStatusEventUpdateWithWhereUniqueWithoutPreOrderInput | PreOrderStatusEventUpdateWithWhereUniqueWithoutPreOrderInput[] updateMany?: PreOrderStatusEventUpdateManyWithWhereWithoutPreOrderInput | PreOrderStatusEventUpdateManyWithWhereWithoutPreOrderInput[] deleteMany?: PreOrderStatusEventScalarWhereInput | PreOrderStatusEventScalarWhereInput[] } export type PreOrderStatusEventUncheckedUpdateManyWithoutPreOrderNestedInput = { create?: XOR | PreOrderStatusEventCreateWithoutPreOrderInput[] | PreOrderStatusEventUncheckedCreateWithoutPreOrderInput[] connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutPreOrderInput | PreOrderStatusEventCreateOrConnectWithoutPreOrderInput[] upsert?: PreOrderStatusEventUpsertWithWhereUniqueWithoutPreOrderInput | PreOrderStatusEventUpsertWithWhereUniqueWithoutPreOrderInput[] createMany?: PreOrderStatusEventCreateManyPreOrderInputEnvelope set?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] disconnect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] delete?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[] update?: PreOrderStatusEventUpdateWithWhereUniqueWithoutPreOrderInput | PreOrderStatusEventUpdateWithWhereUniqueWithoutPreOrderInput[] updateMany?: PreOrderStatusEventUpdateManyWithWhereWithoutPreOrderInput | PreOrderStatusEventUpdateManyWithWhereWithoutPreOrderInput[] deleteMany?: PreOrderStatusEventScalarWhereInput | PreOrderStatusEventScalarWhereInput[] } export type PreOrderCreateNestedOneWithoutStatusEventsInput = { create?: XOR connectOrCreate?: PreOrderCreateOrConnectWithoutStatusEventsInput connect?: PreOrderWhereUniqueInput } export type AdminUserCreateNestedOneWithoutPreOrderStatusEventsInput = { create?: XOR connectOrCreate?: AdminUserCreateOrConnectWithoutPreOrderStatusEventsInput connect?: AdminUserWhereUniqueInput } export type PreOrderUpdateOneRequiredWithoutStatusEventsNestedInput = { create?: XOR connectOrCreate?: PreOrderCreateOrConnectWithoutStatusEventsInput upsert?: PreOrderUpsertWithoutStatusEventsInput connect?: PreOrderWhereUniqueInput update?: XOR, PreOrderUncheckedUpdateWithoutStatusEventsInput> } export type AdminUserUpdateOneWithoutPreOrderStatusEventsNestedInput = { create?: XOR connectOrCreate?: AdminUserCreateOrConnectWithoutPreOrderStatusEventsInput upsert?: AdminUserUpsertWithoutPreOrderStatusEventsInput disconnect?: AdminUserWhereInput | boolean delete?: AdminUserWhereInput | boolean connect?: AdminUserWhereUniqueInput update?: XOR, AdminUserUncheckedUpdateWithoutPreOrderStatusEventsInput> } export type CustomerCreateNestedOneWithoutLedgerEntriesInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutLedgerEntriesInput connect?: CustomerWhereUniqueInput } export type OrderCreateNestedOneWithoutLedgerEntriesInput = { create?: XOR connectOrCreate?: OrderCreateOrConnectWithoutLedgerEntriesInput connect?: OrderWhereUniqueInput } export type AdminUserCreateNestedOneWithoutPostedLedgerEntriesInput = { create?: XOR connectOrCreate?: AdminUserCreateOrConnectWithoutPostedLedgerEntriesInput connect?: AdminUserWhereUniqueInput } export type EnumLedgerCurrencyFieldUpdateOperationsInput = { set?: $Enums.LedgerCurrency } export type EnumLedgerDirectionFieldUpdateOperationsInput = { set?: $Enums.LedgerDirection } export type EnumLedgerSourceTypeFieldUpdateOperationsInput = { set?: $Enums.LedgerSourceType } export type NullableIntFieldUpdateOperationsInput = { set?: number | null increment?: number decrement?: number multiply?: number divide?: number } export type CustomerUpdateOneRequiredWithoutLedgerEntriesNestedInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutLedgerEntriesInput upsert?: CustomerUpsertWithoutLedgerEntriesInput connect?: CustomerWhereUniqueInput update?: XOR, CustomerUncheckedUpdateWithoutLedgerEntriesInput> } export type OrderUpdateOneWithoutLedgerEntriesNestedInput = { create?: XOR connectOrCreate?: OrderCreateOrConnectWithoutLedgerEntriesInput upsert?: OrderUpsertWithoutLedgerEntriesInput disconnect?: OrderWhereInput | boolean delete?: OrderWhereInput | boolean connect?: OrderWhereUniqueInput update?: XOR, OrderUncheckedUpdateWithoutLedgerEntriesInput> } export type AdminUserUpdateOneWithoutPostedLedgerEntriesNestedInput = { create?: XOR connectOrCreate?: AdminUserCreateOrConnectWithoutPostedLedgerEntriesInput upsert?: AdminUserUpsertWithoutPostedLedgerEntriesInput disconnect?: AdminUserWhereInput | boolean delete?: AdminUserWhereInput | boolean connect?: AdminUserWhereUniqueInput update?: XOR, AdminUserUncheckedUpdateWithoutPostedLedgerEntriesInput> } export type CustomerCreateNestedOneWithoutWalletBonusesInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutWalletBonusesInput connect?: CustomerWhereUniqueInput } export type CustomerUpdateOneRequiredWithoutWalletBonusesNestedInput = { create?: XOR connectOrCreate?: CustomerCreateOrConnectWithoutWalletBonusesInput upsert?: CustomerUpsertWithoutWalletBonusesInput connect?: CustomerWhereUniqueInput update?: XOR, CustomerUncheckedUpdateWithoutWalletBonusesInput> } export type NestedStringFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> in?: string[] | ListStringFieldRefInput<$PrismaModel> notIn?: string[] | ListStringFieldRefInput<$PrismaModel> lt?: string | StringFieldRefInput<$PrismaModel> lte?: string | StringFieldRefInput<$PrismaModel> gt?: string | StringFieldRefInput<$PrismaModel> gte?: string | StringFieldRefInput<$PrismaModel> contains?: string | StringFieldRefInput<$PrismaModel> startsWith?: string | StringFieldRefInput<$PrismaModel> endsWith?: string | StringFieldRefInput<$PrismaModel> not?: NestedStringFilter<$PrismaModel> | string } export type NestedStringNullableFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> | null in?: string[] | ListStringFieldRefInput<$PrismaModel> | null notIn?: string[] | ListStringFieldRefInput<$PrismaModel> | null lt?: string | StringFieldRefInput<$PrismaModel> lte?: string | StringFieldRefInput<$PrismaModel> gt?: string | StringFieldRefInput<$PrismaModel> gte?: string | StringFieldRefInput<$PrismaModel> contains?: string | StringFieldRefInput<$PrismaModel> startsWith?: string | StringFieldRefInput<$PrismaModel> endsWith?: string | StringFieldRefInput<$PrismaModel> not?: NestedStringNullableFilter<$PrismaModel> | string | null } export type NestedStringWithAggregatesFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> in?: string[] | ListStringFieldRefInput<$PrismaModel> notIn?: string[] | ListStringFieldRefInput<$PrismaModel> lt?: string | StringFieldRefInput<$PrismaModel> lte?: string | StringFieldRefInput<$PrismaModel> gt?: string | StringFieldRefInput<$PrismaModel> gte?: string | StringFieldRefInput<$PrismaModel> contains?: string | StringFieldRefInput<$PrismaModel> startsWith?: string | StringFieldRefInput<$PrismaModel> endsWith?: string | StringFieldRefInput<$PrismaModel> not?: NestedStringWithAggregatesFilter<$PrismaModel> | string _count?: NestedIntFilter<$PrismaModel> _min?: NestedStringFilter<$PrismaModel> _max?: NestedStringFilter<$PrismaModel> } export type NestedIntFilter<$PrismaModel = never> = { equals?: number | IntFieldRefInput<$PrismaModel> in?: number[] | ListIntFieldRefInput<$PrismaModel> notIn?: number[] | ListIntFieldRefInput<$PrismaModel> lt?: number | IntFieldRefInput<$PrismaModel> lte?: number | IntFieldRefInput<$PrismaModel> gt?: number | IntFieldRefInput<$PrismaModel> gte?: number | IntFieldRefInput<$PrismaModel> not?: NestedIntFilter<$PrismaModel> | number } export type NestedStringNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: string | StringFieldRefInput<$PrismaModel> | null in?: string[] | ListStringFieldRefInput<$PrismaModel> | null notIn?: string[] | ListStringFieldRefInput<$PrismaModel> | null lt?: string | StringFieldRefInput<$PrismaModel> lte?: string | StringFieldRefInput<$PrismaModel> gt?: string | StringFieldRefInput<$PrismaModel> gte?: string | StringFieldRefInput<$PrismaModel> contains?: string | StringFieldRefInput<$PrismaModel> startsWith?: string | StringFieldRefInput<$PrismaModel> endsWith?: string | StringFieldRefInput<$PrismaModel> not?: NestedStringNullableWithAggregatesFilter<$PrismaModel> | string | null _count?: NestedIntNullableFilter<$PrismaModel> _min?: NestedStringNullableFilter<$PrismaModel> _max?: NestedStringNullableFilter<$PrismaModel> } export type NestedIntNullableFilter<$PrismaModel = never> = { equals?: number | IntFieldRefInput<$PrismaModel> | null in?: number[] | ListIntFieldRefInput<$PrismaModel> | null notIn?: number[] | ListIntFieldRefInput<$PrismaModel> | null lt?: number | IntFieldRefInput<$PrismaModel> lte?: number | IntFieldRefInput<$PrismaModel> gt?: number | IntFieldRefInput<$PrismaModel> gte?: number | IntFieldRefInput<$PrismaModel> not?: NestedIntNullableFilter<$PrismaModel> | number | null } export type NestedEnumAdminRoleFilter<$PrismaModel = never> = { equals?: $Enums.AdminRole | EnumAdminRoleFieldRefInput<$PrismaModel> in?: $Enums.AdminRole[] | ListEnumAdminRoleFieldRefInput<$PrismaModel> notIn?: $Enums.AdminRole[] | ListEnumAdminRoleFieldRefInput<$PrismaModel> not?: NestedEnumAdminRoleFilter<$PrismaModel> | $Enums.AdminRole } export type NestedDecimalNullableFilter<$PrismaModel = never> = { equals?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> | null in?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> | null notIn?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> | null lt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> lte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> not?: NestedDecimalNullableFilter<$PrismaModel> | Decimal | DecimalJsLike | number | string | null } export type NestedBoolFilter<$PrismaModel = never> = { equals?: boolean | BooleanFieldRefInput<$PrismaModel> not?: NestedBoolFilter<$PrismaModel> | boolean } export type NestedDateTimeFilter<$PrismaModel = never> = { equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> not?: NestedDateTimeFilter<$PrismaModel> | Date | string } export type NestedEnumAdminRoleWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.AdminRole | EnumAdminRoleFieldRefInput<$PrismaModel> in?: $Enums.AdminRole[] | ListEnumAdminRoleFieldRefInput<$PrismaModel> notIn?: $Enums.AdminRole[] | ListEnumAdminRoleFieldRefInput<$PrismaModel> not?: NestedEnumAdminRoleWithAggregatesFilter<$PrismaModel> | $Enums.AdminRole _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumAdminRoleFilter<$PrismaModel> _max?: NestedEnumAdminRoleFilter<$PrismaModel> } export type NestedDecimalNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> | null in?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> | null notIn?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> | null lt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> lte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> not?: NestedDecimalNullableWithAggregatesFilter<$PrismaModel> | Decimal | DecimalJsLike | number | string | null _count?: NestedIntNullableFilter<$PrismaModel> _avg?: NestedDecimalNullableFilter<$PrismaModel> _sum?: NestedDecimalNullableFilter<$PrismaModel> _min?: NestedDecimalNullableFilter<$PrismaModel> _max?: NestedDecimalNullableFilter<$PrismaModel> } export type NestedBoolWithAggregatesFilter<$PrismaModel = never> = { equals?: boolean | BooleanFieldRefInput<$PrismaModel> not?: NestedBoolWithAggregatesFilter<$PrismaModel> | boolean _count?: NestedIntFilter<$PrismaModel> _min?: NestedBoolFilter<$PrismaModel> _max?: NestedBoolFilter<$PrismaModel> } export type NestedDateTimeWithAggregatesFilter<$PrismaModel = never> = { equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> not?: NestedDateTimeWithAggregatesFilter<$PrismaModel> | Date | string _count?: NestedIntFilter<$PrismaModel> _min?: NestedDateTimeFilter<$PrismaModel> _max?: NestedDateTimeFilter<$PrismaModel> } export type NestedDecimalFilter<$PrismaModel = never> = { equals?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> in?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> notIn?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> lt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> lte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> not?: NestedDecimalFilter<$PrismaModel> | Decimal | DecimalJsLike | number | string } export type NestedEnumVerificationStepFilter<$PrismaModel = never> = { equals?: $Enums.VerificationStep | EnumVerificationStepFieldRefInput<$PrismaModel> in?: $Enums.VerificationStep[] | ListEnumVerificationStepFieldRefInput<$PrismaModel> notIn?: $Enums.VerificationStep[] | ListEnumVerificationStepFieldRefInput<$PrismaModel> not?: NestedEnumVerificationStepFilter<$PrismaModel> | $Enums.VerificationStep } export type NestedDecimalWithAggregatesFilter<$PrismaModel = never> = { equals?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> in?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> notIn?: Decimal[] | DecimalJsLike[] | number[] | string[] | ListDecimalFieldRefInput<$PrismaModel> lt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> lte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gt?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> gte?: Decimal | DecimalJsLike | number | string | DecimalFieldRefInput<$PrismaModel> not?: NestedDecimalWithAggregatesFilter<$PrismaModel> | Decimal | DecimalJsLike | number | string _count?: NestedIntFilter<$PrismaModel> _avg?: NestedDecimalFilter<$PrismaModel> _sum?: NestedDecimalFilter<$PrismaModel> _min?: NestedDecimalFilter<$PrismaModel> _max?: NestedDecimalFilter<$PrismaModel> } export type NestedEnumVerificationStepWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.VerificationStep | EnumVerificationStepFieldRefInput<$PrismaModel> in?: $Enums.VerificationStep[] | ListEnumVerificationStepFieldRefInput<$PrismaModel> notIn?: $Enums.VerificationStep[] | ListEnumVerificationStepFieldRefInput<$PrismaModel> not?: NestedEnumVerificationStepWithAggregatesFilter<$PrismaModel> | $Enums.VerificationStep _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumVerificationStepFilter<$PrismaModel> _max?: NestedEnumVerificationStepFilter<$PrismaModel> } export type NestedIntWithAggregatesFilter<$PrismaModel = never> = { equals?: number | IntFieldRefInput<$PrismaModel> in?: number[] | ListIntFieldRefInput<$PrismaModel> notIn?: number[] | ListIntFieldRefInput<$PrismaModel> lt?: number | IntFieldRefInput<$PrismaModel> lte?: number | IntFieldRefInput<$PrismaModel> gt?: number | IntFieldRefInput<$PrismaModel> gte?: number | IntFieldRefInput<$PrismaModel> not?: NestedIntWithAggregatesFilter<$PrismaModel> | number _count?: NestedIntFilter<$PrismaModel> _avg?: NestedFloatFilter<$PrismaModel> _sum?: NestedIntFilter<$PrismaModel> _min?: NestedIntFilter<$PrismaModel> _max?: NestedIntFilter<$PrismaModel> } export type NestedFloatFilter<$PrismaModel = never> = { equals?: number | FloatFieldRefInput<$PrismaModel> in?: number[] | ListFloatFieldRefInput<$PrismaModel> notIn?: number[] | ListFloatFieldRefInput<$PrismaModel> lt?: number | FloatFieldRefInput<$PrismaModel> lte?: number | FloatFieldRefInput<$PrismaModel> gt?: number | FloatFieldRefInput<$PrismaModel> gte?: number | FloatFieldRefInput<$PrismaModel> not?: NestedFloatFilter<$PrismaModel> | number } export type NestedEnumOrderStatusFilter<$PrismaModel = never> = { equals?: $Enums.OrderStatus | EnumOrderStatusFieldRefInput<$PrismaModel> in?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> notIn?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> not?: NestedEnumOrderStatusFilter<$PrismaModel> | $Enums.OrderStatus } export type NestedDateTimeNullableFilter<$PrismaModel = never> = { equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> | null in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> | null notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> | null lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> not?: NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null } export type NestedEnumOrderStatusWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.OrderStatus | EnumOrderStatusFieldRefInput<$PrismaModel> in?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> notIn?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> not?: NestedEnumOrderStatusWithAggregatesFilter<$PrismaModel> | $Enums.OrderStatus _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumOrderStatusFilter<$PrismaModel> _max?: NestedEnumOrderStatusFilter<$PrismaModel> } export type NestedDateTimeNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> | null in?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> | null notIn?: Date[] | string[] | ListDateTimeFieldRefInput<$PrismaModel> | null lt?: Date | string | DateTimeFieldRefInput<$PrismaModel> lte?: Date | string | DateTimeFieldRefInput<$PrismaModel> gt?: Date | string | DateTimeFieldRefInput<$PrismaModel> gte?: Date | string | DateTimeFieldRefInput<$PrismaModel> not?: NestedDateTimeNullableWithAggregatesFilter<$PrismaModel> | Date | string | null _count?: NestedIntNullableFilter<$PrismaModel> _min?: NestedDateTimeNullableFilter<$PrismaModel> _max?: NestedDateTimeNullableFilter<$PrismaModel> } export type NestedEnumOrderStatusNullableFilter<$PrismaModel = never> = { equals?: $Enums.OrderStatus | EnumOrderStatusFieldRefInput<$PrismaModel> | null in?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> | null notIn?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> | null not?: NestedEnumOrderStatusNullableFilter<$PrismaModel> | $Enums.OrderStatus | null } export type NestedEnumOrderStatusNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.OrderStatus | EnumOrderStatusFieldRefInput<$PrismaModel> | null in?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> | null notIn?: $Enums.OrderStatus[] | ListEnumOrderStatusFieldRefInput<$PrismaModel> | null not?: NestedEnumOrderStatusNullableWithAggregatesFilter<$PrismaModel> | $Enums.OrderStatus | null _count?: NestedIntNullableFilter<$PrismaModel> _min?: NestedEnumOrderStatusNullableFilter<$PrismaModel> _max?: NestedEnumOrderStatusNullableFilter<$PrismaModel> } export type NestedEnumPreOrderStatusFilter<$PrismaModel = never> = { equals?: $Enums.PreOrderStatus | EnumPreOrderStatusFieldRefInput<$PrismaModel> in?: $Enums.PreOrderStatus[] | ListEnumPreOrderStatusFieldRefInput<$PrismaModel> notIn?: $Enums.PreOrderStatus[] | ListEnumPreOrderStatusFieldRefInput<$PrismaModel> not?: NestedEnumPreOrderStatusFilter<$PrismaModel> | $Enums.PreOrderStatus } export type NestedEnumPreOrderStatusWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.PreOrderStatus | EnumPreOrderStatusFieldRefInput<$PrismaModel> in?: $Enums.PreOrderStatus[] | ListEnumPreOrderStatusFieldRefInput<$PrismaModel> notIn?: $Enums.PreOrderStatus[] | ListEnumPreOrderStatusFieldRefInput<$PrismaModel> not?: NestedEnumPreOrderStatusWithAggregatesFilter<$PrismaModel> | $Enums.PreOrderStatus _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumPreOrderStatusFilter<$PrismaModel> _max?: NestedEnumPreOrderStatusFilter<$PrismaModel> } export type NestedJsonFilter<$PrismaModel = never> = | PatchUndefined< Either>, Exclude>, 'path'>>, Required> > | OptionalFlat>, 'path'>> export type NestedJsonFilterBase<$PrismaModel = never> = { equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter path?: string[] string_contains?: string | StringFieldRefInput<$PrismaModel> string_starts_with?: string | StringFieldRefInput<$PrismaModel> string_ends_with?: string | StringFieldRefInput<$PrismaModel> array_contains?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null lt?: InputJsonValue | JsonFieldRefInput<$PrismaModel> lte?: InputJsonValue | JsonFieldRefInput<$PrismaModel> gt?: InputJsonValue | JsonFieldRefInput<$PrismaModel> gte?: InputJsonValue | JsonFieldRefInput<$PrismaModel> not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter } export type NestedEnumLedgerCurrencyFilter<$PrismaModel = never> = { equals?: $Enums.LedgerCurrency | EnumLedgerCurrencyFieldRefInput<$PrismaModel> in?: $Enums.LedgerCurrency[] | ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerCurrency[] | ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> not?: NestedEnumLedgerCurrencyFilter<$PrismaModel> | $Enums.LedgerCurrency } export type NestedEnumLedgerDirectionFilter<$PrismaModel = never> = { equals?: $Enums.LedgerDirection | EnumLedgerDirectionFieldRefInput<$PrismaModel> in?: $Enums.LedgerDirection[] | ListEnumLedgerDirectionFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerDirection[] | ListEnumLedgerDirectionFieldRefInput<$PrismaModel> not?: NestedEnumLedgerDirectionFilter<$PrismaModel> | $Enums.LedgerDirection } export type NestedEnumLedgerSourceTypeFilter<$PrismaModel = never> = { equals?: $Enums.LedgerSourceType | EnumLedgerSourceTypeFieldRefInput<$PrismaModel> in?: $Enums.LedgerSourceType[] | ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerSourceType[] | ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> not?: NestedEnumLedgerSourceTypeFilter<$PrismaModel> | $Enums.LedgerSourceType } export type NestedEnumLedgerCurrencyWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.LedgerCurrency | EnumLedgerCurrencyFieldRefInput<$PrismaModel> in?: $Enums.LedgerCurrency[] | ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerCurrency[] | ListEnumLedgerCurrencyFieldRefInput<$PrismaModel> not?: NestedEnumLedgerCurrencyWithAggregatesFilter<$PrismaModel> | $Enums.LedgerCurrency _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumLedgerCurrencyFilter<$PrismaModel> _max?: NestedEnumLedgerCurrencyFilter<$PrismaModel> } export type NestedEnumLedgerDirectionWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.LedgerDirection | EnumLedgerDirectionFieldRefInput<$PrismaModel> in?: $Enums.LedgerDirection[] | ListEnumLedgerDirectionFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerDirection[] | ListEnumLedgerDirectionFieldRefInput<$PrismaModel> not?: NestedEnumLedgerDirectionWithAggregatesFilter<$PrismaModel> | $Enums.LedgerDirection _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumLedgerDirectionFilter<$PrismaModel> _max?: NestedEnumLedgerDirectionFilter<$PrismaModel> } export type NestedEnumLedgerSourceTypeWithAggregatesFilter<$PrismaModel = never> = { equals?: $Enums.LedgerSourceType | EnumLedgerSourceTypeFieldRefInput<$PrismaModel> in?: $Enums.LedgerSourceType[] | ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> notIn?: $Enums.LedgerSourceType[] | ListEnumLedgerSourceTypeFieldRefInput<$PrismaModel> not?: NestedEnumLedgerSourceTypeWithAggregatesFilter<$PrismaModel> | $Enums.LedgerSourceType _count?: NestedIntFilter<$PrismaModel> _min?: NestedEnumLedgerSourceTypeFilter<$PrismaModel> _max?: NestedEnumLedgerSourceTypeFilter<$PrismaModel> } export type NestedIntNullableWithAggregatesFilter<$PrismaModel = never> = { equals?: number | IntFieldRefInput<$PrismaModel> | null in?: number[] | ListIntFieldRefInput<$PrismaModel> | null notIn?: number[] | ListIntFieldRefInput<$PrismaModel> | null lt?: number | IntFieldRefInput<$PrismaModel> lte?: number | IntFieldRefInput<$PrismaModel> gt?: number | IntFieldRefInput<$PrismaModel> gte?: number | IntFieldRefInput<$PrismaModel> not?: NestedIntNullableWithAggregatesFilter<$PrismaModel> | number | null _count?: NestedIntNullableFilter<$PrismaModel> _avg?: NestedFloatNullableFilter<$PrismaModel> _sum?: NestedIntNullableFilter<$PrismaModel> _min?: NestedIntNullableFilter<$PrismaModel> _max?: NestedIntNullableFilter<$PrismaModel> } export type NestedFloatNullableFilter<$PrismaModel = never> = { equals?: number | FloatFieldRefInput<$PrismaModel> | null in?: number[] | ListFloatFieldRefInput<$PrismaModel> | null notIn?: number[] | ListFloatFieldRefInput<$PrismaModel> | null lt?: number | FloatFieldRefInput<$PrismaModel> lte?: number | FloatFieldRefInput<$PrismaModel> gt?: number | FloatFieldRefInput<$PrismaModel> gte?: number | FloatFieldRefInput<$PrismaModel> not?: NestedFloatNullableFilter<$PrismaModel> | number | null } export type CustomerCreateWithoutCityInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string referredByAgent?: AdminUserCreateNestedOneWithoutReferredCustomersInput addresses?: CustomerAddressCreateNestedManyWithoutCustomerInput orders?: OrderCreateNestedManyWithoutCustomerInput preOrders?: PreOrderCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusCreateNestedManyWithoutCustomerInput } export type CustomerUncheckedCreateWithoutCityInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput orders?: OrderUncheckedCreateNestedManyWithoutCustomerInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusUncheckedCreateNestedManyWithoutCustomerInput } export type CustomerCreateOrConnectWithoutCityInput = { where: CustomerWhereUniqueInput create: XOR } export type CustomerCreateManyCityInputEnvelope = { data: CustomerCreateManyCityInput | CustomerCreateManyCityInput[] skipDuplicates?: boolean } export type CustomerAddressCreateWithoutCityInput = { id?: string addressLine: string isDefault?: boolean customer: CustomerCreateNestedOneWithoutAddressesInput } export type CustomerAddressUncheckedCreateWithoutCityInput = { id?: string customerId: string addressLine: string isDefault?: boolean } export type CustomerAddressCreateOrConnectWithoutCityInput = { where: CustomerAddressWhereUniqueInput create: XOR } export type CustomerAddressCreateManyCityInputEnvelope = { data: CustomerAddressCreateManyCityInput | CustomerAddressCreateManyCityInput[] skipDuplicates?: boolean } export type BranchCreateWithoutCityInput = { id?: string name: string adminUsers?: AdminUserCreateNestedManyWithoutBranchInput orders?: OrderCreateNestedManyWithoutBranchInput } export type BranchUncheckedCreateWithoutCityInput = { id?: string name: string adminUsers?: AdminUserUncheckedCreateNestedManyWithoutBranchInput orders?: OrderUncheckedCreateNestedManyWithoutBranchInput } export type BranchCreateOrConnectWithoutCityInput = { where: BranchWhereUniqueInput create: XOR } export type BranchCreateManyCityInputEnvelope = { data: BranchCreateManyCityInput | BranchCreateManyCityInput[] skipDuplicates?: boolean } export type PreOrderCreateWithoutCityInput = { id?: string status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutPreOrdersInput workshop?: WorkshopCreateNestedOneWithoutPreOrdersInput convertedOrder?: OrderCreateNestedOneWithoutConvertedFromPreOrderInput statusEvents?: PreOrderStatusEventCreateNestedManyWithoutPreOrderInput } export type PreOrderUncheckedCreateWithoutCityInput = { id?: string customerId: string workshopId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string statusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutPreOrderInput } export type PreOrderCreateOrConnectWithoutCityInput = { where: PreOrderWhereUniqueInput create: XOR } export type PreOrderCreateManyCityInputEnvelope = { data: PreOrderCreateManyCityInput | PreOrderCreateManyCityInput[] skipDuplicates?: boolean } export type CustomerUpsertWithWhereUniqueWithoutCityInput = { where: CustomerWhereUniqueInput update: XOR create: XOR } export type CustomerUpdateWithWhereUniqueWithoutCityInput = { where: CustomerWhereUniqueInput data: XOR } export type CustomerUpdateManyWithWhereWithoutCityInput = { where: CustomerScalarWhereInput data: XOR } export type CustomerScalarWhereInput = { AND?: CustomerScalarWhereInput | CustomerScalarWhereInput[] OR?: CustomerScalarWhereInput[] NOT?: CustomerScalarWhereInput | CustomerScalarWhereInput[] id?: StringFilter<"Customer"> | string fullName?: StringFilter<"Customer"> | string mobile?: StringFilter<"Customer"> | string nationalCode?: StringFilter<"Customer"> | string passwordHash?: StringFilter<"Customer"> | string cityId?: StringNullableFilter<"Customer"> | string | null referredByAgentId?: StringNullableFilter<"Customer"> | string | null goldCreditLimitGrams?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFilter<"Customer"> | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFilter<"Customer"> | $Enums.VerificationStep nationalIdImageUrl?: StringNullableFilter<"Customer"> | string | null businessLicenseUrl?: StringNullableFilter<"Customer"> | string | null shopImageUrl?: StringNullableFilter<"Customer"> | string | null isActive?: BoolFilter<"Customer"> | boolean createdAt?: DateTimeFilter<"Customer"> | Date | string updatedAt?: DateTimeFilter<"Customer"> | Date | string } export type CustomerAddressUpsertWithWhereUniqueWithoutCityInput = { where: CustomerAddressWhereUniqueInput update: XOR create: XOR } export type CustomerAddressUpdateWithWhereUniqueWithoutCityInput = { where: CustomerAddressWhereUniqueInput data: XOR } export type CustomerAddressUpdateManyWithWhereWithoutCityInput = { where: CustomerAddressScalarWhereInput data: XOR } export type CustomerAddressScalarWhereInput = { AND?: CustomerAddressScalarWhereInput | CustomerAddressScalarWhereInput[] OR?: CustomerAddressScalarWhereInput[] NOT?: CustomerAddressScalarWhereInput | CustomerAddressScalarWhereInput[] id?: StringFilter<"CustomerAddress"> | string customerId?: StringFilter<"CustomerAddress"> | string cityId?: StringNullableFilter<"CustomerAddress"> | string | null addressLine?: StringFilter<"CustomerAddress"> | string isDefault?: BoolFilter<"CustomerAddress"> | boolean } export type BranchUpsertWithWhereUniqueWithoutCityInput = { where: BranchWhereUniqueInput update: XOR create: XOR } export type BranchUpdateWithWhereUniqueWithoutCityInput = { where: BranchWhereUniqueInput data: XOR } export type BranchUpdateManyWithWhereWithoutCityInput = { where: BranchScalarWhereInput data: XOR } export type BranchScalarWhereInput = { AND?: BranchScalarWhereInput | BranchScalarWhereInput[] OR?: BranchScalarWhereInput[] NOT?: BranchScalarWhereInput | BranchScalarWhereInput[] id?: StringFilter<"Branch"> | string name?: StringFilter<"Branch"> | string cityId?: StringNullableFilter<"Branch"> | string | null } export type PreOrderUpsertWithWhereUniqueWithoutCityInput = { where: PreOrderWhereUniqueInput update: XOR create: XOR } export type PreOrderUpdateWithWhereUniqueWithoutCityInput = { where: PreOrderWhereUniqueInput data: XOR } export type PreOrderUpdateManyWithWhereWithoutCityInput = { where: PreOrderScalarWhereInput data: XOR } export type PreOrderScalarWhereInput = { AND?: PreOrderScalarWhereInput | PreOrderScalarWhereInput[] OR?: PreOrderScalarWhereInput[] NOT?: PreOrderScalarWhereInput | PreOrderScalarWhereInput[] id?: StringFilter<"PreOrder"> | string customerId?: StringFilter<"PreOrder"> | string cityId?: StringNullableFilter<"PreOrder"> | string | null workshopId?: StringNullableFilter<"PreOrder"> | string | null status?: EnumPreOrderStatusFilter<"PreOrder"> | $Enums.PreOrderStatus designImageUrl?: StringNullableFilter<"PreOrder"> | string | null colorName?: StringNullableFilter<"PreOrder"> | string | null sizeSpec?: StringNullableFilter<"PreOrder"> | string | null stoneColor?: StringNullableFilter<"PreOrder"> | string | null minaColor?: StringNullableFilter<"PreOrder"> | string | null estimatedWeightGrams?: DecimalNullableFilter<"PreOrder"> | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: DecimalNullableFilter<"PreOrder"> | Decimal | DecimalJsLike | number | string | null description?: StringNullableFilter<"PreOrder"> | string | null convertedOrderId?: StringNullableFilter<"PreOrder"> | string | null createdAt?: DateTimeFilter<"PreOrder"> | Date | string updatedAt?: DateTimeFilter<"PreOrder"> | Date | string } export type BranchCreateWithoutAdminUsersInput = { id?: string name: string city?: CityCreateNestedOneWithoutBranchesInput orders?: OrderCreateNestedManyWithoutBranchInput } export type BranchUncheckedCreateWithoutAdminUsersInput = { id?: string name: string cityId?: string | null orders?: OrderUncheckedCreateNestedManyWithoutBranchInput } export type BranchCreateOrConnectWithoutAdminUsersInput = { where: BranchWhereUniqueInput create: XOR } export type CustomerCreateWithoutReferredByAgentInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string city?: CityCreateNestedOneWithoutCustomersInput addresses?: CustomerAddressCreateNestedManyWithoutCustomerInput orders?: OrderCreateNestedManyWithoutCustomerInput preOrders?: PreOrderCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusCreateNestedManyWithoutCustomerInput } export type CustomerUncheckedCreateWithoutReferredByAgentInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput orders?: OrderUncheckedCreateNestedManyWithoutCustomerInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusUncheckedCreateNestedManyWithoutCustomerInput } export type CustomerCreateOrConnectWithoutReferredByAgentInput = { where: CustomerWhereUniqueInput create: XOR } export type CustomerCreateManyReferredByAgentInputEnvelope = { data: CustomerCreateManyReferredByAgentInput | CustomerCreateManyReferredByAgentInput[] skipDuplicates?: boolean } export type LedgerEntryCreateWithoutPostedByAdminUserInput = { id?: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null confirmed?: boolean confirmedAt?: Date | string | null note?: string | null createdAt?: Date | string customer: CustomerCreateNestedOneWithoutLedgerEntriesInput order?: OrderCreateNestedOneWithoutLedgerEntriesInput } export type LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput = { id?: string customerId: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null orderId?: string | null confirmed?: boolean confirmedAt?: Date | string | null note?: string | null createdAt?: Date | string } export type LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput = { where: LedgerEntryWhereUniqueInput create: XOR } export type LedgerEntryCreateManyPostedByAdminUserInputEnvelope = { data: LedgerEntryCreateManyPostedByAdminUserInput | LedgerEntryCreateManyPostedByAdminUserInput[] skipDuplicates?: boolean } export type OrderStatusEventCreateWithoutActorAdminUserInput = { id?: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null createdAt?: Date | string order: OrderCreateNestedOneWithoutStatusEventsInput } export type OrderStatusEventUncheckedCreateWithoutActorAdminUserInput = { id?: string orderId: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null createdAt?: Date | string } export type OrderStatusEventCreateOrConnectWithoutActorAdminUserInput = { where: OrderStatusEventWhereUniqueInput create: XOR } export type OrderStatusEventCreateManyActorAdminUserInputEnvelope = { data: OrderStatusEventCreateManyActorAdminUserInput | OrderStatusEventCreateManyActorAdminUserInput[] skipDuplicates?: boolean } export type PreOrderStatusEventCreateWithoutActorAdminUserInput = { id?: string changes: JsonNullValueInput | InputJsonValue ipAddress?: string | null createdAt?: Date | string preOrder: PreOrderCreateNestedOneWithoutStatusEventsInput } export type PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput = { id?: string preOrderId: string changes: JsonNullValueInput | InputJsonValue ipAddress?: string | null createdAt?: Date | string } export type PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput = { where: PreOrderStatusEventWhereUniqueInput create: XOR } export type PreOrderStatusEventCreateManyActorAdminUserInputEnvelope = { data: PreOrderStatusEventCreateManyActorAdminUserInput | PreOrderStatusEventCreateManyActorAdminUserInput[] skipDuplicates?: boolean } export type BranchUpsertWithoutAdminUsersInput = { update: XOR create: XOR where?: BranchWhereInput } export type BranchUpdateToOneWithWhereWithoutAdminUsersInput = { where?: BranchWhereInput data: XOR } export type BranchUpdateWithoutAdminUsersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string city?: CityUpdateOneWithoutBranchesNestedInput orders?: OrderUpdateManyWithoutBranchNestedInput } export type BranchUncheckedUpdateWithoutAdminUsersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null orders?: OrderUncheckedUpdateManyWithoutBranchNestedInput } export type CustomerUpsertWithWhereUniqueWithoutReferredByAgentInput = { where: CustomerWhereUniqueInput update: XOR create: XOR } export type CustomerUpdateWithWhereUniqueWithoutReferredByAgentInput = { where: CustomerWhereUniqueInput data: XOR } export type CustomerUpdateManyWithWhereWithoutReferredByAgentInput = { where: CustomerScalarWhereInput data: XOR } export type LedgerEntryUpsertWithWhereUniqueWithoutPostedByAdminUserInput = { where: LedgerEntryWhereUniqueInput update: XOR create: XOR } export type LedgerEntryUpdateWithWhereUniqueWithoutPostedByAdminUserInput = { where: LedgerEntryWhereUniqueInput data: XOR } export type LedgerEntryUpdateManyWithWhereWithoutPostedByAdminUserInput = { where: LedgerEntryScalarWhereInput data: XOR } export type LedgerEntryScalarWhereInput = { AND?: LedgerEntryScalarWhereInput | LedgerEntryScalarWhereInput[] OR?: LedgerEntryScalarWhereInput[] NOT?: LedgerEntryScalarWhereInput | LedgerEntryScalarWhereInput[] id?: StringFilter<"LedgerEntry"> | string customerId?: StringFilter<"LedgerEntry"> | string currency?: EnumLedgerCurrencyFilter<"LedgerEntry"> | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFilter<"LedgerEntry"> | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFilter<"LedgerEntry"> | $Enums.LedgerSourceType amount?: DecimalFilter<"LedgerEntry"> | Decimal | DecimalJsLike | number | string karatPerMille?: IntNullableFilter<"LedgerEntry"> | number | null pricePerGramRialAtEntry?: DecimalNullableFilter<"LedgerEntry"> | Decimal | DecimalJsLike | number | string | null orderId?: StringNullableFilter<"LedgerEntry"> | string | null confirmed?: BoolFilter<"LedgerEntry"> | boolean confirmedAt?: DateTimeNullableFilter<"LedgerEntry"> | Date | string | null postedByAdminUserId?: StringNullableFilter<"LedgerEntry"> | string | null note?: StringNullableFilter<"LedgerEntry"> | string | null createdAt?: DateTimeFilter<"LedgerEntry"> | Date | string } export type OrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput = { where: OrderStatusEventWhereUniqueInput update: XOR create: XOR } export type OrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput = { where: OrderStatusEventWhereUniqueInput data: XOR } export type OrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput = { where: OrderStatusEventScalarWhereInput data: XOR } export type OrderStatusEventScalarWhereInput = { AND?: OrderStatusEventScalarWhereInput | OrderStatusEventScalarWhereInput[] OR?: OrderStatusEventScalarWhereInput[] NOT?: OrderStatusEventScalarWhereInput | OrderStatusEventScalarWhereInput[] id?: StringFilter<"OrderStatusEvent"> | string orderId?: StringFilter<"OrderStatusEvent"> | string fromStatus?: EnumOrderStatusNullableFilter<"OrderStatusEvent"> | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFilter<"OrderStatusEvent"> | $Enums.OrderStatus note?: StringNullableFilter<"OrderStatusEvent"> | string | null actorAdminUserId?: StringNullableFilter<"OrderStatusEvent"> | string | null createdAt?: DateTimeFilter<"OrderStatusEvent"> | Date | string } export type PreOrderStatusEventUpsertWithWhereUniqueWithoutActorAdminUserInput = { where: PreOrderStatusEventWhereUniqueInput update: XOR create: XOR } export type PreOrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput = { where: PreOrderStatusEventWhereUniqueInput data: XOR } export type PreOrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput = { where: PreOrderStatusEventScalarWhereInput data: XOR } export type PreOrderStatusEventScalarWhereInput = { AND?: PreOrderStatusEventScalarWhereInput | PreOrderStatusEventScalarWhereInput[] OR?: PreOrderStatusEventScalarWhereInput[] NOT?: PreOrderStatusEventScalarWhereInput | PreOrderStatusEventScalarWhereInput[] id?: StringFilter<"PreOrderStatusEvent"> | string preOrderId?: StringFilter<"PreOrderStatusEvent"> | string changes?: JsonFilter<"PreOrderStatusEvent"> actorAdminUserId?: StringNullableFilter<"PreOrderStatusEvent"> | string | null ipAddress?: StringNullableFilter<"PreOrderStatusEvent"> | string | null createdAt?: DateTimeFilter<"PreOrderStatusEvent"> | Date | string } export type CityCreateWithoutCustomersInput = { id?: string name: string province?: string | null addresses?: CustomerAddressCreateNestedManyWithoutCityInput branches?: BranchCreateNestedManyWithoutCityInput preOrders?: PreOrderCreateNestedManyWithoutCityInput } export type CityUncheckedCreateWithoutCustomersInput = { id?: string name: string province?: string | null addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCityInput branches?: BranchUncheckedCreateNestedManyWithoutCityInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCityInput } export type CityCreateOrConnectWithoutCustomersInput = { where: CityWhereUniqueInput create: XOR } export type AdminUserCreateWithoutReferredCustomersInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string branch?: BranchCreateNestedOneWithoutAdminUsersInput postedLedgerEntries?: LedgerEntryCreateNestedManyWithoutPostedByAdminUserInput orderStatusEvents?: OrderStatusEventCreateNestedManyWithoutActorAdminUserInput preOrderStatusEvents?: PreOrderStatusEventCreateNestedManyWithoutActorAdminUserInput } export type AdminUserUncheckedCreateWithoutReferredCustomersInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole branchId?: string | null wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string postedLedgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutPostedByAdminUserInput orderStatusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput preOrderStatusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput } export type AdminUserCreateOrConnectWithoutReferredCustomersInput = { where: AdminUserWhereUniqueInput create: XOR } export type CustomerAddressCreateWithoutCustomerInput = { id?: string addressLine: string isDefault?: boolean city?: CityCreateNestedOneWithoutAddressesInput } export type CustomerAddressUncheckedCreateWithoutCustomerInput = { id?: string cityId?: string | null addressLine: string isDefault?: boolean } export type CustomerAddressCreateOrConnectWithoutCustomerInput = { where: CustomerAddressWhereUniqueInput create: XOR } export type CustomerAddressCreateManyCustomerInputEnvelope = { data: CustomerAddressCreateManyCustomerInput | CustomerAddressCreateManyCustomerInput[] skipDuplicates?: boolean } export type OrderCreateWithoutCustomerInput = { id?: string orderNumber: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string branch?: BranchCreateNestedOneWithoutOrdersInput items?: OrderItemCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderCreateNestedOneWithoutConvertedOrderInput } export type OrderUncheckedCreateWithoutCustomerInput = { id?: string orderNumber: string branchId?: string | null status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string items?: OrderItemUncheckedCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderUncheckedCreateNestedOneWithoutConvertedOrderInput } export type OrderCreateOrConnectWithoutCustomerInput = { where: OrderWhereUniqueInput create: XOR } export type OrderCreateManyCustomerInputEnvelope = { data: OrderCreateManyCustomerInput | OrderCreateManyCustomerInput[] skipDuplicates?: boolean } export type PreOrderCreateWithoutCustomerInput = { id?: string status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null createdAt?: Date | string updatedAt?: Date | string city?: CityCreateNestedOneWithoutPreOrdersInput workshop?: WorkshopCreateNestedOneWithoutPreOrdersInput convertedOrder?: OrderCreateNestedOneWithoutConvertedFromPreOrderInput statusEvents?: PreOrderStatusEventCreateNestedManyWithoutPreOrderInput } export type PreOrderUncheckedCreateWithoutCustomerInput = { id?: string cityId?: string | null workshopId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string statusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutPreOrderInput } export type PreOrderCreateOrConnectWithoutCustomerInput = { where: PreOrderWhereUniqueInput create: XOR } export type PreOrderCreateManyCustomerInputEnvelope = { data: PreOrderCreateManyCustomerInput | PreOrderCreateManyCustomerInput[] skipDuplicates?: boolean } export type LedgerEntryCreateWithoutCustomerInput = { id?: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null confirmed?: boolean confirmedAt?: Date | string | null note?: string | null createdAt?: Date | string order?: OrderCreateNestedOneWithoutLedgerEntriesInput postedByAdminUser?: AdminUserCreateNestedOneWithoutPostedLedgerEntriesInput } export type LedgerEntryUncheckedCreateWithoutCustomerInput = { id?: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null orderId?: string | null confirmed?: boolean confirmedAt?: Date | string | null postedByAdminUserId?: string | null note?: string | null createdAt?: Date | string } export type LedgerEntryCreateOrConnectWithoutCustomerInput = { where: LedgerEntryWhereUniqueInput create: XOR } export type LedgerEntryCreateManyCustomerInputEnvelope = { data: LedgerEntryCreateManyCustomerInput | LedgerEntryCreateManyCustomerInput[] skipDuplicates?: boolean } export type WalletBonusCreateWithoutCustomerInput = { id?: string orderId?: string | null goldGrams: Decimal | DecimalJsLike | number | string grantedAt?: Date | string expiresAt: Date | string consumedAt?: Date | string | null isActive?: boolean } export type WalletBonusUncheckedCreateWithoutCustomerInput = { id?: string orderId?: string | null goldGrams: Decimal | DecimalJsLike | number | string grantedAt?: Date | string expiresAt: Date | string consumedAt?: Date | string | null isActive?: boolean } export type WalletBonusCreateOrConnectWithoutCustomerInput = { where: WalletBonusWhereUniqueInput create: XOR } export type WalletBonusCreateManyCustomerInputEnvelope = { data: WalletBonusCreateManyCustomerInput | WalletBonusCreateManyCustomerInput[] skipDuplicates?: boolean } export type CityUpsertWithoutCustomersInput = { update: XOR create: XOR where?: CityWhereInput } export type CityUpdateToOneWithWhereWithoutCustomersInput = { where?: CityWhereInput data: XOR } export type CityUpdateWithoutCustomersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null addresses?: CustomerAddressUpdateManyWithoutCityNestedInput branches?: BranchUpdateManyWithoutCityNestedInput preOrders?: PreOrderUpdateManyWithoutCityNestedInput } export type CityUncheckedUpdateWithoutCustomersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null addresses?: CustomerAddressUncheckedUpdateManyWithoutCityNestedInput branches?: BranchUncheckedUpdateManyWithoutCityNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCityNestedInput } export type AdminUserUpsertWithoutReferredCustomersInput = { update: XOR create: XOR where?: AdminUserWhereInput } export type AdminUserUpdateToOneWithWhereWithoutReferredCustomersInput = { where?: AdminUserWhereInput data: XOR } export type AdminUserUpdateWithoutReferredCustomersInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string branch?: BranchUpdateOneWithoutAdminUsersNestedInput postedLedgerEntries?: LedgerEntryUpdateManyWithoutPostedByAdminUserNestedInput orderStatusEvents?: OrderStatusEventUpdateManyWithoutActorAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUpdateManyWithoutActorAdminUserNestedInput } export type AdminUserUncheckedUpdateWithoutReferredCustomersInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole branchId?: NullableStringFieldUpdateOperationsInput | string | null wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string postedLedgerEntries?: LedgerEntryUncheckedUpdateManyWithoutPostedByAdminUserNestedInput orderStatusEvents?: OrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput } export type CustomerAddressUpsertWithWhereUniqueWithoutCustomerInput = { where: CustomerAddressWhereUniqueInput update: XOR create: XOR } export type CustomerAddressUpdateWithWhereUniqueWithoutCustomerInput = { where: CustomerAddressWhereUniqueInput data: XOR } export type CustomerAddressUpdateManyWithWhereWithoutCustomerInput = { where: CustomerAddressScalarWhereInput data: XOR } export type OrderUpsertWithWhereUniqueWithoutCustomerInput = { where: OrderWhereUniqueInput update: XOR create: XOR } export type OrderUpdateWithWhereUniqueWithoutCustomerInput = { where: OrderWhereUniqueInput data: XOR } export type OrderUpdateManyWithWhereWithoutCustomerInput = { where: OrderScalarWhereInput data: XOR } export type OrderScalarWhereInput = { AND?: OrderScalarWhereInput | OrderScalarWhereInput[] OR?: OrderScalarWhereInput[] NOT?: OrderScalarWhereInput | OrderScalarWhereInput[] id?: StringFilter<"Order"> | string orderNumber?: StringFilter<"Order"> | string customerId?: StringFilter<"Order"> | string branchId?: StringNullableFilter<"Order"> | string | null status?: EnumOrderStatusFilter<"Order"> | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFilter<"Order"> | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFilter<"Order"> | boolean deliveredAt?: DateTimeNullableFilter<"Order"> | Date | string | null createdAt?: DateTimeFilter<"Order"> | Date | string updatedAt?: DateTimeFilter<"Order"> | Date | string } export type PreOrderUpsertWithWhereUniqueWithoutCustomerInput = { where: PreOrderWhereUniqueInput update: XOR create: XOR } export type PreOrderUpdateWithWhereUniqueWithoutCustomerInput = { where: PreOrderWhereUniqueInput data: XOR } export type PreOrderUpdateManyWithWhereWithoutCustomerInput = { where: PreOrderScalarWhereInput data: XOR } export type LedgerEntryUpsertWithWhereUniqueWithoutCustomerInput = { where: LedgerEntryWhereUniqueInput update: XOR create: XOR } export type LedgerEntryUpdateWithWhereUniqueWithoutCustomerInput = { where: LedgerEntryWhereUniqueInput data: XOR } export type LedgerEntryUpdateManyWithWhereWithoutCustomerInput = { where: LedgerEntryScalarWhereInput data: XOR } export type WalletBonusUpsertWithWhereUniqueWithoutCustomerInput = { where: WalletBonusWhereUniqueInput update: XOR create: XOR } export type WalletBonusUpdateWithWhereUniqueWithoutCustomerInput = { where: WalletBonusWhereUniqueInput data: XOR } export type WalletBonusUpdateManyWithWhereWithoutCustomerInput = { where: WalletBonusScalarWhereInput data: XOR } export type WalletBonusScalarWhereInput = { AND?: WalletBonusScalarWhereInput | WalletBonusScalarWhereInput[] OR?: WalletBonusScalarWhereInput[] NOT?: WalletBonusScalarWhereInput | WalletBonusScalarWhereInput[] id?: StringFilter<"WalletBonus"> | string customerId?: StringFilter<"WalletBonus"> | string orderId?: StringNullableFilter<"WalletBonus"> | string | null goldGrams?: DecimalFilter<"WalletBonus"> | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFilter<"WalletBonus"> | Date | string expiresAt?: DateTimeFilter<"WalletBonus"> | Date | string consumedAt?: DateTimeNullableFilter<"WalletBonus"> | Date | string | null isActive?: BoolFilter<"WalletBonus"> | boolean } export type CustomerCreateWithoutAddressesInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string city?: CityCreateNestedOneWithoutCustomersInput referredByAgent?: AdminUserCreateNestedOneWithoutReferredCustomersInput orders?: OrderCreateNestedManyWithoutCustomerInput preOrders?: PreOrderCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusCreateNestedManyWithoutCustomerInput } export type CustomerUncheckedCreateWithoutAddressesInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string orders?: OrderUncheckedCreateNestedManyWithoutCustomerInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusUncheckedCreateNestedManyWithoutCustomerInput } export type CustomerCreateOrConnectWithoutAddressesInput = { where: CustomerWhereUniqueInput create: XOR } export type CityCreateWithoutAddressesInput = { id?: string name: string province?: string | null customers?: CustomerCreateNestedManyWithoutCityInput branches?: BranchCreateNestedManyWithoutCityInput preOrders?: PreOrderCreateNestedManyWithoutCityInput } export type CityUncheckedCreateWithoutAddressesInput = { id?: string name: string province?: string | null customers?: CustomerUncheckedCreateNestedManyWithoutCityInput branches?: BranchUncheckedCreateNestedManyWithoutCityInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCityInput } export type CityCreateOrConnectWithoutAddressesInput = { where: CityWhereUniqueInput create: XOR } export type CustomerUpsertWithoutAddressesInput = { update: XOR create: XOR where?: CustomerWhereInput } export type CustomerUpdateToOneWithWhereWithoutAddressesInput = { where?: CustomerWhereInput data: XOR } export type CustomerUpdateWithoutAddressesInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string city?: CityUpdateOneWithoutCustomersNestedInput referredByAgent?: AdminUserUpdateOneWithoutReferredCustomersNestedInput orders?: OrderUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateWithoutAddressesInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string orders?: OrderUncheckedUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUncheckedUpdateManyWithoutCustomerNestedInput } export type CityUpsertWithoutAddressesInput = { update: XOR create: XOR where?: CityWhereInput } export type CityUpdateToOneWithWhereWithoutAddressesInput = { where?: CityWhereInput data: XOR } export type CityUpdateWithoutAddressesInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null customers?: CustomerUpdateManyWithoutCityNestedInput branches?: BranchUpdateManyWithoutCityNestedInput preOrders?: PreOrderUpdateManyWithoutCityNestedInput } export type CityUncheckedUpdateWithoutAddressesInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null customers?: CustomerUncheckedUpdateManyWithoutCityNestedInput branches?: BranchUncheckedUpdateManyWithoutCityNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCityNestedInput } export type CityCreateWithoutBranchesInput = { id?: string name: string province?: string | null customers?: CustomerCreateNestedManyWithoutCityInput addresses?: CustomerAddressCreateNestedManyWithoutCityInput preOrders?: PreOrderCreateNestedManyWithoutCityInput } export type CityUncheckedCreateWithoutBranchesInput = { id?: string name: string province?: string | null customers?: CustomerUncheckedCreateNestedManyWithoutCityInput addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCityInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCityInput } export type CityCreateOrConnectWithoutBranchesInput = { where: CityWhereUniqueInput create: XOR } export type AdminUserCreateWithoutBranchInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string referredCustomers?: CustomerCreateNestedManyWithoutReferredByAgentInput postedLedgerEntries?: LedgerEntryCreateNestedManyWithoutPostedByAdminUserInput orderStatusEvents?: OrderStatusEventCreateNestedManyWithoutActorAdminUserInput preOrderStatusEvents?: PreOrderStatusEventCreateNestedManyWithoutActorAdminUserInput } export type AdminUserUncheckedCreateWithoutBranchInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string referredCustomers?: CustomerUncheckedCreateNestedManyWithoutReferredByAgentInput postedLedgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutPostedByAdminUserInput orderStatusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput preOrderStatusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput } export type AdminUserCreateOrConnectWithoutBranchInput = { where: AdminUserWhereUniqueInput create: XOR } export type AdminUserCreateManyBranchInputEnvelope = { data: AdminUserCreateManyBranchInput | AdminUserCreateManyBranchInput[] skipDuplicates?: boolean } export type OrderCreateWithoutBranchInput = { id?: string orderNumber: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutOrdersInput items?: OrderItemCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderCreateNestedOneWithoutConvertedOrderInput } export type OrderUncheckedCreateWithoutBranchInput = { id?: string orderNumber: string customerId: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string items?: OrderItemUncheckedCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderUncheckedCreateNestedOneWithoutConvertedOrderInput } export type OrderCreateOrConnectWithoutBranchInput = { where: OrderWhereUniqueInput create: XOR } export type OrderCreateManyBranchInputEnvelope = { data: OrderCreateManyBranchInput | OrderCreateManyBranchInput[] skipDuplicates?: boolean } export type CityUpsertWithoutBranchesInput = { update: XOR create: XOR where?: CityWhereInput } export type CityUpdateToOneWithWhereWithoutBranchesInput = { where?: CityWhereInput data: XOR } export type CityUpdateWithoutBranchesInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null customers?: CustomerUpdateManyWithoutCityNestedInput addresses?: CustomerAddressUpdateManyWithoutCityNestedInput preOrders?: PreOrderUpdateManyWithoutCityNestedInput } export type CityUncheckedUpdateWithoutBranchesInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null customers?: CustomerUncheckedUpdateManyWithoutCityNestedInput addresses?: CustomerAddressUncheckedUpdateManyWithoutCityNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCityNestedInput } export type AdminUserUpsertWithWhereUniqueWithoutBranchInput = { where: AdminUserWhereUniqueInput update: XOR create: XOR } export type AdminUserUpdateWithWhereUniqueWithoutBranchInput = { where: AdminUserWhereUniqueInput data: XOR } export type AdminUserUpdateManyWithWhereWithoutBranchInput = { where: AdminUserScalarWhereInput data: XOR } export type AdminUserScalarWhereInput = { AND?: AdminUserScalarWhereInput | AdminUserScalarWhereInput[] OR?: AdminUserScalarWhereInput[] NOT?: AdminUserScalarWhereInput | AdminUserScalarWhereInput[] id?: StringFilter<"AdminUser"> | string fullName?: StringFilter<"AdminUser"> | string mobile?: StringFilter<"AdminUser"> | string passwordHash?: StringFilter<"AdminUser"> | string role?: EnumAdminRoleFilter<"AdminUser"> | $Enums.AdminRole branchId?: StringNullableFilter<"AdminUser"> | string | null wagePercent?: DecimalNullableFilter<"AdminUser"> | Decimal | DecimalJsLike | number | string | null isActive?: BoolFilter<"AdminUser"> | boolean createdAt?: DateTimeFilter<"AdminUser"> | Date | string } export type OrderUpsertWithWhereUniqueWithoutBranchInput = { where: OrderWhereUniqueInput update: XOR create: XOR } export type OrderUpdateWithWhereUniqueWithoutBranchInput = { where: OrderWhereUniqueInput data: XOR } export type OrderUpdateManyWithWhereWithoutBranchInput = { where: OrderScalarWhereInput data: XOR } export type PreOrderCreateWithoutWorkshopInput = { id?: string status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutPreOrdersInput city?: CityCreateNestedOneWithoutPreOrdersInput convertedOrder?: OrderCreateNestedOneWithoutConvertedFromPreOrderInput statusEvents?: PreOrderStatusEventCreateNestedManyWithoutPreOrderInput } export type PreOrderUncheckedCreateWithoutWorkshopInput = { id?: string customerId: string cityId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string statusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutPreOrderInput } export type PreOrderCreateOrConnectWithoutWorkshopInput = { where: PreOrderWhereUniqueInput create: XOR } export type PreOrderCreateManyWorkshopInputEnvelope = { data: PreOrderCreateManyWorkshopInput | PreOrderCreateManyWorkshopInput[] skipDuplicates?: boolean } export type PreOrderUpsertWithWhereUniqueWithoutWorkshopInput = { where: PreOrderWhereUniqueInput update: XOR create: XOR } export type PreOrderUpdateWithWhereUniqueWithoutWorkshopInput = { where: PreOrderWhereUniqueInput data: XOR } export type PreOrderUpdateManyWithWhereWithoutWorkshopInput = { where: PreOrderScalarWhereInput data: XOR } export type CategoryCreateWithoutChildrenInput = { id?: string title: string parent?: CategoryCreateNestedOneWithoutChildrenInput products?: ProductCreateNestedManyWithoutCategoryInput } export type CategoryUncheckedCreateWithoutChildrenInput = { id?: string title: string parentId?: string | null products?: ProductUncheckedCreateNestedManyWithoutCategoryInput } export type CategoryCreateOrConnectWithoutChildrenInput = { where: CategoryWhereUniqueInput create: XOR } export type CategoryCreateWithoutParentInput = { id?: string title: string children?: CategoryCreateNestedManyWithoutParentInput products?: ProductCreateNestedManyWithoutCategoryInput } export type CategoryUncheckedCreateWithoutParentInput = { id?: string title: string children?: CategoryUncheckedCreateNestedManyWithoutParentInput products?: ProductUncheckedCreateNestedManyWithoutCategoryInput } export type CategoryCreateOrConnectWithoutParentInput = { where: CategoryWhereUniqueInput create: XOR } export type CategoryCreateManyParentInputEnvelope = { data: CategoryCreateManyParentInput | CategoryCreateManyParentInput[] skipDuplicates?: boolean } export type ProductCreateWithoutCategoryInput = { id?: string title: string description?: string | null isActive?: boolean createdAt?: Date | string brand?: BrandCreateNestedOneWithoutProductsInput variants?: ProductVariantCreateNestedManyWithoutProductInput images?: ProductImageCreateNestedManyWithoutProductInput collections?: CollectionProductCreateNestedManyWithoutProductInput } export type ProductUncheckedCreateWithoutCategoryInput = { id?: string title: string description?: string | null brandId?: string | null isActive?: boolean createdAt?: Date | string variants?: ProductVariantUncheckedCreateNestedManyWithoutProductInput images?: ProductImageUncheckedCreateNestedManyWithoutProductInput collections?: CollectionProductUncheckedCreateNestedManyWithoutProductInput } export type ProductCreateOrConnectWithoutCategoryInput = { where: ProductWhereUniqueInput create: XOR } export type ProductCreateManyCategoryInputEnvelope = { data: ProductCreateManyCategoryInput | ProductCreateManyCategoryInput[] skipDuplicates?: boolean } export type CategoryUpsertWithoutChildrenInput = { update: XOR create: XOR where?: CategoryWhereInput } export type CategoryUpdateToOneWithWhereWithoutChildrenInput = { where?: CategoryWhereInput data: XOR } export type CategoryUpdateWithoutChildrenInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string parent?: CategoryUpdateOneWithoutChildrenNestedInput products?: ProductUpdateManyWithoutCategoryNestedInput } export type CategoryUncheckedUpdateWithoutChildrenInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string parentId?: NullableStringFieldUpdateOperationsInput | string | null products?: ProductUncheckedUpdateManyWithoutCategoryNestedInput } export type CategoryUpsertWithWhereUniqueWithoutParentInput = { where: CategoryWhereUniqueInput update: XOR create: XOR } export type CategoryUpdateWithWhereUniqueWithoutParentInput = { where: CategoryWhereUniqueInput data: XOR } export type CategoryUpdateManyWithWhereWithoutParentInput = { where: CategoryScalarWhereInput data: XOR } export type CategoryScalarWhereInput = { AND?: CategoryScalarWhereInput | CategoryScalarWhereInput[] OR?: CategoryScalarWhereInput[] NOT?: CategoryScalarWhereInput | CategoryScalarWhereInput[] id?: StringFilter<"Category"> | string title?: StringFilter<"Category"> | string parentId?: StringNullableFilter<"Category"> | string | null } export type ProductUpsertWithWhereUniqueWithoutCategoryInput = { where: ProductWhereUniqueInput update: XOR create: XOR } export type ProductUpdateWithWhereUniqueWithoutCategoryInput = { where: ProductWhereUniqueInput data: XOR } export type ProductUpdateManyWithWhereWithoutCategoryInput = { where: ProductScalarWhereInput data: XOR } export type ProductScalarWhereInput = { AND?: ProductScalarWhereInput | ProductScalarWhereInput[] OR?: ProductScalarWhereInput[] NOT?: ProductScalarWhereInput | ProductScalarWhereInput[] id?: StringFilter<"Product"> | string title?: StringFilter<"Product"> | string description?: StringNullableFilter<"Product"> | string | null categoryId?: StringNullableFilter<"Product"> | string | null brandId?: StringNullableFilter<"Product"> | string | null isActive?: BoolFilter<"Product"> | boolean createdAt?: DateTimeFilter<"Product"> | Date | string } export type ProductCreateWithoutBrandInput = { id?: string title: string description?: string | null isActive?: boolean createdAt?: Date | string category?: CategoryCreateNestedOneWithoutProductsInput variants?: ProductVariantCreateNestedManyWithoutProductInput images?: ProductImageCreateNestedManyWithoutProductInput collections?: CollectionProductCreateNestedManyWithoutProductInput } export type ProductUncheckedCreateWithoutBrandInput = { id?: string title: string description?: string | null categoryId?: string | null isActive?: boolean createdAt?: Date | string variants?: ProductVariantUncheckedCreateNestedManyWithoutProductInput images?: ProductImageUncheckedCreateNestedManyWithoutProductInput collections?: CollectionProductUncheckedCreateNestedManyWithoutProductInput } export type ProductCreateOrConnectWithoutBrandInput = { where: ProductWhereUniqueInput create: XOR } export type ProductCreateManyBrandInputEnvelope = { data: ProductCreateManyBrandInput | ProductCreateManyBrandInput[] skipDuplicates?: boolean } export type ProductUpsertWithWhereUniqueWithoutBrandInput = { where: ProductWhereUniqueInput update: XOR create: XOR } export type ProductUpdateWithWhereUniqueWithoutBrandInput = { where: ProductWhereUniqueInput data: XOR } export type ProductUpdateManyWithWhereWithoutBrandInput = { where: ProductScalarWhereInput data: XOR } export type CollectionProductCreateWithoutCollectionInput = { product: ProductCreateNestedOneWithoutCollectionsInput } export type CollectionProductUncheckedCreateWithoutCollectionInput = { productId: string } export type CollectionProductCreateOrConnectWithoutCollectionInput = { where: CollectionProductWhereUniqueInput create: XOR } export type CollectionProductCreateManyCollectionInputEnvelope = { data: CollectionProductCreateManyCollectionInput | CollectionProductCreateManyCollectionInput[] skipDuplicates?: boolean } export type CollectionProductUpsertWithWhereUniqueWithoutCollectionInput = { where: CollectionProductWhereUniqueInput update: XOR create: XOR } export type CollectionProductUpdateWithWhereUniqueWithoutCollectionInput = { where: CollectionProductWhereUniqueInput data: XOR } export type CollectionProductUpdateManyWithWhereWithoutCollectionInput = { where: CollectionProductScalarWhereInput data: XOR } export type CollectionProductScalarWhereInput = { AND?: CollectionProductScalarWhereInput | CollectionProductScalarWhereInput[] OR?: CollectionProductScalarWhereInput[] NOT?: CollectionProductScalarWhereInput | CollectionProductScalarWhereInput[] collectionId?: StringFilter<"CollectionProduct"> | string productId?: StringFilter<"CollectionProduct"> | string } export type CollectionCreateWithoutProductsInput = { id?: string title: string description?: string | null isActive?: boolean } export type CollectionUncheckedCreateWithoutProductsInput = { id?: string title: string description?: string | null isActive?: boolean } export type CollectionCreateOrConnectWithoutProductsInput = { where: CollectionWhereUniqueInput create: XOR } export type ProductCreateWithoutCollectionsInput = { id?: string title: string description?: string | null isActive?: boolean createdAt?: Date | string category?: CategoryCreateNestedOneWithoutProductsInput brand?: BrandCreateNestedOneWithoutProductsInput variants?: ProductVariantCreateNestedManyWithoutProductInput images?: ProductImageCreateNestedManyWithoutProductInput } export type ProductUncheckedCreateWithoutCollectionsInput = { id?: string title: string description?: string | null categoryId?: string | null brandId?: string | null isActive?: boolean createdAt?: Date | string variants?: ProductVariantUncheckedCreateNestedManyWithoutProductInput images?: ProductImageUncheckedCreateNestedManyWithoutProductInput } export type ProductCreateOrConnectWithoutCollectionsInput = { where: ProductWhereUniqueInput create: XOR } export type CollectionUpsertWithoutProductsInput = { update: XOR create: XOR where?: CollectionWhereInput } export type CollectionUpdateToOneWithWhereWithoutProductsInput = { where?: CollectionWhereInput data: XOR } export type CollectionUpdateWithoutProductsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type CollectionUncheckedUpdateWithoutProductsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type ProductUpsertWithoutCollectionsInput = { update: XOR create: XOR where?: ProductWhereInput } export type ProductUpdateToOneWithWhereWithoutCollectionsInput = { where?: ProductWhereInput data: XOR } export type ProductUpdateWithoutCollectionsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string category?: CategoryUpdateOneWithoutProductsNestedInput brand?: BrandUpdateOneWithoutProductsNestedInput variants?: ProductVariantUpdateManyWithoutProductNestedInput images?: ProductImageUpdateManyWithoutProductNestedInput } export type ProductUncheckedUpdateWithoutCollectionsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null categoryId?: NullableStringFieldUpdateOperationsInput | string | null brandId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string variants?: ProductVariantUncheckedUpdateManyWithoutProductNestedInput images?: ProductImageUncheckedUpdateManyWithoutProductNestedInput } export type CategoryCreateWithoutProductsInput = { id?: string title: string parent?: CategoryCreateNestedOneWithoutChildrenInput children?: CategoryCreateNestedManyWithoutParentInput } export type CategoryUncheckedCreateWithoutProductsInput = { id?: string title: string parentId?: string | null children?: CategoryUncheckedCreateNestedManyWithoutParentInput } export type CategoryCreateOrConnectWithoutProductsInput = { where: CategoryWhereUniqueInput create: XOR } export type BrandCreateWithoutProductsInput = { id?: string title: string } export type BrandUncheckedCreateWithoutProductsInput = { id?: string title: string } export type BrandCreateOrConnectWithoutProductsInput = { where: BrandWhereUniqueInput create: XOR } export type ProductVariantCreateWithoutProductInput = { id?: string title: string sku?: string | null rashWeightGrams: Decimal | DecimalJsLike | number | string defaultWagePercent: Decimal | DecimalJsLike | number | string isActive?: boolean orderItems?: OrderItemCreateNestedManyWithoutProductVariantInput } export type ProductVariantUncheckedCreateWithoutProductInput = { id?: string title: string sku?: string | null rashWeightGrams: Decimal | DecimalJsLike | number | string defaultWagePercent: Decimal | DecimalJsLike | number | string isActive?: boolean orderItems?: OrderItemUncheckedCreateNestedManyWithoutProductVariantInput } export type ProductVariantCreateOrConnectWithoutProductInput = { where: ProductVariantWhereUniqueInput create: XOR } export type ProductVariantCreateManyProductInputEnvelope = { data: ProductVariantCreateManyProductInput | ProductVariantCreateManyProductInput[] skipDuplicates?: boolean } export type ProductImageCreateWithoutProductInput = { id?: string url: string sortOrder?: number } export type ProductImageUncheckedCreateWithoutProductInput = { id?: string url: string sortOrder?: number } export type ProductImageCreateOrConnectWithoutProductInput = { where: ProductImageWhereUniqueInput create: XOR } export type ProductImageCreateManyProductInputEnvelope = { data: ProductImageCreateManyProductInput | ProductImageCreateManyProductInput[] skipDuplicates?: boolean } export type CollectionProductCreateWithoutProductInput = { collection: CollectionCreateNestedOneWithoutProductsInput } export type CollectionProductUncheckedCreateWithoutProductInput = { collectionId: string } export type CollectionProductCreateOrConnectWithoutProductInput = { where: CollectionProductWhereUniqueInput create: XOR } export type CollectionProductCreateManyProductInputEnvelope = { data: CollectionProductCreateManyProductInput | CollectionProductCreateManyProductInput[] skipDuplicates?: boolean } export type CategoryUpsertWithoutProductsInput = { update: XOR create: XOR where?: CategoryWhereInput } export type CategoryUpdateToOneWithWhereWithoutProductsInput = { where?: CategoryWhereInput data: XOR } export type CategoryUpdateWithoutProductsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string parent?: CategoryUpdateOneWithoutChildrenNestedInput children?: CategoryUpdateManyWithoutParentNestedInput } export type CategoryUncheckedUpdateWithoutProductsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string parentId?: NullableStringFieldUpdateOperationsInput | string | null children?: CategoryUncheckedUpdateManyWithoutParentNestedInput } export type BrandUpsertWithoutProductsInput = { update: XOR create: XOR where?: BrandWhereInput } export type BrandUpdateToOneWithWhereWithoutProductsInput = { where?: BrandWhereInput data: XOR } export type BrandUpdateWithoutProductsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string } export type BrandUncheckedUpdateWithoutProductsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string } export type ProductVariantUpsertWithWhereUniqueWithoutProductInput = { where: ProductVariantWhereUniqueInput update: XOR create: XOR } export type ProductVariantUpdateWithWhereUniqueWithoutProductInput = { where: ProductVariantWhereUniqueInput data: XOR } export type ProductVariantUpdateManyWithWhereWithoutProductInput = { where: ProductVariantScalarWhereInput data: XOR } export type ProductVariantScalarWhereInput = { AND?: ProductVariantScalarWhereInput | ProductVariantScalarWhereInput[] OR?: ProductVariantScalarWhereInput[] NOT?: ProductVariantScalarWhereInput | ProductVariantScalarWhereInput[] id?: StringFilter<"ProductVariant"> | string productId?: StringFilter<"ProductVariant"> | string title?: StringFilter<"ProductVariant"> | string sku?: StringNullableFilter<"ProductVariant"> | string | null rashWeightGrams?: DecimalFilter<"ProductVariant"> | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFilter<"ProductVariant"> | Decimal | DecimalJsLike | number | string isActive?: BoolFilter<"ProductVariant"> | boolean } export type ProductImageUpsertWithWhereUniqueWithoutProductInput = { where: ProductImageWhereUniqueInput update: XOR create: XOR } export type ProductImageUpdateWithWhereUniqueWithoutProductInput = { where: ProductImageWhereUniqueInput data: XOR } export type ProductImageUpdateManyWithWhereWithoutProductInput = { where: ProductImageScalarWhereInput data: XOR } export type ProductImageScalarWhereInput = { AND?: ProductImageScalarWhereInput | ProductImageScalarWhereInput[] OR?: ProductImageScalarWhereInput[] NOT?: ProductImageScalarWhereInput | ProductImageScalarWhereInput[] id?: StringFilter<"ProductImage"> | string productId?: StringFilter<"ProductImage"> | string url?: StringFilter<"ProductImage"> | string sortOrder?: IntFilter<"ProductImage"> | number } export type CollectionProductUpsertWithWhereUniqueWithoutProductInput = { where: CollectionProductWhereUniqueInput update: XOR create: XOR } export type CollectionProductUpdateWithWhereUniqueWithoutProductInput = { where: CollectionProductWhereUniqueInput data: XOR } export type CollectionProductUpdateManyWithWhereWithoutProductInput = { where: CollectionProductScalarWhereInput data: XOR } export type ProductCreateWithoutImagesInput = { id?: string title: string description?: string | null isActive?: boolean createdAt?: Date | string category?: CategoryCreateNestedOneWithoutProductsInput brand?: BrandCreateNestedOneWithoutProductsInput variants?: ProductVariantCreateNestedManyWithoutProductInput collections?: CollectionProductCreateNestedManyWithoutProductInput } export type ProductUncheckedCreateWithoutImagesInput = { id?: string title: string description?: string | null categoryId?: string | null brandId?: string | null isActive?: boolean createdAt?: Date | string variants?: ProductVariantUncheckedCreateNestedManyWithoutProductInput collections?: CollectionProductUncheckedCreateNestedManyWithoutProductInput } export type ProductCreateOrConnectWithoutImagesInput = { where: ProductWhereUniqueInput create: XOR } export type ProductUpsertWithoutImagesInput = { update: XOR create: XOR where?: ProductWhereInput } export type ProductUpdateToOneWithWhereWithoutImagesInput = { where?: ProductWhereInput data: XOR } export type ProductUpdateWithoutImagesInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string category?: CategoryUpdateOneWithoutProductsNestedInput brand?: BrandUpdateOneWithoutProductsNestedInput variants?: ProductVariantUpdateManyWithoutProductNestedInput collections?: CollectionProductUpdateManyWithoutProductNestedInput } export type ProductUncheckedUpdateWithoutImagesInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null categoryId?: NullableStringFieldUpdateOperationsInput | string | null brandId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string variants?: ProductVariantUncheckedUpdateManyWithoutProductNestedInput collections?: CollectionProductUncheckedUpdateManyWithoutProductNestedInput } export type ProductCreateWithoutVariantsInput = { id?: string title: string description?: string | null isActive?: boolean createdAt?: Date | string category?: CategoryCreateNestedOneWithoutProductsInput brand?: BrandCreateNestedOneWithoutProductsInput images?: ProductImageCreateNestedManyWithoutProductInput collections?: CollectionProductCreateNestedManyWithoutProductInput } export type ProductUncheckedCreateWithoutVariantsInput = { id?: string title: string description?: string | null categoryId?: string | null brandId?: string | null isActive?: boolean createdAt?: Date | string images?: ProductImageUncheckedCreateNestedManyWithoutProductInput collections?: CollectionProductUncheckedCreateNestedManyWithoutProductInput } export type ProductCreateOrConnectWithoutVariantsInput = { where: ProductWhereUniqueInput create: XOR } export type OrderItemCreateWithoutProductVariantInput = { id?: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string order: OrderCreateNestedOneWithoutItemsInput } export type OrderItemUncheckedCreateWithoutProductVariantInput = { id?: string orderId: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string } export type OrderItemCreateOrConnectWithoutProductVariantInput = { where: OrderItemWhereUniqueInput create: XOR } export type OrderItemCreateManyProductVariantInputEnvelope = { data: OrderItemCreateManyProductVariantInput | OrderItemCreateManyProductVariantInput[] skipDuplicates?: boolean } export type ProductUpsertWithoutVariantsInput = { update: XOR create: XOR where?: ProductWhereInput } export type ProductUpdateToOneWithWhereWithoutVariantsInput = { where?: ProductWhereInput data: XOR } export type ProductUpdateWithoutVariantsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string category?: CategoryUpdateOneWithoutProductsNestedInput brand?: BrandUpdateOneWithoutProductsNestedInput images?: ProductImageUpdateManyWithoutProductNestedInput collections?: CollectionProductUpdateManyWithoutProductNestedInput } export type ProductUncheckedUpdateWithoutVariantsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null categoryId?: NullableStringFieldUpdateOperationsInput | string | null brandId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string images?: ProductImageUncheckedUpdateManyWithoutProductNestedInput collections?: CollectionProductUncheckedUpdateManyWithoutProductNestedInput } export type OrderItemUpsertWithWhereUniqueWithoutProductVariantInput = { where: OrderItemWhereUniqueInput update: XOR create: XOR } export type OrderItemUpdateWithWhereUniqueWithoutProductVariantInput = { where: OrderItemWhereUniqueInput data: XOR } export type OrderItemUpdateManyWithWhereWithoutProductVariantInput = { where: OrderItemScalarWhereInput data: XOR } export type OrderItemScalarWhereInput = { AND?: OrderItemScalarWhereInput | OrderItemScalarWhereInput[] OR?: OrderItemScalarWhereInput[] NOT?: OrderItemScalarWhereInput | OrderItemScalarWhereInput[] id?: StringFilter<"OrderItem"> | string orderId?: StringFilter<"OrderItem"> | string productVariantId?: StringFilter<"OrderItem"> | string quantity?: IntFilter<"OrderItem"> | number rashWeightGramsSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFilter<"OrderItem"> | Decimal | DecimalJsLike | number | string } export type CustomerCreateWithoutOrdersInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string city?: CityCreateNestedOneWithoutCustomersInput referredByAgent?: AdminUserCreateNestedOneWithoutReferredCustomersInput addresses?: CustomerAddressCreateNestedManyWithoutCustomerInput preOrders?: PreOrderCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusCreateNestedManyWithoutCustomerInput } export type CustomerUncheckedCreateWithoutOrdersInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusUncheckedCreateNestedManyWithoutCustomerInput } export type CustomerCreateOrConnectWithoutOrdersInput = { where: CustomerWhereUniqueInput create: XOR } export type BranchCreateWithoutOrdersInput = { id?: string name: string city?: CityCreateNestedOneWithoutBranchesInput adminUsers?: AdminUserCreateNestedManyWithoutBranchInput } export type BranchUncheckedCreateWithoutOrdersInput = { id?: string name: string cityId?: string | null adminUsers?: AdminUserUncheckedCreateNestedManyWithoutBranchInput } export type BranchCreateOrConnectWithoutOrdersInput = { where: BranchWhereUniqueInput create: XOR } export type OrderItemCreateWithoutOrderInput = { id?: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string productVariant: ProductVariantCreateNestedOneWithoutOrderItemsInput } export type OrderItemUncheckedCreateWithoutOrderInput = { id?: string productVariantId: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string } export type OrderItemCreateOrConnectWithoutOrderInput = { where: OrderItemWhereUniqueInput create: XOR } export type OrderItemCreateManyOrderInputEnvelope = { data: OrderItemCreateManyOrderInput | OrderItemCreateManyOrderInput[] skipDuplicates?: boolean } export type OrderStatusEventCreateWithoutOrderInput = { id?: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null createdAt?: Date | string actorAdminUser?: AdminUserCreateNestedOneWithoutOrderStatusEventsInput } export type OrderStatusEventUncheckedCreateWithoutOrderInput = { id?: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null actorAdminUserId?: string | null createdAt?: Date | string } export type OrderStatusEventCreateOrConnectWithoutOrderInput = { where: OrderStatusEventWhereUniqueInput create: XOR } export type OrderStatusEventCreateManyOrderInputEnvelope = { data: OrderStatusEventCreateManyOrderInput | OrderStatusEventCreateManyOrderInput[] skipDuplicates?: boolean } export type LedgerEntryCreateWithoutOrderInput = { id?: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null confirmed?: boolean confirmedAt?: Date | string | null note?: string | null createdAt?: Date | string customer: CustomerCreateNestedOneWithoutLedgerEntriesInput postedByAdminUser?: AdminUserCreateNestedOneWithoutPostedLedgerEntriesInput } export type LedgerEntryUncheckedCreateWithoutOrderInput = { id?: string customerId: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null confirmed?: boolean confirmedAt?: Date | string | null postedByAdminUserId?: string | null note?: string | null createdAt?: Date | string } export type LedgerEntryCreateOrConnectWithoutOrderInput = { where: LedgerEntryWhereUniqueInput create: XOR } export type LedgerEntryCreateManyOrderInputEnvelope = { data: LedgerEntryCreateManyOrderInput | LedgerEntryCreateManyOrderInput[] skipDuplicates?: boolean } export type PreOrderCreateWithoutConvertedOrderInput = { id?: string status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutPreOrdersInput city?: CityCreateNestedOneWithoutPreOrdersInput workshop?: WorkshopCreateNestedOneWithoutPreOrdersInput statusEvents?: PreOrderStatusEventCreateNestedManyWithoutPreOrderInput } export type PreOrderUncheckedCreateWithoutConvertedOrderInput = { id?: string customerId: string cityId?: string | null workshopId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null createdAt?: Date | string updatedAt?: Date | string statusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutPreOrderInput } export type PreOrderCreateOrConnectWithoutConvertedOrderInput = { where: PreOrderWhereUniqueInput create: XOR } export type CustomerUpsertWithoutOrdersInput = { update: XOR create: XOR where?: CustomerWhereInput } export type CustomerUpdateToOneWithWhereWithoutOrdersInput = { where?: CustomerWhereInput data: XOR } export type CustomerUpdateWithoutOrdersInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string city?: CityUpdateOneWithoutCustomersNestedInput referredByAgent?: AdminUserUpdateOneWithoutReferredCustomersNestedInput addresses?: CustomerAddressUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateWithoutOrdersInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string addresses?: CustomerAddressUncheckedUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUncheckedUpdateManyWithoutCustomerNestedInput } export type BranchUpsertWithoutOrdersInput = { update: XOR create: XOR where?: BranchWhereInput } export type BranchUpdateToOneWithWhereWithoutOrdersInput = { where?: BranchWhereInput data: XOR } export type BranchUpdateWithoutOrdersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string city?: CityUpdateOneWithoutBranchesNestedInput adminUsers?: AdminUserUpdateManyWithoutBranchNestedInput } export type BranchUncheckedUpdateWithoutOrdersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null adminUsers?: AdminUserUncheckedUpdateManyWithoutBranchNestedInput } export type OrderItemUpsertWithWhereUniqueWithoutOrderInput = { where: OrderItemWhereUniqueInput update: XOR create: XOR } export type OrderItemUpdateWithWhereUniqueWithoutOrderInput = { where: OrderItemWhereUniqueInput data: XOR } export type OrderItemUpdateManyWithWhereWithoutOrderInput = { where: OrderItemScalarWhereInput data: XOR } export type OrderStatusEventUpsertWithWhereUniqueWithoutOrderInput = { where: OrderStatusEventWhereUniqueInput update: XOR create: XOR } export type OrderStatusEventUpdateWithWhereUniqueWithoutOrderInput = { where: OrderStatusEventWhereUniqueInput data: XOR } export type OrderStatusEventUpdateManyWithWhereWithoutOrderInput = { where: OrderStatusEventScalarWhereInput data: XOR } export type LedgerEntryUpsertWithWhereUniqueWithoutOrderInput = { where: LedgerEntryWhereUniqueInput update: XOR create: XOR } export type LedgerEntryUpdateWithWhereUniqueWithoutOrderInput = { where: LedgerEntryWhereUniqueInput data: XOR } export type LedgerEntryUpdateManyWithWhereWithoutOrderInput = { where: LedgerEntryScalarWhereInput data: XOR } export type PreOrderUpsertWithoutConvertedOrderInput = { update: XOR create: XOR where?: PreOrderWhereInput } export type PreOrderUpdateToOneWithWhereWithoutConvertedOrderInput = { where?: PreOrderWhereInput data: XOR } export type PreOrderUpdateWithoutConvertedOrderInput = { id?: StringFieldUpdateOperationsInput | string status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutPreOrdersNestedInput city?: CityUpdateOneWithoutPreOrdersNestedInput workshop?: WorkshopUpdateOneWithoutPreOrdersNestedInput statusEvents?: PreOrderStatusEventUpdateManyWithoutPreOrderNestedInput } export type PreOrderUncheckedUpdateWithoutConvertedOrderInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null workshopId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string statusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutPreOrderNestedInput } export type OrderCreateWithoutItemsInput = { id?: string orderNumber: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutOrdersInput branch?: BranchCreateNestedOneWithoutOrdersInput statusEvents?: OrderStatusEventCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderCreateNestedOneWithoutConvertedOrderInput } export type OrderUncheckedCreateWithoutItemsInput = { id?: string orderNumber: string customerId: string branchId?: string | null status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string statusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderUncheckedCreateNestedOneWithoutConvertedOrderInput } export type OrderCreateOrConnectWithoutItemsInput = { where: OrderWhereUniqueInput create: XOR } export type ProductVariantCreateWithoutOrderItemsInput = { id?: string title: string sku?: string | null rashWeightGrams: Decimal | DecimalJsLike | number | string defaultWagePercent: Decimal | DecimalJsLike | number | string isActive?: boolean product: ProductCreateNestedOneWithoutVariantsInput } export type ProductVariantUncheckedCreateWithoutOrderItemsInput = { id?: string productId: string title: string sku?: string | null rashWeightGrams: Decimal | DecimalJsLike | number | string defaultWagePercent: Decimal | DecimalJsLike | number | string isActive?: boolean } export type ProductVariantCreateOrConnectWithoutOrderItemsInput = { where: ProductVariantWhereUniqueInput create: XOR } export type OrderUpsertWithoutItemsInput = { update: XOR create: XOR where?: OrderWhereInput } export type OrderUpdateToOneWithWhereWithoutItemsInput = { where?: OrderWhereInput data: XOR } export type OrderUpdateWithoutItemsInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutOrdersNestedInput branch?: BranchUpdateOneWithoutOrdersNestedInput statusEvents?: OrderStatusEventUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUpdateOneWithoutConvertedOrderNestedInput } export type OrderUncheckedUpdateWithoutItemsInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string branchId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string statusEvents?: OrderStatusEventUncheckedUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUncheckedUpdateOneWithoutConvertedOrderNestedInput } export type ProductVariantUpsertWithoutOrderItemsInput = { update: XOR create: XOR where?: ProductVariantWhereInput } export type ProductVariantUpdateToOneWithWhereWithoutOrderItemsInput = { where?: ProductVariantWhereInput data: XOR } export type ProductVariantUpdateWithoutOrderItemsInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean product?: ProductUpdateOneRequiredWithoutVariantsNestedInput } export type ProductVariantUncheckedUpdateWithoutOrderItemsInput = { id?: StringFieldUpdateOperationsInput | string productId?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean } export type OrderCreateWithoutStatusEventsInput = { id?: string orderNumber: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutOrdersInput branch?: BranchCreateNestedOneWithoutOrdersInput items?: OrderItemCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderCreateNestedOneWithoutConvertedOrderInput } export type OrderUncheckedCreateWithoutStatusEventsInput = { id?: string orderNumber: string customerId: string branchId?: string | null status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string items?: OrderItemUncheckedCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderUncheckedCreateNestedOneWithoutConvertedOrderInput } export type OrderCreateOrConnectWithoutStatusEventsInput = { where: OrderWhereUniqueInput create: XOR } export type AdminUserCreateWithoutOrderStatusEventsInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string branch?: BranchCreateNestedOneWithoutAdminUsersInput referredCustomers?: CustomerCreateNestedManyWithoutReferredByAgentInput postedLedgerEntries?: LedgerEntryCreateNestedManyWithoutPostedByAdminUserInput preOrderStatusEvents?: PreOrderStatusEventCreateNestedManyWithoutActorAdminUserInput } export type AdminUserUncheckedCreateWithoutOrderStatusEventsInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole branchId?: string | null wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string referredCustomers?: CustomerUncheckedCreateNestedManyWithoutReferredByAgentInput postedLedgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutPostedByAdminUserInput preOrderStatusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput } export type AdminUserCreateOrConnectWithoutOrderStatusEventsInput = { where: AdminUserWhereUniqueInput create: XOR } export type OrderUpsertWithoutStatusEventsInput = { update: XOR create: XOR where?: OrderWhereInput } export type OrderUpdateToOneWithWhereWithoutStatusEventsInput = { where?: OrderWhereInput data: XOR } export type OrderUpdateWithoutStatusEventsInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutOrdersNestedInput branch?: BranchUpdateOneWithoutOrdersNestedInput items?: OrderItemUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUpdateOneWithoutConvertedOrderNestedInput } export type OrderUncheckedUpdateWithoutStatusEventsInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string branchId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string items?: OrderItemUncheckedUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUncheckedUpdateOneWithoutConvertedOrderNestedInput } export type AdminUserUpsertWithoutOrderStatusEventsInput = { update: XOR create: XOR where?: AdminUserWhereInput } export type AdminUserUpdateToOneWithWhereWithoutOrderStatusEventsInput = { where?: AdminUserWhereInput data: XOR } export type AdminUserUpdateWithoutOrderStatusEventsInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string branch?: BranchUpdateOneWithoutAdminUsersNestedInput referredCustomers?: CustomerUpdateManyWithoutReferredByAgentNestedInput postedLedgerEntries?: LedgerEntryUpdateManyWithoutPostedByAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUpdateManyWithoutActorAdminUserNestedInput } export type AdminUserUncheckedUpdateWithoutOrderStatusEventsInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole branchId?: NullableStringFieldUpdateOperationsInput | string | null wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string referredCustomers?: CustomerUncheckedUpdateManyWithoutReferredByAgentNestedInput postedLedgerEntries?: LedgerEntryUncheckedUpdateManyWithoutPostedByAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput } export type CustomerCreateWithoutPreOrdersInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string city?: CityCreateNestedOneWithoutCustomersInput referredByAgent?: AdminUserCreateNestedOneWithoutReferredCustomersInput addresses?: CustomerAddressCreateNestedManyWithoutCustomerInput orders?: OrderCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusCreateNestedManyWithoutCustomerInput } export type CustomerUncheckedCreateWithoutPreOrdersInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput orders?: OrderUncheckedCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusUncheckedCreateNestedManyWithoutCustomerInput } export type CustomerCreateOrConnectWithoutPreOrdersInput = { where: CustomerWhereUniqueInput create: XOR } export type CityCreateWithoutPreOrdersInput = { id?: string name: string province?: string | null customers?: CustomerCreateNestedManyWithoutCityInput addresses?: CustomerAddressCreateNestedManyWithoutCityInput branches?: BranchCreateNestedManyWithoutCityInput } export type CityUncheckedCreateWithoutPreOrdersInput = { id?: string name: string province?: string | null customers?: CustomerUncheckedCreateNestedManyWithoutCityInput addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCityInput branches?: BranchUncheckedCreateNestedManyWithoutCityInput } export type CityCreateOrConnectWithoutPreOrdersInput = { where: CityWhereUniqueInput create: XOR } export type WorkshopCreateWithoutPreOrdersInput = { id?: string name: string isActive?: boolean } export type WorkshopUncheckedCreateWithoutPreOrdersInput = { id?: string name: string isActive?: boolean } export type WorkshopCreateOrConnectWithoutPreOrdersInput = { where: WorkshopWhereUniqueInput create: XOR } export type OrderCreateWithoutConvertedFromPreOrderInput = { id?: string orderNumber: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutOrdersInput branch?: BranchCreateNestedOneWithoutOrdersInput items?: OrderItemCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutOrderInput } export type OrderUncheckedCreateWithoutConvertedFromPreOrderInput = { id?: string orderNumber: string customerId: string branchId?: string | null status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string items?: OrderItemUncheckedCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutOrderInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutOrderInput } export type OrderCreateOrConnectWithoutConvertedFromPreOrderInput = { where: OrderWhereUniqueInput create: XOR } export type PreOrderStatusEventCreateWithoutPreOrderInput = { id?: string changes: JsonNullValueInput | InputJsonValue ipAddress?: string | null createdAt?: Date | string actorAdminUser?: AdminUserCreateNestedOneWithoutPreOrderStatusEventsInput } export type PreOrderStatusEventUncheckedCreateWithoutPreOrderInput = { id?: string changes: JsonNullValueInput | InputJsonValue actorAdminUserId?: string | null ipAddress?: string | null createdAt?: Date | string } export type PreOrderStatusEventCreateOrConnectWithoutPreOrderInput = { where: PreOrderStatusEventWhereUniqueInput create: XOR } export type PreOrderStatusEventCreateManyPreOrderInputEnvelope = { data: PreOrderStatusEventCreateManyPreOrderInput | PreOrderStatusEventCreateManyPreOrderInput[] skipDuplicates?: boolean } export type CustomerUpsertWithoutPreOrdersInput = { update: XOR create: XOR where?: CustomerWhereInput } export type CustomerUpdateToOneWithWhereWithoutPreOrdersInput = { where?: CustomerWhereInput data: XOR } export type CustomerUpdateWithoutPreOrdersInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string city?: CityUpdateOneWithoutCustomersNestedInput referredByAgent?: AdminUserUpdateOneWithoutReferredCustomersNestedInput addresses?: CustomerAddressUpdateManyWithoutCustomerNestedInput orders?: OrderUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateWithoutPreOrdersInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string addresses?: CustomerAddressUncheckedUpdateManyWithoutCustomerNestedInput orders?: OrderUncheckedUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUncheckedUpdateManyWithoutCustomerNestedInput } export type CityUpsertWithoutPreOrdersInput = { update: XOR create: XOR where?: CityWhereInput } export type CityUpdateToOneWithWhereWithoutPreOrdersInput = { where?: CityWhereInput data: XOR } export type CityUpdateWithoutPreOrdersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null customers?: CustomerUpdateManyWithoutCityNestedInput addresses?: CustomerAddressUpdateManyWithoutCityNestedInput branches?: BranchUpdateManyWithoutCityNestedInput } export type CityUncheckedUpdateWithoutPreOrdersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string province?: NullableStringFieldUpdateOperationsInput | string | null customers?: CustomerUncheckedUpdateManyWithoutCityNestedInput addresses?: CustomerAddressUncheckedUpdateManyWithoutCityNestedInput branches?: BranchUncheckedUpdateManyWithoutCityNestedInput } export type WorkshopUpsertWithoutPreOrdersInput = { update: XOR create: XOR where?: WorkshopWhereInput } export type WorkshopUpdateToOneWithWhereWithoutPreOrdersInput = { where?: WorkshopWhereInput data: XOR } export type WorkshopUpdateWithoutPreOrdersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string isActive?: BoolFieldUpdateOperationsInput | boolean } export type WorkshopUncheckedUpdateWithoutPreOrdersInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string isActive?: BoolFieldUpdateOperationsInput | boolean } export type OrderUpsertWithoutConvertedFromPreOrderInput = { update: XOR create: XOR where?: OrderWhereInput } export type OrderUpdateToOneWithWhereWithoutConvertedFromPreOrderInput = { where?: OrderWhereInput data: XOR } export type OrderUpdateWithoutConvertedFromPreOrderInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutOrdersNestedInput branch?: BranchUpdateOneWithoutOrdersNestedInput items?: OrderItemUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutOrderNestedInput } export type OrderUncheckedUpdateWithoutConvertedFromPreOrderInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string branchId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string items?: OrderItemUncheckedUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUncheckedUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutOrderNestedInput } export type PreOrderStatusEventUpsertWithWhereUniqueWithoutPreOrderInput = { where: PreOrderStatusEventWhereUniqueInput update: XOR create: XOR } export type PreOrderStatusEventUpdateWithWhereUniqueWithoutPreOrderInput = { where: PreOrderStatusEventWhereUniqueInput data: XOR } export type PreOrderStatusEventUpdateManyWithWhereWithoutPreOrderInput = { where: PreOrderStatusEventScalarWhereInput data: XOR } export type PreOrderCreateWithoutStatusEventsInput = { id?: string status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutPreOrdersInput city?: CityCreateNestedOneWithoutPreOrdersInput workshop?: WorkshopCreateNestedOneWithoutPreOrdersInput convertedOrder?: OrderCreateNestedOneWithoutConvertedFromPreOrderInput } export type PreOrderUncheckedCreateWithoutStatusEventsInput = { id?: string customerId: string cityId?: string | null workshopId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string } export type PreOrderCreateOrConnectWithoutStatusEventsInput = { where: PreOrderWhereUniqueInput create: XOR } export type AdminUserCreateWithoutPreOrderStatusEventsInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string branch?: BranchCreateNestedOneWithoutAdminUsersInput referredCustomers?: CustomerCreateNestedManyWithoutReferredByAgentInput postedLedgerEntries?: LedgerEntryCreateNestedManyWithoutPostedByAdminUserInput orderStatusEvents?: OrderStatusEventCreateNestedManyWithoutActorAdminUserInput } export type AdminUserUncheckedCreateWithoutPreOrderStatusEventsInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole branchId?: string | null wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string referredCustomers?: CustomerUncheckedCreateNestedManyWithoutReferredByAgentInput postedLedgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutPostedByAdminUserInput orderStatusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput } export type AdminUserCreateOrConnectWithoutPreOrderStatusEventsInput = { where: AdminUserWhereUniqueInput create: XOR } export type PreOrderUpsertWithoutStatusEventsInput = { update: XOR create: XOR where?: PreOrderWhereInput } export type PreOrderUpdateToOneWithWhereWithoutStatusEventsInput = { where?: PreOrderWhereInput data: XOR } export type PreOrderUpdateWithoutStatusEventsInput = { id?: StringFieldUpdateOperationsInput | string status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutPreOrdersNestedInput city?: CityUpdateOneWithoutPreOrdersNestedInput workshop?: WorkshopUpdateOneWithoutPreOrdersNestedInput convertedOrder?: OrderUpdateOneWithoutConvertedFromPreOrderNestedInput } export type PreOrderUncheckedUpdateWithoutStatusEventsInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null workshopId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type AdminUserUpsertWithoutPreOrderStatusEventsInput = { update: XOR create: XOR where?: AdminUserWhereInput } export type AdminUserUpdateToOneWithWhereWithoutPreOrderStatusEventsInput = { where?: AdminUserWhereInput data: XOR } export type AdminUserUpdateWithoutPreOrderStatusEventsInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string branch?: BranchUpdateOneWithoutAdminUsersNestedInput referredCustomers?: CustomerUpdateManyWithoutReferredByAgentNestedInput postedLedgerEntries?: LedgerEntryUpdateManyWithoutPostedByAdminUserNestedInput orderStatusEvents?: OrderStatusEventUpdateManyWithoutActorAdminUserNestedInput } export type AdminUserUncheckedUpdateWithoutPreOrderStatusEventsInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole branchId?: NullableStringFieldUpdateOperationsInput | string | null wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string referredCustomers?: CustomerUncheckedUpdateManyWithoutReferredByAgentNestedInput postedLedgerEntries?: LedgerEntryUncheckedUpdateManyWithoutPostedByAdminUserNestedInput orderStatusEvents?: OrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput } export type CustomerCreateWithoutLedgerEntriesInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string city?: CityCreateNestedOneWithoutCustomersInput referredByAgent?: AdminUserCreateNestedOneWithoutReferredCustomersInput addresses?: CustomerAddressCreateNestedManyWithoutCustomerInput orders?: OrderCreateNestedManyWithoutCustomerInput preOrders?: PreOrderCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusCreateNestedManyWithoutCustomerInput } export type CustomerUncheckedCreateWithoutLedgerEntriesInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput orders?: OrderUncheckedCreateNestedManyWithoutCustomerInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCustomerInput walletBonuses?: WalletBonusUncheckedCreateNestedManyWithoutCustomerInput } export type CustomerCreateOrConnectWithoutLedgerEntriesInput = { where: CustomerWhereUniqueInput create: XOR } export type OrderCreateWithoutLedgerEntriesInput = { id?: string orderNumber: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string customer: CustomerCreateNestedOneWithoutOrdersInput branch?: BranchCreateNestedOneWithoutOrdersInput items?: OrderItemCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderCreateNestedOneWithoutConvertedOrderInput } export type OrderUncheckedCreateWithoutLedgerEntriesInput = { id?: string orderNumber: string customerId: string branchId?: string | null status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string items?: OrderItemUncheckedCreateNestedManyWithoutOrderInput statusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutOrderInput convertedFromPreOrder?: PreOrderUncheckedCreateNestedOneWithoutConvertedOrderInput } export type OrderCreateOrConnectWithoutLedgerEntriesInput = { where: OrderWhereUniqueInput create: XOR } export type AdminUserCreateWithoutPostedLedgerEntriesInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string branch?: BranchCreateNestedOneWithoutAdminUsersInput referredCustomers?: CustomerCreateNestedManyWithoutReferredByAgentInput orderStatusEvents?: OrderStatusEventCreateNestedManyWithoutActorAdminUserInput preOrderStatusEvents?: PreOrderStatusEventCreateNestedManyWithoutActorAdminUserInput } export type AdminUserUncheckedCreateWithoutPostedLedgerEntriesInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole branchId?: string | null wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string referredCustomers?: CustomerUncheckedCreateNestedManyWithoutReferredByAgentInput orderStatusEvents?: OrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput preOrderStatusEvents?: PreOrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput } export type AdminUserCreateOrConnectWithoutPostedLedgerEntriesInput = { where: AdminUserWhereUniqueInput create: XOR } export type CustomerUpsertWithoutLedgerEntriesInput = { update: XOR create: XOR where?: CustomerWhereInput } export type CustomerUpdateToOneWithWhereWithoutLedgerEntriesInput = { where?: CustomerWhereInput data: XOR } export type CustomerUpdateWithoutLedgerEntriesInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string city?: CityUpdateOneWithoutCustomersNestedInput referredByAgent?: AdminUserUpdateOneWithoutReferredCustomersNestedInput addresses?: CustomerAddressUpdateManyWithoutCustomerNestedInput orders?: OrderUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateWithoutLedgerEntriesInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string addresses?: CustomerAddressUncheckedUpdateManyWithoutCustomerNestedInput orders?: OrderUncheckedUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUncheckedUpdateManyWithoutCustomerNestedInput } export type OrderUpsertWithoutLedgerEntriesInput = { update: XOR create: XOR where?: OrderWhereInput } export type OrderUpdateToOneWithWhereWithoutLedgerEntriesInput = { where?: OrderWhereInput data: XOR } export type OrderUpdateWithoutLedgerEntriesInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutOrdersNestedInput branch?: BranchUpdateOneWithoutOrdersNestedInput items?: OrderItemUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUpdateOneWithoutConvertedOrderNestedInput } export type OrderUncheckedUpdateWithoutLedgerEntriesInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string branchId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string items?: OrderItemUncheckedUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUncheckedUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUncheckedUpdateOneWithoutConvertedOrderNestedInput } export type AdminUserUpsertWithoutPostedLedgerEntriesInput = { update: XOR create: XOR where?: AdminUserWhereInput } export type AdminUserUpdateToOneWithWhereWithoutPostedLedgerEntriesInput = { where?: AdminUserWhereInput data: XOR } export type AdminUserUpdateWithoutPostedLedgerEntriesInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string branch?: BranchUpdateOneWithoutAdminUsersNestedInput referredCustomers?: CustomerUpdateManyWithoutReferredByAgentNestedInput orderStatusEvents?: OrderStatusEventUpdateManyWithoutActorAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUpdateManyWithoutActorAdminUserNestedInput } export type AdminUserUncheckedUpdateWithoutPostedLedgerEntriesInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole branchId?: NullableStringFieldUpdateOperationsInput | string | null wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string referredCustomers?: CustomerUncheckedUpdateManyWithoutReferredByAgentNestedInput orderStatusEvents?: OrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput } export type CustomerCreateWithoutWalletBonusesInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string city?: CityCreateNestedOneWithoutCustomersInput referredByAgent?: AdminUserCreateNestedOneWithoutReferredCustomersInput addresses?: CustomerAddressCreateNestedManyWithoutCustomerInput orders?: OrderCreateNestedManyWithoutCustomerInput preOrders?: PreOrderCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryCreateNestedManyWithoutCustomerInput } export type CustomerUncheckedCreateWithoutWalletBonusesInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string addresses?: CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput orders?: OrderUncheckedCreateNestedManyWithoutCustomerInput preOrders?: PreOrderUncheckedCreateNestedManyWithoutCustomerInput ledgerEntries?: LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput } export type CustomerCreateOrConnectWithoutWalletBonusesInput = { where: CustomerWhereUniqueInput create: XOR } export type CustomerUpsertWithoutWalletBonusesInput = { update: XOR create: XOR where?: CustomerWhereInput } export type CustomerUpdateToOneWithWhereWithoutWalletBonusesInput = { where?: CustomerWhereInput data: XOR } export type CustomerUpdateWithoutWalletBonusesInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string city?: CityUpdateOneWithoutCustomersNestedInput referredByAgent?: AdminUserUpdateOneWithoutReferredCustomersNestedInput addresses?: CustomerAddressUpdateManyWithoutCustomerNestedInput orders?: OrderUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateWithoutWalletBonusesInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string addresses?: CustomerAddressUncheckedUpdateManyWithoutCustomerNestedInput orders?: OrderUncheckedUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutCustomerNestedInput } export type CustomerCreateManyCityInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string referredByAgentId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string } export type CustomerAddressCreateManyCityInput = { id?: string customerId: string addressLine: string isDefault?: boolean } export type BranchCreateManyCityInput = { id?: string name: string } export type PreOrderCreateManyCityInput = { id?: string customerId: string workshopId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string } export type CustomerUpdateWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string referredByAgent?: AdminUserUpdateOneWithoutReferredCustomersNestedInput addresses?: CustomerAddressUpdateManyWithoutCustomerNestedInput orders?: OrderUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string addresses?: CustomerAddressUncheckedUpdateManyWithoutCustomerNestedInput orders?: OrderUncheckedUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUncheckedUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateManyWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string referredByAgentId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type CustomerAddressUpdateWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean customer?: CustomerUpdateOneRequiredWithoutAddressesNestedInput } export type CustomerAddressUncheckedUpdateWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean } export type CustomerAddressUncheckedUpdateManyWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean } export type BranchUpdateWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string adminUsers?: AdminUserUpdateManyWithoutBranchNestedInput orders?: OrderUpdateManyWithoutBranchNestedInput } export type BranchUncheckedUpdateWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string adminUsers?: AdminUserUncheckedUpdateManyWithoutBranchNestedInput orders?: OrderUncheckedUpdateManyWithoutBranchNestedInput } export type BranchUncheckedUpdateManyWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string name?: StringFieldUpdateOperationsInput | string } export type PreOrderUpdateWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutPreOrdersNestedInput workshop?: WorkshopUpdateOneWithoutPreOrdersNestedInput convertedOrder?: OrderUpdateOneWithoutConvertedFromPreOrderNestedInput statusEvents?: PreOrderStatusEventUpdateManyWithoutPreOrderNestedInput } export type PreOrderUncheckedUpdateWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string workshopId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string statusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutPreOrderNestedInput } export type PreOrderUncheckedUpdateManyWithoutCityInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string workshopId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type CustomerCreateManyReferredByAgentInput = { id?: string fullName: string mobile: string nationalCode: string passwordHash: string cityId?: string | null goldCreditLimitGrams?: Decimal | DecimalJsLike | number | string goldDebtGrams?: Decimal | DecimalJsLike | number | string fiatDebtRial?: Decimal | DecimalJsLike | number | string verificationStep?: $Enums.VerificationStep nationalIdImageUrl?: string | null businessLicenseUrl?: string | null shopImageUrl?: string | null isActive?: boolean createdAt?: Date | string updatedAt?: Date | string } export type LedgerEntryCreateManyPostedByAdminUserInput = { id?: string customerId: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null orderId?: string | null confirmed?: boolean confirmedAt?: Date | string | null note?: string | null createdAt?: Date | string } export type OrderStatusEventCreateManyActorAdminUserInput = { id?: string orderId: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null createdAt?: Date | string } export type PreOrderStatusEventCreateManyActorAdminUserInput = { id?: string preOrderId: string changes: JsonNullValueInput | InputJsonValue ipAddress?: string | null createdAt?: Date | string } export type CustomerUpdateWithoutReferredByAgentInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string city?: CityUpdateOneWithoutCustomersNestedInput addresses?: CustomerAddressUpdateManyWithoutCustomerNestedInput orders?: OrderUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateWithoutReferredByAgentInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string addresses?: CustomerAddressUncheckedUpdateManyWithoutCustomerNestedInput orders?: OrderUncheckedUpdateManyWithoutCustomerNestedInput preOrders?: PreOrderUncheckedUpdateManyWithoutCustomerNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutCustomerNestedInput walletBonuses?: WalletBonusUncheckedUpdateManyWithoutCustomerNestedInput } export type CustomerUncheckedUpdateManyWithoutReferredByAgentInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string nationalCode?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null goldCreditLimitGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string goldDebtGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string fiatDebtRial?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string verificationStep?: EnumVerificationStepFieldUpdateOperationsInput | $Enums.VerificationStep nationalIdImageUrl?: NullableStringFieldUpdateOperationsInput | string | null businessLicenseUrl?: NullableStringFieldUpdateOperationsInput | string | null shopImageUrl?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryUpdateWithoutPostedByAdminUserInput = { id?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutLedgerEntriesNestedInput order?: OrderUpdateOneWithoutLedgerEntriesNestedInput } export type LedgerEntryUncheckedUpdateWithoutPostedByAdminUserInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null orderId?: NullableStringFieldUpdateOperationsInput | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryUncheckedUpdateManyWithoutPostedByAdminUserInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null orderId?: NullableStringFieldUpdateOperationsInput | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type OrderStatusEventUpdateWithoutActorAdminUserInput = { id?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string order?: OrderUpdateOneRequiredWithoutStatusEventsNestedInput } export type OrderStatusEventUncheckedUpdateWithoutActorAdminUserInput = { id?: StringFieldUpdateOperationsInput | string orderId?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type OrderStatusEventUncheckedUpdateManyWithoutActorAdminUserInput = { id?: StringFieldUpdateOperationsInput | string orderId?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderStatusEventUpdateWithoutActorAdminUserInput = { id?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string preOrder?: PreOrderUpdateOneRequiredWithoutStatusEventsNestedInput } export type PreOrderStatusEventUncheckedUpdateWithoutActorAdminUserInput = { id?: StringFieldUpdateOperationsInput | string preOrderId?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderStatusEventUncheckedUpdateManyWithoutActorAdminUserInput = { id?: StringFieldUpdateOperationsInput | string preOrderId?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type CustomerAddressCreateManyCustomerInput = { id?: string cityId?: string | null addressLine: string isDefault?: boolean } export type OrderCreateManyCustomerInput = { id?: string orderNumber: string branchId?: string | null status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string } export type PreOrderCreateManyCustomerInput = { id?: string cityId?: string | null workshopId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string } export type LedgerEntryCreateManyCustomerInput = { id?: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null orderId?: string | null confirmed?: boolean confirmedAt?: Date | string | null postedByAdminUserId?: string | null note?: string | null createdAt?: Date | string } export type WalletBonusCreateManyCustomerInput = { id?: string orderId?: string | null goldGrams: Decimal | DecimalJsLike | number | string grantedAt?: Date | string expiresAt: Date | string consumedAt?: Date | string | null isActive?: boolean } export type CustomerAddressUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean city?: CityUpdateOneWithoutAddressesNestedInput } export type CustomerAddressUncheckedUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean } export type CustomerAddressUncheckedUpdateManyWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null addressLine?: StringFieldUpdateOperationsInput | string isDefault?: BoolFieldUpdateOperationsInput | boolean } export type OrderUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string branch?: BranchUpdateOneWithoutOrdersNestedInput items?: OrderItemUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUpdateOneWithoutConvertedOrderNestedInput } export type OrderUncheckedUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string branchId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string items?: OrderItemUncheckedUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUncheckedUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUncheckedUpdateOneWithoutConvertedOrderNestedInput } export type OrderUncheckedUpdateManyWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string branchId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string city?: CityUpdateOneWithoutPreOrdersNestedInput workshop?: WorkshopUpdateOneWithoutPreOrdersNestedInput convertedOrder?: OrderUpdateOneWithoutConvertedFromPreOrderNestedInput statusEvents?: PreOrderStatusEventUpdateManyWithoutPreOrderNestedInput } export type PreOrderUncheckedUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null workshopId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string statusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutPreOrderNestedInput } export type PreOrderUncheckedUpdateManyWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null workshopId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string order?: OrderUpdateOneWithoutLedgerEntriesNestedInput postedByAdminUser?: AdminUserUpdateOneWithoutPostedLedgerEntriesNestedInput } export type LedgerEntryUncheckedUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null orderId?: NullableStringFieldUpdateOperationsInput | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null postedByAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryUncheckedUpdateManyWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null orderId?: NullableStringFieldUpdateOperationsInput | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null postedByAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type WalletBonusUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string orderId?: NullableStringFieldUpdateOperationsInput | string | null goldGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFieldUpdateOperationsInput | Date | string expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string consumedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type WalletBonusUncheckedUpdateWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string orderId?: NullableStringFieldUpdateOperationsInput | string | null goldGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFieldUpdateOperationsInput | Date | string expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string consumedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type WalletBonusUncheckedUpdateManyWithoutCustomerInput = { id?: StringFieldUpdateOperationsInput | string orderId?: NullableStringFieldUpdateOperationsInput | string | null goldGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string grantedAt?: DateTimeFieldUpdateOperationsInput | Date | string expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string consumedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null isActive?: BoolFieldUpdateOperationsInput | boolean } export type AdminUserCreateManyBranchInput = { id?: string fullName: string mobile: string passwordHash: string role: $Enums.AdminRole wagePercent?: Decimal | DecimalJsLike | number | string | null isActive?: boolean createdAt?: Date | string } export type OrderCreateManyBranchInput = { id?: string orderNumber: string customerId: string status?: $Enums.OrderStatus totalGoldWeightGrams: Decimal | DecimalJsLike | number | string wageWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: boolean deliveredAt?: Date | string | null createdAt?: Date | string updatedAt?: Date | string } export type AdminUserUpdateWithoutBranchInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string referredCustomers?: CustomerUpdateManyWithoutReferredByAgentNestedInput postedLedgerEntries?: LedgerEntryUpdateManyWithoutPostedByAdminUserNestedInput orderStatusEvents?: OrderStatusEventUpdateManyWithoutActorAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUpdateManyWithoutActorAdminUserNestedInput } export type AdminUserUncheckedUpdateWithoutBranchInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string referredCustomers?: CustomerUncheckedUpdateManyWithoutReferredByAgentNestedInput postedLedgerEntries?: LedgerEntryUncheckedUpdateManyWithoutPostedByAdminUserNestedInput orderStatusEvents?: OrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput preOrderStatusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutActorAdminUserNestedInput } export type AdminUserUncheckedUpdateManyWithoutBranchInput = { id?: StringFieldUpdateOperationsInput | string fullName?: StringFieldUpdateOperationsInput | string mobile?: StringFieldUpdateOperationsInput | string passwordHash?: StringFieldUpdateOperationsInput | string role?: EnumAdminRoleFieldUpdateOperationsInput | $Enums.AdminRole wagePercent?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type OrderUpdateWithoutBranchInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutOrdersNestedInput items?: OrderItemUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUpdateOneWithoutConvertedOrderNestedInput } export type OrderUncheckedUpdateWithoutBranchInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string items?: OrderItemUncheckedUpdateManyWithoutOrderNestedInput statusEvents?: OrderStatusEventUncheckedUpdateManyWithoutOrderNestedInput ledgerEntries?: LedgerEntryUncheckedUpdateManyWithoutOrderNestedInput convertedFromPreOrder?: PreOrderUncheckedUpdateOneWithoutConvertedOrderNestedInput } export type OrderUncheckedUpdateManyWithoutBranchInput = { id?: StringFieldUpdateOperationsInput | string orderNumber?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string status?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus totalGoldWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wageWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isSuspendedOverCreditLimit?: BoolFieldUpdateOperationsInput | boolean deliveredAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderCreateManyWorkshopInput = { id?: string customerId: string cityId?: string | null status?: $Enums.PreOrderStatus designImageUrl?: string | null colorName?: string | null sizeSpec?: string | null stoneColor?: string | null minaColor?: string | null estimatedWeightGrams?: Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: Decimal | DecimalJsLike | number | string | null description?: string | null convertedOrderId?: string | null createdAt?: Date | string updatedAt?: Date | string } export type PreOrderUpdateWithoutWorkshopInput = { id?: StringFieldUpdateOperationsInput | string status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutPreOrdersNestedInput city?: CityUpdateOneWithoutPreOrdersNestedInput convertedOrder?: OrderUpdateOneWithoutConvertedFromPreOrderNestedInput statusEvents?: PreOrderStatusEventUpdateManyWithoutPreOrderNestedInput } export type PreOrderUncheckedUpdateWithoutWorkshopInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string statusEvents?: PreOrderStatusEventUncheckedUpdateManyWithoutPreOrderNestedInput } export type PreOrderUncheckedUpdateManyWithoutWorkshopInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string cityId?: NullableStringFieldUpdateOperationsInput | string | null status?: EnumPreOrderStatusFieldUpdateOperationsInput | $Enums.PreOrderStatus designImageUrl?: NullableStringFieldUpdateOperationsInput | string | null colorName?: NullableStringFieldUpdateOperationsInput | string | null sizeSpec?: NullableStringFieldUpdateOperationsInput | string | null stoneColor?: NullableStringFieldUpdateOperationsInput | string | null minaColor?: NullableStringFieldUpdateOperationsInput | string | null estimatedWeightGrams?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null estimatedPriceRial?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null description?: NullableStringFieldUpdateOperationsInput | string | null convertedOrderId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type CategoryCreateManyParentInput = { id?: string title: string } export type ProductCreateManyCategoryInput = { id?: string title: string description?: string | null brandId?: string | null isActive?: boolean createdAt?: Date | string } export type CategoryUpdateWithoutParentInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string children?: CategoryUpdateManyWithoutParentNestedInput products?: ProductUpdateManyWithoutCategoryNestedInput } export type CategoryUncheckedUpdateWithoutParentInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string children?: CategoryUncheckedUpdateManyWithoutParentNestedInput products?: ProductUncheckedUpdateManyWithoutCategoryNestedInput } export type CategoryUncheckedUpdateManyWithoutParentInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string } export type ProductUpdateWithoutCategoryInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string brand?: BrandUpdateOneWithoutProductsNestedInput variants?: ProductVariantUpdateManyWithoutProductNestedInput images?: ProductImageUpdateManyWithoutProductNestedInput collections?: CollectionProductUpdateManyWithoutProductNestedInput } export type ProductUncheckedUpdateWithoutCategoryInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null brandId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string variants?: ProductVariantUncheckedUpdateManyWithoutProductNestedInput images?: ProductImageUncheckedUpdateManyWithoutProductNestedInput collections?: CollectionProductUncheckedUpdateManyWithoutProductNestedInput } export type ProductUncheckedUpdateManyWithoutCategoryInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null brandId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type ProductCreateManyBrandInput = { id?: string title: string description?: string | null categoryId?: string | null isActive?: boolean createdAt?: Date | string } export type ProductUpdateWithoutBrandInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string category?: CategoryUpdateOneWithoutProductsNestedInput variants?: ProductVariantUpdateManyWithoutProductNestedInput images?: ProductImageUpdateManyWithoutProductNestedInput collections?: CollectionProductUpdateManyWithoutProductNestedInput } export type ProductUncheckedUpdateWithoutBrandInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null categoryId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string variants?: ProductVariantUncheckedUpdateManyWithoutProductNestedInput images?: ProductImageUncheckedUpdateManyWithoutProductNestedInput collections?: CollectionProductUncheckedUpdateManyWithoutProductNestedInput } export type ProductUncheckedUpdateManyWithoutBrandInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string description?: NullableStringFieldUpdateOperationsInput | string | null categoryId?: NullableStringFieldUpdateOperationsInput | string | null isActive?: BoolFieldUpdateOperationsInput | boolean createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type CollectionProductCreateManyCollectionInput = { productId: string } export type CollectionProductUpdateWithoutCollectionInput = { product?: ProductUpdateOneRequiredWithoutCollectionsNestedInput } export type CollectionProductUncheckedUpdateWithoutCollectionInput = { productId?: StringFieldUpdateOperationsInput | string } export type CollectionProductUncheckedUpdateManyWithoutCollectionInput = { productId?: StringFieldUpdateOperationsInput | string } export type ProductVariantCreateManyProductInput = { id?: string title: string sku?: string | null rashWeightGrams: Decimal | DecimalJsLike | number | string defaultWagePercent: Decimal | DecimalJsLike | number | string isActive?: boolean } export type ProductImageCreateManyProductInput = { id?: string url: string sortOrder?: number } export type CollectionProductCreateManyProductInput = { collectionId: string } export type ProductVariantUpdateWithoutProductInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean orderItems?: OrderItemUpdateManyWithoutProductVariantNestedInput } export type ProductVariantUncheckedUpdateWithoutProductInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean orderItems?: OrderItemUncheckedUpdateManyWithoutProductVariantNestedInput } export type ProductVariantUncheckedUpdateManyWithoutProductInput = { id?: StringFieldUpdateOperationsInput | string title?: StringFieldUpdateOperationsInput | string sku?: NullableStringFieldUpdateOperationsInput | string | null rashWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string defaultWagePercent?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string isActive?: BoolFieldUpdateOperationsInput | boolean } export type ProductImageUpdateWithoutProductInput = { id?: StringFieldUpdateOperationsInput | string url?: StringFieldUpdateOperationsInput | string sortOrder?: IntFieldUpdateOperationsInput | number } export type ProductImageUncheckedUpdateWithoutProductInput = { id?: StringFieldUpdateOperationsInput | string url?: StringFieldUpdateOperationsInput | string sortOrder?: IntFieldUpdateOperationsInput | number } export type ProductImageUncheckedUpdateManyWithoutProductInput = { id?: StringFieldUpdateOperationsInput | string url?: StringFieldUpdateOperationsInput | string sortOrder?: IntFieldUpdateOperationsInput | number } export type CollectionProductUpdateWithoutProductInput = { collection?: CollectionUpdateOneRequiredWithoutProductsNestedInput } export type CollectionProductUncheckedUpdateWithoutProductInput = { collectionId?: StringFieldUpdateOperationsInput | string } export type CollectionProductUncheckedUpdateManyWithoutProductInput = { collectionId?: StringFieldUpdateOperationsInput | string } export type OrderItemCreateManyProductVariantInput = { id?: string orderId: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string } export type OrderItemUpdateWithoutProductVariantInput = { id?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string order?: OrderUpdateOneRequiredWithoutItemsNestedInput } export type OrderItemUncheckedUpdateWithoutProductVariantInput = { id?: StringFieldUpdateOperationsInput | string orderId?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string } export type OrderItemUncheckedUpdateManyWithoutProductVariantInput = { id?: StringFieldUpdateOperationsInput | string orderId?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string } export type OrderItemCreateManyOrderInput = { id?: string productVariantId: string quantity: number rashWeightGramsSnapshot: Decimal | DecimalJsLike | number | string wagePercentSnapshot: Decimal | DecimalJsLike | number | string discountPercentSnapshot?: Decimal | DecimalJsLike | number | string computedWeightGrams: Decimal | DecimalJsLike | number | string flatRialCharge?: Decimal | DecimalJsLike | number | string } export type OrderStatusEventCreateManyOrderInput = { id?: string fromStatus?: $Enums.OrderStatus | null toStatus: $Enums.OrderStatus note?: string | null actorAdminUserId?: string | null createdAt?: Date | string } export type LedgerEntryCreateManyOrderInput = { id?: string customerId: string currency: $Enums.LedgerCurrency direction: $Enums.LedgerDirection sourceType: $Enums.LedgerSourceType amount: Decimal | DecimalJsLike | number | string karatPerMille?: number | null pricePerGramRialAtEntry?: Decimal | DecimalJsLike | number | string | null confirmed?: boolean confirmedAt?: Date | string | null postedByAdminUserId?: string | null note?: string | null createdAt?: Date | string } export type OrderItemUpdateWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string productVariant?: ProductVariantUpdateOneRequiredWithoutOrderItemsNestedInput } export type OrderItemUncheckedUpdateWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string productVariantId?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string } export type OrderItemUncheckedUpdateManyWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string productVariantId?: StringFieldUpdateOperationsInput | string quantity?: IntFieldUpdateOperationsInput | number rashWeightGramsSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string wagePercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string discountPercentSnapshot?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string computedWeightGrams?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string flatRialCharge?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string } export type OrderStatusEventUpdateWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string actorAdminUser?: AdminUserUpdateOneWithoutOrderStatusEventsNestedInput } export type OrderStatusEventUncheckedUpdateWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null actorAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type OrderStatusEventUncheckedUpdateManyWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string fromStatus?: NullableEnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus | null toStatus?: EnumOrderStatusFieldUpdateOperationsInput | $Enums.OrderStatus note?: NullableStringFieldUpdateOperationsInput | string | null actorAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryUpdateWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string customer?: CustomerUpdateOneRequiredWithoutLedgerEntriesNestedInput postedByAdminUser?: AdminUserUpdateOneWithoutPostedLedgerEntriesNestedInput } export type LedgerEntryUncheckedUpdateWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null postedByAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type LedgerEntryUncheckedUpdateManyWithoutOrderInput = { id?: StringFieldUpdateOperationsInput | string customerId?: StringFieldUpdateOperationsInput | string currency?: EnumLedgerCurrencyFieldUpdateOperationsInput | $Enums.LedgerCurrency direction?: EnumLedgerDirectionFieldUpdateOperationsInput | $Enums.LedgerDirection sourceType?: EnumLedgerSourceTypeFieldUpdateOperationsInput | $Enums.LedgerSourceType amount?: DecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string karatPerMille?: NullableIntFieldUpdateOperationsInput | number | null pricePerGramRialAtEntry?: NullableDecimalFieldUpdateOperationsInput | Decimal | DecimalJsLike | number | string | null confirmed?: BoolFieldUpdateOperationsInput | boolean confirmedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null postedByAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null note?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderStatusEventCreateManyPreOrderInput = { id?: string changes: JsonNullValueInput | InputJsonValue actorAdminUserId?: string | null ipAddress?: string | null createdAt?: Date | string } export type PreOrderStatusEventUpdateWithoutPreOrderInput = { id?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string actorAdminUser?: AdminUserUpdateOneWithoutPreOrderStatusEventsNestedInput } export type PreOrderStatusEventUncheckedUpdateWithoutPreOrderInput = { id?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue actorAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } export type PreOrderStatusEventUncheckedUpdateManyWithoutPreOrderInput = { id?: StringFieldUpdateOperationsInput | string changes?: JsonNullValueInput | InputJsonValue actorAdminUserId?: NullableStringFieldUpdateOperationsInput | string | null ipAddress?: NullableStringFieldUpdateOperationsInput | string | null createdAt?: DateTimeFieldUpdateOperationsInput | Date | string } /** * Aliases for legacy arg types */ /** * @deprecated Use CityCountOutputTypeDefaultArgs instead */ export type CityCountOutputTypeArgs = CityCountOutputTypeDefaultArgs /** * @deprecated Use AdminUserCountOutputTypeDefaultArgs instead */ export type AdminUserCountOutputTypeArgs = AdminUserCountOutputTypeDefaultArgs /** * @deprecated Use CustomerCountOutputTypeDefaultArgs instead */ export type CustomerCountOutputTypeArgs = CustomerCountOutputTypeDefaultArgs /** * @deprecated Use BranchCountOutputTypeDefaultArgs instead */ export type BranchCountOutputTypeArgs = BranchCountOutputTypeDefaultArgs /** * @deprecated Use WorkshopCountOutputTypeDefaultArgs instead */ export type WorkshopCountOutputTypeArgs = WorkshopCountOutputTypeDefaultArgs /** * @deprecated Use CategoryCountOutputTypeDefaultArgs instead */ export type CategoryCountOutputTypeArgs = CategoryCountOutputTypeDefaultArgs /** * @deprecated Use BrandCountOutputTypeDefaultArgs instead */ export type BrandCountOutputTypeArgs = BrandCountOutputTypeDefaultArgs /** * @deprecated Use CollectionCountOutputTypeDefaultArgs instead */ export type CollectionCountOutputTypeArgs = CollectionCountOutputTypeDefaultArgs /** * @deprecated Use ProductCountOutputTypeDefaultArgs instead */ export type ProductCountOutputTypeArgs = ProductCountOutputTypeDefaultArgs /** * @deprecated Use ProductVariantCountOutputTypeDefaultArgs instead */ export type ProductVariantCountOutputTypeArgs = ProductVariantCountOutputTypeDefaultArgs /** * @deprecated Use OrderCountOutputTypeDefaultArgs instead */ export type OrderCountOutputTypeArgs = OrderCountOutputTypeDefaultArgs /** * @deprecated Use PreOrderCountOutputTypeDefaultArgs instead */ export type PreOrderCountOutputTypeArgs = PreOrderCountOutputTypeDefaultArgs /** * @deprecated Use CityDefaultArgs instead */ export type CityArgs = CityDefaultArgs /** * @deprecated Use AdminUserDefaultArgs instead */ export type AdminUserArgs = AdminUserDefaultArgs /** * @deprecated Use CustomerDefaultArgs instead */ export type CustomerArgs = CustomerDefaultArgs /** * @deprecated Use CustomerAddressDefaultArgs instead */ export type CustomerAddressArgs = CustomerAddressDefaultArgs /** * @deprecated Use BranchDefaultArgs instead */ export type BranchArgs = BranchDefaultArgs /** * @deprecated Use WorkshopDefaultArgs instead */ export type WorkshopArgs = WorkshopDefaultArgs /** * @deprecated Use CategoryDefaultArgs instead */ export type CategoryArgs = CategoryDefaultArgs /** * @deprecated Use BrandDefaultArgs instead */ export type BrandArgs = BrandDefaultArgs /** * @deprecated Use CollectionDefaultArgs instead */ export type CollectionArgs = CollectionDefaultArgs /** * @deprecated Use CollectionProductDefaultArgs instead */ export type CollectionProductArgs = CollectionProductDefaultArgs /** * @deprecated Use ProductDefaultArgs instead */ export type ProductArgs = ProductDefaultArgs /** * @deprecated Use ProductImageDefaultArgs instead */ export type ProductImageArgs = ProductImageDefaultArgs /** * @deprecated Use ProductVariantDefaultArgs instead */ export type ProductVariantArgs = ProductVariantDefaultArgs /** * @deprecated Use OrderDefaultArgs instead */ export type OrderArgs = OrderDefaultArgs /** * @deprecated Use OrderItemDefaultArgs instead */ export type OrderItemArgs = OrderItemDefaultArgs /** * @deprecated Use OrderStatusEventDefaultArgs instead */ export type OrderStatusEventArgs = OrderStatusEventDefaultArgs /** * @deprecated Use PreOrderDefaultArgs instead */ export type PreOrderArgs = PreOrderDefaultArgs /** * @deprecated Use PreOrderStatusEventDefaultArgs instead */ export type PreOrderStatusEventArgs = PreOrderStatusEventDefaultArgs /** * @deprecated Use LedgerEntryDefaultArgs instead */ export type LedgerEntryArgs = LedgerEntryDefaultArgs /** * @deprecated Use GoldPriceQuoteDefaultArgs instead */ export type GoldPriceQuoteArgs = GoldPriceQuoteDefaultArgs /** * @deprecated Use WalletBonusDefaultArgs instead */ export type WalletBonusArgs = WalletBonusDefaultArgs /** * Batch Payload for updateMany & deleteMany & createMany */ export type BatchPayload = { count: number } /** * DMMF */ export const dmmf: runtime.BaseDMMF }