Files
hedena_gold/apps/api/release/vendor/.prisma/client/index.d.ts
T

36993 lines
1.4 MiB
Plaintext

/**
* 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<T> = $Public.PrismaPromise<T>
/**
* Model City
*
*/
export type City = $Result.DefaultSelection<Prisma.$CityPayload>
/**
* Model AdminUser
*
*/
export type AdminUser = $Result.DefaultSelection<Prisma.$AdminUserPayload>
/**
* Model Customer
*
*/
export type Customer = $Result.DefaultSelection<Prisma.$CustomerPayload>
/**
* Model CustomerAddress
*
*/
export type CustomerAddress = $Result.DefaultSelection<Prisma.$CustomerAddressPayload>
/**
* Model Branch
*
*/
export type Branch = $Result.DefaultSelection<Prisma.$BranchPayload>
/**
* Model Workshop
*
*/
export type Workshop = $Result.DefaultSelection<Prisma.$WorkshopPayload>
/**
* Model Category
*
*/
export type Category = $Result.DefaultSelection<Prisma.$CategoryPayload>
/**
* Model Brand
*
*/
export type Brand = $Result.DefaultSelection<Prisma.$BrandPayload>
/**
* 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<Prisma.$CollectionPayload>
/**
* Model CollectionProduct
*
*/
export type CollectionProduct = $Result.DefaultSelection<Prisma.$CollectionProductPayload>
/**
* Model Product
*
*/
export type Product = $Result.DefaultSelection<Prisma.$ProductPayload>
/**
* Model ProductImage
*
*/
export type ProductImage = $Result.DefaultSelection<Prisma.$ProductImagePayload>
/**
* Model ProductVariant
*
*/
export type ProductVariant = $Result.DefaultSelection<Prisma.$ProductVariantPayload>
/**
* Model Order
*
*/
export type Order = $Result.DefaultSelection<Prisma.$OrderPayload>
/**
* Model OrderItem
*
*/
export type OrderItem = $Result.DefaultSelection<Prisma.$OrderItemPayload>
/**
* Model OrderStatusEvent
*
*/
export type OrderStatusEvent = $Result.DefaultSelection<Prisma.$OrderStatusEventPayload>
/**
* Model PreOrder
*
*/
export type PreOrder = $Result.DefaultSelection<Prisma.$PreOrderPayload>
/**
* Model PreOrderStatusEvent
*
*/
export type PreOrderStatusEvent = $Result.DefaultSelection<Prisma.$PreOrderStatusEventPayload>
/**
* Model LedgerEntry
*
*/
export type LedgerEntry = $Result.DefaultSelection<Prisma.$LedgerEntryPayload>
/**
* Model GoldPriceQuote
* Replaces legacy WebServiceGold / ConfigStatic.gold_price — timestamped price feed.
*/
export type GoldPriceQuote = $Result.DefaultSelection<Prisma.$GoldPriceQuotePayload>
/**
* Model WalletBonus
* Time-limited gold cashback bonus — replaces the legacy Rooyesh\Wallet gold credit.
*/
export type WalletBonus = $Result.DefaultSelection<Prisma.$WalletBonusPayload>
/**
* 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.LogLevel | Prisma.LogDefinition> ? Prisma.GetEvents<ClientOptions['log']> : never : never,
ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs
> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<ClientOptions, Prisma.PrismaClientOptions>);
$on<V extends U>(eventType: V, callback: (event: V extends 'query' ? Prisma.QueryEvent : Prisma.LogEvent) => void): void;
/**
* Connect with the database
*/
$connect(): $Utils.JsPromise<void>;
/**
* Disconnect from the database
*/
$disconnect(): $Utils.JsPromise<void>;
/**
* 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<T = unknown>(query: TemplateStringsArray | Prisma.Sql, ...values: any[]): Prisma.PrismaPromise<number>;
/**
* 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<T = unknown>(query: string, ...values: any[]): Prisma.PrismaPromise<number>;
/**
* 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<T = unknown>(query: TemplateStringsArray | Prisma.Sql, ...values: any[]): Prisma.PrismaPromise<T>;
/**
* 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<T = unknown>(query: string, ...values: any[]): Prisma.PrismaPromise<T>;
/**
* 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<P extends Prisma.PrismaPromise<any>[]>(arg: [...P], options?: { isolationLevel?: Prisma.TransactionIsolationLevel }): $Utils.JsPromise<runtime.Types.Utils.UnwrapTuple<P>>
$transaction<R>(fn: (prisma: Omit<PrismaClient, runtime.ITXClientDenyList>) => $Utils.JsPromise<R>, options?: { maxWait?: number, timeout?: number, isolationLevel?: Prisma.TransactionIsolationLevel }): $Utils.JsPromise<R>
$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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
/**
* `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<ExtArgs>;
}
export namespace Prisma {
export import DMMF = runtime.DMMF
export type PrismaPromise<T> = $Public.PrismaPromise<T>
/**
* 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<T> = runtime.Metric<T>
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<any>> = T extends PromiseLike<infer U> ? U : T;
/**
* Get the return type of a function which returns a Promise.
*/
export type PromiseReturnType<T extends (...args: any) => $Utils.JsPromise<any>> = PromiseType<ReturnType<T>>
/**
* From T, pick a set of properties whose keys are in the union K
*/
type Prisma__Pick<T, K extends keyof T> = {
[P in K]: T[P];
};
export type Enumerable<T> = T | Array<T>;
export type RequiredKeys<T> = {
[K in keyof T]-?: {} extends Prisma__Pick<T, K> ? never : K
}[keyof T]
export type TruthyKeys<T> = keyof {
[K in keyof T as T[K] extends false | undefined | null ? never : K]: K
}
export type TrueKeys<T> = TruthyKeys<Prisma__Pick<T, RequiredKeys<T>>>
/**
* Subset
* @desc From `T` pick properties that exist in `U`. Simple version of Intersection
*/
export type Subset<T, U> = {
[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<T, U> = {
[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<T, U, K> = {
[key in keyof T]: key extends keyof U ? T[key] : never
} &
K
type Without<T, U> = { [P in Exclude<keyof T, keyof U>]?: 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, U> =
T extends object ?
U extends object ?
(Without<T, U> & U) | (Without<U, T> & T)
: U : T
/**
* Is T a Record?
*/
type IsObject<T extends any> = T extends Array<any>
? 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 unknown> = T extends Array<infer U> ? U : T
/**
* From ts-toolbelt
*/
type __Either<O extends object, K extends Key> = Omit<O, K> &
{
// Merge all but K
[P in K]: Prisma__Pick<O, P & keyof O> // With K possibilities
}[K]
type EitherStrict<O extends object, K extends Key> = Strict<__Either<O, K>>
type EitherLoose<O extends object, K extends Key> = ComputeRaw<__Either<O, K>>
type _Either<
O extends object,
K extends Key,
strict extends Boolean
> = {
1: EitherStrict<O, K>
0: EitherLoose<O, K>
}[strict]
type Either<
O extends object,
K extends Key,
strict extends Boolean = 1
> = O extends unknown ? _Either<O, K, strict> : never
export type Union = any
type PatchUndefined<O extends object, O1 extends object> = {
[K in keyof O]: O[K] extends undefined ? At<O1, K> : O[K]
} & {}
/** Helper Types for "Merge" **/
export type IntersectOf<U extends Union> = (
U extends unknown ? (k: U) => void : never
) extends (k: infer I) => void
? I
: never
export type Overwrite<O extends object, O1 extends object> = {
[K in keyof O]: K extends keyof O1 ? O1[K] : O[K];
} & {};
type _Merge<U extends object> = IntersectOf<Overwrite<U, {
[K in keyof U]-?: At<U, K>;
}>>;
type Key = string | number | symbol;
type AtBasic<O extends object, K extends Key> = K extends keyof O ? O[K] : never;
type AtStrict<O extends object, K extends Key> = O[K & keyof O];
type AtLoose<O extends object, K extends Key> = O extends unknown ? AtStrict<O, K> : never;
export type At<O extends object, K extends Key, strict extends Boolean = 1> = {
1: AtStrict<O, K>;
0: AtLoose<O, K>;
}[strict];
export type ComputeRaw<A extends any> = A extends Function ? A : {
[K in keyof A]: A[K];
} & {};
export type OptionalFlat<O> = {
[K in keyof O]?: O[K];
} & {};
type _Record<K extends keyof any, T> = {
[P in K]: T;
};
// cause typescript not to expand types and preserve names
type NoExpand<T> = T extends unknown ? T : never;
// this type assumes the passed object is entirely optional
type AtLeast<O extends object, K extends string> = 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, _U = U> = U extends unknown ? U & OptionalFlat<_Record<Exclude<Keys<_U>, keyof U>, never>> : never;
export type Strict<U extends object> = ComputeRaw<_Strict<U>>;
/** End Helper Types for "Merge" **/
export type Merge<U extends object> = ComputeRaw<_Merge<Strict<U>>>;
/**
A [[Boolean]]
*/
export type Boolean = True | False
// /**
// 1
// */
export type True = 1
/**
0
*/
export type False = 0
export type Not<B extends Boolean> = {
0: 1
1: 0
}[B]
export type Extends<A1 extends any, A2 extends any> = [A1] extends [never]
? 0 // anything `never` is false
: A1 extends A2
? 1
: 0
export type Has<U extends Union, U1 extends Union> = Not<
Extends<Exclude<U1, U>, U1>
>
export type Or<B1 extends Boolean, B2 extends Boolean> = {
0: {
0: 0
1: 1
}
1: {
0: 1
1: 1
}
}[B1][B2]
export type Keys<U extends Union> = U extends unknown ? keyof U : never
type Cast<A, B> = A extends B ? A : B;
export const type: unique symbol;
/**
* Used by group by
*/
export type GetScalarType<T, O> = O extends object ? {
[P in keyof T]: P extends keyof O
? O[P]
: never
} : never
type FieldPaths<
T,
U = Omit<T, '_avg' | '_sum' | '_count' | '_min' | '_max'>
> = IsObject<T> extends True ? U : T
type GetHavingFields<T> = {
[K in keyof T]: Or<
Or<Extends<'OR', K>, 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<UnEnumerate<TK> extends object ? Merge<UnEnumerate<TK>> : never>
: never
: {} extends FieldPaths<T[K]>
? never
: K
}[keyof T]
/**
* Convert tuple to union
*/
type _TupleToUnion<T> = T extends (infer E)[] ? E : never
type TupleToUnion<K extends readonly any[]> = _TupleToUnion<K>
type MaybeTupleToUnion<T> = T extends any[] ? TupleToUnion<T> : T
/**
* Like `Pick`, but additionally can also accept an array of keys
*/
type PickEnumerable<T, K extends Enumerable<keyof T> | keyof T> = Prisma__Pick<T, MaybeTupleToUnion<K>>
/**
* Exclude all keys with underscores
*/
type ExcludeUnderscoreKeys<T extends string> = T extends `_${string}` ? never : T
export type FieldRef<Model, FieldType> = runtime.FieldRef<Model, FieldType>
type FieldRefInputType<Model, FieldType> = Model extends never ? never : FieldRef<Model, FieldType>
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<string, any>> {
returns: Prisma.TypeMap<this['params']['extArgs'], this['params']['clientOptions']>
}
export type TypeMap<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, ClientOptions = {}> = {
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<ExtArgs>
fields: Prisma.CityFieldRefs
operations: {
findUnique: {
args: Prisma.CityFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload> | null
}
findUniqueOrThrow: {
args: Prisma.CityFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload>
}
findFirst: {
args: Prisma.CityFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload> | null
}
findFirstOrThrow: {
args: Prisma.CityFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload>
}
findMany: {
args: Prisma.CityFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload>[]
}
create: {
args: Prisma.CityCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload>
}
createMany: {
args: Prisma.CityCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.CityCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload>[]
}
delete: {
args: Prisma.CityDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload>
}
update: {
args: Prisma.CityUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload>
}
deleteMany: {
args: Prisma.CityDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.CityUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.CityUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CityPayload>
}
aggregate: {
args: Prisma.CityAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateCity>
}
groupBy: {
args: Prisma.CityGroupByArgs<ExtArgs>
result: $Utils.Optional<CityGroupByOutputType>[]
}
count: {
args: Prisma.CityCountArgs<ExtArgs>
result: $Utils.Optional<CityCountAggregateOutputType> | number
}
}
}
AdminUser: {
payload: Prisma.$AdminUserPayload<ExtArgs>
fields: Prisma.AdminUserFieldRefs
operations: {
findUnique: {
args: Prisma.AdminUserFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload> | null
}
findUniqueOrThrow: {
args: Prisma.AdminUserFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload>
}
findFirst: {
args: Prisma.AdminUserFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload> | null
}
findFirstOrThrow: {
args: Prisma.AdminUserFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload>
}
findMany: {
args: Prisma.AdminUserFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload>[]
}
create: {
args: Prisma.AdminUserCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload>
}
createMany: {
args: Prisma.AdminUserCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.AdminUserCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload>[]
}
delete: {
args: Prisma.AdminUserDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload>
}
update: {
args: Prisma.AdminUserUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload>
}
deleteMany: {
args: Prisma.AdminUserDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.AdminUserUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.AdminUserUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$AdminUserPayload>
}
aggregate: {
args: Prisma.AdminUserAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateAdminUser>
}
groupBy: {
args: Prisma.AdminUserGroupByArgs<ExtArgs>
result: $Utils.Optional<AdminUserGroupByOutputType>[]
}
count: {
args: Prisma.AdminUserCountArgs<ExtArgs>
result: $Utils.Optional<AdminUserCountAggregateOutputType> | number
}
}
}
Customer: {
payload: Prisma.$CustomerPayload<ExtArgs>
fields: Prisma.CustomerFieldRefs
operations: {
findUnique: {
args: Prisma.CustomerFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload> | null
}
findUniqueOrThrow: {
args: Prisma.CustomerFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload>
}
findFirst: {
args: Prisma.CustomerFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload> | null
}
findFirstOrThrow: {
args: Prisma.CustomerFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload>
}
findMany: {
args: Prisma.CustomerFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload>[]
}
create: {
args: Prisma.CustomerCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload>
}
createMany: {
args: Prisma.CustomerCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.CustomerCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload>[]
}
delete: {
args: Prisma.CustomerDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload>
}
update: {
args: Prisma.CustomerUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload>
}
deleteMany: {
args: Prisma.CustomerDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.CustomerUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.CustomerUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerPayload>
}
aggregate: {
args: Prisma.CustomerAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateCustomer>
}
groupBy: {
args: Prisma.CustomerGroupByArgs<ExtArgs>
result: $Utils.Optional<CustomerGroupByOutputType>[]
}
count: {
args: Prisma.CustomerCountArgs<ExtArgs>
result: $Utils.Optional<CustomerCountAggregateOutputType> | number
}
}
}
CustomerAddress: {
payload: Prisma.$CustomerAddressPayload<ExtArgs>
fields: Prisma.CustomerAddressFieldRefs
operations: {
findUnique: {
args: Prisma.CustomerAddressFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload> | null
}
findUniqueOrThrow: {
args: Prisma.CustomerAddressFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload>
}
findFirst: {
args: Prisma.CustomerAddressFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload> | null
}
findFirstOrThrow: {
args: Prisma.CustomerAddressFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload>
}
findMany: {
args: Prisma.CustomerAddressFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload>[]
}
create: {
args: Prisma.CustomerAddressCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload>
}
createMany: {
args: Prisma.CustomerAddressCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.CustomerAddressCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload>[]
}
delete: {
args: Prisma.CustomerAddressDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload>
}
update: {
args: Prisma.CustomerAddressUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload>
}
deleteMany: {
args: Prisma.CustomerAddressDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.CustomerAddressUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.CustomerAddressUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CustomerAddressPayload>
}
aggregate: {
args: Prisma.CustomerAddressAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateCustomerAddress>
}
groupBy: {
args: Prisma.CustomerAddressGroupByArgs<ExtArgs>
result: $Utils.Optional<CustomerAddressGroupByOutputType>[]
}
count: {
args: Prisma.CustomerAddressCountArgs<ExtArgs>
result: $Utils.Optional<CustomerAddressCountAggregateOutputType> | number
}
}
}
Branch: {
payload: Prisma.$BranchPayload<ExtArgs>
fields: Prisma.BranchFieldRefs
operations: {
findUnique: {
args: Prisma.BranchFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload> | null
}
findUniqueOrThrow: {
args: Prisma.BranchFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload>
}
findFirst: {
args: Prisma.BranchFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload> | null
}
findFirstOrThrow: {
args: Prisma.BranchFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload>
}
findMany: {
args: Prisma.BranchFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload>[]
}
create: {
args: Prisma.BranchCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload>
}
createMany: {
args: Prisma.BranchCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.BranchCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload>[]
}
delete: {
args: Prisma.BranchDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload>
}
update: {
args: Prisma.BranchUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload>
}
deleteMany: {
args: Prisma.BranchDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.BranchUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.BranchUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BranchPayload>
}
aggregate: {
args: Prisma.BranchAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateBranch>
}
groupBy: {
args: Prisma.BranchGroupByArgs<ExtArgs>
result: $Utils.Optional<BranchGroupByOutputType>[]
}
count: {
args: Prisma.BranchCountArgs<ExtArgs>
result: $Utils.Optional<BranchCountAggregateOutputType> | number
}
}
}
Workshop: {
payload: Prisma.$WorkshopPayload<ExtArgs>
fields: Prisma.WorkshopFieldRefs
operations: {
findUnique: {
args: Prisma.WorkshopFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload> | null
}
findUniqueOrThrow: {
args: Prisma.WorkshopFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload>
}
findFirst: {
args: Prisma.WorkshopFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload> | null
}
findFirstOrThrow: {
args: Prisma.WorkshopFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload>
}
findMany: {
args: Prisma.WorkshopFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload>[]
}
create: {
args: Prisma.WorkshopCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload>
}
createMany: {
args: Prisma.WorkshopCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.WorkshopCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload>[]
}
delete: {
args: Prisma.WorkshopDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload>
}
update: {
args: Prisma.WorkshopUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload>
}
deleteMany: {
args: Prisma.WorkshopDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.WorkshopUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.WorkshopUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WorkshopPayload>
}
aggregate: {
args: Prisma.WorkshopAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateWorkshop>
}
groupBy: {
args: Prisma.WorkshopGroupByArgs<ExtArgs>
result: $Utils.Optional<WorkshopGroupByOutputType>[]
}
count: {
args: Prisma.WorkshopCountArgs<ExtArgs>
result: $Utils.Optional<WorkshopCountAggregateOutputType> | number
}
}
}
Category: {
payload: Prisma.$CategoryPayload<ExtArgs>
fields: Prisma.CategoryFieldRefs
operations: {
findUnique: {
args: Prisma.CategoryFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload> | null
}
findUniqueOrThrow: {
args: Prisma.CategoryFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload>
}
findFirst: {
args: Prisma.CategoryFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload> | null
}
findFirstOrThrow: {
args: Prisma.CategoryFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload>
}
findMany: {
args: Prisma.CategoryFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload>[]
}
create: {
args: Prisma.CategoryCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload>
}
createMany: {
args: Prisma.CategoryCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.CategoryCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload>[]
}
delete: {
args: Prisma.CategoryDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload>
}
update: {
args: Prisma.CategoryUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload>
}
deleteMany: {
args: Prisma.CategoryDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.CategoryUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.CategoryUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CategoryPayload>
}
aggregate: {
args: Prisma.CategoryAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateCategory>
}
groupBy: {
args: Prisma.CategoryGroupByArgs<ExtArgs>
result: $Utils.Optional<CategoryGroupByOutputType>[]
}
count: {
args: Prisma.CategoryCountArgs<ExtArgs>
result: $Utils.Optional<CategoryCountAggregateOutputType> | number
}
}
}
Brand: {
payload: Prisma.$BrandPayload<ExtArgs>
fields: Prisma.BrandFieldRefs
operations: {
findUnique: {
args: Prisma.BrandFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload> | null
}
findUniqueOrThrow: {
args: Prisma.BrandFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload>
}
findFirst: {
args: Prisma.BrandFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload> | null
}
findFirstOrThrow: {
args: Prisma.BrandFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload>
}
findMany: {
args: Prisma.BrandFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload>[]
}
create: {
args: Prisma.BrandCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload>
}
createMany: {
args: Prisma.BrandCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.BrandCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload>[]
}
delete: {
args: Prisma.BrandDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload>
}
update: {
args: Prisma.BrandUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload>
}
deleteMany: {
args: Prisma.BrandDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.BrandUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.BrandUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$BrandPayload>
}
aggregate: {
args: Prisma.BrandAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateBrand>
}
groupBy: {
args: Prisma.BrandGroupByArgs<ExtArgs>
result: $Utils.Optional<BrandGroupByOutputType>[]
}
count: {
args: Prisma.BrandCountArgs<ExtArgs>
result: $Utils.Optional<BrandCountAggregateOutputType> | number
}
}
}
Collection: {
payload: Prisma.$CollectionPayload<ExtArgs>
fields: Prisma.CollectionFieldRefs
operations: {
findUnique: {
args: Prisma.CollectionFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload> | null
}
findUniqueOrThrow: {
args: Prisma.CollectionFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload>
}
findFirst: {
args: Prisma.CollectionFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload> | null
}
findFirstOrThrow: {
args: Prisma.CollectionFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload>
}
findMany: {
args: Prisma.CollectionFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload>[]
}
create: {
args: Prisma.CollectionCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload>
}
createMany: {
args: Prisma.CollectionCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.CollectionCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload>[]
}
delete: {
args: Prisma.CollectionDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload>
}
update: {
args: Prisma.CollectionUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload>
}
deleteMany: {
args: Prisma.CollectionDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.CollectionUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.CollectionUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionPayload>
}
aggregate: {
args: Prisma.CollectionAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateCollection>
}
groupBy: {
args: Prisma.CollectionGroupByArgs<ExtArgs>
result: $Utils.Optional<CollectionGroupByOutputType>[]
}
count: {
args: Prisma.CollectionCountArgs<ExtArgs>
result: $Utils.Optional<CollectionCountAggregateOutputType> | number
}
}
}
CollectionProduct: {
payload: Prisma.$CollectionProductPayload<ExtArgs>
fields: Prisma.CollectionProductFieldRefs
operations: {
findUnique: {
args: Prisma.CollectionProductFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload> | null
}
findUniqueOrThrow: {
args: Prisma.CollectionProductFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload>
}
findFirst: {
args: Prisma.CollectionProductFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload> | null
}
findFirstOrThrow: {
args: Prisma.CollectionProductFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload>
}
findMany: {
args: Prisma.CollectionProductFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload>[]
}
create: {
args: Prisma.CollectionProductCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload>
}
createMany: {
args: Prisma.CollectionProductCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.CollectionProductCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload>[]
}
delete: {
args: Prisma.CollectionProductDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload>
}
update: {
args: Prisma.CollectionProductUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload>
}
deleteMany: {
args: Prisma.CollectionProductDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.CollectionProductUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.CollectionProductUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$CollectionProductPayload>
}
aggregate: {
args: Prisma.CollectionProductAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateCollectionProduct>
}
groupBy: {
args: Prisma.CollectionProductGroupByArgs<ExtArgs>
result: $Utils.Optional<CollectionProductGroupByOutputType>[]
}
count: {
args: Prisma.CollectionProductCountArgs<ExtArgs>
result: $Utils.Optional<CollectionProductCountAggregateOutputType> | number
}
}
}
Product: {
payload: Prisma.$ProductPayload<ExtArgs>
fields: Prisma.ProductFieldRefs
operations: {
findUnique: {
args: Prisma.ProductFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload> | null
}
findUniqueOrThrow: {
args: Prisma.ProductFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload>
}
findFirst: {
args: Prisma.ProductFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload> | null
}
findFirstOrThrow: {
args: Prisma.ProductFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload>
}
findMany: {
args: Prisma.ProductFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload>[]
}
create: {
args: Prisma.ProductCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload>
}
createMany: {
args: Prisma.ProductCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.ProductCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload>[]
}
delete: {
args: Prisma.ProductDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload>
}
update: {
args: Prisma.ProductUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload>
}
deleteMany: {
args: Prisma.ProductDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.ProductUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.ProductUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductPayload>
}
aggregate: {
args: Prisma.ProductAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateProduct>
}
groupBy: {
args: Prisma.ProductGroupByArgs<ExtArgs>
result: $Utils.Optional<ProductGroupByOutputType>[]
}
count: {
args: Prisma.ProductCountArgs<ExtArgs>
result: $Utils.Optional<ProductCountAggregateOutputType> | number
}
}
}
ProductImage: {
payload: Prisma.$ProductImagePayload<ExtArgs>
fields: Prisma.ProductImageFieldRefs
operations: {
findUnique: {
args: Prisma.ProductImageFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload> | null
}
findUniqueOrThrow: {
args: Prisma.ProductImageFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload>
}
findFirst: {
args: Prisma.ProductImageFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload> | null
}
findFirstOrThrow: {
args: Prisma.ProductImageFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload>
}
findMany: {
args: Prisma.ProductImageFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload>[]
}
create: {
args: Prisma.ProductImageCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload>
}
createMany: {
args: Prisma.ProductImageCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.ProductImageCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload>[]
}
delete: {
args: Prisma.ProductImageDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload>
}
update: {
args: Prisma.ProductImageUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload>
}
deleteMany: {
args: Prisma.ProductImageDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.ProductImageUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.ProductImageUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductImagePayload>
}
aggregate: {
args: Prisma.ProductImageAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateProductImage>
}
groupBy: {
args: Prisma.ProductImageGroupByArgs<ExtArgs>
result: $Utils.Optional<ProductImageGroupByOutputType>[]
}
count: {
args: Prisma.ProductImageCountArgs<ExtArgs>
result: $Utils.Optional<ProductImageCountAggregateOutputType> | number
}
}
}
ProductVariant: {
payload: Prisma.$ProductVariantPayload<ExtArgs>
fields: Prisma.ProductVariantFieldRefs
operations: {
findUnique: {
args: Prisma.ProductVariantFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload> | null
}
findUniqueOrThrow: {
args: Prisma.ProductVariantFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload>
}
findFirst: {
args: Prisma.ProductVariantFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload> | null
}
findFirstOrThrow: {
args: Prisma.ProductVariantFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload>
}
findMany: {
args: Prisma.ProductVariantFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload>[]
}
create: {
args: Prisma.ProductVariantCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload>
}
createMany: {
args: Prisma.ProductVariantCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.ProductVariantCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload>[]
}
delete: {
args: Prisma.ProductVariantDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload>
}
update: {
args: Prisma.ProductVariantUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload>
}
deleteMany: {
args: Prisma.ProductVariantDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.ProductVariantUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.ProductVariantUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$ProductVariantPayload>
}
aggregate: {
args: Prisma.ProductVariantAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateProductVariant>
}
groupBy: {
args: Prisma.ProductVariantGroupByArgs<ExtArgs>
result: $Utils.Optional<ProductVariantGroupByOutputType>[]
}
count: {
args: Prisma.ProductVariantCountArgs<ExtArgs>
result: $Utils.Optional<ProductVariantCountAggregateOutputType> | number
}
}
}
Order: {
payload: Prisma.$OrderPayload<ExtArgs>
fields: Prisma.OrderFieldRefs
operations: {
findUnique: {
args: Prisma.OrderFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload> | null
}
findUniqueOrThrow: {
args: Prisma.OrderFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload>
}
findFirst: {
args: Prisma.OrderFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload> | null
}
findFirstOrThrow: {
args: Prisma.OrderFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload>
}
findMany: {
args: Prisma.OrderFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload>[]
}
create: {
args: Prisma.OrderCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload>
}
createMany: {
args: Prisma.OrderCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.OrderCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload>[]
}
delete: {
args: Prisma.OrderDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload>
}
update: {
args: Prisma.OrderUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload>
}
deleteMany: {
args: Prisma.OrderDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.OrderUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.OrderUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderPayload>
}
aggregate: {
args: Prisma.OrderAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateOrder>
}
groupBy: {
args: Prisma.OrderGroupByArgs<ExtArgs>
result: $Utils.Optional<OrderGroupByOutputType>[]
}
count: {
args: Prisma.OrderCountArgs<ExtArgs>
result: $Utils.Optional<OrderCountAggregateOutputType> | number
}
}
}
OrderItem: {
payload: Prisma.$OrderItemPayload<ExtArgs>
fields: Prisma.OrderItemFieldRefs
operations: {
findUnique: {
args: Prisma.OrderItemFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload> | null
}
findUniqueOrThrow: {
args: Prisma.OrderItemFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload>
}
findFirst: {
args: Prisma.OrderItemFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload> | null
}
findFirstOrThrow: {
args: Prisma.OrderItemFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload>
}
findMany: {
args: Prisma.OrderItemFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload>[]
}
create: {
args: Prisma.OrderItemCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload>
}
createMany: {
args: Prisma.OrderItemCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.OrderItemCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload>[]
}
delete: {
args: Prisma.OrderItemDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload>
}
update: {
args: Prisma.OrderItemUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload>
}
deleteMany: {
args: Prisma.OrderItemDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.OrderItemUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.OrderItemUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderItemPayload>
}
aggregate: {
args: Prisma.OrderItemAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateOrderItem>
}
groupBy: {
args: Prisma.OrderItemGroupByArgs<ExtArgs>
result: $Utils.Optional<OrderItemGroupByOutputType>[]
}
count: {
args: Prisma.OrderItemCountArgs<ExtArgs>
result: $Utils.Optional<OrderItemCountAggregateOutputType> | number
}
}
}
OrderStatusEvent: {
payload: Prisma.$OrderStatusEventPayload<ExtArgs>
fields: Prisma.OrderStatusEventFieldRefs
operations: {
findUnique: {
args: Prisma.OrderStatusEventFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload> | null
}
findUniqueOrThrow: {
args: Prisma.OrderStatusEventFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload>
}
findFirst: {
args: Prisma.OrderStatusEventFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload> | null
}
findFirstOrThrow: {
args: Prisma.OrderStatusEventFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload>
}
findMany: {
args: Prisma.OrderStatusEventFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload>[]
}
create: {
args: Prisma.OrderStatusEventCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload>
}
createMany: {
args: Prisma.OrderStatusEventCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.OrderStatusEventCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload>[]
}
delete: {
args: Prisma.OrderStatusEventDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload>
}
update: {
args: Prisma.OrderStatusEventUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload>
}
deleteMany: {
args: Prisma.OrderStatusEventDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.OrderStatusEventUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.OrderStatusEventUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$OrderStatusEventPayload>
}
aggregate: {
args: Prisma.OrderStatusEventAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateOrderStatusEvent>
}
groupBy: {
args: Prisma.OrderStatusEventGroupByArgs<ExtArgs>
result: $Utils.Optional<OrderStatusEventGroupByOutputType>[]
}
count: {
args: Prisma.OrderStatusEventCountArgs<ExtArgs>
result: $Utils.Optional<OrderStatusEventCountAggregateOutputType> | number
}
}
}
PreOrder: {
payload: Prisma.$PreOrderPayload<ExtArgs>
fields: Prisma.PreOrderFieldRefs
operations: {
findUnique: {
args: Prisma.PreOrderFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload> | null
}
findUniqueOrThrow: {
args: Prisma.PreOrderFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload>
}
findFirst: {
args: Prisma.PreOrderFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload> | null
}
findFirstOrThrow: {
args: Prisma.PreOrderFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload>
}
findMany: {
args: Prisma.PreOrderFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload>[]
}
create: {
args: Prisma.PreOrderCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload>
}
createMany: {
args: Prisma.PreOrderCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.PreOrderCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload>[]
}
delete: {
args: Prisma.PreOrderDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload>
}
update: {
args: Prisma.PreOrderUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload>
}
deleteMany: {
args: Prisma.PreOrderDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.PreOrderUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.PreOrderUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderPayload>
}
aggregate: {
args: Prisma.PreOrderAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregatePreOrder>
}
groupBy: {
args: Prisma.PreOrderGroupByArgs<ExtArgs>
result: $Utils.Optional<PreOrderGroupByOutputType>[]
}
count: {
args: Prisma.PreOrderCountArgs<ExtArgs>
result: $Utils.Optional<PreOrderCountAggregateOutputType> | number
}
}
}
PreOrderStatusEvent: {
payload: Prisma.$PreOrderStatusEventPayload<ExtArgs>
fields: Prisma.PreOrderStatusEventFieldRefs
operations: {
findUnique: {
args: Prisma.PreOrderStatusEventFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload> | null
}
findUniqueOrThrow: {
args: Prisma.PreOrderStatusEventFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload>
}
findFirst: {
args: Prisma.PreOrderStatusEventFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload> | null
}
findFirstOrThrow: {
args: Prisma.PreOrderStatusEventFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload>
}
findMany: {
args: Prisma.PreOrderStatusEventFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload>[]
}
create: {
args: Prisma.PreOrderStatusEventCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload>
}
createMany: {
args: Prisma.PreOrderStatusEventCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.PreOrderStatusEventCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload>[]
}
delete: {
args: Prisma.PreOrderStatusEventDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload>
}
update: {
args: Prisma.PreOrderStatusEventUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload>
}
deleteMany: {
args: Prisma.PreOrderStatusEventDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.PreOrderStatusEventUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.PreOrderStatusEventUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$PreOrderStatusEventPayload>
}
aggregate: {
args: Prisma.PreOrderStatusEventAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregatePreOrderStatusEvent>
}
groupBy: {
args: Prisma.PreOrderStatusEventGroupByArgs<ExtArgs>
result: $Utils.Optional<PreOrderStatusEventGroupByOutputType>[]
}
count: {
args: Prisma.PreOrderStatusEventCountArgs<ExtArgs>
result: $Utils.Optional<PreOrderStatusEventCountAggregateOutputType> | number
}
}
}
LedgerEntry: {
payload: Prisma.$LedgerEntryPayload<ExtArgs>
fields: Prisma.LedgerEntryFieldRefs
operations: {
findUnique: {
args: Prisma.LedgerEntryFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload> | null
}
findUniqueOrThrow: {
args: Prisma.LedgerEntryFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload>
}
findFirst: {
args: Prisma.LedgerEntryFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload> | null
}
findFirstOrThrow: {
args: Prisma.LedgerEntryFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload>
}
findMany: {
args: Prisma.LedgerEntryFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload>[]
}
create: {
args: Prisma.LedgerEntryCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload>
}
createMany: {
args: Prisma.LedgerEntryCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.LedgerEntryCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload>[]
}
delete: {
args: Prisma.LedgerEntryDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload>
}
update: {
args: Prisma.LedgerEntryUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload>
}
deleteMany: {
args: Prisma.LedgerEntryDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.LedgerEntryUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.LedgerEntryUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$LedgerEntryPayload>
}
aggregate: {
args: Prisma.LedgerEntryAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateLedgerEntry>
}
groupBy: {
args: Prisma.LedgerEntryGroupByArgs<ExtArgs>
result: $Utils.Optional<LedgerEntryGroupByOutputType>[]
}
count: {
args: Prisma.LedgerEntryCountArgs<ExtArgs>
result: $Utils.Optional<LedgerEntryCountAggregateOutputType> | number
}
}
}
GoldPriceQuote: {
payload: Prisma.$GoldPriceQuotePayload<ExtArgs>
fields: Prisma.GoldPriceQuoteFieldRefs
operations: {
findUnique: {
args: Prisma.GoldPriceQuoteFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload> | null
}
findUniqueOrThrow: {
args: Prisma.GoldPriceQuoteFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload>
}
findFirst: {
args: Prisma.GoldPriceQuoteFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload> | null
}
findFirstOrThrow: {
args: Prisma.GoldPriceQuoteFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload>
}
findMany: {
args: Prisma.GoldPriceQuoteFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload>[]
}
create: {
args: Prisma.GoldPriceQuoteCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload>
}
createMany: {
args: Prisma.GoldPriceQuoteCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.GoldPriceQuoteCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload>[]
}
delete: {
args: Prisma.GoldPriceQuoteDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload>
}
update: {
args: Prisma.GoldPriceQuoteUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload>
}
deleteMany: {
args: Prisma.GoldPriceQuoteDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.GoldPriceQuoteUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.GoldPriceQuoteUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$GoldPriceQuotePayload>
}
aggregate: {
args: Prisma.GoldPriceQuoteAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateGoldPriceQuote>
}
groupBy: {
args: Prisma.GoldPriceQuoteGroupByArgs<ExtArgs>
result: $Utils.Optional<GoldPriceQuoteGroupByOutputType>[]
}
count: {
args: Prisma.GoldPriceQuoteCountArgs<ExtArgs>
result: $Utils.Optional<GoldPriceQuoteCountAggregateOutputType> | number
}
}
}
WalletBonus: {
payload: Prisma.$WalletBonusPayload<ExtArgs>
fields: Prisma.WalletBonusFieldRefs
operations: {
findUnique: {
args: Prisma.WalletBonusFindUniqueArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload> | null
}
findUniqueOrThrow: {
args: Prisma.WalletBonusFindUniqueOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload>
}
findFirst: {
args: Prisma.WalletBonusFindFirstArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload> | null
}
findFirstOrThrow: {
args: Prisma.WalletBonusFindFirstOrThrowArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload>
}
findMany: {
args: Prisma.WalletBonusFindManyArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload>[]
}
create: {
args: Prisma.WalletBonusCreateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload>
}
createMany: {
args: Prisma.WalletBonusCreateManyArgs<ExtArgs>
result: BatchPayload
}
createManyAndReturn: {
args: Prisma.WalletBonusCreateManyAndReturnArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload>[]
}
delete: {
args: Prisma.WalletBonusDeleteArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload>
}
update: {
args: Prisma.WalletBonusUpdateArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload>
}
deleteMany: {
args: Prisma.WalletBonusDeleteManyArgs<ExtArgs>
result: BatchPayload
}
updateMany: {
args: Prisma.WalletBonusUpdateManyArgs<ExtArgs>
result: BatchPayload
}
upsert: {
args: Prisma.WalletBonusUpsertArgs<ExtArgs>
result: $Utils.PayloadToResult<Prisma.$WalletBonusPayload>
}
aggregate: {
args: Prisma.WalletBonusAggregateArgs<ExtArgs>
result: $Utils.Optional<AggregateWalletBonus>
}
groupBy: {
args: Prisma.WalletBonusGroupByArgs<ExtArgs>
result: $Utils.Optional<WalletBonusGroupByOutputType>[]
}
count: {
args: Prisma.WalletBonusCountArgs<ExtArgs>
result: $Utils.Optional<WalletBonusCountAggregateOutputType> | 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 LogLevel | LogDefinition> = T extends LogDefinition ? T['emit'] extends 'event' ? T['level'] : never : never
export type GetEvents<T extends any> = T extends Array<LogLevel | LogDefinition> ?
GetLogType<T[0]> | GetLogType<T[1]> | GetLogType<T[2]> | GetLogType<T[3]>
: 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<T = any> = (
params: MiddlewareParams,
next: (params: MiddlewareParams) => $Utils.JsPromise<T>,
) => $Utils.JsPromise<T>
// tested in getLogLevel.test.ts
export function getLogLevel(log: Array<LogLevel | LogDefinition>): LogLevel | undefined;
/**
* `PrismaClient` proxy available in interactive transactions.
*/
export type TransactionClient = Omit<Prisma.DefaultPrismaClient, runtime.ITXClientDenyList>
export type Datasource = {
url?: string
}
/**
* Count Types
*/
/**
* Count Type CityCountOutputType
*/
export type CityCountOutputType = {
customers: number
addresses: number
branches: number
preOrders: number
}
export type CityCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customers?: boolean | CityCountOutputTypeCountCustomersArgs
addresses?: boolean | CityCountOutputTypeCountAddressesArgs
branches?: boolean | CityCountOutputTypeCountBranchesArgs
preOrders?: boolean | CityCountOutputTypeCountPreOrdersArgs
}
// Custom InputTypes
/**
* CityCountOutputType without action
*/
export type CityCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CityCountOutputType
*/
select?: CityCountOutputTypeSelect<ExtArgs> | null
}
/**
* CityCountOutputType without action
*/
export type CityCountOutputTypeCountCustomersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: CustomerWhereInput
}
/**
* CityCountOutputType without action
*/
export type CityCountOutputTypeCountAddressesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: CustomerAddressWhereInput
}
/**
* CityCountOutputType without action
*/
export type CityCountOutputTypeCountBranchesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: BranchWhereInput
}
/**
* CityCountOutputType without action
*/
export type CityCountOutputTypeCountPreOrdersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: PreOrderWhereInput
}
/**
* Count Type AdminUserCountOutputType
*/
export type AdminUserCountOutputType = {
referredCustomers: number
postedLedgerEntries: number
orderStatusEvents: number
preOrderStatusEvents: number
}
export type AdminUserCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
referredCustomers?: boolean | AdminUserCountOutputTypeCountReferredCustomersArgs
postedLedgerEntries?: boolean | AdminUserCountOutputTypeCountPostedLedgerEntriesArgs
orderStatusEvents?: boolean | AdminUserCountOutputTypeCountOrderStatusEventsArgs
preOrderStatusEvents?: boolean | AdminUserCountOutputTypeCountPreOrderStatusEventsArgs
}
// Custom InputTypes
/**
* AdminUserCountOutputType without action
*/
export type AdminUserCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUserCountOutputType
*/
select?: AdminUserCountOutputTypeSelect<ExtArgs> | null
}
/**
* AdminUserCountOutputType without action
*/
export type AdminUserCountOutputTypeCountReferredCustomersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: CustomerWhereInput
}
/**
* AdminUserCountOutputType without action
*/
export type AdminUserCountOutputTypeCountPostedLedgerEntriesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: LedgerEntryWhereInput
}
/**
* AdminUserCountOutputType without action
*/
export type AdminUserCountOutputTypeCountOrderStatusEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: OrderStatusEventWhereInput
}
/**
* AdminUserCountOutputType without action
*/
export type AdminUserCountOutputTypeCountPreOrderStatusEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: PreOrderStatusEventWhereInput
}
/**
* Count Type CustomerCountOutputType
*/
export type CustomerCountOutputType = {
addresses: number
orders: number
preOrders: number
ledgerEntries: number
walletBonuses: number
}
export type CustomerCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
addresses?: boolean | CustomerCountOutputTypeCountAddressesArgs
orders?: boolean | CustomerCountOutputTypeCountOrdersArgs
preOrders?: boolean | CustomerCountOutputTypeCountPreOrdersArgs
ledgerEntries?: boolean | CustomerCountOutputTypeCountLedgerEntriesArgs
walletBonuses?: boolean | CustomerCountOutputTypeCountWalletBonusesArgs
}
// Custom InputTypes
/**
* CustomerCountOutputType without action
*/
export type CustomerCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerCountOutputType
*/
select?: CustomerCountOutputTypeSelect<ExtArgs> | null
}
/**
* CustomerCountOutputType without action
*/
export type CustomerCountOutputTypeCountAddressesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: CustomerAddressWhereInput
}
/**
* CustomerCountOutputType without action
*/
export type CustomerCountOutputTypeCountOrdersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: OrderWhereInput
}
/**
* CustomerCountOutputType without action
*/
export type CustomerCountOutputTypeCountPreOrdersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: PreOrderWhereInput
}
/**
* CustomerCountOutputType without action
*/
export type CustomerCountOutputTypeCountLedgerEntriesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: LedgerEntryWhereInput
}
/**
* CustomerCountOutputType without action
*/
export type CustomerCountOutputTypeCountWalletBonusesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: WalletBonusWhereInput
}
/**
* Count Type BranchCountOutputType
*/
export type BranchCountOutputType = {
adminUsers: number
orders: number
}
export type BranchCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
adminUsers?: boolean | BranchCountOutputTypeCountAdminUsersArgs
orders?: boolean | BranchCountOutputTypeCountOrdersArgs
}
// Custom InputTypes
/**
* BranchCountOutputType without action
*/
export type BranchCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the BranchCountOutputType
*/
select?: BranchCountOutputTypeSelect<ExtArgs> | null
}
/**
* BranchCountOutputType without action
*/
export type BranchCountOutputTypeCountAdminUsersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: AdminUserWhereInput
}
/**
* BranchCountOutputType without action
*/
export type BranchCountOutputTypeCountOrdersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: OrderWhereInput
}
/**
* Count Type WorkshopCountOutputType
*/
export type WorkshopCountOutputType = {
preOrders: number
}
export type WorkshopCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
preOrders?: boolean | WorkshopCountOutputTypeCountPreOrdersArgs
}
// Custom InputTypes
/**
* WorkshopCountOutputType without action
*/
export type WorkshopCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WorkshopCountOutputType
*/
select?: WorkshopCountOutputTypeSelect<ExtArgs> | null
}
/**
* WorkshopCountOutputType without action
*/
export type WorkshopCountOutputTypeCountPreOrdersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: PreOrderWhereInput
}
/**
* Count Type CategoryCountOutputType
*/
export type CategoryCountOutputType = {
children: number
products: number
}
export type CategoryCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
children?: boolean | CategoryCountOutputTypeCountChildrenArgs
products?: boolean | CategoryCountOutputTypeCountProductsArgs
}
// Custom InputTypes
/**
* CategoryCountOutputType without action
*/
export type CategoryCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CategoryCountOutputType
*/
select?: CategoryCountOutputTypeSelect<ExtArgs> | null
}
/**
* CategoryCountOutputType without action
*/
export type CategoryCountOutputTypeCountChildrenArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: CategoryWhereInput
}
/**
* CategoryCountOutputType without action
*/
export type CategoryCountOutputTypeCountProductsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: ProductWhereInput
}
/**
* Count Type BrandCountOutputType
*/
export type BrandCountOutputType = {
products: number
}
export type BrandCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
products?: boolean | BrandCountOutputTypeCountProductsArgs
}
// Custom InputTypes
/**
* BrandCountOutputType without action
*/
export type BrandCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the BrandCountOutputType
*/
select?: BrandCountOutputTypeSelect<ExtArgs> | null
}
/**
* BrandCountOutputType without action
*/
export type BrandCountOutputTypeCountProductsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: ProductWhereInput
}
/**
* Count Type CollectionCountOutputType
*/
export type CollectionCountOutputType = {
products: number
}
export type CollectionCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
products?: boolean | CollectionCountOutputTypeCountProductsArgs
}
// Custom InputTypes
/**
* CollectionCountOutputType without action
*/
export type CollectionCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionCountOutputType
*/
select?: CollectionCountOutputTypeSelect<ExtArgs> | null
}
/**
* CollectionCountOutputType without action
*/
export type CollectionCountOutputTypeCountProductsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: CollectionProductWhereInput
}
/**
* Count Type ProductCountOutputType
*/
export type ProductCountOutputType = {
variants: number
images: number
collections: number
}
export type ProductCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
variants?: boolean | ProductCountOutputTypeCountVariantsArgs
images?: boolean | ProductCountOutputTypeCountImagesArgs
collections?: boolean | ProductCountOutputTypeCountCollectionsArgs
}
// Custom InputTypes
/**
* ProductCountOutputType without action
*/
export type ProductCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductCountOutputType
*/
select?: ProductCountOutputTypeSelect<ExtArgs> | null
}
/**
* ProductCountOutputType without action
*/
export type ProductCountOutputTypeCountVariantsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: ProductVariantWhereInput
}
/**
* ProductCountOutputType without action
*/
export type ProductCountOutputTypeCountImagesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: ProductImageWhereInput
}
/**
* ProductCountOutputType without action
*/
export type ProductCountOutputTypeCountCollectionsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: CollectionProductWhereInput
}
/**
* Count Type ProductVariantCountOutputType
*/
export type ProductVariantCountOutputType = {
orderItems: number
}
export type ProductVariantCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
orderItems?: boolean | ProductVariantCountOutputTypeCountOrderItemsArgs
}
// Custom InputTypes
/**
* ProductVariantCountOutputType without action
*/
export type ProductVariantCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariantCountOutputType
*/
select?: ProductVariantCountOutputTypeSelect<ExtArgs> | null
}
/**
* ProductVariantCountOutputType without action
*/
export type ProductVariantCountOutputTypeCountOrderItemsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: OrderItemWhereInput
}
/**
* Count Type OrderCountOutputType
*/
export type OrderCountOutputType = {
items: number
statusEvents: number
ledgerEntries: number
}
export type OrderCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
items?: boolean | OrderCountOutputTypeCountItemsArgs
statusEvents?: boolean | OrderCountOutputTypeCountStatusEventsArgs
ledgerEntries?: boolean | OrderCountOutputTypeCountLedgerEntriesArgs
}
// Custom InputTypes
/**
* OrderCountOutputType without action
*/
export type OrderCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderCountOutputType
*/
select?: OrderCountOutputTypeSelect<ExtArgs> | null
}
/**
* OrderCountOutputType without action
*/
export type OrderCountOutputTypeCountItemsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: OrderItemWhereInput
}
/**
* OrderCountOutputType without action
*/
export type OrderCountOutputTypeCountStatusEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: OrderStatusEventWhereInput
}
/**
* OrderCountOutputType without action
*/
export type OrderCountOutputTypeCountLedgerEntriesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
where?: LedgerEntryWhereInput
}
/**
* Count Type PreOrderCountOutputType
*/
export type PreOrderCountOutputType = {
statusEvents: number
}
export type PreOrderCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
statusEvents?: boolean | PreOrderCountOutputTypeCountStatusEventsArgs
}
// Custom InputTypes
/**
* PreOrderCountOutputType without action
*/
export type PreOrderCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderCountOutputType
*/
select?: PreOrderCountOutputTypeSelect<ExtArgs> | null
}
/**
* PreOrderCountOutputType without action
*/
export type PreOrderCountOutputTypeCountStatusEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends CityAggregateArgs> = {
[P in keyof T & keyof AggregateCity]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateCity[P]>
: GetScalarType<T[P], AggregateCity[P]>
}
export type CityGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends CityGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<CityGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof CityGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], CityGroupByOutputType[P]>
: GetScalarType<T[P], CityGroupByOutputType[P]>
}
>
>
export type CitySelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
name?: boolean
province?: boolean
customers?: boolean | City$customersArgs<ExtArgs>
addresses?: boolean | City$addressesArgs<ExtArgs>
branches?: boolean | City$branchesArgs<ExtArgs>
preOrders?: boolean | City$preOrdersArgs<ExtArgs>
_count?: boolean | CityCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["city"]>
export type CitySelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
name?: boolean
province?: boolean
}, ExtArgs["result"]["city"]>
export type CitySelectScalar = {
id?: boolean
name?: boolean
province?: boolean
}
export type CityInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customers?: boolean | City$customersArgs<ExtArgs>
addresses?: boolean | City$addressesArgs<ExtArgs>
branches?: boolean | City$branchesArgs<ExtArgs>
preOrders?: boolean | City$preOrdersArgs<ExtArgs>
_count?: boolean | CityCountOutputTypeDefaultArgs<ExtArgs>
}
export type CityIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {}
export type $CityPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "City"
objects: {
customers: Prisma.$CustomerPayload<ExtArgs>[]
addresses: Prisma.$CustomerAddressPayload<ExtArgs>[]
branches: Prisma.$BranchPayload<ExtArgs>[]
preOrders: Prisma.$PreOrderPayload<ExtArgs>[]
}
scalars: $Extensions.GetPayloadResult<{
id: string
name: string
province: string | null
}, ExtArgs["result"]["city"]>
composites: {}
}
type CityGetPayload<S extends boolean | null | undefined | CityDefaultArgs> = $Result.GetResult<Prisma.$CityPayload, S>
type CityCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<CityFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: CityCountAggregateInputType | true
}
export interface CityDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends CityFindUniqueArgs>(args: SelectSubset<T, CityFindUniqueArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityFindUniqueOrThrowArgs>(args: SelectSubset<T, CityFindUniqueOrThrowArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityFindFirstArgs>(args?: SelectSubset<T, CityFindFirstArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityFindFirstOrThrowArgs>(args?: SelectSubset<T, CityFindFirstOrThrowArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityFindManyArgs>(args?: SelectSubset<T, CityFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityCreateArgs>(args: SelectSubset<T, CityCreateArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityCreateManyArgs>(args?: SelectSubset<T, CityCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CityCreateManyAndReturnArgs>(args?: SelectSubset<T, CityCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityDeleteArgs>(args: SelectSubset<T, CityDeleteArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityUpdateArgs>(args: SelectSubset<T, CityUpdateArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityDeleteManyArgs>(args?: SelectSubset<T, CityDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CityUpdateManyArgs>(args: SelectSubset<T, CityUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CityUpsertArgs>(args: SelectSubset<T, CityUpsertArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<T extends CityCountArgs>(
args?: Subset<T, CityCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], CityCountAggregateOutputType>
: 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<T extends CityAggregateArgs>(args: Subset<T, CityAggregateArgs>): Prisma.PrismaPromise<GetCityAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: CityGroupByArgs['orderBy'] }
: { orderBy?: CityGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, CityGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCityGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
customers<T extends City$customersArgs<ExtArgs> = {}>(args?: Subset<T, City$customersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findMany"> | Null>
addresses<T extends City$addressesArgs<ExtArgs> = {}>(args?: Subset<T, City$addressesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, T, "findMany"> | Null>
branches<T extends City$branchesArgs<ExtArgs> = {}>(args?: Subset<T, City$branchesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, T, "findMany"> | Null>
preOrders<T extends City$preOrdersArgs<ExtArgs> = {}>(args?: Subset<T, City$preOrdersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
/**
* Filter, which City to fetch.
*/
where: CityWhereUniqueInput
}
/**
* City findUniqueOrThrow
*/
export type CityFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
/**
* Filter, which City to fetch.
*/
where: CityWhereUniqueInput
}
/**
* City findFirst
*/
export type CityFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
/**
* The data needed to create a City.
*/
data: XOR<CityCreateInput, CityUncheckedCreateInput>
}
/**
* City createMany
*/
export type CityCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Cities.
*/
data: CityCreateManyInput | CityCreateManyInput[]
skipDuplicates?: boolean
}
/**
* City createManyAndReturn
*/
export type CityCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Cities.
*/
data: CityCreateManyInput | CityCreateManyInput[]
skipDuplicates?: boolean
}
/**
* City update
*/
export type CityUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
/**
* The data needed to update a City.
*/
data: XOR<CityUpdateInput, CityUncheckedUpdateInput>
/**
* Choose, which City to update.
*/
where: CityWhereUniqueInput
}
/**
* City updateMany
*/
export type CityUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Cities.
*/
data: XOR<CityUpdateManyMutationInput, CityUncheckedUpdateManyInput>
/**
* Filter which Cities to update
*/
where?: CityWhereInput
}
/**
* City upsert
*/
export type CityUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | 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<CityCreateInput, CityUncheckedCreateInput>
/**
* In case the City was found with the provided `where` argument, update it with this data.
*/
update: XOR<CityUpdateInput, CityUncheckedUpdateInput>
}
/**
* City delete
*/
export type CityDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
/**
* Filter which City to delete.
*/
where: CityWhereUniqueInput
}
/**
* City deleteMany
*/
export type CityDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Cities to delete
*/
where?: CityWhereInput
}
/**
* City.customers
*/
export type City$customersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | null
where?: CustomerWhereInput
orderBy?: CustomerOrderByWithRelationInput | CustomerOrderByWithRelationInput[]
cursor?: CustomerWhereUniqueInput
take?: number
skip?: number
distinct?: CustomerScalarFieldEnum | CustomerScalarFieldEnum[]
}
/**
* City.addresses
*/
export type City$addressesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | null
where?: CustomerAddressWhereInput
orderBy?: CustomerAddressOrderByWithRelationInput | CustomerAddressOrderByWithRelationInput[]
cursor?: CustomerAddressWhereUniqueInput
take?: number
skip?: number
distinct?: CustomerAddressScalarFieldEnum | CustomerAddressScalarFieldEnum[]
}
/**
* City.branches
*/
export type City$branchesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | null
where?: BranchWhereInput
orderBy?: BranchOrderByWithRelationInput | BranchOrderByWithRelationInput[]
cursor?: BranchWhereUniqueInput
take?: number
skip?: number
distinct?: BranchScalarFieldEnum | BranchScalarFieldEnum[]
}
/**
* City.preOrders
*/
export type City$preOrdersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
where?: PreOrderWhereInput
orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[]
cursor?: PreOrderWhereUniqueInput
take?: number
skip?: number
distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[]
}
/**
* City without action
*/
export type CityDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends AdminUserAggregateArgs> = {
[P in keyof T & keyof AggregateAdminUser]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateAdminUser[P]>
: GetScalarType<T[P], AggregateAdminUser[P]>
}
export type AdminUserGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends AdminUserGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<AdminUserGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof AdminUserGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], AdminUserGroupByOutputType[P]>
: GetScalarType<T[P], AdminUserGroupByOutputType[P]>
}
>
>
export type AdminUserSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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>
referredCustomers?: boolean | AdminUser$referredCustomersArgs<ExtArgs>
postedLedgerEntries?: boolean | AdminUser$postedLedgerEntriesArgs<ExtArgs>
orderStatusEvents?: boolean | AdminUser$orderStatusEventsArgs<ExtArgs>
preOrderStatusEvents?: boolean | AdminUser$preOrderStatusEventsArgs<ExtArgs>
_count?: boolean | AdminUserCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["adminUser"]>
export type AdminUserSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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>
}, 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
branch?: boolean | AdminUser$branchArgs<ExtArgs>
referredCustomers?: boolean | AdminUser$referredCustomersArgs<ExtArgs>
postedLedgerEntries?: boolean | AdminUser$postedLedgerEntriesArgs<ExtArgs>
orderStatusEvents?: boolean | AdminUser$orderStatusEventsArgs<ExtArgs>
preOrderStatusEvents?: boolean | AdminUser$preOrderStatusEventsArgs<ExtArgs>
_count?: boolean | AdminUserCountOutputTypeDefaultArgs<ExtArgs>
}
export type AdminUserIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
branch?: boolean | AdminUser$branchArgs<ExtArgs>
}
export type $AdminUserPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "AdminUser"
objects: {
branch: Prisma.$BranchPayload<ExtArgs> | null
referredCustomers: Prisma.$CustomerPayload<ExtArgs>[]
postedLedgerEntries: Prisma.$LedgerEntryPayload<ExtArgs>[]
orderStatusEvents: Prisma.$OrderStatusEventPayload<ExtArgs>[]
preOrderStatusEvents: Prisma.$PreOrderStatusEventPayload<ExtArgs>[]
}
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<S extends boolean | null | undefined | AdminUserDefaultArgs> = $Result.GetResult<Prisma.$AdminUserPayload, S>
type AdminUserCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<AdminUserFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: AdminUserCountAggregateInputType | true
}
export interface AdminUserDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends AdminUserFindUniqueArgs>(args: SelectSubset<T, AdminUserFindUniqueArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserFindUniqueOrThrowArgs>(args: SelectSubset<T, AdminUserFindUniqueOrThrowArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserFindFirstArgs>(args?: SelectSubset<T, AdminUserFindFirstArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserFindFirstOrThrowArgs>(args?: SelectSubset<T, AdminUserFindFirstOrThrowArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserFindManyArgs>(args?: SelectSubset<T, AdminUserFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserCreateArgs>(args: SelectSubset<T, AdminUserCreateArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserCreateManyArgs>(args?: SelectSubset<T, AdminUserCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends AdminUserCreateManyAndReturnArgs>(args?: SelectSubset<T, AdminUserCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserDeleteArgs>(args: SelectSubset<T, AdminUserDeleteArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserUpdateArgs>(args: SelectSubset<T, AdminUserUpdateArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserDeleteManyArgs>(args?: SelectSubset<T, AdminUserDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends AdminUserUpdateManyArgs>(args: SelectSubset<T, AdminUserUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends AdminUserUpsertArgs>(args: SelectSubset<T, AdminUserUpsertArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<T extends AdminUserCountArgs>(
args?: Subset<T, AdminUserCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], AdminUserCountAggregateOutputType>
: 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<T extends AdminUserAggregateArgs>(args: Subset<T, AdminUserAggregateArgs>): Prisma.PrismaPromise<GetAdminUserAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: AdminUserGroupByArgs['orderBy'] }
: { orderBy?: AdminUserGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, AdminUserGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetAdminUserGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
branch<T extends AdminUser$branchArgs<ExtArgs> = {}>(args?: Subset<T, AdminUser$branchArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
referredCustomers<T extends AdminUser$referredCustomersArgs<ExtArgs> = {}>(args?: Subset<T, AdminUser$referredCustomersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findMany"> | Null>
postedLedgerEntries<T extends AdminUser$postedLedgerEntriesArgs<ExtArgs> = {}>(args?: Subset<T, AdminUser$postedLedgerEntriesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, T, "findMany"> | Null>
orderStatusEvents<T extends AdminUser$orderStatusEventsArgs<ExtArgs> = {}>(args?: Subset<T, AdminUser$orderStatusEventsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, T, "findMany"> | Null>
preOrderStatusEvents<T extends AdminUser$preOrderStatusEventsArgs<ExtArgs> = {}>(args?: Subset<T, AdminUser$preOrderStatusEventsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
/**
* Filter, which AdminUser to fetch.
*/
where: AdminUserWhereUniqueInput
}
/**
* AdminUser findUniqueOrThrow
*/
export type AdminUserFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
/**
* Filter, which AdminUser to fetch.
*/
where: AdminUserWhereUniqueInput
}
/**
* AdminUser findFirst
*/
export type AdminUserFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
/**
* The data needed to create a AdminUser.
*/
data: XOR<AdminUserCreateInput, AdminUserUncheckedCreateInput>
}
/**
* AdminUser createMany
*/
export type AdminUserCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many AdminUsers.
*/
data: AdminUserCreateManyInput | AdminUserCreateManyInput[]
skipDuplicates?: boolean
}
/**
* AdminUser createManyAndReturn
*/
export type AdminUserCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many AdminUsers.
*/
data: AdminUserCreateManyInput | AdminUserCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* AdminUser update
*/
export type AdminUserUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
/**
* The data needed to update a AdminUser.
*/
data: XOR<AdminUserUpdateInput, AdminUserUncheckedUpdateInput>
/**
* Choose, which AdminUser to update.
*/
where: AdminUserWhereUniqueInput
}
/**
* AdminUser updateMany
*/
export type AdminUserUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update AdminUsers.
*/
data: XOR<AdminUserUpdateManyMutationInput, AdminUserUncheckedUpdateManyInput>
/**
* Filter which AdminUsers to update
*/
where?: AdminUserWhereInput
}
/**
* AdminUser upsert
*/
export type AdminUserUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | 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<AdminUserCreateInput, AdminUserUncheckedCreateInput>
/**
* In case the AdminUser was found with the provided `where` argument, update it with this data.
*/
update: XOR<AdminUserUpdateInput, AdminUserUncheckedUpdateInput>
}
/**
* AdminUser delete
*/
export type AdminUserDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
/**
* Filter which AdminUser to delete.
*/
where: AdminUserWhereUniqueInput
}
/**
* AdminUser deleteMany
*/
export type AdminUserDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which AdminUsers to delete
*/
where?: AdminUserWhereInput
}
/**
* AdminUser.branch
*/
export type AdminUser$branchArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | null
where?: BranchWhereInput
}
/**
* AdminUser.referredCustomers
*/
export type AdminUser$referredCustomersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | null
where?: CustomerWhereInput
orderBy?: CustomerOrderByWithRelationInput | CustomerOrderByWithRelationInput[]
cursor?: CustomerWhereUniqueInput
take?: number
skip?: number
distinct?: CustomerScalarFieldEnum | CustomerScalarFieldEnum[]
}
/**
* AdminUser.postedLedgerEntries
*/
export type AdminUser$postedLedgerEntriesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | null
where?: LedgerEntryWhereInput
orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[]
cursor?: LedgerEntryWhereUniqueInput
take?: number
skip?: number
distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[]
}
/**
* AdminUser.orderStatusEvents
*/
export type AdminUser$orderStatusEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | null
where?: OrderStatusEventWhereInput
orderBy?: OrderStatusEventOrderByWithRelationInput | OrderStatusEventOrderByWithRelationInput[]
cursor?: OrderStatusEventWhereUniqueInput
take?: number
skip?: number
distinct?: OrderStatusEventScalarFieldEnum | OrderStatusEventScalarFieldEnum[]
}
/**
* AdminUser.preOrderStatusEvents
*/
export type AdminUser$preOrderStatusEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | null
where?: PreOrderStatusEventWhereInput
orderBy?: PreOrderStatusEventOrderByWithRelationInput | PreOrderStatusEventOrderByWithRelationInput[]
cursor?: PreOrderStatusEventWhereUniqueInput
take?: number
skip?: number
distinct?: PreOrderStatusEventScalarFieldEnum | PreOrderStatusEventScalarFieldEnum[]
}
/**
* AdminUser without action
*/
export type AdminUserDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends CustomerAggregateArgs> = {
[P in keyof T & keyof AggregateCustomer]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateCustomer[P]>
: GetScalarType<T[P], AggregateCustomer[P]>
}
export type CustomerGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends CustomerGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<CustomerGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof CustomerGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], CustomerGroupByOutputType[P]>
: GetScalarType<T[P], CustomerGroupByOutputType[P]>
}
>
>
export type CustomerSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs>
referredByAgent?: boolean | Customer$referredByAgentArgs<ExtArgs>
addresses?: boolean | Customer$addressesArgs<ExtArgs>
orders?: boolean | Customer$ordersArgs<ExtArgs>
preOrders?: boolean | Customer$preOrdersArgs<ExtArgs>
ledgerEntries?: boolean | Customer$ledgerEntriesArgs<ExtArgs>
walletBonuses?: boolean | Customer$walletBonusesArgs<ExtArgs>
_count?: boolean | CustomerCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["customer"]>
export type CustomerSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs>
referredByAgent?: boolean | Customer$referredByAgentArgs<ExtArgs>
}, 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
city?: boolean | Customer$cityArgs<ExtArgs>
referredByAgent?: boolean | Customer$referredByAgentArgs<ExtArgs>
addresses?: boolean | Customer$addressesArgs<ExtArgs>
orders?: boolean | Customer$ordersArgs<ExtArgs>
preOrders?: boolean | Customer$preOrdersArgs<ExtArgs>
ledgerEntries?: boolean | Customer$ledgerEntriesArgs<ExtArgs>
walletBonuses?: boolean | Customer$walletBonusesArgs<ExtArgs>
_count?: boolean | CustomerCountOutputTypeDefaultArgs<ExtArgs>
}
export type CustomerIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
city?: boolean | Customer$cityArgs<ExtArgs>
referredByAgent?: boolean | Customer$referredByAgentArgs<ExtArgs>
}
export type $CustomerPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "Customer"
objects: {
city: Prisma.$CityPayload<ExtArgs> | null
referredByAgent: Prisma.$AdminUserPayload<ExtArgs> | null
addresses: Prisma.$CustomerAddressPayload<ExtArgs>[]
orders: Prisma.$OrderPayload<ExtArgs>[]
preOrders: Prisma.$PreOrderPayload<ExtArgs>[]
ledgerEntries: Prisma.$LedgerEntryPayload<ExtArgs>[]
walletBonuses: Prisma.$WalletBonusPayload<ExtArgs>[]
}
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<S extends boolean | null | undefined | CustomerDefaultArgs> = $Result.GetResult<Prisma.$CustomerPayload, S>
type CustomerCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<CustomerFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: CustomerCountAggregateInputType | true
}
export interface CustomerDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends CustomerFindUniqueArgs>(args: SelectSubset<T, CustomerFindUniqueArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerFindUniqueOrThrowArgs>(args: SelectSubset<T, CustomerFindUniqueOrThrowArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerFindFirstArgs>(args?: SelectSubset<T, CustomerFindFirstArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerFindFirstOrThrowArgs>(args?: SelectSubset<T, CustomerFindFirstOrThrowArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerFindManyArgs>(args?: SelectSubset<T, CustomerFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerCreateArgs>(args: SelectSubset<T, CustomerCreateArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerCreateManyArgs>(args?: SelectSubset<T, CustomerCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CustomerCreateManyAndReturnArgs>(args?: SelectSubset<T, CustomerCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerDeleteArgs>(args: SelectSubset<T, CustomerDeleteArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerUpdateArgs>(args: SelectSubset<T, CustomerUpdateArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerDeleteManyArgs>(args?: SelectSubset<T, CustomerDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CustomerUpdateManyArgs>(args: SelectSubset<T, CustomerUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CustomerUpsertArgs>(args: SelectSubset<T, CustomerUpsertArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<T extends CustomerCountArgs>(
args?: Subset<T, CustomerCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], CustomerCountAggregateOutputType>
: 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<T extends CustomerAggregateArgs>(args: Subset<T, CustomerAggregateArgs>): Prisma.PrismaPromise<GetCustomerAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: CustomerGroupByArgs['orderBy'] }
: { orderBy?: CustomerGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, CustomerGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCustomerGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
city<T extends Customer$cityArgs<ExtArgs> = {}>(args?: Subset<T, Customer$cityArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
referredByAgent<T extends Customer$referredByAgentArgs<ExtArgs> = {}>(args?: Subset<T, Customer$referredByAgentArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
addresses<T extends Customer$addressesArgs<ExtArgs> = {}>(args?: Subset<T, Customer$addressesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, T, "findMany"> | Null>
orders<T extends Customer$ordersArgs<ExtArgs> = {}>(args?: Subset<T, Customer$ordersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, T, "findMany"> | Null>
preOrders<T extends Customer$preOrdersArgs<ExtArgs> = {}>(args?: Subset<T, Customer$preOrdersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, T, "findMany"> | Null>
ledgerEntries<T extends Customer$ledgerEntriesArgs<ExtArgs> = {}>(args?: Subset<T, Customer$ledgerEntriesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, T, "findMany"> | Null>
walletBonuses<T extends Customer$walletBonusesArgs<ExtArgs> = {}>(args?: Subset<T, Customer$walletBonusesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | null
/**
* Filter, which Customer to fetch.
*/
where: CustomerWhereUniqueInput
}
/**
* Customer findUniqueOrThrow
*/
export type CustomerFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | null
/**
* Filter, which Customer to fetch.
*/
where: CustomerWhereUniqueInput
}
/**
* Customer findFirst
*/
export type CustomerFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | null
/**
* The data needed to create a Customer.
*/
data: XOR<CustomerCreateInput, CustomerUncheckedCreateInput>
}
/**
* Customer createMany
*/
export type CustomerCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Customers.
*/
data: CustomerCreateManyInput | CustomerCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Customer createManyAndReturn
*/
export type CustomerCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Customers.
*/
data: CustomerCreateManyInput | CustomerCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* Customer update
*/
export type CustomerUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | null
/**
* The data needed to update a Customer.
*/
data: XOR<CustomerUpdateInput, CustomerUncheckedUpdateInput>
/**
* Choose, which Customer to update.
*/
where: CustomerWhereUniqueInput
}
/**
* Customer updateMany
*/
export type CustomerUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Customers.
*/
data: XOR<CustomerUpdateManyMutationInput, CustomerUncheckedUpdateManyInput>
/**
* Filter which Customers to update
*/
where?: CustomerWhereInput
}
/**
* Customer upsert
*/
export type CustomerUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | 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<CustomerCreateInput, CustomerUncheckedCreateInput>
/**
* In case the Customer was found with the provided `where` argument, update it with this data.
*/
update: XOR<CustomerUpdateInput, CustomerUncheckedUpdateInput>
}
/**
* Customer delete
*/
export type CustomerDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | null
/**
* Filter which Customer to delete.
*/
where: CustomerWhereUniqueInput
}
/**
* Customer deleteMany
*/
export type CustomerDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Customers to delete
*/
where?: CustomerWhereInput
}
/**
* Customer.city
*/
export type Customer$cityArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
where?: CityWhereInput
}
/**
* Customer.referredByAgent
*/
export type Customer$referredByAgentArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
where?: AdminUserWhereInput
}
/**
* Customer.addresses
*/
export type Customer$addressesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | null
where?: CustomerAddressWhereInput
orderBy?: CustomerAddressOrderByWithRelationInput | CustomerAddressOrderByWithRelationInput[]
cursor?: CustomerAddressWhereUniqueInput
take?: number
skip?: number
distinct?: CustomerAddressScalarFieldEnum | CustomerAddressScalarFieldEnum[]
}
/**
* Customer.orders
*/
export type Customer$ordersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
where?: OrderWhereInput
orderBy?: OrderOrderByWithRelationInput | OrderOrderByWithRelationInput[]
cursor?: OrderWhereUniqueInput
take?: number
skip?: number
distinct?: OrderScalarFieldEnum | OrderScalarFieldEnum[]
}
/**
* Customer.preOrders
*/
export type Customer$preOrdersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
where?: PreOrderWhereInput
orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[]
cursor?: PreOrderWhereUniqueInput
take?: number
skip?: number
distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[]
}
/**
* Customer.ledgerEntries
*/
export type Customer$ledgerEntriesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | null
where?: LedgerEntryWhereInput
orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[]
cursor?: LedgerEntryWhereUniqueInput
take?: number
skip?: number
distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[]
}
/**
* Customer.walletBonuses
*/
export type Customer$walletBonusesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | null
where?: WalletBonusWhereInput
orderBy?: WalletBonusOrderByWithRelationInput | WalletBonusOrderByWithRelationInput[]
cursor?: WalletBonusWhereUniqueInput
take?: number
skip?: number
distinct?: WalletBonusScalarFieldEnum | WalletBonusScalarFieldEnum[]
}
/**
* Customer without action
*/
export type CustomerDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Customer
*/
select?: CustomerSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends CustomerAddressAggregateArgs> = {
[P in keyof T & keyof AggregateCustomerAddress]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateCustomerAddress[P]>
: GetScalarType<T[P], AggregateCustomerAddress[P]>
}
export type CustomerAddressGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends CustomerAddressGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<CustomerAddressGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof CustomerAddressGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], CustomerAddressGroupByOutputType[P]>
: GetScalarType<T[P], CustomerAddressGroupByOutputType[P]>
}
>
>
export type CustomerAddressSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
customerId?: boolean
cityId?: boolean
addressLine?: boolean
isDefault?: boolean
customer?: boolean | CustomerDefaultArgs<ExtArgs>
city?: boolean | CustomerAddress$cityArgs<ExtArgs>
}, ExtArgs["result"]["customerAddress"]>
export type CustomerAddressSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
customerId?: boolean
cityId?: boolean
addressLine?: boolean
isDefault?: boolean
customer?: boolean | CustomerDefaultArgs<ExtArgs>
city?: boolean | CustomerAddress$cityArgs<ExtArgs>
}, ExtArgs["result"]["customerAddress"]>
export type CustomerAddressSelectScalar = {
id?: boolean
customerId?: boolean
cityId?: boolean
addressLine?: boolean
isDefault?: boolean
}
export type CustomerAddressInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
city?: boolean | CustomerAddress$cityArgs<ExtArgs>
}
export type CustomerAddressIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
city?: boolean | CustomerAddress$cityArgs<ExtArgs>
}
export type $CustomerAddressPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "CustomerAddress"
objects: {
customer: Prisma.$CustomerPayload<ExtArgs>
city: Prisma.$CityPayload<ExtArgs> | null
}
scalars: $Extensions.GetPayloadResult<{
id: string
customerId: string
cityId: string | null
addressLine: string
isDefault: boolean
}, ExtArgs["result"]["customerAddress"]>
composites: {}
}
type CustomerAddressGetPayload<S extends boolean | null | undefined | CustomerAddressDefaultArgs> = $Result.GetResult<Prisma.$CustomerAddressPayload, S>
type CustomerAddressCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<CustomerAddressFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: CustomerAddressCountAggregateInputType | true
}
export interface CustomerAddressDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends CustomerAddressFindUniqueArgs>(args: SelectSubset<T, CustomerAddressFindUniqueArgs<ExtArgs>>): Prisma__CustomerAddressClient<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressFindUniqueOrThrowArgs>(args: SelectSubset<T, CustomerAddressFindUniqueOrThrowArgs<ExtArgs>>): Prisma__CustomerAddressClient<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressFindFirstArgs>(args?: SelectSubset<T, CustomerAddressFindFirstArgs<ExtArgs>>): Prisma__CustomerAddressClient<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressFindFirstOrThrowArgs>(args?: SelectSubset<T, CustomerAddressFindFirstOrThrowArgs<ExtArgs>>): Prisma__CustomerAddressClient<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressFindManyArgs>(args?: SelectSubset<T, CustomerAddressFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressCreateArgs>(args: SelectSubset<T, CustomerAddressCreateArgs<ExtArgs>>): Prisma__CustomerAddressClient<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressCreateManyArgs>(args?: SelectSubset<T, CustomerAddressCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CustomerAddressCreateManyAndReturnArgs>(args?: SelectSubset<T, CustomerAddressCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressDeleteArgs>(args: SelectSubset<T, CustomerAddressDeleteArgs<ExtArgs>>): Prisma__CustomerAddressClient<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressUpdateArgs>(args: SelectSubset<T, CustomerAddressUpdateArgs<ExtArgs>>): Prisma__CustomerAddressClient<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressDeleteManyArgs>(args?: SelectSubset<T, CustomerAddressDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CustomerAddressUpdateManyArgs>(args: SelectSubset<T, CustomerAddressUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CustomerAddressUpsertArgs>(args: SelectSubset<T, CustomerAddressUpsertArgs<ExtArgs>>): Prisma__CustomerAddressClient<$Result.GetResult<Prisma.$CustomerAddressPayload<ExtArgs>, 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<T extends CustomerAddressCountArgs>(
args?: Subset<T, CustomerAddressCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], CustomerAddressCountAggregateOutputType>
: 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<T extends CustomerAddressAggregateArgs>(args: Subset<T, CustomerAddressAggregateArgs>): Prisma.PrismaPromise<GetCustomerAddressAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: CustomerAddressGroupByArgs['orderBy'] }
: { orderBy?: CustomerAddressGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, CustomerAddressGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCustomerAddressGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
customer<T extends CustomerDefaultArgs<ExtArgs> = {}>(args?: Subset<T, CustomerDefaultArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
city<T extends CustomerAddress$cityArgs<ExtArgs> = {}>(args?: Subset<T, CustomerAddress$cityArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | null
/**
* Filter, which CustomerAddress to fetch.
*/
where: CustomerAddressWhereUniqueInput
}
/**
* CustomerAddress findUniqueOrThrow
*/
export type CustomerAddressFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | null
/**
* Filter, which CustomerAddress to fetch.
*/
where: CustomerAddressWhereUniqueInput
}
/**
* CustomerAddress findFirst
*/
export type CustomerAddressFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | null
/**
* The data needed to create a CustomerAddress.
*/
data: XOR<CustomerAddressCreateInput, CustomerAddressUncheckedCreateInput>
}
/**
* CustomerAddress createMany
*/
export type CustomerAddressCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many CustomerAddresses.
*/
data: CustomerAddressCreateManyInput | CustomerAddressCreateManyInput[]
skipDuplicates?: boolean
}
/**
* CustomerAddress createManyAndReturn
*/
export type CustomerAddressCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many CustomerAddresses.
*/
data: CustomerAddressCreateManyInput | CustomerAddressCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* CustomerAddress update
*/
export type CustomerAddressUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | null
/**
* The data needed to update a CustomerAddress.
*/
data: XOR<CustomerAddressUpdateInput, CustomerAddressUncheckedUpdateInput>
/**
* Choose, which CustomerAddress to update.
*/
where: CustomerAddressWhereUniqueInput
}
/**
* CustomerAddress updateMany
*/
export type CustomerAddressUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update CustomerAddresses.
*/
data: XOR<CustomerAddressUpdateManyMutationInput, CustomerAddressUncheckedUpdateManyInput>
/**
* Filter which CustomerAddresses to update
*/
where?: CustomerAddressWhereInput
}
/**
* CustomerAddress upsert
*/
export type CustomerAddressUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | 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<CustomerAddressCreateInput, CustomerAddressUncheckedCreateInput>
/**
* In case the CustomerAddress was found with the provided `where` argument, update it with this data.
*/
update: XOR<CustomerAddressUpdateInput, CustomerAddressUncheckedUpdateInput>
}
/**
* CustomerAddress delete
*/
export type CustomerAddressDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | null
/**
* Filter which CustomerAddress to delete.
*/
where: CustomerAddressWhereUniqueInput
}
/**
* CustomerAddress deleteMany
*/
export type CustomerAddressDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which CustomerAddresses to delete
*/
where?: CustomerAddressWhereInput
}
/**
* CustomerAddress.city
*/
export type CustomerAddress$cityArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
where?: CityWhereInput
}
/**
* CustomerAddress without action
*/
export type CustomerAddressDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CustomerAddress
*/
select?: CustomerAddressSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CustomerAddressInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends BranchAggregateArgs> = {
[P in keyof T & keyof AggregateBranch]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateBranch[P]>
: GetScalarType<T[P], AggregateBranch[P]>
}
export type BranchGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends BranchGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<BranchGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof BranchGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], BranchGroupByOutputType[P]>
: GetScalarType<T[P], BranchGroupByOutputType[P]>
}
>
>
export type BranchSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
name?: boolean
cityId?: boolean
city?: boolean | Branch$cityArgs<ExtArgs>
adminUsers?: boolean | Branch$adminUsersArgs<ExtArgs>
orders?: boolean | Branch$ordersArgs<ExtArgs>
_count?: boolean | BranchCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["branch"]>
export type BranchSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
name?: boolean
cityId?: boolean
city?: boolean | Branch$cityArgs<ExtArgs>
}, ExtArgs["result"]["branch"]>
export type BranchSelectScalar = {
id?: boolean
name?: boolean
cityId?: boolean
}
export type BranchInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
city?: boolean | Branch$cityArgs<ExtArgs>
adminUsers?: boolean | Branch$adminUsersArgs<ExtArgs>
orders?: boolean | Branch$ordersArgs<ExtArgs>
_count?: boolean | BranchCountOutputTypeDefaultArgs<ExtArgs>
}
export type BranchIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
city?: boolean | Branch$cityArgs<ExtArgs>
}
export type $BranchPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "Branch"
objects: {
city: Prisma.$CityPayload<ExtArgs> | null
adminUsers: Prisma.$AdminUserPayload<ExtArgs>[]
orders: Prisma.$OrderPayload<ExtArgs>[]
}
scalars: $Extensions.GetPayloadResult<{
id: string
name: string
cityId: string | null
}, ExtArgs["result"]["branch"]>
composites: {}
}
type BranchGetPayload<S extends boolean | null | undefined | BranchDefaultArgs> = $Result.GetResult<Prisma.$BranchPayload, S>
type BranchCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<BranchFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: BranchCountAggregateInputType | true
}
export interface BranchDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends BranchFindUniqueArgs>(args: SelectSubset<T, BranchFindUniqueArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchFindUniqueOrThrowArgs>(args: SelectSubset<T, BranchFindUniqueOrThrowArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchFindFirstArgs>(args?: SelectSubset<T, BranchFindFirstArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchFindFirstOrThrowArgs>(args?: SelectSubset<T, BranchFindFirstOrThrowArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchFindManyArgs>(args?: SelectSubset<T, BranchFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchCreateArgs>(args: SelectSubset<T, BranchCreateArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchCreateManyArgs>(args?: SelectSubset<T, BranchCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends BranchCreateManyAndReturnArgs>(args?: SelectSubset<T, BranchCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchDeleteArgs>(args: SelectSubset<T, BranchDeleteArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchUpdateArgs>(args: SelectSubset<T, BranchUpdateArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchDeleteManyArgs>(args?: SelectSubset<T, BranchDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends BranchUpdateManyArgs>(args: SelectSubset<T, BranchUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends BranchUpsertArgs>(args: SelectSubset<T, BranchUpsertArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, 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<T extends BranchCountArgs>(
args?: Subset<T, BranchCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], BranchCountAggregateOutputType>
: 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<T extends BranchAggregateArgs>(args: Subset<T, BranchAggregateArgs>): Prisma.PrismaPromise<GetBranchAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: BranchGroupByArgs['orderBy'] }
: { orderBy?: BranchGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, BranchGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetBranchGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
city<T extends Branch$cityArgs<ExtArgs> = {}>(args?: Subset<T, Branch$cityArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
adminUsers<T extends Branch$adminUsersArgs<ExtArgs> = {}>(args?: Subset<T, Branch$adminUsersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, T, "findMany"> | Null>
orders<T extends Branch$ordersArgs<ExtArgs> = {}>(args?: Subset<T, Branch$ordersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | null
/**
* Filter, which Branch to fetch.
*/
where: BranchWhereUniqueInput
}
/**
* Branch findUniqueOrThrow
*/
export type BranchFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | null
/**
* Filter, which Branch to fetch.
*/
where: BranchWhereUniqueInput
}
/**
* Branch findFirst
*/
export type BranchFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | null
/**
* The data needed to create a Branch.
*/
data: XOR<BranchCreateInput, BranchUncheckedCreateInput>
}
/**
* Branch createMany
*/
export type BranchCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Branches.
*/
data: BranchCreateManyInput | BranchCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Branch createManyAndReturn
*/
export type BranchCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Branches.
*/
data: BranchCreateManyInput | BranchCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* Branch update
*/
export type BranchUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | null
/**
* The data needed to update a Branch.
*/
data: XOR<BranchUpdateInput, BranchUncheckedUpdateInput>
/**
* Choose, which Branch to update.
*/
where: BranchWhereUniqueInput
}
/**
* Branch updateMany
*/
export type BranchUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Branches.
*/
data: XOR<BranchUpdateManyMutationInput, BranchUncheckedUpdateManyInput>
/**
* Filter which Branches to update
*/
where?: BranchWhereInput
}
/**
* Branch upsert
*/
export type BranchUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | 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<BranchCreateInput, BranchUncheckedCreateInput>
/**
* In case the Branch was found with the provided `where` argument, update it with this data.
*/
update: XOR<BranchUpdateInput, BranchUncheckedUpdateInput>
}
/**
* Branch delete
*/
export type BranchDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | null
/**
* Filter which Branch to delete.
*/
where: BranchWhereUniqueInput
}
/**
* Branch deleteMany
*/
export type BranchDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Branches to delete
*/
where?: BranchWhereInput
}
/**
* Branch.city
*/
export type Branch$cityArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
where?: CityWhereInput
}
/**
* Branch.adminUsers
*/
export type Branch$adminUsersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
where?: AdminUserWhereInput
orderBy?: AdminUserOrderByWithRelationInput | AdminUserOrderByWithRelationInput[]
cursor?: AdminUserWhereUniqueInput
take?: number
skip?: number
distinct?: AdminUserScalarFieldEnum | AdminUserScalarFieldEnum[]
}
/**
* Branch.orders
*/
export type Branch$ordersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
where?: OrderWhereInput
orderBy?: OrderOrderByWithRelationInput | OrderOrderByWithRelationInput[]
cursor?: OrderWhereUniqueInput
take?: number
skip?: number
distinct?: OrderScalarFieldEnum | OrderScalarFieldEnum[]
}
/**
* Branch without action
*/
export type BranchDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends WorkshopAggregateArgs> = {
[P in keyof T & keyof AggregateWorkshop]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateWorkshop[P]>
: GetScalarType<T[P], AggregateWorkshop[P]>
}
export type WorkshopGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends WorkshopGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<WorkshopGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof WorkshopGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], WorkshopGroupByOutputType[P]>
: GetScalarType<T[P], WorkshopGroupByOutputType[P]>
}
>
>
export type WorkshopSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
name?: boolean
isActive?: boolean
preOrders?: boolean | Workshop$preOrdersArgs<ExtArgs>
_count?: boolean | WorkshopCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["workshop"]>
export type WorkshopSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
name?: boolean
isActive?: boolean
}, ExtArgs["result"]["workshop"]>
export type WorkshopSelectScalar = {
id?: boolean
name?: boolean
isActive?: boolean
}
export type WorkshopInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
preOrders?: boolean | Workshop$preOrdersArgs<ExtArgs>
_count?: boolean | WorkshopCountOutputTypeDefaultArgs<ExtArgs>
}
export type WorkshopIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {}
export type $WorkshopPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "Workshop"
objects: {
preOrders: Prisma.$PreOrderPayload<ExtArgs>[]
}
scalars: $Extensions.GetPayloadResult<{
id: string
name: string
isActive: boolean
}, ExtArgs["result"]["workshop"]>
composites: {}
}
type WorkshopGetPayload<S extends boolean | null | undefined | WorkshopDefaultArgs> = $Result.GetResult<Prisma.$WorkshopPayload, S>
type WorkshopCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<WorkshopFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: WorkshopCountAggregateInputType | true
}
export interface WorkshopDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends WorkshopFindUniqueArgs>(args: SelectSubset<T, WorkshopFindUniqueArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopFindUniqueOrThrowArgs>(args: SelectSubset<T, WorkshopFindUniqueOrThrowArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopFindFirstArgs>(args?: SelectSubset<T, WorkshopFindFirstArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopFindFirstOrThrowArgs>(args?: SelectSubset<T, WorkshopFindFirstOrThrowArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopFindManyArgs>(args?: SelectSubset<T, WorkshopFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopCreateArgs>(args: SelectSubset<T, WorkshopCreateArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopCreateManyArgs>(args?: SelectSubset<T, WorkshopCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends WorkshopCreateManyAndReturnArgs>(args?: SelectSubset<T, WorkshopCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopDeleteArgs>(args: SelectSubset<T, WorkshopDeleteArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopUpdateArgs>(args: SelectSubset<T, WorkshopUpdateArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopDeleteManyArgs>(args?: SelectSubset<T, WorkshopDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends WorkshopUpdateManyArgs>(args: SelectSubset<T, WorkshopUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends WorkshopUpsertArgs>(args: SelectSubset<T, WorkshopUpsertArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, 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<T extends WorkshopCountArgs>(
args?: Subset<T, WorkshopCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], WorkshopCountAggregateOutputType>
: 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<T extends WorkshopAggregateArgs>(args: Subset<T, WorkshopAggregateArgs>): Prisma.PrismaPromise<GetWorkshopAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: WorkshopGroupByArgs['orderBy'] }
: { orderBy?: WorkshopGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, WorkshopGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetWorkshopGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
preOrders<T extends Workshop$preOrdersArgs<ExtArgs> = {}>(args?: Subset<T, Workshop$preOrdersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | null
/**
* Filter, which Workshop to fetch.
*/
where: WorkshopWhereUniqueInput
}
/**
* Workshop findUniqueOrThrow
*/
export type WorkshopFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | null
/**
* Filter, which Workshop to fetch.
*/
where: WorkshopWhereUniqueInput
}
/**
* Workshop findFirst
*/
export type WorkshopFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | null
/**
* The data needed to create a Workshop.
*/
data: XOR<WorkshopCreateInput, WorkshopUncheckedCreateInput>
}
/**
* Workshop createMany
*/
export type WorkshopCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Workshops.
*/
data: WorkshopCreateManyInput | WorkshopCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Workshop createManyAndReturn
*/
export type WorkshopCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Workshops.
*/
data: WorkshopCreateManyInput | WorkshopCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Workshop update
*/
export type WorkshopUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | null
/**
* The data needed to update a Workshop.
*/
data: XOR<WorkshopUpdateInput, WorkshopUncheckedUpdateInput>
/**
* Choose, which Workshop to update.
*/
where: WorkshopWhereUniqueInput
}
/**
* Workshop updateMany
*/
export type WorkshopUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Workshops.
*/
data: XOR<WorkshopUpdateManyMutationInput, WorkshopUncheckedUpdateManyInput>
/**
* Filter which Workshops to update
*/
where?: WorkshopWhereInput
}
/**
* Workshop upsert
*/
export type WorkshopUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | 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<WorkshopCreateInput, WorkshopUncheckedCreateInput>
/**
* In case the Workshop was found with the provided `where` argument, update it with this data.
*/
update: XOR<WorkshopUpdateInput, WorkshopUncheckedUpdateInput>
}
/**
* Workshop delete
*/
export type WorkshopDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | null
/**
* Filter which Workshop to delete.
*/
where: WorkshopWhereUniqueInput
}
/**
* Workshop deleteMany
*/
export type WorkshopDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Workshops to delete
*/
where?: WorkshopWhereInput
}
/**
* Workshop.preOrders
*/
export type Workshop$preOrdersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
where?: PreOrderWhereInput
orderBy?: PreOrderOrderByWithRelationInput | PreOrderOrderByWithRelationInput[]
cursor?: PreOrderWhereUniqueInput
take?: number
skip?: number
distinct?: PreOrderScalarFieldEnum | PreOrderScalarFieldEnum[]
}
/**
* Workshop without action
*/
export type WorkshopDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends CategoryAggregateArgs> = {
[P in keyof T & keyof AggregateCategory]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateCategory[P]>
: GetScalarType<T[P], AggregateCategory[P]>
}
export type CategoryGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends CategoryGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<CategoryGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof CategoryGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], CategoryGroupByOutputType[P]>
: GetScalarType<T[P], CategoryGroupByOutputType[P]>
}
>
>
export type CategorySelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
title?: boolean
parentId?: boolean
parent?: boolean | Category$parentArgs<ExtArgs>
children?: boolean | Category$childrenArgs<ExtArgs>
products?: boolean | Category$productsArgs<ExtArgs>
_count?: boolean | CategoryCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["category"]>
export type CategorySelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
title?: boolean
parentId?: boolean
parent?: boolean | Category$parentArgs<ExtArgs>
}, ExtArgs["result"]["category"]>
export type CategorySelectScalar = {
id?: boolean
title?: boolean
parentId?: boolean
}
export type CategoryInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
parent?: boolean | Category$parentArgs<ExtArgs>
children?: boolean | Category$childrenArgs<ExtArgs>
products?: boolean | Category$productsArgs<ExtArgs>
_count?: boolean | CategoryCountOutputTypeDefaultArgs<ExtArgs>
}
export type CategoryIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
parent?: boolean | Category$parentArgs<ExtArgs>
}
export type $CategoryPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "Category"
objects: {
parent: Prisma.$CategoryPayload<ExtArgs> | null
children: Prisma.$CategoryPayload<ExtArgs>[]
products: Prisma.$ProductPayload<ExtArgs>[]
}
scalars: $Extensions.GetPayloadResult<{
id: string
title: string
parentId: string | null
}, ExtArgs["result"]["category"]>
composites: {}
}
type CategoryGetPayload<S extends boolean | null | undefined | CategoryDefaultArgs> = $Result.GetResult<Prisma.$CategoryPayload, S>
type CategoryCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<CategoryFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: CategoryCountAggregateInputType | true
}
export interface CategoryDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends CategoryFindUniqueArgs>(args: SelectSubset<T, CategoryFindUniqueArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryFindUniqueOrThrowArgs>(args: SelectSubset<T, CategoryFindUniqueOrThrowArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryFindFirstArgs>(args?: SelectSubset<T, CategoryFindFirstArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryFindFirstOrThrowArgs>(args?: SelectSubset<T, CategoryFindFirstOrThrowArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryFindManyArgs>(args?: SelectSubset<T, CategoryFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryCreateArgs>(args: SelectSubset<T, CategoryCreateArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryCreateManyArgs>(args?: SelectSubset<T, CategoryCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CategoryCreateManyAndReturnArgs>(args?: SelectSubset<T, CategoryCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryDeleteArgs>(args: SelectSubset<T, CategoryDeleteArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryUpdateArgs>(args: SelectSubset<T, CategoryUpdateArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryDeleteManyArgs>(args?: SelectSubset<T, CategoryDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CategoryUpdateManyArgs>(args: SelectSubset<T, CategoryUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CategoryUpsertArgs>(args: SelectSubset<T, CategoryUpsertArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, 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<T extends CategoryCountArgs>(
args?: Subset<T, CategoryCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], CategoryCountAggregateOutputType>
: 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<T extends CategoryAggregateArgs>(args: Subset<T, CategoryAggregateArgs>): Prisma.PrismaPromise<GetCategoryAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: CategoryGroupByArgs['orderBy'] }
: { orderBy?: CategoryGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, CategoryGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCategoryGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
parent<T extends Category$parentArgs<ExtArgs> = {}>(args?: Subset<T, Category$parentArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
children<T extends Category$childrenArgs<ExtArgs> = {}>(args?: Subset<T, Category$childrenArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, T, "findMany"> | Null>
products<T extends Category$productsArgs<ExtArgs> = {}>(args?: Subset<T, Category$productsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | null
/**
* Filter, which Category to fetch.
*/
where: CategoryWhereUniqueInput
}
/**
* Category findUniqueOrThrow
*/
export type CategoryFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | null
/**
* Filter, which Category to fetch.
*/
where: CategoryWhereUniqueInput
}
/**
* Category findFirst
*/
export type CategoryFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | null
/**
* The data needed to create a Category.
*/
data: XOR<CategoryCreateInput, CategoryUncheckedCreateInput>
}
/**
* Category createMany
*/
export type CategoryCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Categories.
*/
data: CategoryCreateManyInput | CategoryCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Category createManyAndReturn
*/
export type CategoryCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Categories.
*/
data: CategoryCreateManyInput | CategoryCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* Category update
*/
export type CategoryUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | null
/**
* The data needed to update a Category.
*/
data: XOR<CategoryUpdateInput, CategoryUncheckedUpdateInput>
/**
* Choose, which Category to update.
*/
where: CategoryWhereUniqueInput
}
/**
* Category updateMany
*/
export type CategoryUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Categories.
*/
data: XOR<CategoryUpdateManyMutationInput, CategoryUncheckedUpdateManyInput>
/**
* Filter which Categories to update
*/
where?: CategoryWhereInput
}
/**
* Category upsert
*/
export type CategoryUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | 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<CategoryCreateInput, CategoryUncheckedCreateInput>
/**
* In case the Category was found with the provided `where` argument, update it with this data.
*/
update: XOR<CategoryUpdateInput, CategoryUncheckedUpdateInput>
}
/**
* Category delete
*/
export type CategoryDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | null
/**
* Filter which Category to delete.
*/
where: CategoryWhereUniqueInput
}
/**
* Category deleteMany
*/
export type CategoryDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Categories to delete
*/
where?: CategoryWhereInput
}
/**
* Category.parent
*/
export type Category$parentArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | null
where?: CategoryWhereInput
}
/**
* Category.children
*/
export type Category$childrenArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | null
where?: CategoryWhereInput
orderBy?: CategoryOrderByWithRelationInput | CategoryOrderByWithRelationInput[]
cursor?: CategoryWhereUniqueInput
take?: number
skip?: number
distinct?: CategoryScalarFieldEnum | CategoryScalarFieldEnum[]
}
/**
* Category.products
*/
export type Category$productsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | null
where?: ProductWhereInput
orderBy?: ProductOrderByWithRelationInput | ProductOrderByWithRelationInput[]
cursor?: ProductWhereUniqueInput
take?: number
skip?: number
distinct?: ProductScalarFieldEnum | ProductScalarFieldEnum[]
}
/**
* Category without action
*/
export type CategoryDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends BrandAggregateArgs> = {
[P in keyof T & keyof AggregateBrand]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateBrand[P]>
: GetScalarType<T[P], AggregateBrand[P]>
}
export type BrandGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends BrandGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<BrandGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof BrandGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], BrandGroupByOutputType[P]>
: GetScalarType<T[P], BrandGroupByOutputType[P]>
}
>
>
export type BrandSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
title?: boolean
products?: boolean | Brand$productsArgs<ExtArgs>
_count?: boolean | BrandCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["brand"]>
export type BrandSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
title?: boolean
}, ExtArgs["result"]["brand"]>
export type BrandSelectScalar = {
id?: boolean
title?: boolean
}
export type BrandInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
products?: boolean | Brand$productsArgs<ExtArgs>
_count?: boolean | BrandCountOutputTypeDefaultArgs<ExtArgs>
}
export type BrandIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {}
export type $BrandPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "Brand"
objects: {
products: Prisma.$ProductPayload<ExtArgs>[]
}
scalars: $Extensions.GetPayloadResult<{
id: string
title: string
}, ExtArgs["result"]["brand"]>
composites: {}
}
type BrandGetPayload<S extends boolean | null | undefined | BrandDefaultArgs> = $Result.GetResult<Prisma.$BrandPayload, S>
type BrandCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<BrandFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: BrandCountAggregateInputType | true
}
export interface BrandDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends BrandFindUniqueArgs>(args: SelectSubset<T, BrandFindUniqueArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandFindUniqueOrThrowArgs>(args: SelectSubset<T, BrandFindUniqueOrThrowArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandFindFirstArgs>(args?: SelectSubset<T, BrandFindFirstArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandFindFirstOrThrowArgs>(args?: SelectSubset<T, BrandFindFirstOrThrowArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandFindManyArgs>(args?: SelectSubset<T, BrandFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandCreateArgs>(args: SelectSubset<T, BrandCreateArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandCreateManyArgs>(args?: SelectSubset<T, BrandCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends BrandCreateManyAndReturnArgs>(args?: SelectSubset<T, BrandCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandDeleteArgs>(args: SelectSubset<T, BrandDeleteArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandUpdateArgs>(args: SelectSubset<T, BrandUpdateArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandDeleteManyArgs>(args?: SelectSubset<T, BrandDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends BrandUpdateManyArgs>(args: SelectSubset<T, BrandUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends BrandUpsertArgs>(args: SelectSubset<T, BrandUpsertArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, 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<T extends BrandCountArgs>(
args?: Subset<T, BrandCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], BrandCountAggregateOutputType>
: 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<T extends BrandAggregateArgs>(args: Subset<T, BrandAggregateArgs>): Prisma.PrismaPromise<GetBrandAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: BrandGroupByArgs['orderBy'] }
: { orderBy?: BrandGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, BrandGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetBrandGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
products<T extends Brand$productsArgs<ExtArgs> = {}>(args?: Subset<T, Brand$productsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* Fields of the Brand model
*/
interface BrandFieldRefs {
readonly id: FieldRef<"Brand", 'String'>
readonly title: FieldRef<"Brand", 'String'>
}
// Custom InputTypes
/**
* Brand findUnique
*/
export type BrandFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | null
/**
* Filter, which Brand to fetch.
*/
where: BrandWhereUniqueInput
}
/**
* Brand findUniqueOrThrow
*/
export type BrandFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | null
/**
* Filter, which Brand to fetch.
*/
where: BrandWhereUniqueInput
}
/**
* Brand findFirst
*/
export type BrandFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | null
/**
* The data needed to create a Brand.
*/
data: XOR<BrandCreateInput, BrandUncheckedCreateInput>
}
/**
* Brand createMany
*/
export type BrandCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Brands.
*/
data: BrandCreateManyInput | BrandCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Brand createManyAndReturn
*/
export type BrandCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Brands.
*/
data: BrandCreateManyInput | BrandCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Brand update
*/
export type BrandUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | null
/**
* The data needed to update a Brand.
*/
data: XOR<BrandUpdateInput, BrandUncheckedUpdateInput>
/**
* Choose, which Brand to update.
*/
where: BrandWhereUniqueInput
}
/**
* Brand updateMany
*/
export type BrandUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Brands.
*/
data: XOR<BrandUpdateManyMutationInput, BrandUncheckedUpdateManyInput>
/**
* Filter which Brands to update
*/
where?: BrandWhereInput
}
/**
* Brand upsert
*/
export type BrandUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | 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<BrandCreateInput, BrandUncheckedCreateInput>
/**
* In case the Brand was found with the provided `where` argument, update it with this data.
*/
update: XOR<BrandUpdateInput, BrandUncheckedUpdateInput>
}
/**
* Brand delete
*/
export type BrandDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | null
/**
* Filter which Brand to delete.
*/
where: BrandWhereUniqueInput
}
/**
* Brand deleteMany
*/
export type BrandDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Brands to delete
*/
where?: BrandWhereInput
}
/**
* Brand.products
*/
export type Brand$productsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | null
where?: ProductWhereInput
orderBy?: ProductOrderByWithRelationInput | ProductOrderByWithRelationInput[]
cursor?: ProductWhereUniqueInput
take?: number
skip?: number
distinct?: ProductScalarFieldEnum | ProductScalarFieldEnum[]
}
/**
* Brand without action
*/
export type BrandDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends CollectionAggregateArgs> = {
[P in keyof T & keyof AggregateCollection]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateCollection[P]>
: GetScalarType<T[P], AggregateCollection[P]>
}
export type CollectionGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends CollectionGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<CollectionGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof CollectionGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], CollectionGroupByOutputType[P]>
: GetScalarType<T[P], CollectionGroupByOutputType[P]>
}
>
>
export type CollectionSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
title?: boolean
description?: boolean
isActive?: boolean
products?: boolean | Collection$productsArgs<ExtArgs>
_count?: boolean | CollectionCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["collection"]>
export type CollectionSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
products?: boolean | Collection$productsArgs<ExtArgs>
_count?: boolean | CollectionCountOutputTypeDefaultArgs<ExtArgs>
}
export type CollectionIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {}
export type $CollectionPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "Collection"
objects: {
products: Prisma.$CollectionProductPayload<ExtArgs>[]
}
scalars: $Extensions.GetPayloadResult<{
id: string
title: string
description: string | null
isActive: boolean
}, ExtArgs["result"]["collection"]>
composites: {}
}
type CollectionGetPayload<S extends boolean | null | undefined | CollectionDefaultArgs> = $Result.GetResult<Prisma.$CollectionPayload, S>
type CollectionCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<CollectionFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: CollectionCountAggregateInputType | true
}
export interface CollectionDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends CollectionFindUniqueArgs>(args: SelectSubset<T, CollectionFindUniqueArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionFindUniqueOrThrowArgs>(args: SelectSubset<T, CollectionFindUniqueOrThrowArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionFindFirstArgs>(args?: SelectSubset<T, CollectionFindFirstArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionFindFirstOrThrowArgs>(args?: SelectSubset<T, CollectionFindFirstOrThrowArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionFindManyArgs>(args?: SelectSubset<T, CollectionFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionCreateArgs>(args: SelectSubset<T, CollectionCreateArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionCreateManyArgs>(args?: SelectSubset<T, CollectionCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CollectionCreateManyAndReturnArgs>(args?: SelectSubset<T, CollectionCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionDeleteArgs>(args: SelectSubset<T, CollectionDeleteArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionUpdateArgs>(args: SelectSubset<T, CollectionUpdateArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionDeleteManyArgs>(args?: SelectSubset<T, CollectionDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CollectionUpdateManyArgs>(args: SelectSubset<T, CollectionUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CollectionUpsertArgs>(args: SelectSubset<T, CollectionUpsertArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, 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<T extends CollectionCountArgs>(
args?: Subset<T, CollectionCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], CollectionCountAggregateOutputType>
: 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<T extends CollectionAggregateArgs>(args: Subset<T, CollectionAggregateArgs>): Prisma.PrismaPromise<GetCollectionAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: CollectionGroupByArgs['orderBy'] }
: { orderBy?: CollectionGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, CollectionGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCollectionGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
products<T extends Collection$productsArgs<ExtArgs> = {}>(args?: Subset<T, Collection$productsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | null
/**
* Filter, which Collection to fetch.
*/
where: CollectionWhereUniqueInput
}
/**
* Collection findUniqueOrThrow
*/
export type CollectionFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | null
/**
* Filter, which Collection to fetch.
*/
where: CollectionWhereUniqueInput
}
/**
* Collection findFirst
*/
export type CollectionFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | null
/**
* The data needed to create a Collection.
*/
data: XOR<CollectionCreateInput, CollectionUncheckedCreateInput>
}
/**
* Collection createMany
*/
export type CollectionCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Collections.
*/
data: CollectionCreateManyInput | CollectionCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Collection createManyAndReturn
*/
export type CollectionCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Collections.
*/
data: CollectionCreateManyInput | CollectionCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Collection update
*/
export type CollectionUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | null
/**
* The data needed to update a Collection.
*/
data: XOR<CollectionUpdateInput, CollectionUncheckedUpdateInput>
/**
* Choose, which Collection to update.
*/
where: CollectionWhereUniqueInput
}
/**
* Collection updateMany
*/
export type CollectionUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Collections.
*/
data: XOR<CollectionUpdateManyMutationInput, CollectionUncheckedUpdateManyInput>
/**
* Filter which Collections to update
*/
where?: CollectionWhereInput
}
/**
* Collection upsert
*/
export type CollectionUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | 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<CollectionCreateInput, CollectionUncheckedCreateInput>
/**
* In case the Collection was found with the provided `where` argument, update it with this data.
*/
update: XOR<CollectionUpdateInput, CollectionUncheckedUpdateInput>
}
/**
* Collection delete
*/
export type CollectionDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | null
/**
* Filter which Collection to delete.
*/
where: CollectionWhereUniqueInput
}
/**
* Collection deleteMany
*/
export type CollectionDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Collections to delete
*/
where?: CollectionWhereInput
}
/**
* Collection.products
*/
export type Collection$productsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | null
where?: CollectionProductWhereInput
orderBy?: CollectionProductOrderByWithRelationInput | CollectionProductOrderByWithRelationInput[]
cursor?: CollectionProductWhereUniqueInput
take?: number
skip?: number
distinct?: CollectionProductScalarFieldEnum | CollectionProductScalarFieldEnum[]
}
/**
* Collection without action
*/
export type CollectionDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Collection
*/
select?: CollectionSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends CollectionProductAggregateArgs> = {
[P in keyof T & keyof AggregateCollectionProduct]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateCollectionProduct[P]>
: GetScalarType<T[P], AggregateCollectionProduct[P]>
}
export type CollectionProductGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends CollectionProductGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<CollectionProductGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof CollectionProductGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], CollectionProductGroupByOutputType[P]>
: GetScalarType<T[P], CollectionProductGroupByOutputType[P]>
}
>
>
export type CollectionProductSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
collectionId?: boolean
productId?: boolean
collection?: boolean | CollectionDefaultArgs<ExtArgs>
product?: boolean | ProductDefaultArgs<ExtArgs>
}, ExtArgs["result"]["collectionProduct"]>
export type CollectionProductSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
collectionId?: boolean
productId?: boolean
collection?: boolean | CollectionDefaultArgs<ExtArgs>
product?: boolean | ProductDefaultArgs<ExtArgs>
}, ExtArgs["result"]["collectionProduct"]>
export type CollectionProductSelectScalar = {
collectionId?: boolean
productId?: boolean
}
export type CollectionProductInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
collection?: boolean | CollectionDefaultArgs<ExtArgs>
product?: boolean | ProductDefaultArgs<ExtArgs>
}
export type CollectionProductIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
collection?: boolean | CollectionDefaultArgs<ExtArgs>
product?: boolean | ProductDefaultArgs<ExtArgs>
}
export type $CollectionProductPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "CollectionProduct"
objects: {
collection: Prisma.$CollectionPayload<ExtArgs>
product: Prisma.$ProductPayload<ExtArgs>
}
scalars: $Extensions.GetPayloadResult<{
collectionId: string
productId: string
}, ExtArgs["result"]["collectionProduct"]>
composites: {}
}
type CollectionProductGetPayload<S extends boolean | null | undefined | CollectionProductDefaultArgs> = $Result.GetResult<Prisma.$CollectionProductPayload, S>
type CollectionProductCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<CollectionProductFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: CollectionProductCountAggregateInputType | true
}
export interface CollectionProductDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends CollectionProductFindUniqueArgs>(args: SelectSubset<T, CollectionProductFindUniqueArgs<ExtArgs>>): Prisma__CollectionProductClient<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductFindUniqueOrThrowArgs>(args: SelectSubset<T, CollectionProductFindUniqueOrThrowArgs<ExtArgs>>): Prisma__CollectionProductClient<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductFindFirstArgs>(args?: SelectSubset<T, CollectionProductFindFirstArgs<ExtArgs>>): Prisma__CollectionProductClient<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductFindFirstOrThrowArgs>(args?: SelectSubset<T, CollectionProductFindFirstOrThrowArgs<ExtArgs>>): Prisma__CollectionProductClient<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductFindManyArgs>(args?: SelectSubset<T, CollectionProductFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductCreateArgs>(args: SelectSubset<T, CollectionProductCreateArgs<ExtArgs>>): Prisma__CollectionProductClient<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductCreateManyArgs>(args?: SelectSubset<T, CollectionProductCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CollectionProductCreateManyAndReturnArgs>(args?: SelectSubset<T, CollectionProductCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductDeleteArgs>(args: SelectSubset<T, CollectionProductDeleteArgs<ExtArgs>>): Prisma__CollectionProductClient<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductUpdateArgs>(args: SelectSubset<T, CollectionProductUpdateArgs<ExtArgs>>): Prisma__CollectionProductClient<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductDeleteManyArgs>(args?: SelectSubset<T, CollectionProductDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CollectionProductUpdateManyArgs>(args: SelectSubset<T, CollectionProductUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends CollectionProductUpsertArgs>(args: SelectSubset<T, CollectionProductUpsertArgs<ExtArgs>>): Prisma__CollectionProductClient<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<T extends CollectionProductCountArgs>(
args?: Subset<T, CollectionProductCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], CollectionProductCountAggregateOutputType>
: 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<T extends CollectionProductAggregateArgs>(args: Subset<T, CollectionProductAggregateArgs>): Prisma.PrismaPromise<GetCollectionProductAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: CollectionProductGroupByArgs['orderBy'] }
: { orderBy?: CollectionProductGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, CollectionProductGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCollectionProductGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
collection<T extends CollectionDefaultArgs<ExtArgs> = {}>(args?: Subset<T, CollectionDefaultArgs<ExtArgs>>): Prisma__CollectionClient<$Result.GetResult<Prisma.$CollectionPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
product<T extends ProductDefaultArgs<ExtArgs> = {}>(args?: Subset<T, ProductDefaultArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* Fields of the CollectionProduct model
*/
interface CollectionProductFieldRefs {
readonly collectionId: FieldRef<"CollectionProduct", 'String'>
readonly productId: FieldRef<"CollectionProduct", 'String'>
}
// Custom InputTypes
/**
* CollectionProduct findUnique
*/
export type CollectionProductFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | null
/**
* Filter, which CollectionProduct to fetch.
*/
where: CollectionProductWhereUniqueInput
}
/**
* CollectionProduct findUniqueOrThrow
*/
export type CollectionProductFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | null
/**
* Filter, which CollectionProduct to fetch.
*/
where: CollectionProductWhereUniqueInput
}
/**
* CollectionProduct findFirst
*/
export type CollectionProductFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | null
/**
* The data needed to create a CollectionProduct.
*/
data: XOR<CollectionProductCreateInput, CollectionProductUncheckedCreateInput>
}
/**
* CollectionProduct createMany
*/
export type CollectionProductCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many CollectionProducts.
*/
data: CollectionProductCreateManyInput | CollectionProductCreateManyInput[]
skipDuplicates?: boolean
}
/**
* CollectionProduct createManyAndReturn
*/
export type CollectionProductCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many CollectionProducts.
*/
data: CollectionProductCreateManyInput | CollectionProductCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* CollectionProduct update
*/
export type CollectionProductUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | null
/**
* The data needed to update a CollectionProduct.
*/
data: XOR<CollectionProductUpdateInput, CollectionProductUncheckedUpdateInput>
/**
* Choose, which CollectionProduct to update.
*/
where: CollectionProductWhereUniqueInput
}
/**
* CollectionProduct updateMany
*/
export type CollectionProductUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update CollectionProducts.
*/
data: XOR<CollectionProductUpdateManyMutationInput, CollectionProductUncheckedUpdateManyInput>
/**
* Filter which CollectionProducts to update
*/
where?: CollectionProductWhereInput
}
/**
* CollectionProduct upsert
*/
export type CollectionProductUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | 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<CollectionProductCreateInput, CollectionProductUncheckedCreateInput>
/**
* In case the CollectionProduct was found with the provided `where` argument, update it with this data.
*/
update: XOR<CollectionProductUpdateInput, CollectionProductUncheckedUpdateInput>
}
/**
* CollectionProduct delete
*/
export type CollectionProductDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | null
/**
* Filter which CollectionProduct to delete.
*/
where: CollectionProductWhereUniqueInput
}
/**
* CollectionProduct deleteMany
*/
export type CollectionProductDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which CollectionProducts to delete
*/
where?: CollectionProductWhereInput
}
/**
* CollectionProduct without action
*/
export type CollectionProductDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends ProductAggregateArgs> = {
[P in keyof T & keyof AggregateProduct]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateProduct[P]>
: GetScalarType<T[P], AggregateProduct[P]>
}
export type ProductGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends ProductGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<ProductGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof ProductGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], ProductGroupByOutputType[P]>
: GetScalarType<T[P], ProductGroupByOutputType[P]>
}
>
>
export type ProductSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
title?: boolean
description?: boolean
categoryId?: boolean
brandId?: boolean
isActive?: boolean
createdAt?: boolean
category?: boolean | Product$categoryArgs<ExtArgs>
brand?: boolean | Product$brandArgs<ExtArgs>
variants?: boolean | Product$variantsArgs<ExtArgs>
images?: boolean | Product$imagesArgs<ExtArgs>
collections?: boolean | Product$collectionsArgs<ExtArgs>
_count?: boolean | ProductCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["product"]>
export type ProductSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
title?: boolean
description?: boolean
categoryId?: boolean
brandId?: boolean
isActive?: boolean
createdAt?: boolean
category?: boolean | Product$categoryArgs<ExtArgs>
brand?: boolean | Product$brandArgs<ExtArgs>
}, ExtArgs["result"]["product"]>
export type ProductSelectScalar = {
id?: boolean
title?: boolean
description?: boolean
categoryId?: boolean
brandId?: boolean
isActive?: boolean
createdAt?: boolean
}
export type ProductInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
category?: boolean | Product$categoryArgs<ExtArgs>
brand?: boolean | Product$brandArgs<ExtArgs>
variants?: boolean | Product$variantsArgs<ExtArgs>
images?: boolean | Product$imagesArgs<ExtArgs>
collections?: boolean | Product$collectionsArgs<ExtArgs>
_count?: boolean | ProductCountOutputTypeDefaultArgs<ExtArgs>
}
export type ProductIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
category?: boolean | Product$categoryArgs<ExtArgs>
brand?: boolean | Product$brandArgs<ExtArgs>
}
export type $ProductPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "Product"
objects: {
category: Prisma.$CategoryPayload<ExtArgs> | null
brand: Prisma.$BrandPayload<ExtArgs> | null
variants: Prisma.$ProductVariantPayload<ExtArgs>[]
images: Prisma.$ProductImagePayload<ExtArgs>[]
collections: Prisma.$CollectionProductPayload<ExtArgs>[]
}
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<S extends boolean | null | undefined | ProductDefaultArgs> = $Result.GetResult<Prisma.$ProductPayload, S>
type ProductCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<ProductFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: ProductCountAggregateInputType | true
}
export interface ProductDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends ProductFindUniqueArgs>(args: SelectSubset<T, ProductFindUniqueArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductFindUniqueOrThrowArgs>(args: SelectSubset<T, ProductFindUniqueOrThrowArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductFindFirstArgs>(args?: SelectSubset<T, ProductFindFirstArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductFindFirstOrThrowArgs>(args?: SelectSubset<T, ProductFindFirstOrThrowArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductFindManyArgs>(args?: SelectSubset<T, ProductFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductCreateArgs>(args: SelectSubset<T, ProductCreateArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductCreateManyArgs>(args?: SelectSubset<T, ProductCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductCreateManyAndReturnArgs>(args?: SelectSubset<T, ProductCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductDeleteArgs>(args: SelectSubset<T, ProductDeleteArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductUpdateArgs>(args: SelectSubset<T, ProductUpdateArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductDeleteManyArgs>(args?: SelectSubset<T, ProductDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductUpdateManyArgs>(args: SelectSubset<T, ProductUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductUpsertArgs>(args: SelectSubset<T, ProductUpsertArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<T extends ProductCountArgs>(
args?: Subset<T, ProductCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], ProductCountAggregateOutputType>
: 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<T extends ProductAggregateArgs>(args: Subset<T, ProductAggregateArgs>): Prisma.PrismaPromise<GetProductAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: ProductGroupByArgs['orderBy'] }
: { orderBy?: ProductGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, ProductGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetProductGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
category<T extends Product$categoryArgs<ExtArgs> = {}>(args?: Subset<T, Product$categoryArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
brand<T extends Product$brandArgs<ExtArgs> = {}>(args?: Subset<T, Product$brandArgs<ExtArgs>>): Prisma__BrandClient<$Result.GetResult<Prisma.$BrandPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
variants<T extends Product$variantsArgs<ExtArgs> = {}>(args?: Subset<T, Product$variantsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, T, "findMany"> | Null>
images<T extends Product$imagesArgs<ExtArgs> = {}>(args?: Subset<T, Product$imagesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, T, "findMany"> | Null>
collections<T extends Product$collectionsArgs<ExtArgs> = {}>(args?: Subset<T, Product$collectionsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CollectionProductPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | null
/**
* Filter, which Product to fetch.
*/
where: ProductWhereUniqueInput
}
/**
* Product findUniqueOrThrow
*/
export type ProductFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | null
/**
* Filter, which Product to fetch.
*/
where: ProductWhereUniqueInput
}
/**
* Product findFirst
*/
export type ProductFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | null
/**
* The data needed to create a Product.
*/
data: XOR<ProductCreateInput, ProductUncheckedCreateInput>
}
/**
* Product createMany
*/
export type ProductCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Products.
*/
data: ProductCreateManyInput | ProductCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Product createManyAndReturn
*/
export type ProductCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Products.
*/
data: ProductCreateManyInput | ProductCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* Product update
*/
export type ProductUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | null
/**
* The data needed to update a Product.
*/
data: XOR<ProductUpdateInput, ProductUncheckedUpdateInput>
/**
* Choose, which Product to update.
*/
where: ProductWhereUniqueInput
}
/**
* Product updateMany
*/
export type ProductUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Products.
*/
data: XOR<ProductUpdateManyMutationInput, ProductUncheckedUpdateManyInput>
/**
* Filter which Products to update
*/
where?: ProductWhereInput
}
/**
* Product upsert
*/
export type ProductUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | 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<ProductCreateInput, ProductUncheckedCreateInput>
/**
* In case the Product was found with the provided `where` argument, update it with this data.
*/
update: XOR<ProductUpdateInput, ProductUncheckedUpdateInput>
}
/**
* Product delete
*/
export type ProductDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | null
/**
* Filter which Product to delete.
*/
where: ProductWhereUniqueInput
}
/**
* Product deleteMany
*/
export type ProductDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Products to delete
*/
where?: ProductWhereInput
}
/**
* Product.category
*/
export type Product$categoryArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Category
*/
select?: CategorySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CategoryInclude<ExtArgs> | null
where?: CategoryWhereInput
}
/**
* Product.brand
*/
export type Product$brandArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Brand
*/
select?: BrandSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BrandInclude<ExtArgs> | null
where?: BrandWhereInput
}
/**
* Product.variants
*/
export type Product$variantsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | null
where?: ProductVariantWhereInput
orderBy?: ProductVariantOrderByWithRelationInput | ProductVariantOrderByWithRelationInput[]
cursor?: ProductVariantWhereUniqueInput
take?: number
skip?: number
distinct?: ProductVariantScalarFieldEnum | ProductVariantScalarFieldEnum[]
}
/**
* Product.images
*/
export type Product$imagesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | null
where?: ProductImageWhereInput
orderBy?: ProductImageOrderByWithRelationInput | ProductImageOrderByWithRelationInput[]
cursor?: ProductImageWhereUniqueInput
take?: number
skip?: number
distinct?: ProductImageScalarFieldEnum | ProductImageScalarFieldEnum[]
}
/**
* Product.collections
*/
export type Product$collectionsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the CollectionProduct
*/
select?: CollectionProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CollectionProductInclude<ExtArgs> | null
where?: CollectionProductWhereInput
orderBy?: CollectionProductOrderByWithRelationInput | CollectionProductOrderByWithRelationInput[]
cursor?: CollectionProductWhereUniqueInput
take?: number
skip?: number
distinct?: CollectionProductScalarFieldEnum | CollectionProductScalarFieldEnum[]
}
/**
* Product without action
*/
export type ProductDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Product
*/
select?: ProductSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends ProductImageAggregateArgs> = {
[P in keyof T & keyof AggregateProductImage]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateProductImage[P]>
: GetScalarType<T[P], AggregateProductImage[P]>
}
export type ProductImageGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends ProductImageGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<ProductImageGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof ProductImageGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], ProductImageGroupByOutputType[P]>
: GetScalarType<T[P], ProductImageGroupByOutputType[P]>
}
>
>
export type ProductImageSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
productId?: boolean
url?: boolean
sortOrder?: boolean
product?: boolean | ProductDefaultArgs<ExtArgs>
}, ExtArgs["result"]["productImage"]>
export type ProductImageSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
productId?: boolean
url?: boolean
sortOrder?: boolean
product?: boolean | ProductDefaultArgs<ExtArgs>
}, ExtArgs["result"]["productImage"]>
export type ProductImageSelectScalar = {
id?: boolean
productId?: boolean
url?: boolean
sortOrder?: boolean
}
export type ProductImageInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
product?: boolean | ProductDefaultArgs<ExtArgs>
}
export type ProductImageIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
product?: boolean | ProductDefaultArgs<ExtArgs>
}
export type $ProductImagePayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "ProductImage"
objects: {
product: Prisma.$ProductPayload<ExtArgs>
}
scalars: $Extensions.GetPayloadResult<{
id: string
productId: string
url: string
sortOrder: number
}, ExtArgs["result"]["productImage"]>
composites: {}
}
type ProductImageGetPayload<S extends boolean | null | undefined | ProductImageDefaultArgs> = $Result.GetResult<Prisma.$ProductImagePayload, S>
type ProductImageCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<ProductImageFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: ProductImageCountAggregateInputType | true
}
export interface ProductImageDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends ProductImageFindUniqueArgs>(args: SelectSubset<T, ProductImageFindUniqueArgs<ExtArgs>>): Prisma__ProductImageClient<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageFindUniqueOrThrowArgs>(args: SelectSubset<T, ProductImageFindUniqueOrThrowArgs<ExtArgs>>): Prisma__ProductImageClient<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageFindFirstArgs>(args?: SelectSubset<T, ProductImageFindFirstArgs<ExtArgs>>): Prisma__ProductImageClient<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageFindFirstOrThrowArgs>(args?: SelectSubset<T, ProductImageFindFirstOrThrowArgs<ExtArgs>>): Prisma__ProductImageClient<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageFindManyArgs>(args?: SelectSubset<T, ProductImageFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageCreateArgs>(args: SelectSubset<T, ProductImageCreateArgs<ExtArgs>>): Prisma__ProductImageClient<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageCreateManyArgs>(args?: SelectSubset<T, ProductImageCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductImageCreateManyAndReturnArgs>(args?: SelectSubset<T, ProductImageCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageDeleteArgs>(args: SelectSubset<T, ProductImageDeleteArgs<ExtArgs>>): Prisma__ProductImageClient<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageUpdateArgs>(args: SelectSubset<T, ProductImageUpdateArgs<ExtArgs>>): Prisma__ProductImageClient<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageDeleteManyArgs>(args?: SelectSubset<T, ProductImageDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductImageUpdateManyArgs>(args: SelectSubset<T, ProductImageUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductImageUpsertArgs>(args: SelectSubset<T, ProductImageUpsertArgs<ExtArgs>>): Prisma__ProductImageClient<$Result.GetResult<Prisma.$ProductImagePayload<ExtArgs>, 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<T extends ProductImageCountArgs>(
args?: Subset<T, ProductImageCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], ProductImageCountAggregateOutputType>
: 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<T extends ProductImageAggregateArgs>(args: Subset<T, ProductImageAggregateArgs>): Prisma.PrismaPromise<GetProductImageAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: ProductImageGroupByArgs['orderBy'] }
: { orderBy?: ProductImageGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, ProductImageGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetProductImageGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
product<T extends ProductDefaultArgs<ExtArgs> = {}>(args?: Subset<T, ProductDefaultArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | null
/**
* Filter, which ProductImage to fetch.
*/
where: ProductImageWhereUniqueInput
}
/**
* ProductImage findUniqueOrThrow
*/
export type ProductImageFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | null
/**
* Filter, which ProductImage to fetch.
*/
where: ProductImageWhereUniqueInput
}
/**
* ProductImage findFirst
*/
export type ProductImageFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | null
/**
* The data needed to create a ProductImage.
*/
data: XOR<ProductImageCreateInput, ProductImageUncheckedCreateInput>
}
/**
* ProductImage createMany
*/
export type ProductImageCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many ProductImages.
*/
data: ProductImageCreateManyInput | ProductImageCreateManyInput[]
skipDuplicates?: boolean
}
/**
* ProductImage createManyAndReturn
*/
export type ProductImageCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many ProductImages.
*/
data: ProductImageCreateManyInput | ProductImageCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* ProductImage update
*/
export type ProductImageUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | null
/**
* The data needed to update a ProductImage.
*/
data: XOR<ProductImageUpdateInput, ProductImageUncheckedUpdateInput>
/**
* Choose, which ProductImage to update.
*/
where: ProductImageWhereUniqueInput
}
/**
* ProductImage updateMany
*/
export type ProductImageUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update ProductImages.
*/
data: XOR<ProductImageUpdateManyMutationInput, ProductImageUncheckedUpdateManyInput>
/**
* Filter which ProductImages to update
*/
where?: ProductImageWhereInput
}
/**
* ProductImage upsert
*/
export type ProductImageUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | 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<ProductImageCreateInput, ProductImageUncheckedCreateInput>
/**
* In case the ProductImage was found with the provided `where` argument, update it with this data.
*/
update: XOR<ProductImageUpdateInput, ProductImageUncheckedUpdateInput>
}
/**
* ProductImage delete
*/
export type ProductImageDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | null
/**
* Filter which ProductImage to delete.
*/
where: ProductImageWhereUniqueInput
}
/**
* ProductImage deleteMany
*/
export type ProductImageDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which ProductImages to delete
*/
where?: ProductImageWhereInput
}
/**
* ProductImage without action
*/
export type ProductImageDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductImage
*/
select?: ProductImageSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductImageInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends ProductVariantAggregateArgs> = {
[P in keyof T & keyof AggregateProductVariant]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateProductVariant[P]>
: GetScalarType<T[P], AggregateProductVariant[P]>
}
export type ProductVariantGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends ProductVariantGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<ProductVariantGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof ProductVariantGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], ProductVariantGroupByOutputType[P]>
: GetScalarType<T[P], ProductVariantGroupByOutputType[P]>
}
>
>
export type ProductVariantSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
productId?: boolean
title?: boolean
sku?: boolean
rashWeightGrams?: boolean
defaultWagePercent?: boolean
isActive?: boolean
product?: boolean | ProductDefaultArgs<ExtArgs>
orderItems?: boolean | ProductVariant$orderItemsArgs<ExtArgs>
_count?: boolean | ProductVariantCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["productVariant"]>
export type ProductVariantSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
productId?: boolean
title?: boolean
sku?: boolean
rashWeightGrams?: boolean
defaultWagePercent?: boolean
isActive?: boolean
product?: boolean | ProductDefaultArgs<ExtArgs>
}, ExtArgs["result"]["productVariant"]>
export type ProductVariantSelectScalar = {
id?: boolean
productId?: boolean
title?: boolean
sku?: boolean
rashWeightGrams?: boolean
defaultWagePercent?: boolean
isActive?: boolean
}
export type ProductVariantInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
product?: boolean | ProductDefaultArgs<ExtArgs>
orderItems?: boolean | ProductVariant$orderItemsArgs<ExtArgs>
_count?: boolean | ProductVariantCountOutputTypeDefaultArgs<ExtArgs>
}
export type ProductVariantIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
product?: boolean | ProductDefaultArgs<ExtArgs>
}
export type $ProductVariantPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "ProductVariant"
objects: {
product: Prisma.$ProductPayload<ExtArgs>
orderItems: Prisma.$OrderItemPayload<ExtArgs>[]
}
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<S extends boolean | null | undefined | ProductVariantDefaultArgs> = $Result.GetResult<Prisma.$ProductVariantPayload, S>
type ProductVariantCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<ProductVariantFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: ProductVariantCountAggregateInputType | true
}
export interface ProductVariantDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends ProductVariantFindUniqueArgs>(args: SelectSubset<T, ProductVariantFindUniqueArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantFindUniqueOrThrowArgs>(args: SelectSubset<T, ProductVariantFindUniqueOrThrowArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantFindFirstArgs>(args?: SelectSubset<T, ProductVariantFindFirstArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantFindFirstOrThrowArgs>(args?: SelectSubset<T, ProductVariantFindFirstOrThrowArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantFindManyArgs>(args?: SelectSubset<T, ProductVariantFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantCreateArgs>(args: SelectSubset<T, ProductVariantCreateArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantCreateManyArgs>(args?: SelectSubset<T, ProductVariantCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductVariantCreateManyAndReturnArgs>(args?: SelectSubset<T, ProductVariantCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantDeleteArgs>(args: SelectSubset<T, ProductVariantDeleteArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantUpdateArgs>(args: SelectSubset<T, ProductVariantUpdateArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantDeleteManyArgs>(args?: SelectSubset<T, ProductVariantDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductVariantUpdateManyArgs>(args: SelectSubset<T, ProductVariantUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends ProductVariantUpsertArgs>(args: SelectSubset<T, ProductVariantUpsertArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<T extends ProductVariantCountArgs>(
args?: Subset<T, ProductVariantCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], ProductVariantCountAggregateOutputType>
: 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<T extends ProductVariantAggregateArgs>(args: Subset<T, ProductVariantAggregateArgs>): Prisma.PrismaPromise<GetProductVariantAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: ProductVariantGroupByArgs['orderBy'] }
: { orderBy?: ProductVariantGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, ProductVariantGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetProductVariantGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
product<T extends ProductDefaultArgs<ExtArgs> = {}>(args?: Subset<T, ProductDefaultArgs<ExtArgs>>): Prisma__ProductClient<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
orderItems<T extends ProductVariant$orderItemsArgs<ExtArgs> = {}>(args?: Subset<T, ProductVariant$orderItemsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | null
/**
* Filter, which ProductVariant to fetch.
*/
where: ProductVariantWhereUniqueInput
}
/**
* ProductVariant findUniqueOrThrow
*/
export type ProductVariantFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | null
/**
* Filter, which ProductVariant to fetch.
*/
where: ProductVariantWhereUniqueInput
}
/**
* ProductVariant findFirst
*/
export type ProductVariantFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | null
/**
* The data needed to create a ProductVariant.
*/
data: XOR<ProductVariantCreateInput, ProductVariantUncheckedCreateInput>
}
/**
* ProductVariant createMany
*/
export type ProductVariantCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many ProductVariants.
*/
data: ProductVariantCreateManyInput | ProductVariantCreateManyInput[]
skipDuplicates?: boolean
}
/**
* ProductVariant createManyAndReturn
*/
export type ProductVariantCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many ProductVariants.
*/
data: ProductVariantCreateManyInput | ProductVariantCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* ProductVariant update
*/
export type ProductVariantUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | null
/**
* The data needed to update a ProductVariant.
*/
data: XOR<ProductVariantUpdateInput, ProductVariantUncheckedUpdateInput>
/**
* Choose, which ProductVariant to update.
*/
where: ProductVariantWhereUniqueInput
}
/**
* ProductVariant updateMany
*/
export type ProductVariantUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update ProductVariants.
*/
data: XOR<ProductVariantUpdateManyMutationInput, ProductVariantUncheckedUpdateManyInput>
/**
* Filter which ProductVariants to update
*/
where?: ProductVariantWhereInput
}
/**
* ProductVariant upsert
*/
export type ProductVariantUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | 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<ProductVariantCreateInput, ProductVariantUncheckedCreateInput>
/**
* In case the ProductVariant was found with the provided `where` argument, update it with this data.
*/
update: XOR<ProductVariantUpdateInput, ProductVariantUncheckedUpdateInput>
}
/**
* ProductVariant delete
*/
export type ProductVariantDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | null
/**
* Filter which ProductVariant to delete.
*/
where: ProductVariantWhereUniqueInput
}
/**
* ProductVariant deleteMany
*/
export type ProductVariantDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which ProductVariants to delete
*/
where?: ProductVariantWhereInput
}
/**
* ProductVariant.orderItems
*/
export type ProductVariant$orderItemsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | null
where?: OrderItemWhereInput
orderBy?: OrderItemOrderByWithRelationInput | OrderItemOrderByWithRelationInput[]
cursor?: OrderItemWhereUniqueInput
take?: number
skip?: number
distinct?: OrderItemScalarFieldEnum | OrderItemScalarFieldEnum[]
}
/**
* ProductVariant without action
*/
export type ProductVariantDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the ProductVariant
*/
select?: ProductVariantSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: ProductVariantInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends OrderAggregateArgs> = {
[P in keyof T & keyof AggregateOrder]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateOrder[P]>
: GetScalarType<T[P], AggregateOrder[P]>
}
export type OrderGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends OrderGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<OrderGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof OrderGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], OrderGroupByOutputType[P]>
: GetScalarType<T[P], OrderGroupByOutputType[P]>
}
>
>
export type OrderSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs>
branch?: boolean | Order$branchArgs<ExtArgs>
items?: boolean | Order$itemsArgs<ExtArgs>
statusEvents?: boolean | Order$statusEventsArgs<ExtArgs>
ledgerEntries?: boolean | Order$ledgerEntriesArgs<ExtArgs>
convertedFromPreOrder?: boolean | Order$convertedFromPreOrderArgs<ExtArgs>
_count?: boolean | OrderCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["order"]>
export type OrderSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs>
branch?: boolean | Order$branchArgs<ExtArgs>
}, 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
branch?: boolean | Order$branchArgs<ExtArgs>
items?: boolean | Order$itemsArgs<ExtArgs>
statusEvents?: boolean | Order$statusEventsArgs<ExtArgs>
ledgerEntries?: boolean | Order$ledgerEntriesArgs<ExtArgs>
convertedFromPreOrder?: boolean | Order$convertedFromPreOrderArgs<ExtArgs>
_count?: boolean | OrderCountOutputTypeDefaultArgs<ExtArgs>
}
export type OrderIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
branch?: boolean | Order$branchArgs<ExtArgs>
}
export type $OrderPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "Order"
objects: {
customer: Prisma.$CustomerPayload<ExtArgs>
branch: Prisma.$BranchPayload<ExtArgs> | null
items: Prisma.$OrderItemPayload<ExtArgs>[]
statusEvents: Prisma.$OrderStatusEventPayload<ExtArgs>[]
ledgerEntries: Prisma.$LedgerEntryPayload<ExtArgs>[]
convertedFromPreOrder: Prisma.$PreOrderPayload<ExtArgs> | 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<S extends boolean | null | undefined | OrderDefaultArgs> = $Result.GetResult<Prisma.$OrderPayload, S>
type OrderCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<OrderFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: OrderCountAggregateInputType | true
}
export interface OrderDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends OrderFindUniqueArgs>(args: SelectSubset<T, OrderFindUniqueArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderFindUniqueOrThrowArgs>(args: SelectSubset<T, OrderFindUniqueOrThrowArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderFindFirstArgs>(args?: SelectSubset<T, OrderFindFirstArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderFindFirstOrThrowArgs>(args?: SelectSubset<T, OrderFindFirstOrThrowArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderFindManyArgs>(args?: SelectSubset<T, OrderFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderCreateArgs>(args: SelectSubset<T, OrderCreateArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderCreateManyArgs>(args?: SelectSubset<T, OrderCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderCreateManyAndReturnArgs>(args?: SelectSubset<T, OrderCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderDeleteArgs>(args: SelectSubset<T, OrderDeleteArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderUpdateArgs>(args: SelectSubset<T, OrderUpdateArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderDeleteManyArgs>(args?: SelectSubset<T, OrderDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderUpdateManyArgs>(args: SelectSubset<T, OrderUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderUpsertArgs>(args: SelectSubset<T, OrderUpsertArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, 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<T extends OrderCountArgs>(
args?: Subset<T, OrderCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], OrderCountAggregateOutputType>
: 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<T extends OrderAggregateArgs>(args: Subset<T, OrderAggregateArgs>): Prisma.PrismaPromise<GetOrderAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: OrderGroupByArgs['orderBy'] }
: { orderBy?: OrderGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, OrderGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetOrderGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
customer<T extends CustomerDefaultArgs<ExtArgs> = {}>(args?: Subset<T, CustomerDefaultArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
branch<T extends Order$branchArgs<ExtArgs> = {}>(args?: Subset<T, Order$branchArgs<ExtArgs>>): Prisma__BranchClient<$Result.GetResult<Prisma.$BranchPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
items<T extends Order$itemsArgs<ExtArgs> = {}>(args?: Subset<T, Order$itemsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, T, "findMany"> | Null>
statusEvents<T extends Order$statusEventsArgs<ExtArgs> = {}>(args?: Subset<T, Order$statusEventsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, T, "findMany"> | Null>
ledgerEntries<T extends Order$ledgerEntriesArgs<ExtArgs> = {}>(args?: Subset<T, Order$ledgerEntriesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, T, "findMany"> | Null>
convertedFromPreOrder<T extends Order$convertedFromPreOrderArgs<ExtArgs> = {}>(args?: Subset<T, Order$convertedFromPreOrderArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
/**
* Filter, which Order to fetch.
*/
where: OrderWhereUniqueInput
}
/**
* Order findUniqueOrThrow
*/
export type OrderFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
/**
* Filter, which Order to fetch.
*/
where: OrderWhereUniqueInput
}
/**
* Order findFirst
*/
export type OrderFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
/**
* The data needed to create a Order.
*/
data: XOR<OrderCreateInput, OrderUncheckedCreateInput>
}
/**
* Order createMany
*/
export type OrderCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many Orders.
*/
data: OrderCreateManyInput | OrderCreateManyInput[]
skipDuplicates?: boolean
}
/**
* Order createManyAndReturn
*/
export type OrderCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many Orders.
*/
data: OrderCreateManyInput | OrderCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* Order update
*/
export type OrderUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
/**
* The data needed to update a Order.
*/
data: XOR<OrderUpdateInput, OrderUncheckedUpdateInput>
/**
* Choose, which Order to update.
*/
where: OrderWhereUniqueInput
}
/**
* Order updateMany
*/
export type OrderUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update Orders.
*/
data: XOR<OrderUpdateManyMutationInput, OrderUncheckedUpdateManyInput>
/**
* Filter which Orders to update
*/
where?: OrderWhereInput
}
/**
* Order upsert
*/
export type OrderUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | 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<OrderCreateInput, OrderUncheckedCreateInput>
/**
* In case the Order was found with the provided `where` argument, update it with this data.
*/
update: XOR<OrderUpdateInput, OrderUncheckedUpdateInput>
}
/**
* Order delete
*/
export type OrderDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
/**
* Filter which Order to delete.
*/
where: OrderWhereUniqueInput
}
/**
* Order deleteMany
*/
export type OrderDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which Orders to delete
*/
where?: OrderWhereInput
}
/**
* Order.branch
*/
export type Order$branchArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Branch
*/
select?: BranchSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: BranchInclude<ExtArgs> | null
where?: BranchWhereInput
}
/**
* Order.items
*/
export type Order$itemsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | null
where?: OrderItemWhereInput
orderBy?: OrderItemOrderByWithRelationInput | OrderItemOrderByWithRelationInput[]
cursor?: OrderItemWhereUniqueInput
take?: number
skip?: number
distinct?: OrderItemScalarFieldEnum | OrderItemScalarFieldEnum[]
}
/**
* Order.statusEvents
*/
export type Order$statusEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | null
where?: OrderStatusEventWhereInput
orderBy?: OrderStatusEventOrderByWithRelationInput | OrderStatusEventOrderByWithRelationInput[]
cursor?: OrderStatusEventWhereUniqueInput
take?: number
skip?: number
distinct?: OrderStatusEventScalarFieldEnum | OrderStatusEventScalarFieldEnum[]
}
/**
* Order.ledgerEntries
*/
export type Order$ledgerEntriesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | null
where?: LedgerEntryWhereInput
orderBy?: LedgerEntryOrderByWithRelationInput | LedgerEntryOrderByWithRelationInput[]
cursor?: LedgerEntryWhereUniqueInput
take?: number
skip?: number
distinct?: LedgerEntryScalarFieldEnum | LedgerEntryScalarFieldEnum[]
}
/**
* Order.convertedFromPreOrder
*/
export type Order$convertedFromPreOrderArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
where?: PreOrderWhereInput
}
/**
* Order without action
*/
export type OrderDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends OrderItemAggregateArgs> = {
[P in keyof T & keyof AggregateOrderItem]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateOrderItem[P]>
: GetScalarType<T[P], AggregateOrderItem[P]>
}
export type OrderItemGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends OrderItemGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<OrderItemGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof OrderItemGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], OrderItemGroupByOutputType[P]>
: GetScalarType<T[P], OrderItemGroupByOutputType[P]>
}
>
>
export type OrderItemSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
orderId?: boolean
productVariantId?: boolean
quantity?: boolean
rashWeightGramsSnapshot?: boolean
wagePercentSnapshot?: boolean
discountPercentSnapshot?: boolean
computedWeightGrams?: boolean
flatRialCharge?: boolean
order?: boolean | OrderDefaultArgs<ExtArgs>
productVariant?: boolean | ProductVariantDefaultArgs<ExtArgs>
}, ExtArgs["result"]["orderItem"]>
export type OrderItemSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
orderId?: boolean
productVariantId?: boolean
quantity?: boolean
rashWeightGramsSnapshot?: boolean
wagePercentSnapshot?: boolean
discountPercentSnapshot?: boolean
computedWeightGrams?: boolean
flatRialCharge?: boolean
order?: boolean | OrderDefaultArgs<ExtArgs>
productVariant?: boolean | ProductVariantDefaultArgs<ExtArgs>
}, 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
order?: boolean | OrderDefaultArgs<ExtArgs>
productVariant?: boolean | ProductVariantDefaultArgs<ExtArgs>
}
export type OrderItemIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
order?: boolean | OrderDefaultArgs<ExtArgs>
productVariant?: boolean | ProductVariantDefaultArgs<ExtArgs>
}
export type $OrderItemPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "OrderItem"
objects: {
order: Prisma.$OrderPayload<ExtArgs>
productVariant: Prisma.$ProductVariantPayload<ExtArgs>
}
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<S extends boolean | null | undefined | OrderItemDefaultArgs> = $Result.GetResult<Prisma.$OrderItemPayload, S>
type OrderItemCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<OrderItemFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: OrderItemCountAggregateInputType | true
}
export interface OrderItemDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends OrderItemFindUniqueArgs>(args: SelectSubset<T, OrderItemFindUniqueArgs<ExtArgs>>): Prisma__OrderItemClient<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemFindUniqueOrThrowArgs>(args: SelectSubset<T, OrderItemFindUniqueOrThrowArgs<ExtArgs>>): Prisma__OrderItemClient<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemFindFirstArgs>(args?: SelectSubset<T, OrderItemFindFirstArgs<ExtArgs>>): Prisma__OrderItemClient<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemFindFirstOrThrowArgs>(args?: SelectSubset<T, OrderItemFindFirstOrThrowArgs<ExtArgs>>): Prisma__OrderItemClient<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemFindManyArgs>(args?: SelectSubset<T, OrderItemFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemCreateArgs>(args: SelectSubset<T, OrderItemCreateArgs<ExtArgs>>): Prisma__OrderItemClient<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemCreateManyArgs>(args?: SelectSubset<T, OrderItemCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderItemCreateManyAndReturnArgs>(args?: SelectSubset<T, OrderItemCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemDeleteArgs>(args: SelectSubset<T, OrderItemDeleteArgs<ExtArgs>>): Prisma__OrderItemClient<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemUpdateArgs>(args: SelectSubset<T, OrderItemUpdateArgs<ExtArgs>>): Prisma__OrderItemClient<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemDeleteManyArgs>(args?: SelectSubset<T, OrderItemDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderItemUpdateManyArgs>(args: SelectSubset<T, OrderItemUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderItemUpsertArgs>(args: SelectSubset<T, OrderItemUpsertArgs<ExtArgs>>): Prisma__OrderItemClient<$Result.GetResult<Prisma.$OrderItemPayload<ExtArgs>, 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<T extends OrderItemCountArgs>(
args?: Subset<T, OrderItemCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], OrderItemCountAggregateOutputType>
: 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<T extends OrderItemAggregateArgs>(args: Subset<T, OrderItemAggregateArgs>): Prisma.PrismaPromise<GetOrderItemAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: OrderItemGroupByArgs['orderBy'] }
: { orderBy?: OrderItemGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, OrderItemGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetOrderItemGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
order<T extends OrderDefaultArgs<ExtArgs> = {}>(args?: Subset<T, OrderDefaultArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
productVariant<T extends ProductVariantDefaultArgs<ExtArgs> = {}>(args?: Subset<T, ProductVariantDefaultArgs<ExtArgs>>): Prisma__ProductVariantClient<$Result.GetResult<Prisma.$ProductVariantPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | null
/**
* Filter, which OrderItem to fetch.
*/
where: OrderItemWhereUniqueInput
}
/**
* OrderItem findUniqueOrThrow
*/
export type OrderItemFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | null
/**
* Filter, which OrderItem to fetch.
*/
where: OrderItemWhereUniqueInput
}
/**
* OrderItem findFirst
*/
export type OrderItemFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | null
/**
* The data needed to create a OrderItem.
*/
data: XOR<OrderItemCreateInput, OrderItemUncheckedCreateInput>
}
/**
* OrderItem createMany
*/
export type OrderItemCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many OrderItems.
*/
data: OrderItemCreateManyInput | OrderItemCreateManyInput[]
skipDuplicates?: boolean
}
/**
* OrderItem createManyAndReturn
*/
export type OrderItemCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many OrderItems.
*/
data: OrderItemCreateManyInput | OrderItemCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* OrderItem update
*/
export type OrderItemUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | null
/**
* The data needed to update a OrderItem.
*/
data: XOR<OrderItemUpdateInput, OrderItemUncheckedUpdateInput>
/**
* Choose, which OrderItem to update.
*/
where: OrderItemWhereUniqueInput
}
/**
* OrderItem updateMany
*/
export type OrderItemUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update OrderItems.
*/
data: XOR<OrderItemUpdateManyMutationInput, OrderItemUncheckedUpdateManyInput>
/**
* Filter which OrderItems to update
*/
where?: OrderItemWhereInput
}
/**
* OrderItem upsert
*/
export type OrderItemUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | 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<OrderItemCreateInput, OrderItemUncheckedCreateInput>
/**
* In case the OrderItem was found with the provided `where` argument, update it with this data.
*/
update: XOR<OrderItemUpdateInput, OrderItemUncheckedUpdateInput>
}
/**
* OrderItem delete
*/
export type OrderItemDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | null
/**
* Filter which OrderItem to delete.
*/
where: OrderItemWhereUniqueInput
}
/**
* OrderItem deleteMany
*/
export type OrderItemDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which OrderItems to delete
*/
where?: OrderItemWhereInput
}
/**
* OrderItem without action
*/
export type OrderItemDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderItem
*/
select?: OrderItemSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderItemInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends OrderStatusEventAggregateArgs> = {
[P in keyof T & keyof AggregateOrderStatusEvent]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateOrderStatusEvent[P]>
: GetScalarType<T[P], AggregateOrderStatusEvent[P]>
}
export type OrderStatusEventGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends OrderStatusEventGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<OrderStatusEventGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof OrderStatusEventGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], OrderStatusEventGroupByOutputType[P]>
: GetScalarType<T[P], OrderStatusEventGroupByOutputType[P]>
}
>
>
export type OrderStatusEventSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
orderId?: boolean
fromStatus?: boolean
toStatus?: boolean
note?: boolean
actorAdminUserId?: boolean
createdAt?: boolean
order?: boolean | OrderDefaultArgs<ExtArgs>
actorAdminUser?: boolean | OrderStatusEvent$actorAdminUserArgs<ExtArgs>
}, ExtArgs["result"]["orderStatusEvent"]>
export type OrderStatusEventSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
orderId?: boolean
fromStatus?: boolean
toStatus?: boolean
note?: boolean
actorAdminUserId?: boolean
createdAt?: boolean
order?: boolean | OrderDefaultArgs<ExtArgs>
actorAdminUser?: boolean | OrderStatusEvent$actorAdminUserArgs<ExtArgs>
}, ExtArgs["result"]["orderStatusEvent"]>
export type OrderStatusEventSelectScalar = {
id?: boolean
orderId?: boolean
fromStatus?: boolean
toStatus?: boolean
note?: boolean
actorAdminUserId?: boolean
createdAt?: boolean
}
export type OrderStatusEventInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
order?: boolean | OrderDefaultArgs<ExtArgs>
actorAdminUser?: boolean | OrderStatusEvent$actorAdminUserArgs<ExtArgs>
}
export type OrderStatusEventIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
order?: boolean | OrderDefaultArgs<ExtArgs>
actorAdminUser?: boolean | OrderStatusEvent$actorAdminUserArgs<ExtArgs>
}
export type $OrderStatusEventPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "OrderStatusEvent"
objects: {
order: Prisma.$OrderPayload<ExtArgs>
actorAdminUser: Prisma.$AdminUserPayload<ExtArgs> | 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<S extends boolean | null | undefined | OrderStatusEventDefaultArgs> = $Result.GetResult<Prisma.$OrderStatusEventPayload, S>
type OrderStatusEventCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<OrderStatusEventFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: OrderStatusEventCountAggregateInputType | true
}
export interface OrderStatusEventDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends OrderStatusEventFindUniqueArgs>(args: SelectSubset<T, OrderStatusEventFindUniqueArgs<ExtArgs>>): Prisma__OrderStatusEventClient<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventFindUniqueOrThrowArgs>(args: SelectSubset<T, OrderStatusEventFindUniqueOrThrowArgs<ExtArgs>>): Prisma__OrderStatusEventClient<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventFindFirstArgs>(args?: SelectSubset<T, OrderStatusEventFindFirstArgs<ExtArgs>>): Prisma__OrderStatusEventClient<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventFindFirstOrThrowArgs>(args?: SelectSubset<T, OrderStatusEventFindFirstOrThrowArgs<ExtArgs>>): Prisma__OrderStatusEventClient<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventFindManyArgs>(args?: SelectSubset<T, OrderStatusEventFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventCreateArgs>(args: SelectSubset<T, OrderStatusEventCreateArgs<ExtArgs>>): Prisma__OrderStatusEventClient<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventCreateManyArgs>(args?: SelectSubset<T, OrderStatusEventCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderStatusEventCreateManyAndReturnArgs>(args?: SelectSubset<T, OrderStatusEventCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventDeleteArgs>(args: SelectSubset<T, OrderStatusEventDeleteArgs<ExtArgs>>): Prisma__OrderStatusEventClient<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventUpdateArgs>(args: SelectSubset<T, OrderStatusEventUpdateArgs<ExtArgs>>): Prisma__OrderStatusEventClient<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventDeleteManyArgs>(args?: SelectSubset<T, OrderStatusEventDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderStatusEventUpdateManyArgs>(args: SelectSubset<T, OrderStatusEventUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends OrderStatusEventUpsertArgs>(args: SelectSubset<T, OrderStatusEventUpsertArgs<ExtArgs>>): Prisma__OrderStatusEventClient<$Result.GetResult<Prisma.$OrderStatusEventPayload<ExtArgs>, 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<T extends OrderStatusEventCountArgs>(
args?: Subset<T, OrderStatusEventCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], OrderStatusEventCountAggregateOutputType>
: 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<T extends OrderStatusEventAggregateArgs>(args: Subset<T, OrderStatusEventAggregateArgs>): Prisma.PrismaPromise<GetOrderStatusEventAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: OrderStatusEventGroupByArgs['orderBy'] }
: { orderBy?: OrderStatusEventGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, OrderStatusEventGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetOrderStatusEventGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
order<T extends OrderDefaultArgs<ExtArgs> = {}>(args?: Subset<T, OrderDefaultArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
actorAdminUser<T extends OrderStatusEvent$actorAdminUserArgs<ExtArgs> = {}>(args?: Subset<T, OrderStatusEvent$actorAdminUserArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | null
/**
* Filter, which OrderStatusEvent to fetch.
*/
where: OrderStatusEventWhereUniqueInput
}
/**
* OrderStatusEvent findUniqueOrThrow
*/
export type OrderStatusEventFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | null
/**
* Filter, which OrderStatusEvent to fetch.
*/
where: OrderStatusEventWhereUniqueInput
}
/**
* OrderStatusEvent findFirst
*/
export type OrderStatusEventFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | null
/**
* The data needed to create a OrderStatusEvent.
*/
data: XOR<OrderStatusEventCreateInput, OrderStatusEventUncheckedCreateInput>
}
/**
* OrderStatusEvent createMany
*/
export type OrderStatusEventCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many OrderStatusEvents.
*/
data: OrderStatusEventCreateManyInput | OrderStatusEventCreateManyInput[]
skipDuplicates?: boolean
}
/**
* OrderStatusEvent createManyAndReturn
*/
export type OrderStatusEventCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many OrderStatusEvents.
*/
data: OrderStatusEventCreateManyInput | OrderStatusEventCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* OrderStatusEvent update
*/
export type OrderStatusEventUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | null
/**
* The data needed to update a OrderStatusEvent.
*/
data: XOR<OrderStatusEventUpdateInput, OrderStatusEventUncheckedUpdateInput>
/**
* Choose, which OrderStatusEvent to update.
*/
where: OrderStatusEventWhereUniqueInput
}
/**
* OrderStatusEvent updateMany
*/
export type OrderStatusEventUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update OrderStatusEvents.
*/
data: XOR<OrderStatusEventUpdateManyMutationInput, OrderStatusEventUncheckedUpdateManyInput>
/**
* Filter which OrderStatusEvents to update
*/
where?: OrderStatusEventWhereInput
}
/**
* OrderStatusEvent upsert
*/
export type OrderStatusEventUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | 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<OrderStatusEventCreateInput, OrderStatusEventUncheckedCreateInput>
/**
* In case the OrderStatusEvent was found with the provided `where` argument, update it with this data.
*/
update: XOR<OrderStatusEventUpdateInput, OrderStatusEventUncheckedUpdateInput>
}
/**
* OrderStatusEvent delete
*/
export type OrderStatusEventDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | null
/**
* Filter which OrderStatusEvent to delete.
*/
where: OrderStatusEventWhereUniqueInput
}
/**
* OrderStatusEvent deleteMany
*/
export type OrderStatusEventDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which OrderStatusEvents to delete
*/
where?: OrderStatusEventWhereInput
}
/**
* OrderStatusEvent.actorAdminUser
*/
export type OrderStatusEvent$actorAdminUserArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
where?: AdminUserWhereInput
}
/**
* OrderStatusEvent without action
*/
export type OrderStatusEventDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the OrderStatusEvent
*/
select?: OrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderStatusEventInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends PreOrderAggregateArgs> = {
[P in keyof T & keyof AggregatePreOrder]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregatePreOrder[P]>
: GetScalarType<T[P], AggregatePreOrder[P]>
}
export type PreOrderGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends PreOrderGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<PreOrderGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof PreOrderGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], PreOrderGroupByOutputType[P]>
: GetScalarType<T[P], PreOrderGroupByOutputType[P]>
}
>
>
export type PreOrderSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs>
city?: boolean | PreOrder$cityArgs<ExtArgs>
workshop?: boolean | PreOrder$workshopArgs<ExtArgs>
convertedOrder?: boolean | PreOrder$convertedOrderArgs<ExtArgs>
statusEvents?: boolean | PreOrder$statusEventsArgs<ExtArgs>
_count?: boolean | PreOrderCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["preOrder"]>
export type PreOrderSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs>
city?: boolean | PreOrder$cityArgs<ExtArgs>
workshop?: boolean | PreOrder$workshopArgs<ExtArgs>
convertedOrder?: boolean | PreOrder$convertedOrderArgs<ExtArgs>
}, 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
city?: boolean | PreOrder$cityArgs<ExtArgs>
workshop?: boolean | PreOrder$workshopArgs<ExtArgs>
convertedOrder?: boolean | PreOrder$convertedOrderArgs<ExtArgs>
statusEvents?: boolean | PreOrder$statusEventsArgs<ExtArgs>
_count?: boolean | PreOrderCountOutputTypeDefaultArgs<ExtArgs>
}
export type PreOrderIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
city?: boolean | PreOrder$cityArgs<ExtArgs>
workshop?: boolean | PreOrder$workshopArgs<ExtArgs>
convertedOrder?: boolean | PreOrder$convertedOrderArgs<ExtArgs>
}
export type $PreOrderPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "PreOrder"
objects: {
customer: Prisma.$CustomerPayload<ExtArgs>
city: Prisma.$CityPayload<ExtArgs> | null
workshop: Prisma.$WorkshopPayload<ExtArgs> | null
convertedOrder: Prisma.$OrderPayload<ExtArgs> | null
statusEvents: Prisma.$PreOrderStatusEventPayload<ExtArgs>[]
}
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<S extends boolean | null | undefined | PreOrderDefaultArgs> = $Result.GetResult<Prisma.$PreOrderPayload, S>
type PreOrderCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<PreOrderFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: PreOrderCountAggregateInputType | true
}
export interface PreOrderDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends PreOrderFindUniqueArgs>(args: SelectSubset<T, PreOrderFindUniqueArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderFindUniqueOrThrowArgs>(args: SelectSubset<T, PreOrderFindUniqueOrThrowArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderFindFirstArgs>(args?: SelectSubset<T, PreOrderFindFirstArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderFindFirstOrThrowArgs>(args?: SelectSubset<T, PreOrderFindFirstOrThrowArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderFindManyArgs>(args?: SelectSubset<T, PreOrderFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderCreateArgs>(args: SelectSubset<T, PreOrderCreateArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderCreateManyArgs>(args?: SelectSubset<T, PreOrderCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends PreOrderCreateManyAndReturnArgs>(args?: SelectSubset<T, PreOrderCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderDeleteArgs>(args: SelectSubset<T, PreOrderDeleteArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderUpdateArgs>(args: SelectSubset<T, PreOrderUpdateArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderDeleteManyArgs>(args?: SelectSubset<T, PreOrderDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends PreOrderUpdateManyArgs>(args: SelectSubset<T, PreOrderUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends PreOrderUpsertArgs>(args: SelectSubset<T, PreOrderUpsertArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, 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<T extends PreOrderCountArgs>(
args?: Subset<T, PreOrderCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], PreOrderCountAggregateOutputType>
: 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<T extends PreOrderAggregateArgs>(args: Subset<T, PreOrderAggregateArgs>): Prisma.PrismaPromise<GetPreOrderAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: PreOrderGroupByArgs['orderBy'] }
: { orderBy?: PreOrderGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, PreOrderGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetPreOrderGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
customer<T extends CustomerDefaultArgs<ExtArgs> = {}>(args?: Subset<T, CustomerDefaultArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
city<T extends PreOrder$cityArgs<ExtArgs> = {}>(args?: Subset<T, PreOrder$cityArgs<ExtArgs>>): Prisma__CityClient<$Result.GetResult<Prisma.$CityPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
workshop<T extends PreOrder$workshopArgs<ExtArgs> = {}>(args?: Subset<T, PreOrder$workshopArgs<ExtArgs>>): Prisma__WorkshopClient<$Result.GetResult<Prisma.$WorkshopPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
convertedOrder<T extends PreOrder$convertedOrderArgs<ExtArgs> = {}>(args?: Subset<T, PreOrder$convertedOrderArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
statusEvents<T extends PreOrder$statusEventsArgs<ExtArgs> = {}>(args?: Subset<T, PreOrder$statusEventsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
/**
* Filter, which PreOrder to fetch.
*/
where: PreOrderWhereUniqueInput
}
/**
* PreOrder findUniqueOrThrow
*/
export type PreOrderFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
/**
* Filter, which PreOrder to fetch.
*/
where: PreOrderWhereUniqueInput
}
/**
* PreOrder findFirst
*/
export type PreOrderFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
/**
* The data needed to create a PreOrder.
*/
data: XOR<PreOrderCreateInput, PreOrderUncheckedCreateInput>
}
/**
* PreOrder createMany
*/
export type PreOrderCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many PreOrders.
*/
data: PreOrderCreateManyInput | PreOrderCreateManyInput[]
skipDuplicates?: boolean
}
/**
* PreOrder createManyAndReturn
*/
export type PreOrderCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many PreOrders.
*/
data: PreOrderCreateManyInput | PreOrderCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* PreOrder update
*/
export type PreOrderUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
/**
* The data needed to update a PreOrder.
*/
data: XOR<PreOrderUpdateInput, PreOrderUncheckedUpdateInput>
/**
* Choose, which PreOrder to update.
*/
where: PreOrderWhereUniqueInput
}
/**
* PreOrder updateMany
*/
export type PreOrderUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update PreOrders.
*/
data: XOR<PreOrderUpdateManyMutationInput, PreOrderUncheckedUpdateManyInput>
/**
* Filter which PreOrders to update
*/
where?: PreOrderWhereInput
}
/**
* PreOrder upsert
*/
export type PreOrderUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | 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<PreOrderCreateInput, PreOrderUncheckedCreateInput>
/**
* In case the PreOrder was found with the provided `where` argument, update it with this data.
*/
update: XOR<PreOrderUpdateInput, PreOrderUncheckedUpdateInput>
}
/**
* PreOrder delete
*/
export type PreOrderDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | null
/**
* Filter which PreOrder to delete.
*/
where: PreOrderWhereUniqueInput
}
/**
* PreOrder deleteMany
*/
export type PreOrderDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which PreOrders to delete
*/
where?: PreOrderWhereInput
}
/**
* PreOrder.city
*/
export type PreOrder$cityArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the City
*/
select?: CitySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: CityInclude<ExtArgs> | null
where?: CityWhereInput
}
/**
* PreOrder.workshop
*/
export type PreOrder$workshopArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Workshop
*/
select?: WorkshopSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WorkshopInclude<ExtArgs> | null
where?: WorkshopWhereInput
}
/**
* PreOrder.convertedOrder
*/
export type PreOrder$convertedOrderArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
where?: OrderWhereInput
}
/**
* PreOrder.statusEvents
*/
export type PreOrder$statusEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | null
where?: PreOrderStatusEventWhereInput
orderBy?: PreOrderStatusEventOrderByWithRelationInput | PreOrderStatusEventOrderByWithRelationInput[]
cursor?: PreOrderStatusEventWhereUniqueInput
take?: number
skip?: number
distinct?: PreOrderStatusEventScalarFieldEnum | PreOrderStatusEventScalarFieldEnum[]
}
/**
* PreOrder without action
*/
export type PreOrderDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrder
*/
select?: PreOrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends PreOrderStatusEventAggregateArgs> = {
[P in keyof T & keyof AggregatePreOrderStatusEvent]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregatePreOrderStatusEvent[P]>
: GetScalarType<T[P], AggregatePreOrderStatusEvent[P]>
}
export type PreOrderStatusEventGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends PreOrderStatusEventGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<PreOrderStatusEventGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof PreOrderStatusEventGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], PreOrderStatusEventGroupByOutputType[P]>
: GetScalarType<T[P], PreOrderStatusEventGroupByOutputType[P]>
}
>
>
export type PreOrderStatusEventSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
preOrderId?: boolean
changes?: boolean
actorAdminUserId?: boolean
ipAddress?: boolean
createdAt?: boolean
preOrder?: boolean | PreOrderDefaultArgs<ExtArgs>
actorAdminUser?: boolean | PreOrderStatusEvent$actorAdminUserArgs<ExtArgs>
}, ExtArgs["result"]["preOrderStatusEvent"]>
export type PreOrderStatusEventSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
preOrderId?: boolean
changes?: boolean
actorAdminUserId?: boolean
ipAddress?: boolean
createdAt?: boolean
preOrder?: boolean | PreOrderDefaultArgs<ExtArgs>
actorAdminUser?: boolean | PreOrderStatusEvent$actorAdminUserArgs<ExtArgs>
}, ExtArgs["result"]["preOrderStatusEvent"]>
export type PreOrderStatusEventSelectScalar = {
id?: boolean
preOrderId?: boolean
changes?: boolean
actorAdminUserId?: boolean
ipAddress?: boolean
createdAt?: boolean
}
export type PreOrderStatusEventInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
preOrder?: boolean | PreOrderDefaultArgs<ExtArgs>
actorAdminUser?: boolean | PreOrderStatusEvent$actorAdminUserArgs<ExtArgs>
}
export type PreOrderStatusEventIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
preOrder?: boolean | PreOrderDefaultArgs<ExtArgs>
actorAdminUser?: boolean | PreOrderStatusEvent$actorAdminUserArgs<ExtArgs>
}
export type $PreOrderStatusEventPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "PreOrderStatusEvent"
objects: {
preOrder: Prisma.$PreOrderPayload<ExtArgs>
actorAdminUser: Prisma.$AdminUserPayload<ExtArgs> | 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<S extends boolean | null | undefined | PreOrderStatusEventDefaultArgs> = $Result.GetResult<Prisma.$PreOrderStatusEventPayload, S>
type PreOrderStatusEventCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<PreOrderStatusEventFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: PreOrderStatusEventCountAggregateInputType | true
}
export interface PreOrderStatusEventDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends PreOrderStatusEventFindUniqueArgs>(args: SelectSubset<T, PreOrderStatusEventFindUniqueArgs<ExtArgs>>): Prisma__PreOrderStatusEventClient<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventFindUniqueOrThrowArgs>(args: SelectSubset<T, PreOrderStatusEventFindUniqueOrThrowArgs<ExtArgs>>): Prisma__PreOrderStatusEventClient<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventFindFirstArgs>(args?: SelectSubset<T, PreOrderStatusEventFindFirstArgs<ExtArgs>>): Prisma__PreOrderStatusEventClient<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventFindFirstOrThrowArgs>(args?: SelectSubset<T, PreOrderStatusEventFindFirstOrThrowArgs<ExtArgs>>): Prisma__PreOrderStatusEventClient<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventFindManyArgs>(args?: SelectSubset<T, PreOrderStatusEventFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventCreateArgs>(args: SelectSubset<T, PreOrderStatusEventCreateArgs<ExtArgs>>): Prisma__PreOrderStatusEventClient<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventCreateManyArgs>(args?: SelectSubset<T, PreOrderStatusEventCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends PreOrderStatusEventCreateManyAndReturnArgs>(args?: SelectSubset<T, PreOrderStatusEventCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventDeleteArgs>(args: SelectSubset<T, PreOrderStatusEventDeleteArgs<ExtArgs>>): Prisma__PreOrderStatusEventClient<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventUpdateArgs>(args: SelectSubset<T, PreOrderStatusEventUpdateArgs<ExtArgs>>): Prisma__PreOrderStatusEventClient<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventDeleteManyArgs>(args?: SelectSubset<T, PreOrderStatusEventDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends PreOrderStatusEventUpdateManyArgs>(args: SelectSubset<T, PreOrderStatusEventUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends PreOrderStatusEventUpsertArgs>(args: SelectSubset<T, PreOrderStatusEventUpsertArgs<ExtArgs>>): Prisma__PreOrderStatusEventClient<$Result.GetResult<Prisma.$PreOrderStatusEventPayload<ExtArgs>, 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<T extends PreOrderStatusEventCountArgs>(
args?: Subset<T, PreOrderStatusEventCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], PreOrderStatusEventCountAggregateOutputType>
: 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<T extends PreOrderStatusEventAggregateArgs>(args: Subset<T, PreOrderStatusEventAggregateArgs>): Prisma.PrismaPromise<GetPreOrderStatusEventAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: PreOrderStatusEventGroupByArgs['orderBy'] }
: { orderBy?: PreOrderStatusEventGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, PreOrderStatusEventGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetPreOrderStatusEventGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
preOrder<T extends PreOrderDefaultArgs<ExtArgs> = {}>(args?: Subset<T, PreOrderDefaultArgs<ExtArgs>>): Prisma__PreOrderClient<$Result.GetResult<Prisma.$PreOrderPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
actorAdminUser<T extends PreOrderStatusEvent$actorAdminUserArgs<ExtArgs> = {}>(args?: Subset<T, PreOrderStatusEvent$actorAdminUserArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | null
/**
* Filter, which PreOrderStatusEvent to fetch.
*/
where: PreOrderStatusEventWhereUniqueInput
}
/**
* PreOrderStatusEvent findUniqueOrThrow
*/
export type PreOrderStatusEventFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | null
/**
* Filter, which PreOrderStatusEvent to fetch.
*/
where: PreOrderStatusEventWhereUniqueInput
}
/**
* PreOrderStatusEvent findFirst
*/
export type PreOrderStatusEventFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | null
/**
* The data needed to create a PreOrderStatusEvent.
*/
data: XOR<PreOrderStatusEventCreateInput, PreOrderStatusEventUncheckedCreateInput>
}
/**
* PreOrderStatusEvent createMany
*/
export type PreOrderStatusEventCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many PreOrderStatusEvents.
*/
data: PreOrderStatusEventCreateManyInput | PreOrderStatusEventCreateManyInput[]
skipDuplicates?: boolean
}
/**
* PreOrderStatusEvent createManyAndReturn
*/
export type PreOrderStatusEventCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many PreOrderStatusEvents.
*/
data: PreOrderStatusEventCreateManyInput | PreOrderStatusEventCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* PreOrderStatusEvent update
*/
export type PreOrderStatusEventUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | null
/**
* The data needed to update a PreOrderStatusEvent.
*/
data: XOR<PreOrderStatusEventUpdateInput, PreOrderStatusEventUncheckedUpdateInput>
/**
* Choose, which PreOrderStatusEvent to update.
*/
where: PreOrderStatusEventWhereUniqueInput
}
/**
* PreOrderStatusEvent updateMany
*/
export type PreOrderStatusEventUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update PreOrderStatusEvents.
*/
data: XOR<PreOrderStatusEventUpdateManyMutationInput, PreOrderStatusEventUncheckedUpdateManyInput>
/**
* Filter which PreOrderStatusEvents to update
*/
where?: PreOrderStatusEventWhereInput
}
/**
* PreOrderStatusEvent upsert
*/
export type PreOrderStatusEventUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | 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<PreOrderStatusEventCreateInput, PreOrderStatusEventUncheckedCreateInput>
/**
* In case the PreOrderStatusEvent was found with the provided `where` argument, update it with this data.
*/
update: XOR<PreOrderStatusEventUpdateInput, PreOrderStatusEventUncheckedUpdateInput>
}
/**
* PreOrderStatusEvent delete
*/
export type PreOrderStatusEventDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | null
/**
* Filter which PreOrderStatusEvent to delete.
*/
where: PreOrderStatusEventWhereUniqueInput
}
/**
* PreOrderStatusEvent deleteMany
*/
export type PreOrderStatusEventDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which PreOrderStatusEvents to delete
*/
where?: PreOrderStatusEventWhereInput
}
/**
* PreOrderStatusEvent.actorAdminUser
*/
export type PreOrderStatusEvent$actorAdminUserArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
where?: AdminUserWhereInput
}
/**
* PreOrderStatusEvent without action
*/
export type PreOrderStatusEventDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the PreOrderStatusEvent
*/
select?: PreOrderStatusEventSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: PreOrderStatusEventInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends LedgerEntryAggregateArgs> = {
[P in keyof T & keyof AggregateLedgerEntry]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateLedgerEntry[P]>
: GetScalarType<T[P], AggregateLedgerEntry[P]>
}
export type LedgerEntryGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends LedgerEntryGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<LedgerEntryGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof LedgerEntryGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], LedgerEntryGroupByOutputType[P]>
: GetScalarType<T[P], LedgerEntryGroupByOutputType[P]>
}
>
>
export type LedgerEntrySelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs>
order?: boolean | LedgerEntry$orderArgs<ExtArgs>
postedByAdminUser?: boolean | LedgerEntry$postedByAdminUserArgs<ExtArgs>
}, ExtArgs["result"]["ledgerEntry"]>
export type LedgerEntrySelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs>
order?: boolean | LedgerEntry$orderArgs<ExtArgs>
postedByAdminUser?: boolean | LedgerEntry$postedByAdminUserArgs<ExtArgs>
}, 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
order?: boolean | LedgerEntry$orderArgs<ExtArgs>
postedByAdminUser?: boolean | LedgerEntry$postedByAdminUserArgs<ExtArgs>
}
export type LedgerEntryIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
order?: boolean | LedgerEntry$orderArgs<ExtArgs>
postedByAdminUser?: boolean | LedgerEntry$postedByAdminUserArgs<ExtArgs>
}
export type $LedgerEntryPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "LedgerEntry"
objects: {
customer: Prisma.$CustomerPayload<ExtArgs>
order: Prisma.$OrderPayload<ExtArgs> | null
postedByAdminUser: Prisma.$AdminUserPayload<ExtArgs> | 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<S extends boolean | null | undefined | LedgerEntryDefaultArgs> = $Result.GetResult<Prisma.$LedgerEntryPayload, S>
type LedgerEntryCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<LedgerEntryFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: LedgerEntryCountAggregateInputType | true
}
export interface LedgerEntryDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends LedgerEntryFindUniqueArgs>(args: SelectSubset<T, LedgerEntryFindUniqueArgs<ExtArgs>>): Prisma__LedgerEntryClient<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryFindUniqueOrThrowArgs>(args: SelectSubset<T, LedgerEntryFindUniqueOrThrowArgs<ExtArgs>>): Prisma__LedgerEntryClient<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryFindFirstArgs>(args?: SelectSubset<T, LedgerEntryFindFirstArgs<ExtArgs>>): Prisma__LedgerEntryClient<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryFindFirstOrThrowArgs>(args?: SelectSubset<T, LedgerEntryFindFirstOrThrowArgs<ExtArgs>>): Prisma__LedgerEntryClient<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryFindManyArgs>(args?: SelectSubset<T, LedgerEntryFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryCreateArgs>(args: SelectSubset<T, LedgerEntryCreateArgs<ExtArgs>>): Prisma__LedgerEntryClient<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryCreateManyArgs>(args?: SelectSubset<T, LedgerEntryCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends LedgerEntryCreateManyAndReturnArgs>(args?: SelectSubset<T, LedgerEntryCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryDeleteArgs>(args: SelectSubset<T, LedgerEntryDeleteArgs<ExtArgs>>): Prisma__LedgerEntryClient<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryUpdateArgs>(args: SelectSubset<T, LedgerEntryUpdateArgs<ExtArgs>>): Prisma__LedgerEntryClient<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryDeleteManyArgs>(args?: SelectSubset<T, LedgerEntryDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends LedgerEntryUpdateManyArgs>(args: SelectSubset<T, LedgerEntryUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends LedgerEntryUpsertArgs>(args: SelectSubset<T, LedgerEntryUpsertArgs<ExtArgs>>): Prisma__LedgerEntryClient<$Result.GetResult<Prisma.$LedgerEntryPayload<ExtArgs>, 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<T extends LedgerEntryCountArgs>(
args?: Subset<T, LedgerEntryCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], LedgerEntryCountAggregateOutputType>
: 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<T extends LedgerEntryAggregateArgs>(args: Subset<T, LedgerEntryAggregateArgs>): Prisma.PrismaPromise<GetLedgerEntryAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: LedgerEntryGroupByArgs['orderBy'] }
: { orderBy?: LedgerEntryGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, LedgerEntryGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetLedgerEntryGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
customer<T extends CustomerDefaultArgs<ExtArgs> = {}>(args?: Subset<T, CustomerDefaultArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
order<T extends LedgerEntry$orderArgs<ExtArgs> = {}>(args?: Subset<T, LedgerEntry$orderArgs<ExtArgs>>): Prisma__OrderClient<$Result.GetResult<Prisma.$OrderPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
postedByAdminUser<T extends LedgerEntry$postedByAdminUserArgs<ExtArgs> = {}>(args?: Subset<T, LedgerEntry$postedByAdminUserArgs<ExtArgs>>): Prisma__AdminUserClient<$Result.GetResult<Prisma.$AdminUserPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | null
/**
* Filter, which LedgerEntry to fetch.
*/
where: LedgerEntryWhereUniqueInput
}
/**
* LedgerEntry findUniqueOrThrow
*/
export type LedgerEntryFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | null
/**
* Filter, which LedgerEntry to fetch.
*/
where: LedgerEntryWhereUniqueInput
}
/**
* LedgerEntry findFirst
*/
export type LedgerEntryFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | null
/**
* The data needed to create a LedgerEntry.
*/
data: XOR<LedgerEntryCreateInput, LedgerEntryUncheckedCreateInput>
}
/**
* LedgerEntry createMany
*/
export type LedgerEntryCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many LedgerEntries.
*/
data: LedgerEntryCreateManyInput | LedgerEntryCreateManyInput[]
skipDuplicates?: boolean
}
/**
* LedgerEntry createManyAndReturn
*/
export type LedgerEntryCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many LedgerEntries.
*/
data: LedgerEntryCreateManyInput | LedgerEntryCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* LedgerEntry update
*/
export type LedgerEntryUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | null
/**
* The data needed to update a LedgerEntry.
*/
data: XOR<LedgerEntryUpdateInput, LedgerEntryUncheckedUpdateInput>
/**
* Choose, which LedgerEntry to update.
*/
where: LedgerEntryWhereUniqueInput
}
/**
* LedgerEntry updateMany
*/
export type LedgerEntryUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update LedgerEntries.
*/
data: XOR<LedgerEntryUpdateManyMutationInput, LedgerEntryUncheckedUpdateManyInput>
/**
* Filter which LedgerEntries to update
*/
where?: LedgerEntryWhereInput
}
/**
* LedgerEntry upsert
*/
export type LedgerEntryUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | 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<LedgerEntryCreateInput, LedgerEntryUncheckedCreateInput>
/**
* In case the LedgerEntry was found with the provided `where` argument, update it with this data.
*/
update: XOR<LedgerEntryUpdateInput, LedgerEntryUncheckedUpdateInput>
}
/**
* LedgerEntry delete
*/
export type LedgerEntryDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | null
/**
* Filter which LedgerEntry to delete.
*/
where: LedgerEntryWhereUniqueInput
}
/**
* LedgerEntry deleteMany
*/
export type LedgerEntryDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which LedgerEntries to delete
*/
where?: LedgerEntryWhereInput
}
/**
* LedgerEntry.order
*/
export type LedgerEntry$orderArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the Order
*/
select?: OrderSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: OrderInclude<ExtArgs> | null
where?: OrderWhereInput
}
/**
* LedgerEntry.postedByAdminUser
*/
export type LedgerEntry$postedByAdminUserArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the AdminUser
*/
select?: AdminUserSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: AdminUserInclude<ExtArgs> | null
where?: AdminUserWhereInput
}
/**
* LedgerEntry without action
*/
export type LedgerEntryDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the LedgerEntry
*/
select?: LedgerEntrySelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: LedgerEntryInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends GoldPriceQuoteAggregateArgs> = {
[P in keyof T & keyof AggregateGoldPriceQuote]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateGoldPriceQuote[P]>
: GetScalarType<T[P], AggregateGoldPriceQuote[P]>
}
export type GoldPriceQuoteGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends GoldPriceQuoteGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<GoldPriceQuoteGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof GoldPriceQuoteGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], GoldPriceQuoteGroupByOutputType[P]>
: GetScalarType<T[P], GoldPriceQuoteGroupByOutputType[P]>
}
>
>
export type GoldPriceQuoteSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
karatPerMille?: boolean
pricePerGramRial?: boolean
source?: boolean
quotedAt?: boolean
}, ExtArgs["result"]["goldPriceQuote"]>
export type GoldPriceQuoteSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "GoldPriceQuote"
objects: {}
scalars: $Extensions.GetPayloadResult<{
id: string
karatPerMille: number
pricePerGramRial: Prisma.Decimal
source: string
quotedAt: Date
}, ExtArgs["result"]["goldPriceQuote"]>
composites: {}
}
type GoldPriceQuoteGetPayload<S extends boolean | null | undefined | GoldPriceQuoteDefaultArgs> = $Result.GetResult<Prisma.$GoldPriceQuotePayload, S>
type GoldPriceQuoteCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<GoldPriceQuoteFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: GoldPriceQuoteCountAggregateInputType | true
}
export interface GoldPriceQuoteDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends GoldPriceQuoteFindUniqueArgs>(args: SelectSubset<T, GoldPriceQuoteFindUniqueArgs<ExtArgs>>): Prisma__GoldPriceQuoteClient<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteFindUniqueOrThrowArgs>(args: SelectSubset<T, GoldPriceQuoteFindUniqueOrThrowArgs<ExtArgs>>): Prisma__GoldPriceQuoteClient<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteFindFirstArgs>(args?: SelectSubset<T, GoldPriceQuoteFindFirstArgs<ExtArgs>>): Prisma__GoldPriceQuoteClient<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteFindFirstOrThrowArgs>(args?: SelectSubset<T, GoldPriceQuoteFindFirstOrThrowArgs<ExtArgs>>): Prisma__GoldPriceQuoteClient<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteFindManyArgs>(args?: SelectSubset<T, GoldPriceQuoteFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteCreateArgs>(args: SelectSubset<T, GoldPriceQuoteCreateArgs<ExtArgs>>): Prisma__GoldPriceQuoteClient<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteCreateManyArgs>(args?: SelectSubset<T, GoldPriceQuoteCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends GoldPriceQuoteCreateManyAndReturnArgs>(args?: SelectSubset<T, GoldPriceQuoteCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteDeleteArgs>(args: SelectSubset<T, GoldPriceQuoteDeleteArgs<ExtArgs>>): Prisma__GoldPriceQuoteClient<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteUpdateArgs>(args: SelectSubset<T, GoldPriceQuoteUpdateArgs<ExtArgs>>): Prisma__GoldPriceQuoteClient<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteDeleteManyArgs>(args?: SelectSubset<T, GoldPriceQuoteDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends GoldPriceQuoteUpdateManyArgs>(args: SelectSubset<T, GoldPriceQuoteUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends GoldPriceQuoteUpsertArgs>(args: SelectSubset<T, GoldPriceQuoteUpsertArgs<ExtArgs>>): Prisma__GoldPriceQuoteClient<$Result.GetResult<Prisma.$GoldPriceQuotePayload<ExtArgs>, 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<T extends GoldPriceQuoteCountArgs>(
args?: Subset<T, GoldPriceQuoteCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], GoldPriceQuoteCountAggregateOutputType>
: 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<T extends GoldPriceQuoteAggregateArgs>(args: Subset<T, GoldPriceQuoteAggregateArgs>): Prisma.PrismaPromise<GetGoldPriceQuoteAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: GoldPriceQuoteGroupByArgs['orderBy'] }
: { orderBy?: GoldPriceQuoteGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, GoldPriceQuoteGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetGoldPriceQuoteGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | null
/**
* Filter, which GoldPriceQuote to fetch.
*/
where: GoldPriceQuoteWhereUniqueInput
}
/**
* GoldPriceQuote findUniqueOrThrow
*/
export type GoldPriceQuoteFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | null
/**
* Filter, which GoldPriceQuote to fetch.
*/
where: GoldPriceQuoteWhereUniqueInput
}
/**
* GoldPriceQuote findFirst
*/
export type GoldPriceQuoteFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | null
/**
* The data needed to create a GoldPriceQuote.
*/
data: XOR<GoldPriceQuoteCreateInput, GoldPriceQuoteUncheckedCreateInput>
}
/**
* GoldPriceQuote createMany
*/
export type GoldPriceQuoteCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many GoldPriceQuotes.
*/
data: GoldPriceQuoteCreateManyInput | GoldPriceQuoteCreateManyInput[]
skipDuplicates?: boolean
}
/**
* GoldPriceQuote createManyAndReturn
*/
export type GoldPriceQuoteCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many GoldPriceQuotes.
*/
data: GoldPriceQuoteCreateManyInput | GoldPriceQuoteCreateManyInput[]
skipDuplicates?: boolean
}
/**
* GoldPriceQuote update
*/
export type GoldPriceQuoteUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | null
/**
* The data needed to update a GoldPriceQuote.
*/
data: XOR<GoldPriceQuoteUpdateInput, GoldPriceQuoteUncheckedUpdateInput>
/**
* Choose, which GoldPriceQuote to update.
*/
where: GoldPriceQuoteWhereUniqueInput
}
/**
* GoldPriceQuote updateMany
*/
export type GoldPriceQuoteUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update GoldPriceQuotes.
*/
data: XOR<GoldPriceQuoteUpdateManyMutationInput, GoldPriceQuoteUncheckedUpdateManyInput>
/**
* Filter which GoldPriceQuotes to update
*/
where?: GoldPriceQuoteWhereInput
}
/**
* GoldPriceQuote upsert
*/
export type GoldPriceQuoteUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | 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<GoldPriceQuoteCreateInput, GoldPriceQuoteUncheckedCreateInput>
/**
* In case the GoldPriceQuote was found with the provided `where` argument, update it with this data.
*/
update: XOR<GoldPriceQuoteUpdateInput, GoldPriceQuoteUncheckedUpdateInput>
}
/**
* GoldPriceQuote delete
*/
export type GoldPriceQuoteDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | null
/**
* Filter which GoldPriceQuote to delete.
*/
where: GoldPriceQuoteWhereUniqueInput
}
/**
* GoldPriceQuote deleteMany
*/
export type GoldPriceQuoteDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which GoldPriceQuotes to delete
*/
where?: GoldPriceQuoteWhereInput
}
/**
* GoldPriceQuote without action
*/
export type GoldPriceQuoteDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the GoldPriceQuote
*/
select?: GoldPriceQuoteSelect<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* 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<T extends WalletBonusAggregateArgs> = {
[P in keyof T & keyof AggregateWalletBonus]: P extends '_count' | 'count'
? T[P] extends true
? number
: GetScalarType<T[P], AggregateWalletBonus[P]>
: GetScalarType<T[P], AggregateWalletBonus[P]>
}
export type WalletBonusGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
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<T extends WalletBonusGroupByArgs> = Prisma.PrismaPromise<
Array<
PickEnumerable<WalletBonusGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof WalletBonusGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: GetScalarType<T[P], WalletBonusGroupByOutputType[P]>
: GetScalarType<T[P], WalletBonusGroupByOutputType[P]>
}
>
>
export type WalletBonusSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
customerId?: boolean
orderId?: boolean
goldGrams?: boolean
grantedAt?: boolean
expiresAt?: boolean
consumedAt?: boolean
isActive?: boolean
customer?: boolean | CustomerDefaultArgs<ExtArgs>
}, ExtArgs["result"]["walletBonus"]>
export type WalletBonusSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
id?: boolean
customerId?: boolean
orderId?: boolean
goldGrams?: boolean
grantedAt?: boolean
expiresAt?: boolean
consumedAt?: boolean
isActive?: boolean
customer?: boolean | CustomerDefaultArgs<ExtArgs>
}, 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
}
export type WalletBonusIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
customer?: boolean | CustomerDefaultArgs<ExtArgs>
}
export type $WalletBonusPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
name: "WalletBonus"
objects: {
customer: Prisma.$CustomerPayload<ExtArgs>
}
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<S extends boolean | null | undefined | WalletBonusDefaultArgs> = $Result.GetResult<Prisma.$WalletBonusPayload, S>
type WalletBonusCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
Omit<WalletBonusFindManyArgs, 'select' | 'include' | 'distinct'> & {
select?: WalletBonusCountAggregateInputType | true
}
export interface WalletBonusDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['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<T extends WalletBonusFindUniqueArgs>(args: SelectSubset<T, WalletBonusFindUniqueArgs<ExtArgs>>): Prisma__WalletBonusClient<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusFindUniqueOrThrowArgs>(args: SelectSubset<T, WalletBonusFindUniqueOrThrowArgs<ExtArgs>>): Prisma__WalletBonusClient<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusFindFirstArgs>(args?: SelectSubset<T, WalletBonusFindFirstArgs<ExtArgs>>): Prisma__WalletBonusClient<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusFindFirstOrThrowArgs>(args?: SelectSubset<T, WalletBonusFindFirstOrThrowArgs<ExtArgs>>): Prisma__WalletBonusClient<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusFindManyArgs>(args?: SelectSubset<T, WalletBonusFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusCreateArgs>(args: SelectSubset<T, WalletBonusCreateArgs<ExtArgs>>): Prisma__WalletBonusClient<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusCreateManyArgs>(args?: SelectSubset<T, WalletBonusCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends WalletBonusCreateManyAndReturnArgs>(args?: SelectSubset<T, WalletBonusCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusDeleteArgs>(args: SelectSubset<T, WalletBonusDeleteArgs<ExtArgs>>): Prisma__WalletBonusClient<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusUpdateArgs>(args: SelectSubset<T, WalletBonusUpdateArgs<ExtArgs>>): Prisma__WalletBonusClient<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusDeleteManyArgs>(args?: SelectSubset<T, WalletBonusDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends WalletBonusUpdateManyArgs>(args: SelectSubset<T, WalletBonusUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
/**
* 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<T extends WalletBonusUpsertArgs>(args: SelectSubset<T, WalletBonusUpsertArgs<ExtArgs>>): Prisma__WalletBonusClient<$Result.GetResult<Prisma.$WalletBonusPayload<ExtArgs>, 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<T extends WalletBonusCountArgs>(
args?: Subset<T, WalletBonusCountArgs>,
): Prisma.PrismaPromise<
T extends $Utils.Record<'select', any>
? T['select'] extends true
? number
: GetScalarType<T['select'], WalletBonusCountAggregateOutputType>
: 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<T extends WalletBonusAggregateArgs>(args: Subset<T, WalletBonusAggregateArgs>): Prisma.PrismaPromise<GetWalletBonusAggregateType<T>>
/**
* 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<T>>,
Extends<'take', Keys<T>>
>,
OrderByArg extends True extends HasSelectOrTake
? { orderBy: WalletBonusGroupByArgs['orderBy'] }
: { orderBy?: WalletBonusGroupByArgs['orderBy'] },
OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
ByFields extends MaybeTupleToUnion<T['by']>,
ByValid extends Has<ByFields, OrderFields>,
HavingFields extends GetHavingFields<T['having']>,
HavingValid extends Has<ByFields, HavingFields>,
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<T>
? 'orderBy' extends Keys<T>
? 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<T>
? 'orderBy' extends Keys<T>
? 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<T, WalletBonusGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetWalletBonusGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* 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<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
readonly [Symbol.toStringTag]: "PrismaPromise"
customer<T extends CustomerDefaultArgs<ExtArgs> = {}>(args?: Subset<T, CustomerDefaultArgs<ExtArgs>>): Prisma__CustomerClient<$Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, 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<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
/**
* 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<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
/**
* 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<T>
}
/**
* 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | null
/**
* Filter, which WalletBonus to fetch.
*/
where: WalletBonusWhereUniqueInput
}
/**
* WalletBonus findUniqueOrThrow
*/
export type WalletBonusFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | null
/**
* Filter, which WalletBonus to fetch.
*/
where: WalletBonusWhereUniqueInput
}
/**
* WalletBonus findFirst
*/
export type WalletBonusFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | 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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | null
/**
* The data needed to create a WalletBonus.
*/
data: XOR<WalletBonusCreateInput, WalletBonusUncheckedCreateInput>
}
/**
* WalletBonus createMany
*/
export type WalletBonusCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to create many WalletBonuses.
*/
data: WalletBonusCreateManyInput | WalletBonusCreateManyInput[]
skipDuplicates?: boolean
}
/**
* WalletBonus createManyAndReturn
*/
export type WalletBonusCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelectCreateManyAndReturn<ExtArgs> | null
/**
* The data used to create many WalletBonuses.
*/
data: WalletBonusCreateManyInput | WalletBonusCreateManyInput[]
skipDuplicates?: boolean
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusIncludeCreateManyAndReturn<ExtArgs> | null
}
/**
* WalletBonus update
*/
export type WalletBonusUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | null
/**
* The data needed to update a WalletBonus.
*/
data: XOR<WalletBonusUpdateInput, WalletBonusUncheckedUpdateInput>
/**
* Choose, which WalletBonus to update.
*/
where: WalletBonusWhereUniqueInput
}
/**
* WalletBonus updateMany
*/
export type WalletBonusUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* The data used to update WalletBonuses.
*/
data: XOR<WalletBonusUpdateManyMutationInput, WalletBonusUncheckedUpdateManyInput>
/**
* Filter which WalletBonuses to update
*/
where?: WalletBonusWhereInput
}
/**
* WalletBonus upsert
*/
export type WalletBonusUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | 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<WalletBonusCreateInput, WalletBonusUncheckedCreateInput>
/**
* In case the WalletBonus was found with the provided `where` argument, update it with this data.
*/
update: XOR<WalletBonusUpdateInput, WalletBonusUncheckedUpdateInput>
}
/**
* WalletBonus delete
*/
export type WalletBonusDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | null
/**
* Filter which WalletBonus to delete.
*/
where: WalletBonusWhereUniqueInput
}
/**
* WalletBonus deleteMany
*/
export type WalletBonusDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Filter which WalletBonuses to delete
*/
where?: WalletBonusWhereInput
}
/**
* WalletBonus without action
*/
export type WalletBonusDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the WalletBonus
*/
select?: WalletBonusSelect<ExtArgs> | null
/**
* Choose, which related nodes to fetch as well
*/
include?: WalletBonusInclude<ExtArgs> | 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<BranchNullableRelationFilter, BranchWhereInput> | 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<BranchNullableRelationFilter, BranchWhereInput> | 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<CityNullableRelationFilter, CityWhereInput> | null
referredByAgent?: XOR<AdminUserNullableRelationFilter, AdminUserWhereInput> | 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<CityNullableRelationFilter, CityWhereInput> | null
referredByAgent?: XOR<AdminUserNullableRelationFilter, AdminUserWhereInput> | 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<CustomerRelationFilter, CustomerWhereInput>
city?: XOR<CityNullableRelationFilter, CityWhereInput> | 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<CustomerRelationFilter, CustomerWhereInput>
city?: XOR<CityNullableRelationFilter, CityWhereInput> | 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<CityNullableRelationFilter, CityWhereInput> | 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<CityNullableRelationFilter, CityWhereInput> | 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<CategoryNullableRelationFilter, CategoryWhereInput> | 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<CategoryNullableRelationFilter, CategoryWhereInput> | 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<CollectionRelationFilter, CollectionWhereInput>
product?: XOR<ProductRelationFilter, ProductWhereInput>
}
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<CollectionRelationFilter, CollectionWhereInput>
product?: XOR<ProductRelationFilter, ProductWhereInput>
}, "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<CategoryNullableRelationFilter, CategoryWhereInput> | null
brand?: XOR<BrandNullableRelationFilter, BrandWhereInput> | 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<CategoryNullableRelationFilter, CategoryWhereInput> | null
brand?: XOR<BrandNullableRelationFilter, BrandWhereInput> | 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<ProductRelationFilter, ProductWhereInput>
}
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<ProductRelationFilter, ProductWhereInput>
}, "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<ProductRelationFilter, ProductWhereInput>
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<ProductRelationFilter, ProductWhereInput>
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<CustomerRelationFilter, CustomerWhereInput>
branch?: XOR<BranchNullableRelationFilter, BranchWhereInput> | null
items?: OrderItemListRelationFilter
statusEvents?: OrderStatusEventListRelationFilter
ledgerEntries?: LedgerEntryListRelationFilter
convertedFromPreOrder?: XOR<PreOrderNullableRelationFilter, PreOrderWhereInput> | 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<CustomerRelationFilter, CustomerWhereInput>
branch?: XOR<BranchNullableRelationFilter, BranchWhereInput> | null
items?: OrderItemListRelationFilter
statusEvents?: OrderStatusEventListRelationFilter
ledgerEntries?: LedgerEntryListRelationFilter
convertedFromPreOrder?: XOR<PreOrderNullableRelationFilter, PreOrderWhereInput> | 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<OrderRelationFilter, OrderWhereInput>
productVariant?: XOR<ProductVariantRelationFilter, ProductVariantWhereInput>
}
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<OrderRelationFilter, OrderWhereInput>
productVariant?: XOR<ProductVariantRelationFilter, ProductVariantWhereInput>
}, "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<OrderRelationFilter, OrderWhereInput>
actorAdminUser?: XOR<AdminUserNullableRelationFilter, AdminUserWhereInput> | 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<OrderRelationFilter, OrderWhereInput>
actorAdminUser?: XOR<AdminUserNullableRelationFilter, AdminUserWhereInput> | 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<CustomerRelationFilter, CustomerWhereInput>
city?: XOR<CityNullableRelationFilter, CityWhereInput> | null
workshop?: XOR<WorkshopNullableRelationFilter, WorkshopWhereInput> | null
convertedOrder?: XOR<OrderNullableRelationFilter, OrderWhereInput> | 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<CustomerRelationFilter, CustomerWhereInput>
city?: XOR<CityNullableRelationFilter, CityWhereInput> | null
workshop?: XOR<WorkshopNullableRelationFilter, WorkshopWhereInput> | null
convertedOrder?: XOR<OrderNullableRelationFilter, OrderWhereInput> | 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<PreOrderRelationFilter, PreOrderWhereInput>
actorAdminUser?: XOR<AdminUserNullableRelationFilter, AdminUserWhereInput> | 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<PreOrderRelationFilter, PreOrderWhereInput>
actorAdminUser?: XOR<AdminUserNullableRelationFilter, AdminUserWhereInput> | 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<CustomerRelationFilter, CustomerWhereInput>
order?: XOR<OrderNullableRelationFilter, OrderWhereInput> | null
postedByAdminUser?: XOR<AdminUserNullableRelationFilter, AdminUserWhereInput> | 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<CustomerRelationFilter, CustomerWhereInput>
order?: XOR<OrderNullableRelationFilter, OrderWhereInput> | null
postedByAdminUser?: XOR<AdminUserNullableRelationFilter, AdminUserWhereInput> | 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<CustomerRelationFilter, CustomerWhereInput>
}
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<CustomerRelationFilter, CustomerWhereInput>
}, "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<Required<JsonFilterBase<$PrismaModel>>, Exclude<keyof Required<JsonFilterBase<$PrismaModel>>, 'path'>>,
Required<JsonFilterBase<$PrismaModel>>
>
| OptionalFlat<Omit<Required<JsonFilterBase<$PrismaModel>>, '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<Required<JsonWithAggregatesFilterBase<$PrismaModel>>, Exclude<keyof Required<JsonWithAggregatesFilterBase<$PrismaModel>>, 'path'>>,
Required<JsonWithAggregatesFilterBase<$PrismaModel>>
>
| OptionalFlat<Omit<Required<JsonWithAggregatesFilterBase<$PrismaModel>>, '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> | CustomerCreateWithoutCityInput[] | CustomerUncheckedCreateWithoutCityInput[]
connectOrCreate?: CustomerCreateOrConnectWithoutCityInput | CustomerCreateOrConnectWithoutCityInput[]
createMany?: CustomerCreateManyCityInputEnvelope
connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[]
}
export type CustomerAddressCreateNestedManyWithoutCityInput = {
create?: XOR<CustomerAddressCreateWithoutCityInput, CustomerAddressUncheckedCreateWithoutCityInput> | CustomerAddressCreateWithoutCityInput[] | CustomerAddressUncheckedCreateWithoutCityInput[]
connectOrCreate?: CustomerAddressCreateOrConnectWithoutCityInput | CustomerAddressCreateOrConnectWithoutCityInput[]
createMany?: CustomerAddressCreateManyCityInputEnvelope
connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[]
}
export type BranchCreateNestedManyWithoutCityInput = {
create?: XOR<BranchCreateWithoutCityInput, BranchUncheckedCreateWithoutCityInput> | BranchCreateWithoutCityInput[] | BranchUncheckedCreateWithoutCityInput[]
connectOrCreate?: BranchCreateOrConnectWithoutCityInput | BranchCreateOrConnectWithoutCityInput[]
createMany?: BranchCreateManyCityInputEnvelope
connect?: BranchWhereUniqueInput | BranchWhereUniqueInput[]
}
export type PreOrderCreateNestedManyWithoutCityInput = {
create?: XOR<PreOrderCreateWithoutCityInput, PreOrderUncheckedCreateWithoutCityInput> | PreOrderCreateWithoutCityInput[] | PreOrderUncheckedCreateWithoutCityInput[]
connectOrCreate?: PreOrderCreateOrConnectWithoutCityInput | PreOrderCreateOrConnectWithoutCityInput[]
createMany?: PreOrderCreateManyCityInputEnvelope
connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[]
}
export type CustomerUncheckedCreateNestedManyWithoutCityInput = {
create?: XOR<CustomerCreateWithoutCityInput, CustomerUncheckedCreateWithoutCityInput> | CustomerCreateWithoutCityInput[] | CustomerUncheckedCreateWithoutCityInput[]
connectOrCreate?: CustomerCreateOrConnectWithoutCityInput | CustomerCreateOrConnectWithoutCityInput[]
createMany?: CustomerCreateManyCityInputEnvelope
connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[]
}
export type CustomerAddressUncheckedCreateNestedManyWithoutCityInput = {
create?: XOR<CustomerAddressCreateWithoutCityInput, CustomerAddressUncheckedCreateWithoutCityInput> | CustomerAddressCreateWithoutCityInput[] | CustomerAddressUncheckedCreateWithoutCityInput[]
connectOrCreate?: CustomerAddressCreateOrConnectWithoutCityInput | CustomerAddressCreateOrConnectWithoutCityInput[]
createMany?: CustomerAddressCreateManyCityInputEnvelope
connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[]
}
export type BranchUncheckedCreateNestedManyWithoutCityInput = {
create?: XOR<BranchCreateWithoutCityInput, BranchUncheckedCreateWithoutCityInput> | BranchCreateWithoutCityInput[] | BranchUncheckedCreateWithoutCityInput[]
connectOrCreate?: BranchCreateOrConnectWithoutCityInput | BranchCreateOrConnectWithoutCityInput[]
createMany?: BranchCreateManyCityInputEnvelope
connect?: BranchWhereUniqueInput | BranchWhereUniqueInput[]
}
export type PreOrderUncheckedCreateNestedManyWithoutCityInput = {
create?: XOR<PreOrderCreateWithoutCityInput, PreOrderUncheckedCreateWithoutCityInput> | 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> | 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> | 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> | 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> | 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> | 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> | 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> | 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> | 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<BranchCreateWithoutAdminUsersInput, BranchUncheckedCreateWithoutAdminUsersInput>
connectOrCreate?: BranchCreateOrConnectWithoutAdminUsersInput
connect?: BranchWhereUniqueInput
}
export type CustomerCreateNestedManyWithoutReferredByAgentInput = {
create?: XOR<CustomerCreateWithoutReferredByAgentInput, CustomerUncheckedCreateWithoutReferredByAgentInput> | CustomerCreateWithoutReferredByAgentInput[] | CustomerUncheckedCreateWithoutReferredByAgentInput[]
connectOrCreate?: CustomerCreateOrConnectWithoutReferredByAgentInput | CustomerCreateOrConnectWithoutReferredByAgentInput[]
createMany?: CustomerCreateManyReferredByAgentInputEnvelope
connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[]
}
export type LedgerEntryCreateNestedManyWithoutPostedByAdminUserInput = {
create?: XOR<LedgerEntryCreateWithoutPostedByAdminUserInput, LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput> | LedgerEntryCreateWithoutPostedByAdminUserInput[] | LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput[]
connectOrCreate?: LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput | LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput[]
createMany?: LedgerEntryCreateManyPostedByAdminUserInputEnvelope
connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[]
}
export type OrderStatusEventCreateNestedManyWithoutActorAdminUserInput = {
create?: XOR<OrderStatusEventCreateWithoutActorAdminUserInput, OrderStatusEventUncheckedCreateWithoutActorAdminUserInput> | OrderStatusEventCreateWithoutActorAdminUserInput[] | OrderStatusEventUncheckedCreateWithoutActorAdminUserInput[]
connectOrCreate?: OrderStatusEventCreateOrConnectWithoutActorAdminUserInput | OrderStatusEventCreateOrConnectWithoutActorAdminUserInput[]
createMany?: OrderStatusEventCreateManyActorAdminUserInputEnvelope
connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[]
}
export type PreOrderStatusEventCreateNestedManyWithoutActorAdminUserInput = {
create?: XOR<PreOrderStatusEventCreateWithoutActorAdminUserInput, PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput> | PreOrderStatusEventCreateWithoutActorAdminUserInput[] | PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput[]
connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput | PreOrderStatusEventCreateOrConnectWithoutActorAdminUserInput[]
createMany?: PreOrderStatusEventCreateManyActorAdminUserInputEnvelope
connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[]
}
export type CustomerUncheckedCreateNestedManyWithoutReferredByAgentInput = {
create?: XOR<CustomerCreateWithoutReferredByAgentInput, CustomerUncheckedCreateWithoutReferredByAgentInput> | CustomerCreateWithoutReferredByAgentInput[] | CustomerUncheckedCreateWithoutReferredByAgentInput[]
connectOrCreate?: CustomerCreateOrConnectWithoutReferredByAgentInput | CustomerCreateOrConnectWithoutReferredByAgentInput[]
createMany?: CustomerCreateManyReferredByAgentInputEnvelope
connect?: CustomerWhereUniqueInput | CustomerWhereUniqueInput[]
}
export type LedgerEntryUncheckedCreateNestedManyWithoutPostedByAdminUserInput = {
create?: XOR<LedgerEntryCreateWithoutPostedByAdminUserInput, LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput> | LedgerEntryCreateWithoutPostedByAdminUserInput[] | LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput[]
connectOrCreate?: LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput | LedgerEntryCreateOrConnectWithoutPostedByAdminUserInput[]
createMany?: LedgerEntryCreateManyPostedByAdminUserInputEnvelope
connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[]
}
export type OrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput = {
create?: XOR<OrderStatusEventCreateWithoutActorAdminUserInput, OrderStatusEventUncheckedCreateWithoutActorAdminUserInput> | OrderStatusEventCreateWithoutActorAdminUserInput[] | OrderStatusEventUncheckedCreateWithoutActorAdminUserInput[]
connectOrCreate?: OrderStatusEventCreateOrConnectWithoutActorAdminUserInput | OrderStatusEventCreateOrConnectWithoutActorAdminUserInput[]
createMany?: OrderStatusEventCreateManyActorAdminUserInputEnvelope
connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[]
}
export type PreOrderStatusEventUncheckedCreateNestedManyWithoutActorAdminUserInput = {
create?: XOR<PreOrderStatusEventCreateWithoutActorAdminUserInput, PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput> | 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<BranchCreateWithoutAdminUsersInput, BranchUncheckedCreateWithoutAdminUsersInput>
connectOrCreate?: BranchCreateOrConnectWithoutAdminUsersInput
upsert?: BranchUpsertWithoutAdminUsersInput
disconnect?: BranchWhereInput | boolean
delete?: BranchWhereInput | boolean
connect?: BranchWhereUniqueInput
update?: XOR<XOR<BranchUpdateToOneWithWhereWithoutAdminUsersInput, BranchUpdateWithoutAdminUsersInput>, BranchUncheckedUpdateWithoutAdminUsersInput>
}
export type CustomerUpdateManyWithoutReferredByAgentNestedInput = {
create?: XOR<CustomerCreateWithoutReferredByAgentInput, CustomerUncheckedCreateWithoutReferredByAgentInput> | 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> | 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> | 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> | 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> | 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> | 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> | 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> | 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<CityCreateWithoutCustomersInput, CityUncheckedCreateWithoutCustomersInput>
connectOrCreate?: CityCreateOrConnectWithoutCustomersInput
connect?: CityWhereUniqueInput
}
export type AdminUserCreateNestedOneWithoutReferredCustomersInput = {
create?: XOR<AdminUserCreateWithoutReferredCustomersInput, AdminUserUncheckedCreateWithoutReferredCustomersInput>
connectOrCreate?: AdminUserCreateOrConnectWithoutReferredCustomersInput
connect?: AdminUserWhereUniqueInput
}
export type CustomerAddressCreateNestedManyWithoutCustomerInput = {
create?: XOR<CustomerAddressCreateWithoutCustomerInput, CustomerAddressUncheckedCreateWithoutCustomerInput> | CustomerAddressCreateWithoutCustomerInput[] | CustomerAddressUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: CustomerAddressCreateOrConnectWithoutCustomerInput | CustomerAddressCreateOrConnectWithoutCustomerInput[]
createMany?: CustomerAddressCreateManyCustomerInputEnvelope
connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[]
}
export type OrderCreateNestedManyWithoutCustomerInput = {
create?: XOR<OrderCreateWithoutCustomerInput, OrderUncheckedCreateWithoutCustomerInput> | OrderCreateWithoutCustomerInput[] | OrderUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: OrderCreateOrConnectWithoutCustomerInput | OrderCreateOrConnectWithoutCustomerInput[]
createMany?: OrderCreateManyCustomerInputEnvelope
connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[]
}
export type PreOrderCreateNestedManyWithoutCustomerInput = {
create?: XOR<PreOrderCreateWithoutCustomerInput, PreOrderUncheckedCreateWithoutCustomerInput> | PreOrderCreateWithoutCustomerInput[] | PreOrderUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: PreOrderCreateOrConnectWithoutCustomerInput | PreOrderCreateOrConnectWithoutCustomerInput[]
createMany?: PreOrderCreateManyCustomerInputEnvelope
connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[]
}
export type LedgerEntryCreateNestedManyWithoutCustomerInput = {
create?: XOR<LedgerEntryCreateWithoutCustomerInput, LedgerEntryUncheckedCreateWithoutCustomerInput> | LedgerEntryCreateWithoutCustomerInput[] | LedgerEntryUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: LedgerEntryCreateOrConnectWithoutCustomerInput | LedgerEntryCreateOrConnectWithoutCustomerInput[]
createMany?: LedgerEntryCreateManyCustomerInputEnvelope
connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[]
}
export type WalletBonusCreateNestedManyWithoutCustomerInput = {
create?: XOR<WalletBonusCreateWithoutCustomerInput, WalletBonusUncheckedCreateWithoutCustomerInput> | WalletBonusCreateWithoutCustomerInput[] | WalletBonusUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: WalletBonusCreateOrConnectWithoutCustomerInput | WalletBonusCreateOrConnectWithoutCustomerInput[]
createMany?: WalletBonusCreateManyCustomerInputEnvelope
connect?: WalletBonusWhereUniqueInput | WalletBonusWhereUniqueInput[]
}
export type CustomerAddressUncheckedCreateNestedManyWithoutCustomerInput = {
create?: XOR<CustomerAddressCreateWithoutCustomerInput, CustomerAddressUncheckedCreateWithoutCustomerInput> | CustomerAddressCreateWithoutCustomerInput[] | CustomerAddressUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: CustomerAddressCreateOrConnectWithoutCustomerInput | CustomerAddressCreateOrConnectWithoutCustomerInput[]
createMany?: CustomerAddressCreateManyCustomerInputEnvelope
connect?: CustomerAddressWhereUniqueInput | CustomerAddressWhereUniqueInput[]
}
export type OrderUncheckedCreateNestedManyWithoutCustomerInput = {
create?: XOR<OrderCreateWithoutCustomerInput, OrderUncheckedCreateWithoutCustomerInput> | OrderCreateWithoutCustomerInput[] | OrderUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: OrderCreateOrConnectWithoutCustomerInput | OrderCreateOrConnectWithoutCustomerInput[]
createMany?: OrderCreateManyCustomerInputEnvelope
connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[]
}
export type PreOrderUncheckedCreateNestedManyWithoutCustomerInput = {
create?: XOR<PreOrderCreateWithoutCustomerInput, PreOrderUncheckedCreateWithoutCustomerInput> | PreOrderCreateWithoutCustomerInput[] | PreOrderUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: PreOrderCreateOrConnectWithoutCustomerInput | PreOrderCreateOrConnectWithoutCustomerInput[]
createMany?: PreOrderCreateManyCustomerInputEnvelope
connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[]
}
export type LedgerEntryUncheckedCreateNestedManyWithoutCustomerInput = {
create?: XOR<LedgerEntryCreateWithoutCustomerInput, LedgerEntryUncheckedCreateWithoutCustomerInput> | LedgerEntryCreateWithoutCustomerInput[] | LedgerEntryUncheckedCreateWithoutCustomerInput[]
connectOrCreate?: LedgerEntryCreateOrConnectWithoutCustomerInput | LedgerEntryCreateOrConnectWithoutCustomerInput[]
createMany?: LedgerEntryCreateManyCustomerInputEnvelope
connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[]
}
export type WalletBonusUncheckedCreateNestedManyWithoutCustomerInput = {
create?: XOR<WalletBonusCreateWithoutCustomerInput, WalletBonusUncheckedCreateWithoutCustomerInput> | 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<CityCreateWithoutCustomersInput, CityUncheckedCreateWithoutCustomersInput>
connectOrCreate?: CityCreateOrConnectWithoutCustomersInput
upsert?: CityUpsertWithoutCustomersInput
disconnect?: CityWhereInput | boolean
delete?: CityWhereInput | boolean
connect?: CityWhereUniqueInput
update?: XOR<XOR<CityUpdateToOneWithWhereWithoutCustomersInput, CityUpdateWithoutCustomersInput>, CityUncheckedUpdateWithoutCustomersInput>
}
export type AdminUserUpdateOneWithoutReferredCustomersNestedInput = {
create?: XOR<AdminUserCreateWithoutReferredCustomersInput, AdminUserUncheckedCreateWithoutReferredCustomersInput>
connectOrCreate?: AdminUserCreateOrConnectWithoutReferredCustomersInput
upsert?: AdminUserUpsertWithoutReferredCustomersInput
disconnect?: AdminUserWhereInput | boolean
delete?: AdminUserWhereInput | boolean
connect?: AdminUserWhereUniqueInput
update?: XOR<XOR<AdminUserUpdateToOneWithWhereWithoutReferredCustomersInput, AdminUserUpdateWithoutReferredCustomersInput>, AdminUserUncheckedUpdateWithoutReferredCustomersInput>
}
export type CustomerAddressUpdateManyWithoutCustomerNestedInput = {
create?: XOR<CustomerAddressCreateWithoutCustomerInput, CustomerAddressUncheckedCreateWithoutCustomerInput> | 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> | 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> | 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> | 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> | 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> | 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> | 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> | 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> | 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> | 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<CustomerCreateWithoutAddressesInput, CustomerUncheckedCreateWithoutAddressesInput>
connectOrCreate?: CustomerCreateOrConnectWithoutAddressesInput
connect?: CustomerWhereUniqueInput
}
export type CityCreateNestedOneWithoutAddressesInput = {
create?: XOR<CityCreateWithoutAddressesInput, CityUncheckedCreateWithoutAddressesInput>
connectOrCreate?: CityCreateOrConnectWithoutAddressesInput
connect?: CityWhereUniqueInput
}
export type CustomerUpdateOneRequiredWithoutAddressesNestedInput = {
create?: XOR<CustomerCreateWithoutAddressesInput, CustomerUncheckedCreateWithoutAddressesInput>
connectOrCreate?: CustomerCreateOrConnectWithoutAddressesInput
upsert?: CustomerUpsertWithoutAddressesInput
connect?: CustomerWhereUniqueInput
update?: XOR<XOR<CustomerUpdateToOneWithWhereWithoutAddressesInput, CustomerUpdateWithoutAddressesInput>, CustomerUncheckedUpdateWithoutAddressesInput>
}
export type CityUpdateOneWithoutAddressesNestedInput = {
create?: XOR<CityCreateWithoutAddressesInput, CityUncheckedCreateWithoutAddressesInput>
connectOrCreate?: CityCreateOrConnectWithoutAddressesInput
upsert?: CityUpsertWithoutAddressesInput
disconnect?: CityWhereInput | boolean
delete?: CityWhereInput | boolean
connect?: CityWhereUniqueInput
update?: XOR<XOR<CityUpdateToOneWithWhereWithoutAddressesInput, CityUpdateWithoutAddressesInput>, CityUncheckedUpdateWithoutAddressesInput>
}
export type CityCreateNestedOneWithoutBranchesInput = {
create?: XOR<CityCreateWithoutBranchesInput, CityUncheckedCreateWithoutBranchesInput>
connectOrCreate?: CityCreateOrConnectWithoutBranchesInput
connect?: CityWhereUniqueInput
}
export type AdminUserCreateNestedManyWithoutBranchInput = {
create?: XOR<AdminUserCreateWithoutBranchInput, AdminUserUncheckedCreateWithoutBranchInput> | AdminUserCreateWithoutBranchInput[] | AdminUserUncheckedCreateWithoutBranchInput[]
connectOrCreate?: AdminUserCreateOrConnectWithoutBranchInput | AdminUserCreateOrConnectWithoutBranchInput[]
createMany?: AdminUserCreateManyBranchInputEnvelope
connect?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[]
}
export type OrderCreateNestedManyWithoutBranchInput = {
create?: XOR<OrderCreateWithoutBranchInput, OrderUncheckedCreateWithoutBranchInput> | OrderCreateWithoutBranchInput[] | OrderUncheckedCreateWithoutBranchInput[]
connectOrCreate?: OrderCreateOrConnectWithoutBranchInput | OrderCreateOrConnectWithoutBranchInput[]
createMany?: OrderCreateManyBranchInputEnvelope
connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[]
}
export type AdminUserUncheckedCreateNestedManyWithoutBranchInput = {
create?: XOR<AdminUserCreateWithoutBranchInput, AdminUserUncheckedCreateWithoutBranchInput> | AdminUserCreateWithoutBranchInput[] | AdminUserUncheckedCreateWithoutBranchInput[]
connectOrCreate?: AdminUserCreateOrConnectWithoutBranchInput | AdminUserCreateOrConnectWithoutBranchInput[]
createMany?: AdminUserCreateManyBranchInputEnvelope
connect?: AdminUserWhereUniqueInput | AdminUserWhereUniqueInput[]
}
export type OrderUncheckedCreateNestedManyWithoutBranchInput = {
create?: XOR<OrderCreateWithoutBranchInput, OrderUncheckedCreateWithoutBranchInput> | OrderCreateWithoutBranchInput[] | OrderUncheckedCreateWithoutBranchInput[]
connectOrCreate?: OrderCreateOrConnectWithoutBranchInput | OrderCreateOrConnectWithoutBranchInput[]
createMany?: OrderCreateManyBranchInputEnvelope
connect?: OrderWhereUniqueInput | OrderWhereUniqueInput[]
}
export type CityUpdateOneWithoutBranchesNestedInput = {
create?: XOR<CityCreateWithoutBranchesInput, CityUncheckedCreateWithoutBranchesInput>
connectOrCreate?: CityCreateOrConnectWithoutBranchesInput
upsert?: CityUpsertWithoutBranchesInput
disconnect?: CityWhereInput | boolean
delete?: CityWhereInput | boolean
connect?: CityWhereUniqueInput
update?: XOR<XOR<CityUpdateToOneWithWhereWithoutBranchesInput, CityUpdateWithoutBranchesInput>, CityUncheckedUpdateWithoutBranchesInput>
}
export type AdminUserUpdateManyWithoutBranchNestedInput = {
create?: XOR<AdminUserCreateWithoutBranchInput, AdminUserUncheckedCreateWithoutBranchInput> | 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> | 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> | 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> | 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> | PreOrderCreateWithoutWorkshopInput[] | PreOrderUncheckedCreateWithoutWorkshopInput[]
connectOrCreate?: PreOrderCreateOrConnectWithoutWorkshopInput | PreOrderCreateOrConnectWithoutWorkshopInput[]
createMany?: PreOrderCreateManyWorkshopInputEnvelope
connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[]
}
export type PreOrderUncheckedCreateNestedManyWithoutWorkshopInput = {
create?: XOR<PreOrderCreateWithoutWorkshopInput, PreOrderUncheckedCreateWithoutWorkshopInput> | PreOrderCreateWithoutWorkshopInput[] | PreOrderUncheckedCreateWithoutWorkshopInput[]
connectOrCreate?: PreOrderCreateOrConnectWithoutWorkshopInput | PreOrderCreateOrConnectWithoutWorkshopInput[]
createMany?: PreOrderCreateManyWorkshopInputEnvelope
connect?: PreOrderWhereUniqueInput | PreOrderWhereUniqueInput[]
}
export type PreOrderUpdateManyWithoutWorkshopNestedInput = {
create?: XOR<PreOrderCreateWithoutWorkshopInput, PreOrderUncheckedCreateWithoutWorkshopInput> | 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> | 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<CategoryCreateWithoutChildrenInput, CategoryUncheckedCreateWithoutChildrenInput>
connectOrCreate?: CategoryCreateOrConnectWithoutChildrenInput
connect?: CategoryWhereUniqueInput
}
export type CategoryCreateNestedManyWithoutParentInput = {
create?: XOR<CategoryCreateWithoutParentInput, CategoryUncheckedCreateWithoutParentInput> | CategoryCreateWithoutParentInput[] | CategoryUncheckedCreateWithoutParentInput[]
connectOrCreate?: CategoryCreateOrConnectWithoutParentInput | CategoryCreateOrConnectWithoutParentInput[]
createMany?: CategoryCreateManyParentInputEnvelope
connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
}
export type ProductCreateNestedManyWithoutCategoryInput = {
create?: XOR<ProductCreateWithoutCategoryInput, ProductUncheckedCreateWithoutCategoryInput> | ProductCreateWithoutCategoryInput[] | ProductUncheckedCreateWithoutCategoryInput[]
connectOrCreate?: ProductCreateOrConnectWithoutCategoryInput | ProductCreateOrConnectWithoutCategoryInput[]
createMany?: ProductCreateManyCategoryInputEnvelope
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
}
export type CategoryUncheckedCreateNestedManyWithoutParentInput = {
create?: XOR<CategoryCreateWithoutParentInput, CategoryUncheckedCreateWithoutParentInput> | CategoryCreateWithoutParentInput[] | CategoryUncheckedCreateWithoutParentInput[]
connectOrCreate?: CategoryCreateOrConnectWithoutParentInput | CategoryCreateOrConnectWithoutParentInput[]
createMany?: CategoryCreateManyParentInputEnvelope
connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
}
export type ProductUncheckedCreateNestedManyWithoutCategoryInput = {
create?: XOR<ProductCreateWithoutCategoryInput, ProductUncheckedCreateWithoutCategoryInput> | ProductCreateWithoutCategoryInput[] | ProductUncheckedCreateWithoutCategoryInput[]
connectOrCreate?: ProductCreateOrConnectWithoutCategoryInput | ProductCreateOrConnectWithoutCategoryInput[]
createMany?: ProductCreateManyCategoryInputEnvelope
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
}
export type CategoryUpdateOneWithoutChildrenNestedInput = {
create?: XOR<CategoryCreateWithoutChildrenInput, CategoryUncheckedCreateWithoutChildrenInput>
connectOrCreate?: CategoryCreateOrConnectWithoutChildrenInput
upsert?: CategoryUpsertWithoutChildrenInput
disconnect?: CategoryWhereInput | boolean
delete?: CategoryWhereInput | boolean
connect?: CategoryWhereUniqueInput
update?: XOR<XOR<CategoryUpdateToOneWithWhereWithoutChildrenInput, CategoryUpdateWithoutChildrenInput>, CategoryUncheckedUpdateWithoutChildrenInput>
}
export type CategoryUpdateManyWithoutParentNestedInput = {
create?: XOR<CategoryCreateWithoutParentInput, CategoryUncheckedCreateWithoutParentInput> | 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> | 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> | 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> | 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> | ProductCreateWithoutBrandInput[] | ProductUncheckedCreateWithoutBrandInput[]
connectOrCreate?: ProductCreateOrConnectWithoutBrandInput | ProductCreateOrConnectWithoutBrandInput[]
createMany?: ProductCreateManyBrandInputEnvelope
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
}
export type ProductUncheckedCreateNestedManyWithoutBrandInput = {
create?: XOR<ProductCreateWithoutBrandInput, ProductUncheckedCreateWithoutBrandInput> | ProductCreateWithoutBrandInput[] | ProductUncheckedCreateWithoutBrandInput[]
connectOrCreate?: ProductCreateOrConnectWithoutBrandInput | ProductCreateOrConnectWithoutBrandInput[]
createMany?: ProductCreateManyBrandInputEnvelope
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
}
export type ProductUpdateManyWithoutBrandNestedInput = {
create?: XOR<ProductCreateWithoutBrandInput, ProductUncheckedCreateWithoutBrandInput> | 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> | 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> | CollectionProductCreateWithoutCollectionInput[] | CollectionProductUncheckedCreateWithoutCollectionInput[]
connectOrCreate?: CollectionProductCreateOrConnectWithoutCollectionInput | CollectionProductCreateOrConnectWithoutCollectionInput[]
createMany?: CollectionProductCreateManyCollectionInputEnvelope
connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[]
}
export type CollectionProductUncheckedCreateNestedManyWithoutCollectionInput = {
create?: XOR<CollectionProductCreateWithoutCollectionInput, CollectionProductUncheckedCreateWithoutCollectionInput> | CollectionProductCreateWithoutCollectionInput[] | CollectionProductUncheckedCreateWithoutCollectionInput[]
connectOrCreate?: CollectionProductCreateOrConnectWithoutCollectionInput | CollectionProductCreateOrConnectWithoutCollectionInput[]
createMany?: CollectionProductCreateManyCollectionInputEnvelope
connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[]
}
export type CollectionProductUpdateManyWithoutCollectionNestedInput = {
create?: XOR<CollectionProductCreateWithoutCollectionInput, CollectionProductUncheckedCreateWithoutCollectionInput> | 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> | 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<CollectionCreateWithoutProductsInput, CollectionUncheckedCreateWithoutProductsInput>
connectOrCreate?: CollectionCreateOrConnectWithoutProductsInput
connect?: CollectionWhereUniqueInput
}
export type ProductCreateNestedOneWithoutCollectionsInput = {
create?: XOR<ProductCreateWithoutCollectionsInput, ProductUncheckedCreateWithoutCollectionsInput>
connectOrCreate?: ProductCreateOrConnectWithoutCollectionsInput
connect?: ProductWhereUniqueInput
}
export type CollectionUpdateOneRequiredWithoutProductsNestedInput = {
create?: XOR<CollectionCreateWithoutProductsInput, CollectionUncheckedCreateWithoutProductsInput>
connectOrCreate?: CollectionCreateOrConnectWithoutProductsInput
upsert?: CollectionUpsertWithoutProductsInput
connect?: CollectionWhereUniqueInput
update?: XOR<XOR<CollectionUpdateToOneWithWhereWithoutProductsInput, CollectionUpdateWithoutProductsInput>, CollectionUncheckedUpdateWithoutProductsInput>
}
export type ProductUpdateOneRequiredWithoutCollectionsNestedInput = {
create?: XOR<ProductCreateWithoutCollectionsInput, ProductUncheckedCreateWithoutCollectionsInput>
connectOrCreate?: ProductCreateOrConnectWithoutCollectionsInput
upsert?: ProductUpsertWithoutCollectionsInput
connect?: ProductWhereUniqueInput
update?: XOR<XOR<ProductUpdateToOneWithWhereWithoutCollectionsInput, ProductUpdateWithoutCollectionsInput>, ProductUncheckedUpdateWithoutCollectionsInput>
}
export type CategoryCreateNestedOneWithoutProductsInput = {
create?: XOR<CategoryCreateWithoutProductsInput, CategoryUncheckedCreateWithoutProductsInput>
connectOrCreate?: CategoryCreateOrConnectWithoutProductsInput
connect?: CategoryWhereUniqueInput
}
export type BrandCreateNestedOneWithoutProductsInput = {
create?: XOR<BrandCreateWithoutProductsInput, BrandUncheckedCreateWithoutProductsInput>
connectOrCreate?: BrandCreateOrConnectWithoutProductsInput
connect?: BrandWhereUniqueInput
}
export type ProductVariantCreateNestedManyWithoutProductInput = {
create?: XOR<ProductVariantCreateWithoutProductInput, ProductVariantUncheckedCreateWithoutProductInput> | ProductVariantCreateWithoutProductInput[] | ProductVariantUncheckedCreateWithoutProductInput[]
connectOrCreate?: ProductVariantCreateOrConnectWithoutProductInput | ProductVariantCreateOrConnectWithoutProductInput[]
createMany?: ProductVariantCreateManyProductInputEnvelope
connect?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[]
}
export type ProductImageCreateNestedManyWithoutProductInput = {
create?: XOR<ProductImageCreateWithoutProductInput, ProductImageUncheckedCreateWithoutProductInput> | ProductImageCreateWithoutProductInput[] | ProductImageUncheckedCreateWithoutProductInput[]
connectOrCreate?: ProductImageCreateOrConnectWithoutProductInput | ProductImageCreateOrConnectWithoutProductInput[]
createMany?: ProductImageCreateManyProductInputEnvelope
connect?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[]
}
export type CollectionProductCreateNestedManyWithoutProductInput = {
create?: XOR<CollectionProductCreateWithoutProductInput, CollectionProductUncheckedCreateWithoutProductInput> | CollectionProductCreateWithoutProductInput[] | CollectionProductUncheckedCreateWithoutProductInput[]
connectOrCreate?: CollectionProductCreateOrConnectWithoutProductInput | CollectionProductCreateOrConnectWithoutProductInput[]
createMany?: CollectionProductCreateManyProductInputEnvelope
connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[]
}
export type ProductVariantUncheckedCreateNestedManyWithoutProductInput = {
create?: XOR<ProductVariantCreateWithoutProductInput, ProductVariantUncheckedCreateWithoutProductInput> | ProductVariantCreateWithoutProductInput[] | ProductVariantUncheckedCreateWithoutProductInput[]
connectOrCreate?: ProductVariantCreateOrConnectWithoutProductInput | ProductVariantCreateOrConnectWithoutProductInput[]
createMany?: ProductVariantCreateManyProductInputEnvelope
connect?: ProductVariantWhereUniqueInput | ProductVariantWhereUniqueInput[]
}
export type ProductImageUncheckedCreateNestedManyWithoutProductInput = {
create?: XOR<ProductImageCreateWithoutProductInput, ProductImageUncheckedCreateWithoutProductInput> | ProductImageCreateWithoutProductInput[] | ProductImageUncheckedCreateWithoutProductInput[]
connectOrCreate?: ProductImageCreateOrConnectWithoutProductInput | ProductImageCreateOrConnectWithoutProductInput[]
createMany?: ProductImageCreateManyProductInputEnvelope
connect?: ProductImageWhereUniqueInput | ProductImageWhereUniqueInput[]
}
export type CollectionProductUncheckedCreateNestedManyWithoutProductInput = {
create?: XOR<CollectionProductCreateWithoutProductInput, CollectionProductUncheckedCreateWithoutProductInput> | CollectionProductCreateWithoutProductInput[] | CollectionProductUncheckedCreateWithoutProductInput[]
connectOrCreate?: CollectionProductCreateOrConnectWithoutProductInput | CollectionProductCreateOrConnectWithoutProductInput[]
createMany?: CollectionProductCreateManyProductInputEnvelope
connect?: CollectionProductWhereUniqueInput | CollectionProductWhereUniqueInput[]
}
export type CategoryUpdateOneWithoutProductsNestedInput = {
create?: XOR<CategoryCreateWithoutProductsInput, CategoryUncheckedCreateWithoutProductsInput>
connectOrCreate?: CategoryCreateOrConnectWithoutProductsInput
upsert?: CategoryUpsertWithoutProductsInput
disconnect?: CategoryWhereInput | boolean
delete?: CategoryWhereInput | boolean
connect?: CategoryWhereUniqueInput
update?: XOR<XOR<CategoryUpdateToOneWithWhereWithoutProductsInput, CategoryUpdateWithoutProductsInput>, CategoryUncheckedUpdateWithoutProductsInput>
}
export type BrandUpdateOneWithoutProductsNestedInput = {
create?: XOR<BrandCreateWithoutProductsInput, BrandUncheckedCreateWithoutProductsInput>
connectOrCreate?: BrandCreateOrConnectWithoutProductsInput
upsert?: BrandUpsertWithoutProductsInput
disconnect?: BrandWhereInput | boolean
delete?: BrandWhereInput | boolean
connect?: BrandWhereUniqueInput
update?: XOR<XOR<BrandUpdateToOneWithWhereWithoutProductsInput, BrandUpdateWithoutProductsInput>, BrandUncheckedUpdateWithoutProductsInput>
}
export type ProductVariantUpdateManyWithoutProductNestedInput = {
create?: XOR<ProductVariantCreateWithoutProductInput, ProductVariantUncheckedCreateWithoutProductInput> | 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> | 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> | 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> | 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> | 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> | 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<ProductCreateWithoutImagesInput, ProductUncheckedCreateWithoutImagesInput>
connectOrCreate?: ProductCreateOrConnectWithoutImagesInput
connect?: ProductWhereUniqueInput
}
export type IntFieldUpdateOperationsInput = {
set?: number
increment?: number
decrement?: number
multiply?: number
divide?: number
}
export type ProductUpdateOneRequiredWithoutImagesNestedInput = {
create?: XOR<ProductCreateWithoutImagesInput, ProductUncheckedCreateWithoutImagesInput>
connectOrCreate?: ProductCreateOrConnectWithoutImagesInput
upsert?: ProductUpsertWithoutImagesInput
connect?: ProductWhereUniqueInput
update?: XOR<XOR<ProductUpdateToOneWithWhereWithoutImagesInput, ProductUpdateWithoutImagesInput>, ProductUncheckedUpdateWithoutImagesInput>
}
export type ProductCreateNestedOneWithoutVariantsInput = {
create?: XOR<ProductCreateWithoutVariantsInput, ProductUncheckedCreateWithoutVariantsInput>
connectOrCreate?: ProductCreateOrConnectWithoutVariantsInput
connect?: ProductWhereUniqueInput
}
export type OrderItemCreateNestedManyWithoutProductVariantInput = {
create?: XOR<OrderItemCreateWithoutProductVariantInput, OrderItemUncheckedCreateWithoutProductVariantInput> | OrderItemCreateWithoutProductVariantInput[] | OrderItemUncheckedCreateWithoutProductVariantInput[]
connectOrCreate?: OrderItemCreateOrConnectWithoutProductVariantInput | OrderItemCreateOrConnectWithoutProductVariantInput[]
createMany?: OrderItemCreateManyProductVariantInputEnvelope
connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[]
}
export type OrderItemUncheckedCreateNestedManyWithoutProductVariantInput = {
create?: XOR<OrderItemCreateWithoutProductVariantInput, OrderItemUncheckedCreateWithoutProductVariantInput> | OrderItemCreateWithoutProductVariantInput[] | OrderItemUncheckedCreateWithoutProductVariantInput[]
connectOrCreate?: OrderItemCreateOrConnectWithoutProductVariantInput | OrderItemCreateOrConnectWithoutProductVariantInput[]
createMany?: OrderItemCreateManyProductVariantInputEnvelope
connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[]
}
export type ProductUpdateOneRequiredWithoutVariantsNestedInput = {
create?: XOR<ProductCreateWithoutVariantsInput, ProductUncheckedCreateWithoutVariantsInput>
connectOrCreate?: ProductCreateOrConnectWithoutVariantsInput
upsert?: ProductUpsertWithoutVariantsInput
connect?: ProductWhereUniqueInput
update?: XOR<XOR<ProductUpdateToOneWithWhereWithoutVariantsInput, ProductUpdateWithoutVariantsInput>, ProductUncheckedUpdateWithoutVariantsInput>
}
export type OrderItemUpdateManyWithoutProductVariantNestedInput = {
create?: XOR<OrderItemCreateWithoutProductVariantInput, OrderItemUncheckedCreateWithoutProductVariantInput> | 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> | 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<CustomerCreateWithoutOrdersInput, CustomerUncheckedCreateWithoutOrdersInput>
connectOrCreate?: CustomerCreateOrConnectWithoutOrdersInput
connect?: CustomerWhereUniqueInput
}
export type BranchCreateNestedOneWithoutOrdersInput = {
create?: XOR<BranchCreateWithoutOrdersInput, BranchUncheckedCreateWithoutOrdersInput>
connectOrCreate?: BranchCreateOrConnectWithoutOrdersInput
connect?: BranchWhereUniqueInput
}
export type OrderItemCreateNestedManyWithoutOrderInput = {
create?: XOR<OrderItemCreateWithoutOrderInput, OrderItemUncheckedCreateWithoutOrderInput> | OrderItemCreateWithoutOrderInput[] | OrderItemUncheckedCreateWithoutOrderInput[]
connectOrCreate?: OrderItemCreateOrConnectWithoutOrderInput | OrderItemCreateOrConnectWithoutOrderInput[]
createMany?: OrderItemCreateManyOrderInputEnvelope
connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[]
}
export type OrderStatusEventCreateNestedManyWithoutOrderInput = {
create?: XOR<OrderStatusEventCreateWithoutOrderInput, OrderStatusEventUncheckedCreateWithoutOrderInput> | OrderStatusEventCreateWithoutOrderInput[] | OrderStatusEventUncheckedCreateWithoutOrderInput[]
connectOrCreate?: OrderStatusEventCreateOrConnectWithoutOrderInput | OrderStatusEventCreateOrConnectWithoutOrderInput[]
createMany?: OrderStatusEventCreateManyOrderInputEnvelope
connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[]
}
export type LedgerEntryCreateNestedManyWithoutOrderInput = {
create?: XOR<LedgerEntryCreateWithoutOrderInput, LedgerEntryUncheckedCreateWithoutOrderInput> | LedgerEntryCreateWithoutOrderInput[] | LedgerEntryUncheckedCreateWithoutOrderInput[]
connectOrCreate?: LedgerEntryCreateOrConnectWithoutOrderInput | LedgerEntryCreateOrConnectWithoutOrderInput[]
createMany?: LedgerEntryCreateManyOrderInputEnvelope
connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[]
}
export type PreOrderCreateNestedOneWithoutConvertedOrderInput = {
create?: XOR<PreOrderCreateWithoutConvertedOrderInput, PreOrderUncheckedCreateWithoutConvertedOrderInput>
connectOrCreate?: PreOrderCreateOrConnectWithoutConvertedOrderInput
connect?: PreOrderWhereUniqueInput
}
export type OrderItemUncheckedCreateNestedManyWithoutOrderInput = {
create?: XOR<OrderItemCreateWithoutOrderInput, OrderItemUncheckedCreateWithoutOrderInput> | OrderItemCreateWithoutOrderInput[] | OrderItemUncheckedCreateWithoutOrderInput[]
connectOrCreate?: OrderItemCreateOrConnectWithoutOrderInput | OrderItemCreateOrConnectWithoutOrderInput[]
createMany?: OrderItemCreateManyOrderInputEnvelope
connect?: OrderItemWhereUniqueInput | OrderItemWhereUniqueInput[]
}
export type OrderStatusEventUncheckedCreateNestedManyWithoutOrderInput = {
create?: XOR<OrderStatusEventCreateWithoutOrderInput, OrderStatusEventUncheckedCreateWithoutOrderInput> | OrderStatusEventCreateWithoutOrderInput[] | OrderStatusEventUncheckedCreateWithoutOrderInput[]
connectOrCreate?: OrderStatusEventCreateOrConnectWithoutOrderInput | OrderStatusEventCreateOrConnectWithoutOrderInput[]
createMany?: OrderStatusEventCreateManyOrderInputEnvelope
connect?: OrderStatusEventWhereUniqueInput | OrderStatusEventWhereUniqueInput[]
}
export type LedgerEntryUncheckedCreateNestedManyWithoutOrderInput = {
create?: XOR<LedgerEntryCreateWithoutOrderInput, LedgerEntryUncheckedCreateWithoutOrderInput> | LedgerEntryCreateWithoutOrderInput[] | LedgerEntryUncheckedCreateWithoutOrderInput[]
connectOrCreate?: LedgerEntryCreateOrConnectWithoutOrderInput | LedgerEntryCreateOrConnectWithoutOrderInput[]
createMany?: LedgerEntryCreateManyOrderInputEnvelope
connect?: LedgerEntryWhereUniqueInput | LedgerEntryWhereUniqueInput[]
}
export type PreOrderUncheckedCreateNestedOneWithoutConvertedOrderInput = {
create?: XOR<PreOrderCreateWithoutConvertedOrderInput, PreOrderUncheckedCreateWithoutConvertedOrderInput>
connectOrCreate?: PreOrderCreateOrConnectWithoutConvertedOrderInput
connect?: PreOrderWhereUniqueInput
}
export type EnumOrderStatusFieldUpdateOperationsInput = {
set?: $Enums.OrderStatus
}
export type NullableDateTimeFieldUpdateOperationsInput = {
set?: Date | string | null
}
export type CustomerUpdateOneRequiredWithoutOrdersNestedInput = {
create?: XOR<CustomerCreateWithoutOrdersInput, CustomerUncheckedCreateWithoutOrdersInput>
connectOrCreate?: CustomerCreateOrConnectWithoutOrdersInput
upsert?: CustomerUpsertWithoutOrdersInput
connect?: CustomerWhereUniqueInput
update?: XOR<XOR<CustomerUpdateToOneWithWhereWithoutOrdersInput, CustomerUpdateWithoutOrdersInput>, CustomerUncheckedUpdateWithoutOrdersInput>
}
export type BranchUpdateOneWithoutOrdersNestedInput = {
create?: XOR<BranchCreateWithoutOrdersInput, BranchUncheckedCreateWithoutOrdersInput>
connectOrCreate?: BranchCreateOrConnectWithoutOrdersInput
upsert?: BranchUpsertWithoutOrdersInput
disconnect?: BranchWhereInput | boolean
delete?: BranchWhereInput | boolean
connect?: BranchWhereUniqueInput
update?: XOR<XOR<BranchUpdateToOneWithWhereWithoutOrdersInput, BranchUpdateWithoutOrdersInput>, BranchUncheckedUpdateWithoutOrdersInput>
}
export type OrderItemUpdateManyWithoutOrderNestedInput = {
create?: XOR<OrderItemCreateWithoutOrderInput, OrderItemUncheckedCreateWithoutOrderInput> | 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> | 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> | 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<PreOrderCreateWithoutConvertedOrderInput, PreOrderUncheckedCreateWithoutConvertedOrderInput>
connectOrCreate?: PreOrderCreateOrConnectWithoutConvertedOrderInput
upsert?: PreOrderUpsertWithoutConvertedOrderInput
disconnect?: PreOrderWhereInput | boolean
delete?: PreOrderWhereInput | boolean
connect?: PreOrderWhereUniqueInput
update?: XOR<XOR<PreOrderUpdateToOneWithWhereWithoutConvertedOrderInput, PreOrderUpdateWithoutConvertedOrderInput>, PreOrderUncheckedUpdateWithoutConvertedOrderInput>
}
export type OrderItemUncheckedUpdateManyWithoutOrderNestedInput = {
create?: XOR<OrderItemCreateWithoutOrderInput, OrderItemUncheckedCreateWithoutOrderInput> | 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> | 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> | 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<PreOrderCreateWithoutConvertedOrderInput, PreOrderUncheckedCreateWithoutConvertedOrderInput>
connectOrCreate?: PreOrderCreateOrConnectWithoutConvertedOrderInput
upsert?: PreOrderUpsertWithoutConvertedOrderInput
disconnect?: PreOrderWhereInput | boolean
delete?: PreOrderWhereInput | boolean
connect?: PreOrderWhereUniqueInput
update?: XOR<XOR<PreOrderUpdateToOneWithWhereWithoutConvertedOrderInput, PreOrderUpdateWithoutConvertedOrderInput>, PreOrderUncheckedUpdateWithoutConvertedOrderInput>
}
export type OrderCreateNestedOneWithoutItemsInput = {
create?: XOR<OrderCreateWithoutItemsInput, OrderUncheckedCreateWithoutItemsInput>
connectOrCreate?: OrderCreateOrConnectWithoutItemsInput
connect?: OrderWhereUniqueInput
}
export type ProductVariantCreateNestedOneWithoutOrderItemsInput = {
create?: XOR<ProductVariantCreateWithoutOrderItemsInput, ProductVariantUncheckedCreateWithoutOrderItemsInput>
connectOrCreate?: ProductVariantCreateOrConnectWithoutOrderItemsInput
connect?: ProductVariantWhereUniqueInput
}
export type OrderUpdateOneRequiredWithoutItemsNestedInput = {
create?: XOR<OrderCreateWithoutItemsInput, OrderUncheckedCreateWithoutItemsInput>
connectOrCreate?: OrderCreateOrConnectWithoutItemsInput
upsert?: OrderUpsertWithoutItemsInput
connect?: OrderWhereUniqueInput
update?: XOR<XOR<OrderUpdateToOneWithWhereWithoutItemsInput, OrderUpdateWithoutItemsInput>, OrderUncheckedUpdateWithoutItemsInput>
}
export type ProductVariantUpdateOneRequiredWithoutOrderItemsNestedInput = {
create?: XOR<ProductVariantCreateWithoutOrderItemsInput, ProductVariantUncheckedCreateWithoutOrderItemsInput>
connectOrCreate?: ProductVariantCreateOrConnectWithoutOrderItemsInput
upsert?: ProductVariantUpsertWithoutOrderItemsInput
connect?: ProductVariantWhereUniqueInput
update?: XOR<XOR<ProductVariantUpdateToOneWithWhereWithoutOrderItemsInput, ProductVariantUpdateWithoutOrderItemsInput>, ProductVariantUncheckedUpdateWithoutOrderItemsInput>
}
export type OrderCreateNestedOneWithoutStatusEventsInput = {
create?: XOR<OrderCreateWithoutStatusEventsInput, OrderUncheckedCreateWithoutStatusEventsInput>
connectOrCreate?: OrderCreateOrConnectWithoutStatusEventsInput
connect?: OrderWhereUniqueInput
}
export type AdminUserCreateNestedOneWithoutOrderStatusEventsInput = {
create?: XOR<AdminUserCreateWithoutOrderStatusEventsInput, AdminUserUncheckedCreateWithoutOrderStatusEventsInput>
connectOrCreate?: AdminUserCreateOrConnectWithoutOrderStatusEventsInput
connect?: AdminUserWhereUniqueInput
}
export type NullableEnumOrderStatusFieldUpdateOperationsInput = {
set?: $Enums.OrderStatus | null
}
export type OrderUpdateOneRequiredWithoutStatusEventsNestedInput = {
create?: XOR<OrderCreateWithoutStatusEventsInput, OrderUncheckedCreateWithoutStatusEventsInput>
connectOrCreate?: OrderCreateOrConnectWithoutStatusEventsInput
upsert?: OrderUpsertWithoutStatusEventsInput
connect?: OrderWhereUniqueInput
update?: XOR<XOR<OrderUpdateToOneWithWhereWithoutStatusEventsInput, OrderUpdateWithoutStatusEventsInput>, OrderUncheckedUpdateWithoutStatusEventsInput>
}
export type AdminUserUpdateOneWithoutOrderStatusEventsNestedInput = {
create?: XOR<AdminUserCreateWithoutOrderStatusEventsInput, AdminUserUncheckedCreateWithoutOrderStatusEventsInput>
connectOrCreate?: AdminUserCreateOrConnectWithoutOrderStatusEventsInput
upsert?: AdminUserUpsertWithoutOrderStatusEventsInput
disconnect?: AdminUserWhereInput | boolean
delete?: AdminUserWhereInput | boolean
connect?: AdminUserWhereUniqueInput
update?: XOR<XOR<AdminUserUpdateToOneWithWhereWithoutOrderStatusEventsInput, AdminUserUpdateWithoutOrderStatusEventsInput>, AdminUserUncheckedUpdateWithoutOrderStatusEventsInput>
}
export type CustomerCreateNestedOneWithoutPreOrdersInput = {
create?: XOR<CustomerCreateWithoutPreOrdersInput, CustomerUncheckedCreateWithoutPreOrdersInput>
connectOrCreate?: CustomerCreateOrConnectWithoutPreOrdersInput
connect?: CustomerWhereUniqueInput
}
export type CityCreateNestedOneWithoutPreOrdersInput = {
create?: XOR<CityCreateWithoutPreOrdersInput, CityUncheckedCreateWithoutPreOrdersInput>
connectOrCreate?: CityCreateOrConnectWithoutPreOrdersInput
connect?: CityWhereUniqueInput
}
export type WorkshopCreateNestedOneWithoutPreOrdersInput = {
create?: XOR<WorkshopCreateWithoutPreOrdersInput, WorkshopUncheckedCreateWithoutPreOrdersInput>
connectOrCreate?: WorkshopCreateOrConnectWithoutPreOrdersInput
connect?: WorkshopWhereUniqueInput
}
export type OrderCreateNestedOneWithoutConvertedFromPreOrderInput = {
create?: XOR<OrderCreateWithoutConvertedFromPreOrderInput, OrderUncheckedCreateWithoutConvertedFromPreOrderInput>
connectOrCreate?: OrderCreateOrConnectWithoutConvertedFromPreOrderInput
connect?: OrderWhereUniqueInput
}
export type PreOrderStatusEventCreateNestedManyWithoutPreOrderInput = {
create?: XOR<PreOrderStatusEventCreateWithoutPreOrderInput, PreOrderStatusEventUncheckedCreateWithoutPreOrderInput> | PreOrderStatusEventCreateWithoutPreOrderInput[] | PreOrderStatusEventUncheckedCreateWithoutPreOrderInput[]
connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutPreOrderInput | PreOrderStatusEventCreateOrConnectWithoutPreOrderInput[]
createMany?: PreOrderStatusEventCreateManyPreOrderInputEnvelope
connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[]
}
export type PreOrderStatusEventUncheckedCreateNestedManyWithoutPreOrderInput = {
create?: XOR<PreOrderStatusEventCreateWithoutPreOrderInput, PreOrderStatusEventUncheckedCreateWithoutPreOrderInput> | PreOrderStatusEventCreateWithoutPreOrderInput[] | PreOrderStatusEventUncheckedCreateWithoutPreOrderInput[]
connectOrCreate?: PreOrderStatusEventCreateOrConnectWithoutPreOrderInput | PreOrderStatusEventCreateOrConnectWithoutPreOrderInput[]
createMany?: PreOrderStatusEventCreateManyPreOrderInputEnvelope
connect?: PreOrderStatusEventWhereUniqueInput | PreOrderStatusEventWhereUniqueInput[]
}
export type EnumPreOrderStatusFieldUpdateOperationsInput = {
set?: $Enums.PreOrderStatus
}
export type CustomerUpdateOneRequiredWithoutPreOrdersNestedInput = {
create?: XOR<CustomerCreateWithoutPreOrdersInput, CustomerUncheckedCreateWithoutPreOrdersInput>
connectOrCreate?: CustomerCreateOrConnectWithoutPreOrdersInput
upsert?: CustomerUpsertWithoutPreOrdersInput
connect?: CustomerWhereUniqueInput
update?: XOR<XOR<CustomerUpdateToOneWithWhereWithoutPreOrdersInput, CustomerUpdateWithoutPreOrdersInput>, CustomerUncheckedUpdateWithoutPreOrdersInput>
}
export type CityUpdateOneWithoutPreOrdersNestedInput = {
create?: XOR<CityCreateWithoutPreOrdersInput, CityUncheckedCreateWithoutPreOrdersInput>
connectOrCreate?: CityCreateOrConnectWithoutPreOrdersInput
upsert?: CityUpsertWithoutPreOrdersInput
disconnect?: CityWhereInput | boolean
delete?: CityWhereInput | boolean
connect?: CityWhereUniqueInput
update?: XOR<XOR<CityUpdateToOneWithWhereWithoutPreOrdersInput, CityUpdateWithoutPreOrdersInput>, CityUncheckedUpdateWithoutPreOrdersInput>
}
export type WorkshopUpdateOneWithoutPreOrdersNestedInput = {
create?: XOR<WorkshopCreateWithoutPreOrdersInput, WorkshopUncheckedCreateWithoutPreOrdersInput>
connectOrCreate?: WorkshopCreateOrConnectWithoutPreOrdersInput
upsert?: WorkshopUpsertWithoutPreOrdersInput
disconnect?: WorkshopWhereInput | boolean
delete?: WorkshopWhereInput | boolean
connect?: WorkshopWhereUniqueInput
update?: XOR<XOR<WorkshopUpdateToOneWithWhereWithoutPreOrdersInput, WorkshopUpdateWithoutPreOrdersInput>, WorkshopUncheckedUpdateWithoutPreOrdersInput>
}
export type OrderUpdateOneWithoutConvertedFromPreOrderNestedInput = {
create?: XOR<OrderCreateWithoutConvertedFromPreOrderInput, OrderUncheckedCreateWithoutConvertedFromPreOrderInput>
connectOrCreate?: OrderCreateOrConnectWithoutConvertedFromPreOrderInput
upsert?: OrderUpsertWithoutConvertedFromPreOrderInput
disconnect?: OrderWhereInput | boolean
delete?: OrderWhereInput | boolean
connect?: OrderWhereUniqueInput
update?: XOR<XOR<OrderUpdateToOneWithWhereWithoutConvertedFromPreOrderInput, OrderUpdateWithoutConvertedFromPreOrderInput>, OrderUncheckedUpdateWithoutConvertedFromPreOrderInput>
}
export type PreOrderStatusEventUpdateManyWithoutPreOrderNestedInput = {
create?: XOR<PreOrderStatusEventCreateWithoutPreOrderInput, PreOrderStatusEventUncheckedCreateWithoutPreOrderInput> | 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> | 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<PreOrderCreateWithoutStatusEventsInput, PreOrderUncheckedCreateWithoutStatusEventsInput>
connectOrCreate?: PreOrderCreateOrConnectWithoutStatusEventsInput
connect?: PreOrderWhereUniqueInput
}
export type AdminUserCreateNestedOneWithoutPreOrderStatusEventsInput = {
create?: XOR<AdminUserCreateWithoutPreOrderStatusEventsInput, AdminUserUncheckedCreateWithoutPreOrderStatusEventsInput>
connectOrCreate?: AdminUserCreateOrConnectWithoutPreOrderStatusEventsInput
connect?: AdminUserWhereUniqueInput
}
export type PreOrderUpdateOneRequiredWithoutStatusEventsNestedInput = {
create?: XOR<PreOrderCreateWithoutStatusEventsInput, PreOrderUncheckedCreateWithoutStatusEventsInput>
connectOrCreate?: PreOrderCreateOrConnectWithoutStatusEventsInput
upsert?: PreOrderUpsertWithoutStatusEventsInput
connect?: PreOrderWhereUniqueInput
update?: XOR<XOR<PreOrderUpdateToOneWithWhereWithoutStatusEventsInput, PreOrderUpdateWithoutStatusEventsInput>, PreOrderUncheckedUpdateWithoutStatusEventsInput>
}
export type AdminUserUpdateOneWithoutPreOrderStatusEventsNestedInput = {
create?: XOR<AdminUserCreateWithoutPreOrderStatusEventsInput, AdminUserUncheckedCreateWithoutPreOrderStatusEventsInput>
connectOrCreate?: AdminUserCreateOrConnectWithoutPreOrderStatusEventsInput
upsert?: AdminUserUpsertWithoutPreOrderStatusEventsInput
disconnect?: AdminUserWhereInput | boolean
delete?: AdminUserWhereInput | boolean
connect?: AdminUserWhereUniqueInput
update?: XOR<XOR<AdminUserUpdateToOneWithWhereWithoutPreOrderStatusEventsInput, AdminUserUpdateWithoutPreOrderStatusEventsInput>, AdminUserUncheckedUpdateWithoutPreOrderStatusEventsInput>
}
export type CustomerCreateNestedOneWithoutLedgerEntriesInput = {
create?: XOR<CustomerCreateWithoutLedgerEntriesInput, CustomerUncheckedCreateWithoutLedgerEntriesInput>
connectOrCreate?: CustomerCreateOrConnectWithoutLedgerEntriesInput
connect?: CustomerWhereUniqueInput
}
export type OrderCreateNestedOneWithoutLedgerEntriesInput = {
create?: XOR<OrderCreateWithoutLedgerEntriesInput, OrderUncheckedCreateWithoutLedgerEntriesInput>
connectOrCreate?: OrderCreateOrConnectWithoutLedgerEntriesInput
connect?: OrderWhereUniqueInput
}
export type AdminUserCreateNestedOneWithoutPostedLedgerEntriesInput = {
create?: XOR<AdminUserCreateWithoutPostedLedgerEntriesInput, AdminUserUncheckedCreateWithoutPostedLedgerEntriesInput>
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<CustomerCreateWithoutLedgerEntriesInput, CustomerUncheckedCreateWithoutLedgerEntriesInput>
connectOrCreate?: CustomerCreateOrConnectWithoutLedgerEntriesInput
upsert?: CustomerUpsertWithoutLedgerEntriesInput
connect?: CustomerWhereUniqueInput
update?: XOR<XOR<CustomerUpdateToOneWithWhereWithoutLedgerEntriesInput, CustomerUpdateWithoutLedgerEntriesInput>, CustomerUncheckedUpdateWithoutLedgerEntriesInput>
}
export type OrderUpdateOneWithoutLedgerEntriesNestedInput = {
create?: XOR<OrderCreateWithoutLedgerEntriesInput, OrderUncheckedCreateWithoutLedgerEntriesInput>
connectOrCreate?: OrderCreateOrConnectWithoutLedgerEntriesInput
upsert?: OrderUpsertWithoutLedgerEntriesInput
disconnect?: OrderWhereInput | boolean
delete?: OrderWhereInput | boolean
connect?: OrderWhereUniqueInput
update?: XOR<XOR<OrderUpdateToOneWithWhereWithoutLedgerEntriesInput, OrderUpdateWithoutLedgerEntriesInput>, OrderUncheckedUpdateWithoutLedgerEntriesInput>
}
export type AdminUserUpdateOneWithoutPostedLedgerEntriesNestedInput = {
create?: XOR<AdminUserCreateWithoutPostedLedgerEntriesInput, AdminUserUncheckedCreateWithoutPostedLedgerEntriesInput>
connectOrCreate?: AdminUserCreateOrConnectWithoutPostedLedgerEntriesInput
upsert?: AdminUserUpsertWithoutPostedLedgerEntriesInput
disconnect?: AdminUserWhereInput | boolean
delete?: AdminUserWhereInput | boolean
connect?: AdminUserWhereUniqueInput
update?: XOR<XOR<AdminUserUpdateToOneWithWhereWithoutPostedLedgerEntriesInput, AdminUserUpdateWithoutPostedLedgerEntriesInput>, AdminUserUncheckedUpdateWithoutPostedLedgerEntriesInput>
}
export type CustomerCreateNestedOneWithoutWalletBonusesInput = {
create?: XOR<CustomerCreateWithoutWalletBonusesInput, CustomerUncheckedCreateWithoutWalletBonusesInput>
connectOrCreate?: CustomerCreateOrConnectWithoutWalletBonusesInput
connect?: CustomerWhereUniqueInput
}
export type CustomerUpdateOneRequiredWithoutWalletBonusesNestedInput = {
create?: XOR<CustomerCreateWithoutWalletBonusesInput, CustomerUncheckedCreateWithoutWalletBonusesInput>
connectOrCreate?: CustomerCreateOrConnectWithoutWalletBonusesInput
upsert?: CustomerUpsertWithoutWalletBonusesInput
connect?: CustomerWhereUniqueInput
update?: XOR<XOR<CustomerUpdateToOneWithWhereWithoutWalletBonusesInput, CustomerUpdateWithoutWalletBonusesInput>, 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<Required<NestedJsonFilterBase<$PrismaModel>>, Exclude<keyof Required<NestedJsonFilterBase<$PrismaModel>>, 'path'>>,
Required<NestedJsonFilterBase<$PrismaModel>>
>
| OptionalFlat<Omit<Required<NestedJsonFilterBase<$PrismaModel>>, '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<CustomerCreateWithoutCityInput, CustomerUncheckedCreateWithoutCityInput>
}
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<CustomerAddressCreateWithoutCityInput, CustomerAddressUncheckedCreateWithoutCityInput>
}
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<BranchCreateWithoutCityInput, BranchUncheckedCreateWithoutCityInput>
}
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<PreOrderCreateWithoutCityInput, PreOrderUncheckedCreateWithoutCityInput>
}
export type PreOrderCreateManyCityInputEnvelope = {
data: PreOrderCreateManyCityInput | PreOrderCreateManyCityInput[]
skipDuplicates?: boolean
}
export type CustomerUpsertWithWhereUniqueWithoutCityInput = {
where: CustomerWhereUniqueInput
update: XOR<CustomerUpdateWithoutCityInput, CustomerUncheckedUpdateWithoutCityInput>
create: XOR<CustomerCreateWithoutCityInput, CustomerUncheckedCreateWithoutCityInput>
}
export type CustomerUpdateWithWhereUniqueWithoutCityInput = {
where: CustomerWhereUniqueInput
data: XOR<CustomerUpdateWithoutCityInput, CustomerUncheckedUpdateWithoutCityInput>
}
export type CustomerUpdateManyWithWhereWithoutCityInput = {
where: CustomerScalarWhereInput
data: XOR<CustomerUpdateManyMutationInput, CustomerUncheckedUpdateManyWithoutCityInput>
}
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<CustomerAddressUpdateWithoutCityInput, CustomerAddressUncheckedUpdateWithoutCityInput>
create: XOR<CustomerAddressCreateWithoutCityInput, CustomerAddressUncheckedCreateWithoutCityInput>
}
export type CustomerAddressUpdateWithWhereUniqueWithoutCityInput = {
where: CustomerAddressWhereUniqueInput
data: XOR<CustomerAddressUpdateWithoutCityInput, CustomerAddressUncheckedUpdateWithoutCityInput>
}
export type CustomerAddressUpdateManyWithWhereWithoutCityInput = {
where: CustomerAddressScalarWhereInput
data: XOR<CustomerAddressUpdateManyMutationInput, CustomerAddressUncheckedUpdateManyWithoutCityInput>
}
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<BranchUpdateWithoutCityInput, BranchUncheckedUpdateWithoutCityInput>
create: XOR<BranchCreateWithoutCityInput, BranchUncheckedCreateWithoutCityInput>
}
export type BranchUpdateWithWhereUniqueWithoutCityInput = {
where: BranchWhereUniqueInput
data: XOR<BranchUpdateWithoutCityInput, BranchUncheckedUpdateWithoutCityInput>
}
export type BranchUpdateManyWithWhereWithoutCityInput = {
where: BranchScalarWhereInput
data: XOR<BranchUpdateManyMutationInput, BranchUncheckedUpdateManyWithoutCityInput>
}
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<PreOrderUpdateWithoutCityInput, PreOrderUncheckedUpdateWithoutCityInput>
create: XOR<PreOrderCreateWithoutCityInput, PreOrderUncheckedCreateWithoutCityInput>
}
export type PreOrderUpdateWithWhereUniqueWithoutCityInput = {
where: PreOrderWhereUniqueInput
data: XOR<PreOrderUpdateWithoutCityInput, PreOrderUncheckedUpdateWithoutCityInput>
}
export type PreOrderUpdateManyWithWhereWithoutCityInput = {
where: PreOrderScalarWhereInput
data: XOR<PreOrderUpdateManyMutationInput, PreOrderUncheckedUpdateManyWithoutCityInput>
}
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<BranchCreateWithoutAdminUsersInput, BranchUncheckedCreateWithoutAdminUsersInput>
}
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<CustomerCreateWithoutReferredByAgentInput, CustomerUncheckedCreateWithoutReferredByAgentInput>
}
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<LedgerEntryCreateWithoutPostedByAdminUserInput, LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput>
}
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<OrderStatusEventCreateWithoutActorAdminUserInput, OrderStatusEventUncheckedCreateWithoutActorAdminUserInput>
}
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<PreOrderStatusEventCreateWithoutActorAdminUserInput, PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput>
}
export type PreOrderStatusEventCreateManyActorAdminUserInputEnvelope = {
data: PreOrderStatusEventCreateManyActorAdminUserInput | PreOrderStatusEventCreateManyActorAdminUserInput[]
skipDuplicates?: boolean
}
export type BranchUpsertWithoutAdminUsersInput = {
update: XOR<BranchUpdateWithoutAdminUsersInput, BranchUncheckedUpdateWithoutAdminUsersInput>
create: XOR<BranchCreateWithoutAdminUsersInput, BranchUncheckedCreateWithoutAdminUsersInput>
where?: BranchWhereInput
}
export type BranchUpdateToOneWithWhereWithoutAdminUsersInput = {
where?: BranchWhereInput
data: XOR<BranchUpdateWithoutAdminUsersInput, BranchUncheckedUpdateWithoutAdminUsersInput>
}
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<CustomerUpdateWithoutReferredByAgentInput, CustomerUncheckedUpdateWithoutReferredByAgentInput>
create: XOR<CustomerCreateWithoutReferredByAgentInput, CustomerUncheckedCreateWithoutReferredByAgentInput>
}
export type CustomerUpdateWithWhereUniqueWithoutReferredByAgentInput = {
where: CustomerWhereUniqueInput
data: XOR<CustomerUpdateWithoutReferredByAgentInput, CustomerUncheckedUpdateWithoutReferredByAgentInput>
}
export type CustomerUpdateManyWithWhereWithoutReferredByAgentInput = {
where: CustomerScalarWhereInput
data: XOR<CustomerUpdateManyMutationInput, CustomerUncheckedUpdateManyWithoutReferredByAgentInput>
}
export type LedgerEntryUpsertWithWhereUniqueWithoutPostedByAdminUserInput = {
where: LedgerEntryWhereUniqueInput
update: XOR<LedgerEntryUpdateWithoutPostedByAdminUserInput, LedgerEntryUncheckedUpdateWithoutPostedByAdminUserInput>
create: XOR<LedgerEntryCreateWithoutPostedByAdminUserInput, LedgerEntryUncheckedCreateWithoutPostedByAdminUserInput>
}
export type LedgerEntryUpdateWithWhereUniqueWithoutPostedByAdminUserInput = {
where: LedgerEntryWhereUniqueInput
data: XOR<LedgerEntryUpdateWithoutPostedByAdminUserInput, LedgerEntryUncheckedUpdateWithoutPostedByAdminUserInput>
}
export type LedgerEntryUpdateManyWithWhereWithoutPostedByAdminUserInput = {
where: LedgerEntryScalarWhereInput
data: XOR<LedgerEntryUpdateManyMutationInput, LedgerEntryUncheckedUpdateManyWithoutPostedByAdminUserInput>
}
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<OrderStatusEventUpdateWithoutActorAdminUserInput, OrderStatusEventUncheckedUpdateWithoutActorAdminUserInput>
create: XOR<OrderStatusEventCreateWithoutActorAdminUserInput, OrderStatusEventUncheckedCreateWithoutActorAdminUserInput>
}
export type OrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput = {
where: OrderStatusEventWhereUniqueInput
data: XOR<OrderStatusEventUpdateWithoutActorAdminUserInput, OrderStatusEventUncheckedUpdateWithoutActorAdminUserInput>
}
export type OrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput = {
where: OrderStatusEventScalarWhereInput
data: XOR<OrderStatusEventUpdateManyMutationInput, OrderStatusEventUncheckedUpdateManyWithoutActorAdminUserInput>
}
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<PreOrderStatusEventUpdateWithoutActorAdminUserInput, PreOrderStatusEventUncheckedUpdateWithoutActorAdminUserInput>
create: XOR<PreOrderStatusEventCreateWithoutActorAdminUserInput, PreOrderStatusEventUncheckedCreateWithoutActorAdminUserInput>
}
export type PreOrderStatusEventUpdateWithWhereUniqueWithoutActorAdminUserInput = {
where: PreOrderStatusEventWhereUniqueInput
data: XOR<PreOrderStatusEventUpdateWithoutActorAdminUserInput, PreOrderStatusEventUncheckedUpdateWithoutActorAdminUserInput>
}
export type PreOrderStatusEventUpdateManyWithWhereWithoutActorAdminUserInput = {
where: PreOrderStatusEventScalarWhereInput
data: XOR<PreOrderStatusEventUpdateManyMutationInput, PreOrderStatusEventUncheckedUpdateManyWithoutActorAdminUserInput>
}
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<CityCreateWithoutCustomersInput, CityUncheckedCreateWithoutCustomersInput>
}
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<AdminUserCreateWithoutReferredCustomersInput, AdminUserUncheckedCreateWithoutReferredCustomersInput>
}
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<CustomerAddressCreateWithoutCustomerInput, CustomerAddressUncheckedCreateWithoutCustomerInput>
}
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<OrderCreateWithoutCustomerInput, OrderUncheckedCreateWithoutCustomerInput>
}
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<PreOrderCreateWithoutCustomerInput, PreOrderUncheckedCreateWithoutCustomerInput>
}
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<LedgerEntryCreateWithoutCustomerInput, LedgerEntryUncheckedCreateWithoutCustomerInput>
}
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<WalletBonusCreateWithoutCustomerInput, WalletBonusUncheckedCreateWithoutCustomerInput>
}
export type WalletBonusCreateManyCustomerInputEnvelope = {
data: WalletBonusCreateManyCustomerInput | WalletBonusCreateManyCustomerInput[]
skipDuplicates?: boolean
}
export type CityUpsertWithoutCustomersInput = {
update: XOR<CityUpdateWithoutCustomersInput, CityUncheckedUpdateWithoutCustomersInput>
create: XOR<CityCreateWithoutCustomersInput, CityUncheckedCreateWithoutCustomersInput>
where?: CityWhereInput
}
export type CityUpdateToOneWithWhereWithoutCustomersInput = {
where?: CityWhereInput
data: XOR<CityUpdateWithoutCustomersInput, CityUncheckedUpdateWithoutCustomersInput>
}
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<AdminUserUpdateWithoutReferredCustomersInput, AdminUserUncheckedUpdateWithoutReferredCustomersInput>
create: XOR<AdminUserCreateWithoutReferredCustomersInput, AdminUserUncheckedCreateWithoutReferredCustomersInput>
where?: AdminUserWhereInput
}
export type AdminUserUpdateToOneWithWhereWithoutReferredCustomersInput = {
where?: AdminUserWhereInput
data: XOR<AdminUserUpdateWithoutReferredCustomersInput, AdminUserUncheckedUpdateWithoutReferredCustomersInput>
}
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<CustomerAddressUpdateWithoutCustomerInput, CustomerAddressUncheckedUpdateWithoutCustomerInput>
create: XOR<CustomerAddressCreateWithoutCustomerInput, CustomerAddressUncheckedCreateWithoutCustomerInput>
}
export type CustomerAddressUpdateWithWhereUniqueWithoutCustomerInput = {
where: CustomerAddressWhereUniqueInput
data: XOR<CustomerAddressUpdateWithoutCustomerInput, CustomerAddressUncheckedUpdateWithoutCustomerInput>
}
export type CustomerAddressUpdateManyWithWhereWithoutCustomerInput = {
where: CustomerAddressScalarWhereInput
data: XOR<CustomerAddressUpdateManyMutationInput, CustomerAddressUncheckedUpdateManyWithoutCustomerInput>
}
export type OrderUpsertWithWhereUniqueWithoutCustomerInput = {
where: OrderWhereUniqueInput
update: XOR<OrderUpdateWithoutCustomerInput, OrderUncheckedUpdateWithoutCustomerInput>
create: XOR<OrderCreateWithoutCustomerInput, OrderUncheckedCreateWithoutCustomerInput>
}
export type OrderUpdateWithWhereUniqueWithoutCustomerInput = {
where: OrderWhereUniqueInput
data: XOR<OrderUpdateWithoutCustomerInput, OrderUncheckedUpdateWithoutCustomerInput>
}
export type OrderUpdateManyWithWhereWithoutCustomerInput = {
where: OrderScalarWhereInput
data: XOR<OrderUpdateManyMutationInput, OrderUncheckedUpdateManyWithoutCustomerInput>
}
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<PreOrderUpdateWithoutCustomerInput, PreOrderUncheckedUpdateWithoutCustomerInput>
create: XOR<PreOrderCreateWithoutCustomerInput, PreOrderUncheckedCreateWithoutCustomerInput>
}
export type PreOrderUpdateWithWhereUniqueWithoutCustomerInput = {
where: PreOrderWhereUniqueInput
data: XOR<PreOrderUpdateWithoutCustomerInput, PreOrderUncheckedUpdateWithoutCustomerInput>
}
export type PreOrderUpdateManyWithWhereWithoutCustomerInput = {
where: PreOrderScalarWhereInput
data: XOR<PreOrderUpdateManyMutationInput, PreOrderUncheckedUpdateManyWithoutCustomerInput>
}
export type LedgerEntryUpsertWithWhereUniqueWithoutCustomerInput = {
where: LedgerEntryWhereUniqueInput
update: XOR<LedgerEntryUpdateWithoutCustomerInput, LedgerEntryUncheckedUpdateWithoutCustomerInput>
create: XOR<LedgerEntryCreateWithoutCustomerInput, LedgerEntryUncheckedCreateWithoutCustomerInput>
}
export type LedgerEntryUpdateWithWhereUniqueWithoutCustomerInput = {
where: LedgerEntryWhereUniqueInput
data: XOR<LedgerEntryUpdateWithoutCustomerInput, LedgerEntryUncheckedUpdateWithoutCustomerInput>
}
export type LedgerEntryUpdateManyWithWhereWithoutCustomerInput = {
where: LedgerEntryScalarWhereInput
data: XOR<LedgerEntryUpdateManyMutationInput, LedgerEntryUncheckedUpdateManyWithoutCustomerInput>
}
export type WalletBonusUpsertWithWhereUniqueWithoutCustomerInput = {
where: WalletBonusWhereUniqueInput
update: XOR<WalletBonusUpdateWithoutCustomerInput, WalletBonusUncheckedUpdateWithoutCustomerInput>
create: XOR<WalletBonusCreateWithoutCustomerInput, WalletBonusUncheckedCreateWithoutCustomerInput>
}
export type WalletBonusUpdateWithWhereUniqueWithoutCustomerInput = {
where: WalletBonusWhereUniqueInput
data: XOR<WalletBonusUpdateWithoutCustomerInput, WalletBonusUncheckedUpdateWithoutCustomerInput>
}
export type WalletBonusUpdateManyWithWhereWithoutCustomerInput = {
where: WalletBonusScalarWhereInput
data: XOR<WalletBonusUpdateManyMutationInput, WalletBonusUncheckedUpdateManyWithoutCustomerInput>
}
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<CustomerCreateWithoutAddressesInput, CustomerUncheckedCreateWithoutAddressesInput>
}
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<CityCreateWithoutAddressesInput, CityUncheckedCreateWithoutAddressesInput>
}
export type CustomerUpsertWithoutAddressesInput = {
update: XOR<CustomerUpdateWithoutAddressesInput, CustomerUncheckedUpdateWithoutAddressesInput>
create: XOR<CustomerCreateWithoutAddressesInput, CustomerUncheckedCreateWithoutAddressesInput>
where?: CustomerWhereInput
}
export type CustomerUpdateToOneWithWhereWithoutAddressesInput = {
where?: CustomerWhereInput
data: XOR<CustomerUpdateWithoutAddressesInput, CustomerUncheckedUpdateWithoutAddressesInput>
}
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<CityUpdateWithoutAddressesInput, CityUncheckedUpdateWithoutAddressesInput>
create: XOR<CityCreateWithoutAddressesInput, CityUncheckedCreateWithoutAddressesInput>
where?: CityWhereInput
}
export type CityUpdateToOneWithWhereWithoutAddressesInput = {
where?: CityWhereInput
data: XOR<CityUpdateWithoutAddressesInput, CityUncheckedUpdateWithoutAddressesInput>
}
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<CityCreateWithoutBranchesInput, CityUncheckedCreateWithoutBranchesInput>
}
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<AdminUserCreateWithoutBranchInput, AdminUserUncheckedCreateWithoutBranchInput>
}
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<OrderCreateWithoutBranchInput, OrderUncheckedCreateWithoutBranchInput>
}
export type OrderCreateManyBranchInputEnvelope = {
data: OrderCreateManyBranchInput | OrderCreateManyBranchInput[]
skipDuplicates?: boolean
}
export type CityUpsertWithoutBranchesInput = {
update: XOR<CityUpdateWithoutBranchesInput, CityUncheckedUpdateWithoutBranchesInput>
create: XOR<CityCreateWithoutBranchesInput, CityUncheckedCreateWithoutBranchesInput>
where?: CityWhereInput
}
export type CityUpdateToOneWithWhereWithoutBranchesInput = {
where?: CityWhereInput
data: XOR<CityUpdateWithoutBranchesInput, CityUncheckedUpdateWithoutBranchesInput>
}
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<AdminUserUpdateWithoutBranchInput, AdminUserUncheckedUpdateWithoutBranchInput>
create: XOR<AdminUserCreateWithoutBranchInput, AdminUserUncheckedCreateWithoutBranchInput>
}
export type AdminUserUpdateWithWhereUniqueWithoutBranchInput = {
where: AdminUserWhereUniqueInput
data: XOR<AdminUserUpdateWithoutBranchInput, AdminUserUncheckedUpdateWithoutBranchInput>
}
export type AdminUserUpdateManyWithWhereWithoutBranchInput = {
where: AdminUserScalarWhereInput
data: XOR<AdminUserUpdateManyMutationInput, AdminUserUncheckedUpdateManyWithoutBranchInput>
}
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<OrderUpdateWithoutBranchInput, OrderUncheckedUpdateWithoutBranchInput>
create: XOR<OrderCreateWithoutBranchInput, OrderUncheckedCreateWithoutBranchInput>
}
export type OrderUpdateWithWhereUniqueWithoutBranchInput = {
where: OrderWhereUniqueInput
data: XOR<OrderUpdateWithoutBranchInput, OrderUncheckedUpdateWithoutBranchInput>
}
export type OrderUpdateManyWithWhereWithoutBranchInput = {
where: OrderScalarWhereInput
data: XOR<OrderUpdateManyMutationInput, OrderUncheckedUpdateManyWithoutBranchInput>
}
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<PreOrderCreateWithoutWorkshopInput, PreOrderUncheckedCreateWithoutWorkshopInput>
}
export type PreOrderCreateManyWorkshopInputEnvelope = {
data: PreOrderCreateManyWorkshopInput | PreOrderCreateManyWorkshopInput[]
skipDuplicates?: boolean
}
export type PreOrderUpsertWithWhereUniqueWithoutWorkshopInput = {
where: PreOrderWhereUniqueInput
update: XOR<PreOrderUpdateWithoutWorkshopInput, PreOrderUncheckedUpdateWithoutWorkshopInput>
create: XOR<PreOrderCreateWithoutWorkshopInput, PreOrderUncheckedCreateWithoutWorkshopInput>
}
export type PreOrderUpdateWithWhereUniqueWithoutWorkshopInput = {
where: PreOrderWhereUniqueInput
data: XOR<PreOrderUpdateWithoutWorkshopInput, PreOrderUncheckedUpdateWithoutWorkshopInput>
}
export type PreOrderUpdateManyWithWhereWithoutWorkshopInput = {
where: PreOrderScalarWhereInput
data: XOR<PreOrderUpdateManyMutationInput, PreOrderUncheckedUpdateManyWithoutWorkshopInput>
}
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<CategoryCreateWithoutChildrenInput, CategoryUncheckedCreateWithoutChildrenInput>
}
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<CategoryCreateWithoutParentInput, CategoryUncheckedCreateWithoutParentInput>
}
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<ProductCreateWithoutCategoryInput, ProductUncheckedCreateWithoutCategoryInput>
}
export type ProductCreateManyCategoryInputEnvelope = {
data: ProductCreateManyCategoryInput | ProductCreateManyCategoryInput[]
skipDuplicates?: boolean
}
export type CategoryUpsertWithoutChildrenInput = {
update: XOR<CategoryUpdateWithoutChildrenInput, CategoryUncheckedUpdateWithoutChildrenInput>
create: XOR<CategoryCreateWithoutChildrenInput, CategoryUncheckedCreateWithoutChildrenInput>
where?: CategoryWhereInput
}
export type CategoryUpdateToOneWithWhereWithoutChildrenInput = {
where?: CategoryWhereInput
data: XOR<CategoryUpdateWithoutChildrenInput, CategoryUncheckedUpdateWithoutChildrenInput>
}
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<CategoryUpdateWithoutParentInput, CategoryUncheckedUpdateWithoutParentInput>
create: XOR<CategoryCreateWithoutParentInput, CategoryUncheckedCreateWithoutParentInput>
}
export type CategoryUpdateWithWhereUniqueWithoutParentInput = {
where: CategoryWhereUniqueInput
data: XOR<CategoryUpdateWithoutParentInput, CategoryUncheckedUpdateWithoutParentInput>
}
export type CategoryUpdateManyWithWhereWithoutParentInput = {
where: CategoryScalarWhereInput
data: XOR<CategoryUpdateManyMutationInput, CategoryUncheckedUpdateManyWithoutParentInput>
}
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<ProductUpdateWithoutCategoryInput, ProductUncheckedUpdateWithoutCategoryInput>
create: XOR<ProductCreateWithoutCategoryInput, ProductUncheckedCreateWithoutCategoryInput>
}
export type ProductUpdateWithWhereUniqueWithoutCategoryInput = {
where: ProductWhereUniqueInput
data: XOR<ProductUpdateWithoutCategoryInput, ProductUncheckedUpdateWithoutCategoryInput>
}
export type ProductUpdateManyWithWhereWithoutCategoryInput = {
where: ProductScalarWhereInput
data: XOR<ProductUpdateManyMutationInput, ProductUncheckedUpdateManyWithoutCategoryInput>
}
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<ProductCreateWithoutBrandInput, ProductUncheckedCreateWithoutBrandInput>
}
export type ProductCreateManyBrandInputEnvelope = {
data: ProductCreateManyBrandInput | ProductCreateManyBrandInput[]
skipDuplicates?: boolean
}
export type ProductUpsertWithWhereUniqueWithoutBrandInput = {
where: ProductWhereUniqueInput
update: XOR<ProductUpdateWithoutBrandInput, ProductUncheckedUpdateWithoutBrandInput>
create: XOR<ProductCreateWithoutBrandInput, ProductUncheckedCreateWithoutBrandInput>
}
export type ProductUpdateWithWhereUniqueWithoutBrandInput = {
where: ProductWhereUniqueInput
data: XOR<ProductUpdateWithoutBrandInput, ProductUncheckedUpdateWithoutBrandInput>
}
export type ProductUpdateManyWithWhereWithoutBrandInput = {
where: ProductScalarWhereInput
data: XOR<ProductUpdateManyMutationInput, ProductUncheckedUpdateManyWithoutBrandInput>
}
export type CollectionProductCreateWithoutCollectionInput = {
product: ProductCreateNestedOneWithoutCollectionsInput
}
export type CollectionProductUncheckedCreateWithoutCollectionInput = {
productId: string
}
export type CollectionProductCreateOrConnectWithoutCollectionInput = {
where: CollectionProductWhereUniqueInput
create: XOR<CollectionProductCreateWithoutCollectionInput, CollectionProductUncheckedCreateWithoutCollectionInput>
}
export type CollectionProductCreateManyCollectionInputEnvelope = {
data: CollectionProductCreateManyCollectionInput | CollectionProductCreateManyCollectionInput[]
skipDuplicates?: boolean
}
export type CollectionProductUpsertWithWhereUniqueWithoutCollectionInput = {
where: CollectionProductWhereUniqueInput
update: XOR<CollectionProductUpdateWithoutCollectionInput, CollectionProductUncheckedUpdateWithoutCollectionInput>
create: XOR<CollectionProductCreateWithoutCollectionInput, CollectionProductUncheckedCreateWithoutCollectionInput>
}
export type CollectionProductUpdateWithWhereUniqueWithoutCollectionInput = {
where: CollectionProductWhereUniqueInput
data: XOR<CollectionProductUpdateWithoutCollectionInput, CollectionProductUncheckedUpdateWithoutCollectionInput>
}
export type CollectionProductUpdateManyWithWhereWithoutCollectionInput = {
where: CollectionProductScalarWhereInput
data: XOR<CollectionProductUpdateManyMutationInput, CollectionProductUncheckedUpdateManyWithoutCollectionInput>
}
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<CollectionCreateWithoutProductsInput, CollectionUncheckedCreateWithoutProductsInput>
}
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<ProductCreateWithoutCollectionsInput, ProductUncheckedCreateWithoutCollectionsInput>
}
export type CollectionUpsertWithoutProductsInput = {
update: XOR<CollectionUpdateWithoutProductsInput, CollectionUncheckedUpdateWithoutProductsInput>
create: XOR<CollectionCreateWithoutProductsInput, CollectionUncheckedCreateWithoutProductsInput>
where?: CollectionWhereInput
}
export type CollectionUpdateToOneWithWhereWithoutProductsInput = {
where?: CollectionWhereInput
data: XOR<CollectionUpdateWithoutProductsInput, CollectionUncheckedUpdateWithoutProductsInput>
}
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<ProductUpdateWithoutCollectionsInput, ProductUncheckedUpdateWithoutCollectionsInput>
create: XOR<ProductCreateWithoutCollectionsInput, ProductUncheckedCreateWithoutCollectionsInput>
where?: ProductWhereInput
}
export type ProductUpdateToOneWithWhereWithoutCollectionsInput = {
where?: ProductWhereInput
data: XOR<ProductUpdateWithoutCollectionsInput, ProductUncheckedUpdateWithoutCollectionsInput>
}
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<CategoryCreateWithoutProductsInput, CategoryUncheckedCreateWithoutProductsInput>
}
export type BrandCreateWithoutProductsInput = {
id?: string
title: string
}
export type BrandUncheckedCreateWithoutProductsInput = {
id?: string
title: string
}
export type BrandCreateOrConnectWithoutProductsInput = {
where: BrandWhereUniqueInput
create: XOR<BrandCreateWithoutProductsInput, BrandUncheckedCreateWithoutProductsInput>
}
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<ProductVariantCreateWithoutProductInput, ProductVariantUncheckedCreateWithoutProductInput>
}
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<ProductImageCreateWithoutProductInput, ProductImageUncheckedCreateWithoutProductInput>
}
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<CollectionProductCreateWithoutProductInput, CollectionProductUncheckedCreateWithoutProductInput>
}
export type CollectionProductCreateManyProductInputEnvelope = {
data: CollectionProductCreateManyProductInput | CollectionProductCreateManyProductInput[]
skipDuplicates?: boolean
}
export type CategoryUpsertWithoutProductsInput = {
update: XOR<CategoryUpdateWithoutProductsInput, CategoryUncheckedUpdateWithoutProductsInput>
create: XOR<CategoryCreateWithoutProductsInput, CategoryUncheckedCreateWithoutProductsInput>
where?: CategoryWhereInput
}
export type CategoryUpdateToOneWithWhereWithoutProductsInput = {
where?: CategoryWhereInput
data: XOR<CategoryUpdateWithoutProductsInput, CategoryUncheckedUpdateWithoutProductsInput>
}
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<BrandUpdateWithoutProductsInput, BrandUncheckedUpdateWithoutProductsInput>
create: XOR<BrandCreateWithoutProductsInput, BrandUncheckedCreateWithoutProductsInput>
where?: BrandWhereInput
}
export type BrandUpdateToOneWithWhereWithoutProductsInput = {
where?: BrandWhereInput
data: XOR<BrandUpdateWithoutProductsInput, BrandUncheckedUpdateWithoutProductsInput>
}
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<ProductVariantUpdateWithoutProductInput, ProductVariantUncheckedUpdateWithoutProductInput>
create: XOR<ProductVariantCreateWithoutProductInput, ProductVariantUncheckedCreateWithoutProductInput>
}
export type ProductVariantUpdateWithWhereUniqueWithoutProductInput = {
where: ProductVariantWhereUniqueInput
data: XOR<ProductVariantUpdateWithoutProductInput, ProductVariantUncheckedUpdateWithoutProductInput>
}
export type ProductVariantUpdateManyWithWhereWithoutProductInput = {
where: ProductVariantScalarWhereInput
data: XOR<ProductVariantUpdateManyMutationInput, ProductVariantUncheckedUpdateManyWithoutProductInput>
}
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<ProductImageUpdateWithoutProductInput, ProductImageUncheckedUpdateWithoutProductInput>
create: XOR<ProductImageCreateWithoutProductInput, ProductImageUncheckedCreateWithoutProductInput>
}
export type ProductImageUpdateWithWhereUniqueWithoutProductInput = {
where: ProductImageWhereUniqueInput
data: XOR<ProductImageUpdateWithoutProductInput, ProductImageUncheckedUpdateWithoutProductInput>
}
export type ProductImageUpdateManyWithWhereWithoutProductInput = {
where: ProductImageScalarWhereInput
data: XOR<ProductImageUpdateManyMutationInput, ProductImageUncheckedUpdateManyWithoutProductInput>
}
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<CollectionProductUpdateWithoutProductInput, CollectionProductUncheckedUpdateWithoutProductInput>
create: XOR<CollectionProductCreateWithoutProductInput, CollectionProductUncheckedCreateWithoutProductInput>
}
export type CollectionProductUpdateWithWhereUniqueWithoutProductInput = {
where: CollectionProductWhereUniqueInput
data: XOR<CollectionProductUpdateWithoutProductInput, CollectionProductUncheckedUpdateWithoutProductInput>
}
export type CollectionProductUpdateManyWithWhereWithoutProductInput = {
where: CollectionProductScalarWhereInput
data: XOR<CollectionProductUpdateManyMutationInput, CollectionProductUncheckedUpdateManyWithoutProductInput>
}
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<ProductCreateWithoutImagesInput, ProductUncheckedCreateWithoutImagesInput>
}
export type ProductUpsertWithoutImagesInput = {
update: XOR<ProductUpdateWithoutImagesInput, ProductUncheckedUpdateWithoutImagesInput>
create: XOR<ProductCreateWithoutImagesInput, ProductUncheckedCreateWithoutImagesInput>
where?: ProductWhereInput
}
export type ProductUpdateToOneWithWhereWithoutImagesInput = {
where?: ProductWhereInput
data: XOR<ProductUpdateWithoutImagesInput, ProductUncheckedUpdateWithoutImagesInput>
}
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<ProductCreateWithoutVariantsInput, ProductUncheckedCreateWithoutVariantsInput>
}
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<OrderItemCreateWithoutProductVariantInput, OrderItemUncheckedCreateWithoutProductVariantInput>
}
export type OrderItemCreateManyProductVariantInputEnvelope = {
data: OrderItemCreateManyProductVariantInput | OrderItemCreateManyProductVariantInput[]
skipDuplicates?: boolean
}
export type ProductUpsertWithoutVariantsInput = {
update: XOR<ProductUpdateWithoutVariantsInput, ProductUncheckedUpdateWithoutVariantsInput>
create: XOR<ProductCreateWithoutVariantsInput, ProductUncheckedCreateWithoutVariantsInput>
where?: ProductWhereInput
}
export type ProductUpdateToOneWithWhereWithoutVariantsInput = {
where?: ProductWhereInput
data: XOR<ProductUpdateWithoutVariantsInput, ProductUncheckedUpdateWithoutVariantsInput>
}
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<OrderItemUpdateWithoutProductVariantInput, OrderItemUncheckedUpdateWithoutProductVariantInput>
create: XOR<OrderItemCreateWithoutProductVariantInput, OrderItemUncheckedCreateWithoutProductVariantInput>
}
export type OrderItemUpdateWithWhereUniqueWithoutProductVariantInput = {
where: OrderItemWhereUniqueInput
data: XOR<OrderItemUpdateWithoutProductVariantInput, OrderItemUncheckedUpdateWithoutProductVariantInput>
}
export type OrderItemUpdateManyWithWhereWithoutProductVariantInput = {
where: OrderItemScalarWhereInput
data: XOR<OrderItemUpdateManyMutationInput, OrderItemUncheckedUpdateManyWithoutProductVariantInput>
}
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<CustomerCreateWithoutOrdersInput, CustomerUncheckedCreateWithoutOrdersInput>
}
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<BranchCreateWithoutOrdersInput, BranchUncheckedCreateWithoutOrdersInput>
}
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<OrderItemCreateWithoutOrderInput, OrderItemUncheckedCreateWithoutOrderInput>
}
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<OrderStatusEventCreateWithoutOrderInput, OrderStatusEventUncheckedCreateWithoutOrderInput>
}
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<LedgerEntryCreateWithoutOrderInput, LedgerEntryUncheckedCreateWithoutOrderInput>
}
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<PreOrderCreateWithoutConvertedOrderInput, PreOrderUncheckedCreateWithoutConvertedOrderInput>
}
export type CustomerUpsertWithoutOrdersInput = {
update: XOR<CustomerUpdateWithoutOrdersInput, CustomerUncheckedUpdateWithoutOrdersInput>
create: XOR<CustomerCreateWithoutOrdersInput, CustomerUncheckedCreateWithoutOrdersInput>
where?: CustomerWhereInput
}
export type CustomerUpdateToOneWithWhereWithoutOrdersInput = {
where?: CustomerWhereInput
data: XOR<CustomerUpdateWithoutOrdersInput, CustomerUncheckedUpdateWithoutOrdersInput>
}
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<BranchUpdateWithoutOrdersInput, BranchUncheckedUpdateWithoutOrdersInput>
create: XOR<BranchCreateWithoutOrdersInput, BranchUncheckedCreateWithoutOrdersInput>
where?: BranchWhereInput
}
export type BranchUpdateToOneWithWhereWithoutOrdersInput = {
where?: BranchWhereInput
data: XOR<BranchUpdateWithoutOrdersInput, BranchUncheckedUpdateWithoutOrdersInput>
}
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<OrderItemUpdateWithoutOrderInput, OrderItemUncheckedUpdateWithoutOrderInput>
create: XOR<OrderItemCreateWithoutOrderInput, OrderItemUncheckedCreateWithoutOrderInput>
}
export type OrderItemUpdateWithWhereUniqueWithoutOrderInput = {
where: OrderItemWhereUniqueInput
data: XOR<OrderItemUpdateWithoutOrderInput, OrderItemUncheckedUpdateWithoutOrderInput>
}
export type OrderItemUpdateManyWithWhereWithoutOrderInput = {
where: OrderItemScalarWhereInput
data: XOR<OrderItemUpdateManyMutationInput, OrderItemUncheckedUpdateManyWithoutOrderInput>
}
export type OrderStatusEventUpsertWithWhereUniqueWithoutOrderInput = {
where: OrderStatusEventWhereUniqueInput
update: XOR<OrderStatusEventUpdateWithoutOrderInput, OrderStatusEventUncheckedUpdateWithoutOrderInput>
create: XOR<OrderStatusEventCreateWithoutOrderInput, OrderStatusEventUncheckedCreateWithoutOrderInput>
}
export type OrderStatusEventUpdateWithWhereUniqueWithoutOrderInput = {
where: OrderStatusEventWhereUniqueInput
data: XOR<OrderStatusEventUpdateWithoutOrderInput, OrderStatusEventUncheckedUpdateWithoutOrderInput>
}
export type OrderStatusEventUpdateManyWithWhereWithoutOrderInput = {
where: OrderStatusEventScalarWhereInput
data: XOR<OrderStatusEventUpdateManyMutationInput, OrderStatusEventUncheckedUpdateManyWithoutOrderInput>
}
export type LedgerEntryUpsertWithWhereUniqueWithoutOrderInput = {
where: LedgerEntryWhereUniqueInput
update: XOR<LedgerEntryUpdateWithoutOrderInput, LedgerEntryUncheckedUpdateWithoutOrderInput>
create: XOR<LedgerEntryCreateWithoutOrderInput, LedgerEntryUncheckedCreateWithoutOrderInput>
}
export type LedgerEntryUpdateWithWhereUniqueWithoutOrderInput = {
where: LedgerEntryWhereUniqueInput
data: XOR<LedgerEntryUpdateWithoutOrderInput, LedgerEntryUncheckedUpdateWithoutOrderInput>
}
export type LedgerEntryUpdateManyWithWhereWithoutOrderInput = {
where: LedgerEntryScalarWhereInput
data: XOR<LedgerEntryUpdateManyMutationInput, LedgerEntryUncheckedUpdateManyWithoutOrderInput>
}
export type PreOrderUpsertWithoutConvertedOrderInput = {
update: XOR<PreOrderUpdateWithoutConvertedOrderInput, PreOrderUncheckedUpdateWithoutConvertedOrderInput>
create: XOR<PreOrderCreateWithoutConvertedOrderInput, PreOrderUncheckedCreateWithoutConvertedOrderInput>
where?: PreOrderWhereInput
}
export type PreOrderUpdateToOneWithWhereWithoutConvertedOrderInput = {
where?: PreOrderWhereInput
data: XOR<PreOrderUpdateWithoutConvertedOrderInput, PreOrderUncheckedUpdateWithoutConvertedOrderInput>
}
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<OrderCreateWithoutItemsInput, OrderUncheckedCreateWithoutItemsInput>
}
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<ProductVariantCreateWithoutOrderItemsInput, ProductVariantUncheckedCreateWithoutOrderItemsInput>
}
export type OrderUpsertWithoutItemsInput = {
update: XOR<OrderUpdateWithoutItemsInput, OrderUncheckedUpdateWithoutItemsInput>
create: XOR<OrderCreateWithoutItemsInput, OrderUncheckedCreateWithoutItemsInput>
where?: OrderWhereInput
}
export type OrderUpdateToOneWithWhereWithoutItemsInput = {
where?: OrderWhereInput
data: XOR<OrderUpdateWithoutItemsInput, OrderUncheckedUpdateWithoutItemsInput>
}
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<ProductVariantUpdateWithoutOrderItemsInput, ProductVariantUncheckedUpdateWithoutOrderItemsInput>
create: XOR<ProductVariantCreateWithoutOrderItemsInput, ProductVariantUncheckedCreateWithoutOrderItemsInput>
where?: ProductVariantWhereInput
}
export type ProductVariantUpdateToOneWithWhereWithoutOrderItemsInput = {
where?: ProductVariantWhereInput
data: XOR<ProductVariantUpdateWithoutOrderItemsInput, ProductVariantUncheckedUpdateWithoutOrderItemsInput>
}
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<OrderCreateWithoutStatusEventsInput, OrderUncheckedCreateWithoutStatusEventsInput>
}
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<AdminUserCreateWithoutOrderStatusEventsInput, AdminUserUncheckedCreateWithoutOrderStatusEventsInput>
}
export type OrderUpsertWithoutStatusEventsInput = {
update: XOR<OrderUpdateWithoutStatusEventsInput, OrderUncheckedUpdateWithoutStatusEventsInput>
create: XOR<OrderCreateWithoutStatusEventsInput, OrderUncheckedCreateWithoutStatusEventsInput>
where?: OrderWhereInput
}
export type OrderUpdateToOneWithWhereWithoutStatusEventsInput = {
where?: OrderWhereInput
data: XOR<OrderUpdateWithoutStatusEventsInput, OrderUncheckedUpdateWithoutStatusEventsInput>
}
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<AdminUserUpdateWithoutOrderStatusEventsInput, AdminUserUncheckedUpdateWithoutOrderStatusEventsInput>
create: XOR<AdminUserCreateWithoutOrderStatusEventsInput, AdminUserUncheckedCreateWithoutOrderStatusEventsInput>
where?: AdminUserWhereInput
}
export type AdminUserUpdateToOneWithWhereWithoutOrderStatusEventsInput = {
where?: AdminUserWhereInput
data: XOR<AdminUserUpdateWithoutOrderStatusEventsInput, AdminUserUncheckedUpdateWithoutOrderStatusEventsInput>
}
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<CustomerCreateWithoutPreOrdersInput, CustomerUncheckedCreateWithoutPreOrdersInput>
}
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<CityCreateWithoutPreOrdersInput, CityUncheckedCreateWithoutPreOrdersInput>
}
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<WorkshopCreateWithoutPreOrdersInput, WorkshopUncheckedCreateWithoutPreOrdersInput>
}
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<OrderCreateWithoutConvertedFromPreOrderInput, OrderUncheckedCreateWithoutConvertedFromPreOrderInput>
}
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<PreOrderStatusEventCreateWithoutPreOrderInput, PreOrderStatusEventUncheckedCreateWithoutPreOrderInput>
}
export type PreOrderStatusEventCreateManyPreOrderInputEnvelope = {
data: PreOrderStatusEventCreateManyPreOrderInput | PreOrderStatusEventCreateManyPreOrderInput[]
skipDuplicates?: boolean
}
export type CustomerUpsertWithoutPreOrdersInput = {
update: XOR<CustomerUpdateWithoutPreOrdersInput, CustomerUncheckedUpdateWithoutPreOrdersInput>
create: XOR<CustomerCreateWithoutPreOrdersInput, CustomerUncheckedCreateWithoutPreOrdersInput>
where?: CustomerWhereInput
}
export type CustomerUpdateToOneWithWhereWithoutPreOrdersInput = {
where?: CustomerWhereInput
data: XOR<CustomerUpdateWithoutPreOrdersInput, CustomerUncheckedUpdateWithoutPreOrdersInput>
}
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<CityUpdateWithoutPreOrdersInput, CityUncheckedUpdateWithoutPreOrdersInput>
create: XOR<CityCreateWithoutPreOrdersInput, CityUncheckedCreateWithoutPreOrdersInput>
where?: CityWhereInput
}
export type CityUpdateToOneWithWhereWithoutPreOrdersInput = {
where?: CityWhereInput
data: XOR<CityUpdateWithoutPreOrdersInput, CityUncheckedUpdateWithoutPreOrdersInput>
}
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<WorkshopUpdateWithoutPreOrdersInput, WorkshopUncheckedUpdateWithoutPreOrdersInput>
create: XOR<WorkshopCreateWithoutPreOrdersInput, WorkshopUncheckedCreateWithoutPreOrdersInput>
where?: WorkshopWhereInput
}
export type WorkshopUpdateToOneWithWhereWithoutPreOrdersInput = {
where?: WorkshopWhereInput
data: XOR<WorkshopUpdateWithoutPreOrdersInput, WorkshopUncheckedUpdateWithoutPreOrdersInput>
}
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<OrderUpdateWithoutConvertedFromPreOrderInput, OrderUncheckedUpdateWithoutConvertedFromPreOrderInput>
create: XOR<OrderCreateWithoutConvertedFromPreOrderInput, OrderUncheckedCreateWithoutConvertedFromPreOrderInput>
where?: OrderWhereInput
}
export type OrderUpdateToOneWithWhereWithoutConvertedFromPreOrderInput = {
where?: OrderWhereInput
data: XOR<OrderUpdateWithoutConvertedFromPreOrderInput, OrderUncheckedUpdateWithoutConvertedFromPreOrderInput>
}
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<PreOrderStatusEventUpdateWithoutPreOrderInput, PreOrderStatusEventUncheckedUpdateWithoutPreOrderInput>
create: XOR<PreOrderStatusEventCreateWithoutPreOrderInput, PreOrderStatusEventUncheckedCreateWithoutPreOrderInput>
}
export type PreOrderStatusEventUpdateWithWhereUniqueWithoutPreOrderInput = {
where: PreOrderStatusEventWhereUniqueInput
data: XOR<PreOrderStatusEventUpdateWithoutPreOrderInput, PreOrderStatusEventUncheckedUpdateWithoutPreOrderInput>
}
export type PreOrderStatusEventUpdateManyWithWhereWithoutPreOrderInput = {
where: PreOrderStatusEventScalarWhereInput
data: XOR<PreOrderStatusEventUpdateManyMutationInput, PreOrderStatusEventUncheckedUpdateManyWithoutPreOrderInput>
}
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<PreOrderCreateWithoutStatusEventsInput, PreOrderUncheckedCreateWithoutStatusEventsInput>
}
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<AdminUserCreateWithoutPreOrderStatusEventsInput, AdminUserUncheckedCreateWithoutPreOrderStatusEventsInput>
}
export type PreOrderUpsertWithoutStatusEventsInput = {
update: XOR<PreOrderUpdateWithoutStatusEventsInput, PreOrderUncheckedUpdateWithoutStatusEventsInput>
create: XOR<PreOrderCreateWithoutStatusEventsInput, PreOrderUncheckedCreateWithoutStatusEventsInput>
where?: PreOrderWhereInput
}
export type PreOrderUpdateToOneWithWhereWithoutStatusEventsInput = {
where?: PreOrderWhereInput
data: XOR<PreOrderUpdateWithoutStatusEventsInput, PreOrderUncheckedUpdateWithoutStatusEventsInput>
}
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<AdminUserUpdateWithoutPreOrderStatusEventsInput, AdminUserUncheckedUpdateWithoutPreOrderStatusEventsInput>
create: XOR<AdminUserCreateWithoutPreOrderStatusEventsInput, AdminUserUncheckedCreateWithoutPreOrderStatusEventsInput>
where?: AdminUserWhereInput
}
export type AdminUserUpdateToOneWithWhereWithoutPreOrderStatusEventsInput = {
where?: AdminUserWhereInput
data: XOR<AdminUserUpdateWithoutPreOrderStatusEventsInput, AdminUserUncheckedUpdateWithoutPreOrderStatusEventsInput>
}
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<CustomerCreateWithoutLedgerEntriesInput, CustomerUncheckedCreateWithoutLedgerEntriesInput>
}
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<OrderCreateWithoutLedgerEntriesInput, OrderUncheckedCreateWithoutLedgerEntriesInput>
}
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<AdminUserCreateWithoutPostedLedgerEntriesInput, AdminUserUncheckedCreateWithoutPostedLedgerEntriesInput>
}
export type CustomerUpsertWithoutLedgerEntriesInput = {
update: XOR<CustomerUpdateWithoutLedgerEntriesInput, CustomerUncheckedUpdateWithoutLedgerEntriesInput>
create: XOR<CustomerCreateWithoutLedgerEntriesInput, CustomerUncheckedCreateWithoutLedgerEntriesInput>
where?: CustomerWhereInput
}
export type CustomerUpdateToOneWithWhereWithoutLedgerEntriesInput = {
where?: CustomerWhereInput
data: XOR<CustomerUpdateWithoutLedgerEntriesInput, CustomerUncheckedUpdateWithoutLedgerEntriesInput>
}
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<OrderUpdateWithoutLedgerEntriesInput, OrderUncheckedUpdateWithoutLedgerEntriesInput>
create: XOR<OrderCreateWithoutLedgerEntriesInput, OrderUncheckedCreateWithoutLedgerEntriesInput>
where?: OrderWhereInput
}
export type OrderUpdateToOneWithWhereWithoutLedgerEntriesInput = {
where?: OrderWhereInput
data: XOR<OrderUpdateWithoutLedgerEntriesInput, OrderUncheckedUpdateWithoutLedgerEntriesInput>
}
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<AdminUserUpdateWithoutPostedLedgerEntriesInput, AdminUserUncheckedUpdateWithoutPostedLedgerEntriesInput>
create: XOR<AdminUserCreateWithoutPostedLedgerEntriesInput, AdminUserUncheckedCreateWithoutPostedLedgerEntriesInput>
where?: AdminUserWhereInput
}
export type AdminUserUpdateToOneWithWhereWithoutPostedLedgerEntriesInput = {
where?: AdminUserWhereInput
data: XOR<AdminUserUpdateWithoutPostedLedgerEntriesInput, AdminUserUncheckedUpdateWithoutPostedLedgerEntriesInput>
}
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<CustomerCreateWithoutWalletBonusesInput, CustomerUncheckedCreateWithoutWalletBonusesInput>
}
export type CustomerUpsertWithoutWalletBonusesInput = {
update: XOR<CustomerUpdateWithoutWalletBonusesInput, CustomerUncheckedUpdateWithoutWalletBonusesInput>
create: XOR<CustomerCreateWithoutWalletBonusesInput, CustomerUncheckedCreateWithoutWalletBonusesInput>
where?: CustomerWhereInput
}
export type CustomerUpdateToOneWithWhereWithoutWalletBonusesInput = {
where?: CustomerWhereInput
data: XOR<CustomerUpdateWithoutWalletBonusesInput, CustomerUncheckedUpdateWithoutWalletBonusesInput>
}
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<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CityCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use AdminUserCountOutputTypeDefaultArgs instead
*/
export type AdminUserCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = AdminUserCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use CustomerCountOutputTypeDefaultArgs instead
*/
export type CustomerCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CustomerCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use BranchCountOutputTypeDefaultArgs instead
*/
export type BranchCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = BranchCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use WorkshopCountOutputTypeDefaultArgs instead
*/
export type WorkshopCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = WorkshopCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use CategoryCountOutputTypeDefaultArgs instead
*/
export type CategoryCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CategoryCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use BrandCountOutputTypeDefaultArgs instead
*/
export type BrandCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = BrandCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use CollectionCountOutputTypeDefaultArgs instead
*/
export type CollectionCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CollectionCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use ProductCountOutputTypeDefaultArgs instead
*/
export type ProductCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ProductCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use ProductVariantCountOutputTypeDefaultArgs instead
*/
export type ProductVariantCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ProductVariantCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use OrderCountOutputTypeDefaultArgs instead
*/
export type OrderCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = OrderCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use PreOrderCountOutputTypeDefaultArgs instead
*/
export type PreOrderCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = PreOrderCountOutputTypeDefaultArgs<ExtArgs>
/**
* @deprecated Use CityDefaultArgs instead
*/
export type CityArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CityDefaultArgs<ExtArgs>
/**
* @deprecated Use AdminUserDefaultArgs instead
*/
export type AdminUserArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = AdminUserDefaultArgs<ExtArgs>
/**
* @deprecated Use CustomerDefaultArgs instead
*/
export type CustomerArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CustomerDefaultArgs<ExtArgs>
/**
* @deprecated Use CustomerAddressDefaultArgs instead
*/
export type CustomerAddressArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CustomerAddressDefaultArgs<ExtArgs>
/**
* @deprecated Use BranchDefaultArgs instead
*/
export type BranchArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = BranchDefaultArgs<ExtArgs>
/**
* @deprecated Use WorkshopDefaultArgs instead
*/
export type WorkshopArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = WorkshopDefaultArgs<ExtArgs>
/**
* @deprecated Use CategoryDefaultArgs instead
*/
export type CategoryArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CategoryDefaultArgs<ExtArgs>
/**
* @deprecated Use BrandDefaultArgs instead
*/
export type BrandArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = BrandDefaultArgs<ExtArgs>
/**
* @deprecated Use CollectionDefaultArgs instead
*/
export type CollectionArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CollectionDefaultArgs<ExtArgs>
/**
* @deprecated Use CollectionProductDefaultArgs instead
*/
export type CollectionProductArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CollectionProductDefaultArgs<ExtArgs>
/**
* @deprecated Use ProductDefaultArgs instead
*/
export type ProductArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ProductDefaultArgs<ExtArgs>
/**
* @deprecated Use ProductImageDefaultArgs instead
*/
export type ProductImageArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ProductImageDefaultArgs<ExtArgs>
/**
* @deprecated Use ProductVariantDefaultArgs instead
*/
export type ProductVariantArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ProductVariantDefaultArgs<ExtArgs>
/**
* @deprecated Use OrderDefaultArgs instead
*/
export type OrderArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = OrderDefaultArgs<ExtArgs>
/**
* @deprecated Use OrderItemDefaultArgs instead
*/
export type OrderItemArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = OrderItemDefaultArgs<ExtArgs>
/**
* @deprecated Use OrderStatusEventDefaultArgs instead
*/
export type OrderStatusEventArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = OrderStatusEventDefaultArgs<ExtArgs>
/**
* @deprecated Use PreOrderDefaultArgs instead
*/
export type PreOrderArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = PreOrderDefaultArgs<ExtArgs>
/**
* @deprecated Use PreOrderStatusEventDefaultArgs instead
*/
export type PreOrderStatusEventArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = PreOrderStatusEventDefaultArgs<ExtArgs>
/**
* @deprecated Use LedgerEntryDefaultArgs instead
*/
export type LedgerEntryArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = LedgerEntryDefaultArgs<ExtArgs>
/**
* @deprecated Use GoldPriceQuoteDefaultArgs instead
*/
export type GoldPriceQuoteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = GoldPriceQuoteDefaultArgs<ExtArgs>
/**
* @deprecated Use WalletBonusDefaultArgs instead
*/
export type WalletBonusArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = WalletBonusDefaultArgs<ExtArgs>
/**
* Batch Payload for updateMany & deleteMany & createMany
*/
export type BatchPayload = {
count: number
}
/**
* DMMF
*/
export const dmmf: runtime.BaseDMMF
}