- Node/Express/TypeScript API under /api/v1 with JWT auth (login, refresh, logout, /me) - Prisma schema: vendors, users, roles, products, categories, taxes, transactions - SQLite for local dev; Postgres via docker-compose for production - Full CRUD routes for vendors, users, categories, taxes, products with Zod validation and RBAC - Paginated list endpoints scoped per vendor; refresh token rotation - React/TypeScript admin SPA (Vite): login, protected routing, sidebar layout - Pages: Dashboard, Catalog (tabbed Products/Categories/Taxes), Users, Vendor Settings - Shared UI: Table, Modal, FormField, Btn, PageHeader components - Multi-stage Dockerfile; docker-compose with Postgres healthcheck - Seed script with demo vendor and owner account - INSTRUCTIONS.md, ROADMAP.md, .claude/launch.json for dev server config Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
15993 lines
568 KiB
TypeScript
15993 lines
568 KiB
TypeScript
|
|
/**
|
|
* 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 Vendor
|
|
*
|
|
*/
|
|
export type Vendor = $Result.DefaultSelection<Prisma.$VendorPayload>
|
|
/**
|
|
* Model Role
|
|
*
|
|
*/
|
|
export type Role = $Result.DefaultSelection<Prisma.$RolePayload>
|
|
/**
|
|
* Model User
|
|
*
|
|
*/
|
|
export type User = $Result.DefaultSelection<Prisma.$UserPayload>
|
|
/**
|
|
* Model RefreshToken
|
|
*
|
|
*/
|
|
export type RefreshToken = $Result.DefaultSelection<Prisma.$RefreshTokenPayload>
|
|
/**
|
|
* Model Category
|
|
*
|
|
*/
|
|
export type Category = $Result.DefaultSelection<Prisma.$CategoryPayload>
|
|
/**
|
|
* Model Tax
|
|
*
|
|
*/
|
|
export type Tax = $Result.DefaultSelection<Prisma.$TaxPayload>
|
|
/**
|
|
* Model Product
|
|
*
|
|
*/
|
|
export type Product = $Result.DefaultSelection<Prisma.$ProductPayload>
|
|
/**
|
|
* Model Transaction
|
|
*
|
|
*/
|
|
export type Transaction = $Result.DefaultSelection<Prisma.$TransactionPayload>
|
|
/**
|
|
* Model TransactionItem
|
|
*
|
|
*/
|
|
export type TransactionItem = $Result.DefaultSelection<Prisma.$TransactionItemPayload>
|
|
|
|
/**
|
|
* ## Prisma Client ʲˢ
|
|
*
|
|
* Type-safe database client for TypeScript & Node.js
|
|
* @example
|
|
* ```
|
|
* const prisma = new PrismaClient()
|
|
* // Fetch zero or more Vendors
|
|
* const vendors = await prisma.vendor.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 Vendors
|
|
* const vendors = await prisma.vendor.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.vendor`: Exposes CRUD operations for the **Vendor** model.
|
|
* Example usage:
|
|
* ```ts
|
|
* // Fetch zero or more Vendors
|
|
* const vendors = await prisma.vendor.findMany()
|
|
* ```
|
|
*/
|
|
get vendor(): Prisma.VendorDelegate<ExtArgs>;
|
|
|
|
/**
|
|
* `prisma.role`: Exposes CRUD operations for the **Role** model.
|
|
* Example usage:
|
|
* ```ts
|
|
* // Fetch zero or more Roles
|
|
* const roles = await prisma.role.findMany()
|
|
* ```
|
|
*/
|
|
get role(): Prisma.RoleDelegate<ExtArgs>;
|
|
|
|
/**
|
|
* `prisma.user`: Exposes CRUD operations for the **User** model.
|
|
* Example usage:
|
|
* ```ts
|
|
* // Fetch zero or more Users
|
|
* const users = await prisma.user.findMany()
|
|
* ```
|
|
*/
|
|
get user(): Prisma.UserDelegate<ExtArgs>;
|
|
|
|
/**
|
|
* `prisma.refreshToken`: Exposes CRUD operations for the **RefreshToken** model.
|
|
* Example usage:
|
|
* ```ts
|
|
* // Fetch zero or more RefreshTokens
|
|
* const refreshTokens = await prisma.refreshToken.findMany()
|
|
* ```
|
|
*/
|
|
get refreshToken(): Prisma.RefreshTokenDelegate<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.tax`: Exposes CRUD operations for the **Tax** model.
|
|
* Example usage:
|
|
* ```ts
|
|
* // Fetch zero or more Taxes
|
|
* const taxes = await prisma.tax.findMany()
|
|
* ```
|
|
*/
|
|
get tax(): Prisma.TaxDelegate<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.transaction`: Exposes CRUD operations for the **Transaction** model.
|
|
* Example usage:
|
|
* ```ts
|
|
* // Fetch zero or more Transactions
|
|
* const transactions = await prisma.transaction.findMany()
|
|
* ```
|
|
*/
|
|
get transaction(): Prisma.TransactionDelegate<ExtArgs>;
|
|
|
|
/**
|
|
* `prisma.transactionItem`: Exposes CRUD operations for the **TransactionItem** model.
|
|
* Example usage:
|
|
* ```ts
|
|
* // Fetch zero or more TransactionItems
|
|
* const transactionItems = await prisma.transactionItem.findMany()
|
|
* ```
|
|
*/
|
|
get transactionItem(): Prisma.TransactionItemDelegate<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: {
|
|
Vendor: 'Vendor',
|
|
Role: 'Role',
|
|
User: 'User',
|
|
RefreshToken: 'RefreshToken',
|
|
Category: 'Category',
|
|
Tax: 'Tax',
|
|
Product: 'Product',
|
|
Transaction: 'Transaction',
|
|
TransactionItem: 'TransactionItem'
|
|
};
|
|
|
|
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: "vendor" | "role" | "user" | "refreshToken" | "category" | "tax" | "product" | "transaction" | "transactionItem"
|
|
txIsolationLevel: Prisma.TransactionIsolationLevel
|
|
}
|
|
model: {
|
|
Vendor: {
|
|
payload: Prisma.$VendorPayload<ExtArgs>
|
|
fields: Prisma.VendorFieldRefs
|
|
operations: {
|
|
findUnique: {
|
|
args: Prisma.VendorFindUniqueArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload> | null
|
|
}
|
|
findUniqueOrThrow: {
|
|
args: Prisma.VendorFindUniqueOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload>
|
|
}
|
|
findFirst: {
|
|
args: Prisma.VendorFindFirstArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload> | null
|
|
}
|
|
findFirstOrThrow: {
|
|
args: Prisma.VendorFindFirstOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload>
|
|
}
|
|
findMany: {
|
|
args: Prisma.VendorFindManyArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload>[]
|
|
}
|
|
create: {
|
|
args: Prisma.VendorCreateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload>
|
|
}
|
|
createMany: {
|
|
args: Prisma.VendorCreateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
createManyAndReturn: {
|
|
args: Prisma.VendorCreateManyAndReturnArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload>[]
|
|
}
|
|
delete: {
|
|
args: Prisma.VendorDeleteArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload>
|
|
}
|
|
update: {
|
|
args: Prisma.VendorUpdateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload>
|
|
}
|
|
deleteMany: {
|
|
args: Prisma.VendorDeleteManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
updateMany: {
|
|
args: Prisma.VendorUpdateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
upsert: {
|
|
args: Prisma.VendorUpsertArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$VendorPayload>
|
|
}
|
|
aggregate: {
|
|
args: Prisma.VendorAggregateArgs<ExtArgs>
|
|
result: $Utils.Optional<AggregateVendor>
|
|
}
|
|
groupBy: {
|
|
args: Prisma.VendorGroupByArgs<ExtArgs>
|
|
result: $Utils.Optional<VendorGroupByOutputType>[]
|
|
}
|
|
count: {
|
|
args: Prisma.VendorCountArgs<ExtArgs>
|
|
result: $Utils.Optional<VendorCountAggregateOutputType> | number
|
|
}
|
|
}
|
|
}
|
|
Role: {
|
|
payload: Prisma.$RolePayload<ExtArgs>
|
|
fields: Prisma.RoleFieldRefs
|
|
operations: {
|
|
findUnique: {
|
|
args: Prisma.RoleFindUniqueArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload> | null
|
|
}
|
|
findUniqueOrThrow: {
|
|
args: Prisma.RoleFindUniqueOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload>
|
|
}
|
|
findFirst: {
|
|
args: Prisma.RoleFindFirstArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload> | null
|
|
}
|
|
findFirstOrThrow: {
|
|
args: Prisma.RoleFindFirstOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload>
|
|
}
|
|
findMany: {
|
|
args: Prisma.RoleFindManyArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload>[]
|
|
}
|
|
create: {
|
|
args: Prisma.RoleCreateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload>
|
|
}
|
|
createMany: {
|
|
args: Prisma.RoleCreateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
createManyAndReturn: {
|
|
args: Prisma.RoleCreateManyAndReturnArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload>[]
|
|
}
|
|
delete: {
|
|
args: Prisma.RoleDeleteArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload>
|
|
}
|
|
update: {
|
|
args: Prisma.RoleUpdateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload>
|
|
}
|
|
deleteMany: {
|
|
args: Prisma.RoleDeleteManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
updateMany: {
|
|
args: Prisma.RoleUpdateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
upsert: {
|
|
args: Prisma.RoleUpsertArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RolePayload>
|
|
}
|
|
aggregate: {
|
|
args: Prisma.RoleAggregateArgs<ExtArgs>
|
|
result: $Utils.Optional<AggregateRole>
|
|
}
|
|
groupBy: {
|
|
args: Prisma.RoleGroupByArgs<ExtArgs>
|
|
result: $Utils.Optional<RoleGroupByOutputType>[]
|
|
}
|
|
count: {
|
|
args: Prisma.RoleCountArgs<ExtArgs>
|
|
result: $Utils.Optional<RoleCountAggregateOutputType> | number
|
|
}
|
|
}
|
|
}
|
|
User: {
|
|
payload: Prisma.$UserPayload<ExtArgs>
|
|
fields: Prisma.UserFieldRefs
|
|
operations: {
|
|
findUnique: {
|
|
args: Prisma.UserFindUniqueArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload> | null
|
|
}
|
|
findUniqueOrThrow: {
|
|
args: Prisma.UserFindUniqueOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload>
|
|
}
|
|
findFirst: {
|
|
args: Prisma.UserFindFirstArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload> | null
|
|
}
|
|
findFirstOrThrow: {
|
|
args: Prisma.UserFindFirstOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload>
|
|
}
|
|
findMany: {
|
|
args: Prisma.UserFindManyArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload>[]
|
|
}
|
|
create: {
|
|
args: Prisma.UserCreateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload>
|
|
}
|
|
createMany: {
|
|
args: Prisma.UserCreateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
createManyAndReturn: {
|
|
args: Prisma.UserCreateManyAndReturnArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload>[]
|
|
}
|
|
delete: {
|
|
args: Prisma.UserDeleteArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload>
|
|
}
|
|
update: {
|
|
args: Prisma.UserUpdateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload>
|
|
}
|
|
deleteMany: {
|
|
args: Prisma.UserDeleteManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
updateMany: {
|
|
args: Prisma.UserUpdateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
upsert: {
|
|
args: Prisma.UserUpsertArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$UserPayload>
|
|
}
|
|
aggregate: {
|
|
args: Prisma.UserAggregateArgs<ExtArgs>
|
|
result: $Utils.Optional<AggregateUser>
|
|
}
|
|
groupBy: {
|
|
args: Prisma.UserGroupByArgs<ExtArgs>
|
|
result: $Utils.Optional<UserGroupByOutputType>[]
|
|
}
|
|
count: {
|
|
args: Prisma.UserCountArgs<ExtArgs>
|
|
result: $Utils.Optional<UserCountAggregateOutputType> | number
|
|
}
|
|
}
|
|
}
|
|
RefreshToken: {
|
|
payload: Prisma.$RefreshTokenPayload<ExtArgs>
|
|
fields: Prisma.RefreshTokenFieldRefs
|
|
operations: {
|
|
findUnique: {
|
|
args: Prisma.RefreshTokenFindUniqueArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload> | null
|
|
}
|
|
findUniqueOrThrow: {
|
|
args: Prisma.RefreshTokenFindUniqueOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
|
|
}
|
|
findFirst: {
|
|
args: Prisma.RefreshTokenFindFirstArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload> | null
|
|
}
|
|
findFirstOrThrow: {
|
|
args: Prisma.RefreshTokenFindFirstOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
|
|
}
|
|
findMany: {
|
|
args: Prisma.RefreshTokenFindManyArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>[]
|
|
}
|
|
create: {
|
|
args: Prisma.RefreshTokenCreateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
|
|
}
|
|
createMany: {
|
|
args: Prisma.RefreshTokenCreateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
createManyAndReturn: {
|
|
args: Prisma.RefreshTokenCreateManyAndReturnArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>[]
|
|
}
|
|
delete: {
|
|
args: Prisma.RefreshTokenDeleteArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
|
|
}
|
|
update: {
|
|
args: Prisma.RefreshTokenUpdateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
|
|
}
|
|
deleteMany: {
|
|
args: Prisma.RefreshTokenDeleteManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
updateMany: {
|
|
args: Prisma.RefreshTokenUpdateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
upsert: {
|
|
args: Prisma.RefreshTokenUpsertArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
|
|
}
|
|
aggregate: {
|
|
args: Prisma.RefreshTokenAggregateArgs<ExtArgs>
|
|
result: $Utils.Optional<AggregateRefreshToken>
|
|
}
|
|
groupBy: {
|
|
args: Prisma.RefreshTokenGroupByArgs<ExtArgs>
|
|
result: $Utils.Optional<RefreshTokenGroupByOutputType>[]
|
|
}
|
|
count: {
|
|
args: Prisma.RefreshTokenCountArgs<ExtArgs>
|
|
result: $Utils.Optional<RefreshTokenCountAggregateOutputType> | 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
|
|
}
|
|
}
|
|
}
|
|
Tax: {
|
|
payload: Prisma.$TaxPayload<ExtArgs>
|
|
fields: Prisma.TaxFieldRefs
|
|
operations: {
|
|
findUnique: {
|
|
args: Prisma.TaxFindUniqueArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload> | null
|
|
}
|
|
findUniqueOrThrow: {
|
|
args: Prisma.TaxFindUniqueOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload>
|
|
}
|
|
findFirst: {
|
|
args: Prisma.TaxFindFirstArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload> | null
|
|
}
|
|
findFirstOrThrow: {
|
|
args: Prisma.TaxFindFirstOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload>
|
|
}
|
|
findMany: {
|
|
args: Prisma.TaxFindManyArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload>[]
|
|
}
|
|
create: {
|
|
args: Prisma.TaxCreateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload>
|
|
}
|
|
createMany: {
|
|
args: Prisma.TaxCreateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
createManyAndReturn: {
|
|
args: Prisma.TaxCreateManyAndReturnArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload>[]
|
|
}
|
|
delete: {
|
|
args: Prisma.TaxDeleteArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload>
|
|
}
|
|
update: {
|
|
args: Prisma.TaxUpdateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload>
|
|
}
|
|
deleteMany: {
|
|
args: Prisma.TaxDeleteManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
updateMany: {
|
|
args: Prisma.TaxUpdateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
upsert: {
|
|
args: Prisma.TaxUpsertArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TaxPayload>
|
|
}
|
|
aggregate: {
|
|
args: Prisma.TaxAggregateArgs<ExtArgs>
|
|
result: $Utils.Optional<AggregateTax>
|
|
}
|
|
groupBy: {
|
|
args: Prisma.TaxGroupByArgs<ExtArgs>
|
|
result: $Utils.Optional<TaxGroupByOutputType>[]
|
|
}
|
|
count: {
|
|
args: Prisma.TaxCountArgs<ExtArgs>
|
|
result: $Utils.Optional<TaxCountAggregateOutputType> | 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
|
|
}
|
|
}
|
|
}
|
|
Transaction: {
|
|
payload: Prisma.$TransactionPayload<ExtArgs>
|
|
fields: Prisma.TransactionFieldRefs
|
|
operations: {
|
|
findUnique: {
|
|
args: Prisma.TransactionFindUniqueArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload> | null
|
|
}
|
|
findUniqueOrThrow: {
|
|
args: Prisma.TransactionFindUniqueOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
|
|
}
|
|
findFirst: {
|
|
args: Prisma.TransactionFindFirstArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload> | null
|
|
}
|
|
findFirstOrThrow: {
|
|
args: Prisma.TransactionFindFirstOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
|
|
}
|
|
findMany: {
|
|
args: Prisma.TransactionFindManyArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload>[]
|
|
}
|
|
create: {
|
|
args: Prisma.TransactionCreateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
|
|
}
|
|
createMany: {
|
|
args: Prisma.TransactionCreateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
createManyAndReturn: {
|
|
args: Prisma.TransactionCreateManyAndReturnArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload>[]
|
|
}
|
|
delete: {
|
|
args: Prisma.TransactionDeleteArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
|
|
}
|
|
update: {
|
|
args: Prisma.TransactionUpdateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
|
|
}
|
|
deleteMany: {
|
|
args: Prisma.TransactionDeleteManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
updateMany: {
|
|
args: Prisma.TransactionUpdateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
upsert: {
|
|
args: Prisma.TransactionUpsertArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
|
|
}
|
|
aggregate: {
|
|
args: Prisma.TransactionAggregateArgs<ExtArgs>
|
|
result: $Utils.Optional<AggregateTransaction>
|
|
}
|
|
groupBy: {
|
|
args: Prisma.TransactionGroupByArgs<ExtArgs>
|
|
result: $Utils.Optional<TransactionGroupByOutputType>[]
|
|
}
|
|
count: {
|
|
args: Prisma.TransactionCountArgs<ExtArgs>
|
|
result: $Utils.Optional<TransactionCountAggregateOutputType> | number
|
|
}
|
|
}
|
|
}
|
|
TransactionItem: {
|
|
payload: Prisma.$TransactionItemPayload<ExtArgs>
|
|
fields: Prisma.TransactionItemFieldRefs
|
|
operations: {
|
|
findUnique: {
|
|
args: Prisma.TransactionItemFindUniqueArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload> | null
|
|
}
|
|
findUniqueOrThrow: {
|
|
args: Prisma.TransactionItemFindUniqueOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload>
|
|
}
|
|
findFirst: {
|
|
args: Prisma.TransactionItemFindFirstArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload> | null
|
|
}
|
|
findFirstOrThrow: {
|
|
args: Prisma.TransactionItemFindFirstOrThrowArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload>
|
|
}
|
|
findMany: {
|
|
args: Prisma.TransactionItemFindManyArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload>[]
|
|
}
|
|
create: {
|
|
args: Prisma.TransactionItemCreateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload>
|
|
}
|
|
createMany: {
|
|
args: Prisma.TransactionItemCreateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
createManyAndReturn: {
|
|
args: Prisma.TransactionItemCreateManyAndReturnArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload>[]
|
|
}
|
|
delete: {
|
|
args: Prisma.TransactionItemDeleteArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload>
|
|
}
|
|
update: {
|
|
args: Prisma.TransactionItemUpdateArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload>
|
|
}
|
|
deleteMany: {
|
|
args: Prisma.TransactionItemDeleteManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
updateMany: {
|
|
args: Prisma.TransactionItemUpdateManyArgs<ExtArgs>
|
|
result: BatchPayload
|
|
}
|
|
upsert: {
|
|
args: Prisma.TransactionItemUpsertArgs<ExtArgs>
|
|
result: $Utils.PayloadToResult<Prisma.$TransactionItemPayload>
|
|
}
|
|
aggregate: {
|
|
args: Prisma.TransactionItemAggregateArgs<ExtArgs>
|
|
result: $Utils.Optional<AggregateTransactionItem>
|
|
}
|
|
groupBy: {
|
|
args: Prisma.TransactionItemGroupByArgs<ExtArgs>
|
|
result: $Utils.Optional<TransactionItemGroupByOutputType>[]
|
|
}
|
|
count: {
|
|
args: Prisma.TransactionItemCountArgs<ExtArgs>
|
|
result: $Utils.Optional<TransactionItemCountAggregateOutputType> | 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 VendorCountOutputType
|
|
*/
|
|
|
|
export type VendorCountOutputType = {
|
|
users: number
|
|
categories: number
|
|
products: number
|
|
taxes: number
|
|
transactions: number
|
|
}
|
|
|
|
export type VendorCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
users?: boolean | VendorCountOutputTypeCountUsersArgs
|
|
categories?: boolean | VendorCountOutputTypeCountCategoriesArgs
|
|
products?: boolean | VendorCountOutputTypeCountProductsArgs
|
|
taxes?: boolean | VendorCountOutputTypeCountTaxesArgs
|
|
transactions?: boolean | VendorCountOutputTypeCountTransactionsArgs
|
|
}
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* VendorCountOutputType without action
|
|
*/
|
|
export type VendorCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the VendorCountOutputType
|
|
*/
|
|
select?: VendorCountOutputTypeSelect<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* VendorCountOutputType without action
|
|
*/
|
|
export type VendorCountOutputTypeCountUsersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: UserWhereInput
|
|
}
|
|
|
|
/**
|
|
* VendorCountOutputType without action
|
|
*/
|
|
export type VendorCountOutputTypeCountCategoriesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: CategoryWhereInput
|
|
}
|
|
|
|
/**
|
|
* VendorCountOutputType without action
|
|
*/
|
|
export type VendorCountOutputTypeCountProductsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: ProductWhereInput
|
|
}
|
|
|
|
/**
|
|
* VendorCountOutputType without action
|
|
*/
|
|
export type VendorCountOutputTypeCountTaxesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: TaxWhereInput
|
|
}
|
|
|
|
/**
|
|
* VendorCountOutputType without action
|
|
*/
|
|
export type VendorCountOutputTypeCountTransactionsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: TransactionWhereInput
|
|
}
|
|
|
|
|
|
/**
|
|
* Count Type RoleCountOutputType
|
|
*/
|
|
|
|
export type RoleCountOutputType = {
|
|
users: number
|
|
}
|
|
|
|
export type RoleCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
users?: boolean | RoleCountOutputTypeCountUsersArgs
|
|
}
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* RoleCountOutputType without action
|
|
*/
|
|
export type RoleCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RoleCountOutputType
|
|
*/
|
|
select?: RoleCountOutputTypeSelect<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* RoleCountOutputType without action
|
|
*/
|
|
export type RoleCountOutputTypeCountUsersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: UserWhereInput
|
|
}
|
|
|
|
|
|
/**
|
|
* Count Type UserCountOutputType
|
|
*/
|
|
|
|
export type UserCountOutputType = {
|
|
refreshTokens: number
|
|
transactions: number
|
|
}
|
|
|
|
export type UserCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
refreshTokens?: boolean | UserCountOutputTypeCountRefreshTokensArgs
|
|
transactions?: boolean | UserCountOutputTypeCountTransactionsArgs
|
|
}
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* UserCountOutputType without action
|
|
*/
|
|
export type UserCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the UserCountOutputType
|
|
*/
|
|
select?: UserCountOutputTypeSelect<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* UserCountOutputType without action
|
|
*/
|
|
export type UserCountOutputTypeCountRefreshTokensArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: RefreshTokenWhereInput
|
|
}
|
|
|
|
/**
|
|
* UserCountOutputType without action
|
|
*/
|
|
export type UserCountOutputTypeCountTransactionsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: TransactionWhereInput
|
|
}
|
|
|
|
|
|
/**
|
|
* Count Type CategoryCountOutputType
|
|
*/
|
|
|
|
export type CategoryCountOutputType = {
|
|
products: number
|
|
}
|
|
|
|
export type CategoryCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
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 CategoryCountOutputTypeCountProductsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: ProductWhereInput
|
|
}
|
|
|
|
|
|
/**
|
|
* Count Type TaxCountOutputType
|
|
*/
|
|
|
|
export type TaxCountOutputType = {
|
|
products: number
|
|
}
|
|
|
|
export type TaxCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
products?: boolean | TaxCountOutputTypeCountProductsArgs
|
|
}
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* TaxCountOutputType without action
|
|
*/
|
|
export type TaxCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TaxCountOutputType
|
|
*/
|
|
select?: TaxCountOutputTypeSelect<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* TaxCountOutputType without action
|
|
*/
|
|
export type TaxCountOutputTypeCountProductsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: ProductWhereInput
|
|
}
|
|
|
|
|
|
/**
|
|
* Count Type ProductCountOutputType
|
|
*/
|
|
|
|
export type ProductCountOutputType = {
|
|
transactionItems: number
|
|
}
|
|
|
|
export type ProductCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
transactionItems?: boolean | ProductCountOutputTypeCountTransactionItemsArgs
|
|
}
|
|
|
|
// 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 ProductCountOutputTypeCountTransactionItemsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: TransactionItemWhereInput
|
|
}
|
|
|
|
|
|
/**
|
|
* Count Type TransactionCountOutputType
|
|
*/
|
|
|
|
export type TransactionCountOutputType = {
|
|
items: number
|
|
}
|
|
|
|
export type TransactionCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
items?: boolean | TransactionCountOutputTypeCountItemsArgs
|
|
}
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* TransactionCountOutputType without action
|
|
*/
|
|
export type TransactionCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionCountOutputType
|
|
*/
|
|
select?: TransactionCountOutputTypeSelect<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* TransactionCountOutputType without action
|
|
*/
|
|
export type TransactionCountOutputTypeCountItemsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: TransactionItemWhereInput
|
|
}
|
|
|
|
|
|
/**
|
|
* Models
|
|
*/
|
|
|
|
/**
|
|
* Model Vendor
|
|
*/
|
|
|
|
export type AggregateVendor = {
|
|
_count: VendorCountAggregateOutputType | null
|
|
_min: VendorMinAggregateOutputType | null
|
|
_max: VendorMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type VendorMinAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
businessNum: string | null
|
|
taxSettings: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type VendorMaxAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
businessNum: string | null
|
|
taxSettings: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type VendorCountAggregateOutputType = {
|
|
id: number
|
|
name: number
|
|
businessNum: number
|
|
taxSettings: number
|
|
createdAt: number
|
|
updatedAt: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type VendorMinAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
businessNum?: true
|
|
taxSettings?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type VendorMaxAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
businessNum?: true
|
|
taxSettings?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type VendorCountAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
businessNum?: true
|
|
taxSettings?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
_all?: true
|
|
}
|
|
|
|
export type VendorAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Vendor to aggregate.
|
|
*/
|
|
where?: VendorWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Vendors to fetch.
|
|
*/
|
|
orderBy?: VendorOrderByWithRelationInput | VendorOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the start position
|
|
*/
|
|
cursor?: VendorWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Vendors 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` Vendors.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Count returned Vendors
|
|
**/
|
|
_count?: true | VendorCountAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the minimum value
|
|
**/
|
|
_min?: VendorMinAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the maximum value
|
|
**/
|
|
_max?: VendorMaxAggregateInputType
|
|
}
|
|
|
|
export type GetVendorAggregateType<T extends VendorAggregateArgs> = {
|
|
[P in keyof T & keyof AggregateVendor]: P extends '_count' | 'count'
|
|
? T[P] extends true
|
|
? number
|
|
: GetScalarType<T[P], AggregateVendor[P]>
|
|
: GetScalarType<T[P], AggregateVendor[P]>
|
|
}
|
|
|
|
|
|
|
|
|
|
export type VendorGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: VendorWhereInput
|
|
orderBy?: VendorOrderByWithAggregationInput | VendorOrderByWithAggregationInput[]
|
|
by: VendorScalarFieldEnum[] | VendorScalarFieldEnum
|
|
having?: VendorScalarWhereWithAggregatesInput
|
|
take?: number
|
|
skip?: number
|
|
_count?: VendorCountAggregateInputType | true
|
|
_min?: VendorMinAggregateInputType
|
|
_max?: VendorMaxAggregateInputType
|
|
}
|
|
|
|
export type VendorGroupByOutputType = {
|
|
id: string
|
|
name: string
|
|
businessNum: string | null
|
|
taxSettings: string | null
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
_count: VendorCountAggregateOutputType | null
|
|
_min: VendorMinAggregateOutputType | null
|
|
_max: VendorMaxAggregateOutputType | null
|
|
}
|
|
|
|
type GetVendorGroupByPayload<T extends VendorGroupByArgs> = Prisma.PrismaPromise<
|
|
Array<
|
|
PickEnumerable<VendorGroupByOutputType, T['by']> &
|
|
{
|
|
[P in ((keyof T) & (keyof VendorGroupByOutputType))]: P extends '_count'
|
|
? T[P] extends boolean
|
|
? number
|
|
: GetScalarType<T[P], VendorGroupByOutputType[P]>
|
|
: GetScalarType<T[P], VendorGroupByOutputType[P]>
|
|
}
|
|
>
|
|
>
|
|
|
|
|
|
export type VendorSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
name?: boolean
|
|
businessNum?: boolean
|
|
taxSettings?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
users?: boolean | Vendor$usersArgs<ExtArgs>
|
|
categories?: boolean | Vendor$categoriesArgs<ExtArgs>
|
|
products?: boolean | Vendor$productsArgs<ExtArgs>
|
|
taxes?: boolean | Vendor$taxesArgs<ExtArgs>
|
|
transactions?: boolean | Vendor$transactionsArgs<ExtArgs>
|
|
_count?: boolean | VendorCountOutputTypeDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["vendor"]>
|
|
|
|
export type VendorSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
name?: boolean
|
|
businessNum?: boolean
|
|
taxSettings?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
}, ExtArgs["result"]["vendor"]>
|
|
|
|
export type VendorSelectScalar = {
|
|
id?: boolean
|
|
name?: boolean
|
|
businessNum?: boolean
|
|
taxSettings?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
}
|
|
|
|
export type VendorInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
users?: boolean | Vendor$usersArgs<ExtArgs>
|
|
categories?: boolean | Vendor$categoriesArgs<ExtArgs>
|
|
products?: boolean | Vendor$productsArgs<ExtArgs>
|
|
taxes?: boolean | Vendor$taxesArgs<ExtArgs>
|
|
transactions?: boolean | Vendor$transactionsArgs<ExtArgs>
|
|
_count?: boolean | VendorCountOutputTypeDefaultArgs<ExtArgs>
|
|
}
|
|
export type VendorIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {}
|
|
|
|
export type $VendorPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "Vendor"
|
|
objects: {
|
|
users: Prisma.$UserPayload<ExtArgs>[]
|
|
categories: Prisma.$CategoryPayload<ExtArgs>[]
|
|
products: Prisma.$ProductPayload<ExtArgs>[]
|
|
taxes: Prisma.$TaxPayload<ExtArgs>[]
|
|
transactions: Prisma.$TransactionPayload<ExtArgs>[]
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
name: string
|
|
businessNum: string | null
|
|
taxSettings: string | null
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
}, ExtArgs["result"]["vendor"]>
|
|
composites: {}
|
|
}
|
|
|
|
type VendorGetPayload<S extends boolean | null | undefined | VendorDefaultArgs> = $Result.GetResult<Prisma.$VendorPayload, S>
|
|
|
|
type VendorCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
|
|
Omit<VendorFindManyArgs, 'select' | 'include' | 'distinct'> & {
|
|
select?: VendorCountAggregateInputType | true
|
|
}
|
|
|
|
export interface VendorDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
|
|
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Vendor'], meta: { name: 'Vendor' } }
|
|
/**
|
|
* Find zero or one Vendor that matches the filter.
|
|
* @param {VendorFindUniqueArgs} args - Arguments to find a Vendor
|
|
* @example
|
|
* // Get one Vendor
|
|
* const vendor = await prisma.vendor.findUnique({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUnique<T extends VendorFindUniqueArgs>(args: SelectSubset<T, VendorFindUniqueArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findUnique"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find one Vendor that matches the filter or throw an error with `error.code='P2025'`
|
|
* if no matches were found.
|
|
* @param {VendorFindUniqueOrThrowArgs} args - Arguments to find a Vendor
|
|
* @example
|
|
* // Get one Vendor
|
|
* const vendor = await prisma.vendor.findUniqueOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUniqueOrThrow<T extends VendorFindUniqueOrThrowArgs>(args: SelectSubset<T, VendorFindUniqueOrThrowArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findUniqueOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find the first Vendor 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 {VendorFindFirstArgs} args - Arguments to find a Vendor
|
|
* @example
|
|
* // Get one Vendor
|
|
* const vendor = await prisma.vendor.findFirst({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirst<T extends VendorFindFirstArgs>(args?: SelectSubset<T, VendorFindFirstArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find the first Vendor 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 {VendorFindFirstOrThrowArgs} args - Arguments to find a Vendor
|
|
* @example
|
|
* // Get one Vendor
|
|
* const vendor = await prisma.vendor.findFirstOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirstOrThrow<T extends VendorFindFirstOrThrowArgs>(args?: SelectSubset<T, VendorFindFirstOrThrowArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find zero or more Vendors 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 {VendorFindManyArgs} args - Arguments to filter and select certain fields only.
|
|
* @example
|
|
* // Get all Vendors
|
|
* const vendors = await prisma.vendor.findMany()
|
|
*
|
|
* // Get first 10 Vendors
|
|
* const vendors = await prisma.vendor.findMany({ take: 10 })
|
|
*
|
|
* // Only select the `id`
|
|
* const vendorWithIdOnly = await prisma.vendor.findMany({ select: { id: true } })
|
|
*
|
|
*/
|
|
findMany<T extends VendorFindManyArgs>(args?: SelectSubset<T, VendorFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findMany">>
|
|
|
|
/**
|
|
* Create a Vendor.
|
|
* @param {VendorCreateArgs} args - Arguments to create a Vendor.
|
|
* @example
|
|
* // Create one Vendor
|
|
* const Vendor = await prisma.vendor.create({
|
|
* data: {
|
|
* // ... data to create a Vendor
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
create<T extends VendorCreateArgs>(args: SelectSubset<T, VendorCreateArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "create">, never, ExtArgs>
|
|
|
|
/**
|
|
* Create many Vendors.
|
|
* @param {VendorCreateManyArgs} args - Arguments to create many Vendors.
|
|
* @example
|
|
* // Create many Vendors
|
|
* const vendor = await prisma.vendor.createMany({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
*/
|
|
createMany<T extends VendorCreateManyArgs>(args?: SelectSubset<T, VendorCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create many Vendors and returns the data saved in the database.
|
|
* @param {VendorCreateManyAndReturnArgs} args - Arguments to create many Vendors.
|
|
* @example
|
|
* // Create many Vendors
|
|
* const vendor = await prisma.vendor.createManyAndReturn({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
* // Create many Vendors and only return the `id`
|
|
* const vendorWithIdOnly = await prisma.vendor.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 VendorCreateManyAndReturnArgs>(args?: SelectSubset<T, VendorCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "createManyAndReturn">>
|
|
|
|
/**
|
|
* Delete a Vendor.
|
|
* @param {VendorDeleteArgs} args - Arguments to delete one Vendor.
|
|
* @example
|
|
* // Delete one Vendor
|
|
* const Vendor = await prisma.vendor.delete({
|
|
* where: {
|
|
* // ... filter to delete one Vendor
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
delete<T extends VendorDeleteArgs>(args: SelectSubset<T, VendorDeleteArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "delete">, never, ExtArgs>
|
|
|
|
/**
|
|
* Update one Vendor.
|
|
* @param {VendorUpdateArgs} args - Arguments to update one Vendor.
|
|
* @example
|
|
* // Update one Vendor
|
|
* const vendor = await prisma.vendor.update({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
update<T extends VendorUpdateArgs>(args: SelectSubset<T, VendorUpdateArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "update">, never, ExtArgs>
|
|
|
|
/**
|
|
* Delete zero or more Vendors.
|
|
* @param {VendorDeleteManyArgs} args - Arguments to filter Vendors to delete.
|
|
* @example
|
|
* // Delete a few Vendors
|
|
* const { count } = await prisma.vendor.deleteMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
deleteMany<T extends VendorDeleteManyArgs>(args?: SelectSubset<T, VendorDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Update zero or more Vendors.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {VendorUpdateManyArgs} args - Arguments to update one or more rows.
|
|
* @example
|
|
* // Update many Vendors
|
|
* const vendor = await prisma.vendor.updateMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
updateMany<T extends VendorUpdateManyArgs>(args: SelectSubset<T, VendorUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create or update one Vendor.
|
|
* @param {VendorUpsertArgs} args - Arguments to update or create a Vendor.
|
|
* @example
|
|
* // Update or create a Vendor
|
|
* const vendor = await prisma.vendor.upsert({
|
|
* create: {
|
|
* // ... data to create a Vendor
|
|
* },
|
|
* update: {
|
|
* // ... in case it already exists, update
|
|
* },
|
|
* where: {
|
|
* // ... the filter for the Vendor we want to update
|
|
* }
|
|
* })
|
|
*/
|
|
upsert<T extends VendorUpsertArgs>(args: SelectSubset<T, VendorUpsertArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "upsert">, never, ExtArgs>
|
|
|
|
|
|
/**
|
|
* Count the number of Vendors.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {VendorCountArgs} args - Arguments to filter Vendors to count.
|
|
* @example
|
|
* // Count the number of Vendors
|
|
* const count = await prisma.vendor.count({
|
|
* where: {
|
|
* // ... the filter for the Vendors we want to count
|
|
* }
|
|
* })
|
|
**/
|
|
count<T extends VendorCountArgs>(
|
|
args?: Subset<T, VendorCountArgs>,
|
|
): Prisma.PrismaPromise<
|
|
T extends $Utils.Record<'select', any>
|
|
? T['select'] extends true
|
|
? number
|
|
: GetScalarType<T['select'], VendorCountAggregateOutputType>
|
|
: number
|
|
>
|
|
|
|
/**
|
|
* Allows you to perform aggregations operations on a Vendor.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {VendorAggregateArgs} 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 VendorAggregateArgs>(args: Subset<T, VendorAggregateArgs>): Prisma.PrismaPromise<GetVendorAggregateType<T>>
|
|
|
|
/**
|
|
* Group by Vendor.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {VendorGroupByArgs} 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 VendorGroupByArgs,
|
|
HasSelectOrTake extends Or<
|
|
Extends<'skip', Keys<T>>,
|
|
Extends<'take', Keys<T>>
|
|
>,
|
|
OrderByArg extends True extends HasSelectOrTake
|
|
? { orderBy: VendorGroupByArgs['orderBy'] }
|
|
: { orderBy?: VendorGroupByArgs['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, VendorGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetVendorGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
|
|
/**
|
|
* Fields of the Vendor model
|
|
*/
|
|
readonly fields: VendorFieldRefs;
|
|
}
|
|
|
|
/**
|
|
* The delegate class that acts as a "Promise-like" for Vendor.
|
|
* 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__VendorClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
|
|
readonly [Symbol.toStringTag]: "PrismaPromise"
|
|
users<T extends Vendor$usersArgs<ExtArgs> = {}>(args?: Subset<T, Vendor$usersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findMany"> | Null>
|
|
categories<T extends Vendor$categoriesArgs<ExtArgs> = {}>(args?: Subset<T, Vendor$categoriesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, T, "findMany"> | Null>
|
|
products<T extends Vendor$productsArgs<ExtArgs> = {}>(args?: Subset<T, Vendor$productsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ProductPayload<ExtArgs>, T, "findMany"> | Null>
|
|
taxes<T extends Vendor$taxesArgs<ExtArgs> = {}>(args?: Subset<T, Vendor$taxesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "findMany"> | Null>
|
|
transactions<T extends Vendor$transactionsArgs<ExtArgs> = {}>(args?: Subset<T, Vendor$transactionsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionPayload<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 Vendor model
|
|
*/
|
|
interface VendorFieldRefs {
|
|
readonly id: FieldRef<"Vendor", 'String'>
|
|
readonly name: FieldRef<"Vendor", 'String'>
|
|
readonly businessNum: FieldRef<"Vendor", 'String'>
|
|
readonly taxSettings: FieldRef<"Vendor", 'String'>
|
|
readonly createdAt: FieldRef<"Vendor", 'DateTime'>
|
|
readonly updatedAt: FieldRef<"Vendor", 'DateTime'>
|
|
}
|
|
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* Vendor findUnique
|
|
*/
|
|
export type VendorFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Vendor to fetch.
|
|
*/
|
|
where: VendorWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Vendor findUniqueOrThrow
|
|
*/
|
|
export type VendorFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Vendor to fetch.
|
|
*/
|
|
where: VendorWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Vendor findFirst
|
|
*/
|
|
export type VendorFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Vendor to fetch.
|
|
*/
|
|
where?: VendorWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Vendors to fetch.
|
|
*/
|
|
orderBy?: VendorOrderByWithRelationInput | VendorOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Vendors.
|
|
*/
|
|
cursor?: VendorWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Vendors 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` Vendors.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Vendors.
|
|
*/
|
|
distinct?: VendorScalarFieldEnum | VendorScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Vendor findFirstOrThrow
|
|
*/
|
|
export type VendorFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Vendor to fetch.
|
|
*/
|
|
where?: VendorWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Vendors to fetch.
|
|
*/
|
|
orderBy?: VendorOrderByWithRelationInput | VendorOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Vendors.
|
|
*/
|
|
cursor?: VendorWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Vendors 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` Vendors.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Vendors.
|
|
*/
|
|
distinct?: VendorScalarFieldEnum | VendorScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Vendor findMany
|
|
*/
|
|
export type VendorFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Vendors to fetch.
|
|
*/
|
|
where?: VendorWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Vendors to fetch.
|
|
*/
|
|
orderBy?: VendorOrderByWithRelationInput | VendorOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for listing Vendors.
|
|
*/
|
|
cursor?: VendorWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Vendors 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` Vendors.
|
|
*/
|
|
skip?: number
|
|
distinct?: VendorScalarFieldEnum | VendorScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Vendor create
|
|
*/
|
|
export type VendorCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to create a Vendor.
|
|
*/
|
|
data: XOR<VendorCreateInput, VendorUncheckedCreateInput>
|
|
}
|
|
|
|
/**
|
|
* Vendor createMany
|
|
*/
|
|
export type VendorCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to create many Vendors.
|
|
*/
|
|
data: VendorCreateManyInput | VendorCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* Vendor createManyAndReturn
|
|
*/
|
|
export type VendorCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelectCreateManyAndReturn<ExtArgs> | null
|
|
/**
|
|
* The data used to create many Vendors.
|
|
*/
|
|
data: VendorCreateManyInput | VendorCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* Vendor update
|
|
*/
|
|
export type VendorUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to update a Vendor.
|
|
*/
|
|
data: XOR<VendorUpdateInput, VendorUncheckedUpdateInput>
|
|
/**
|
|
* Choose, which Vendor to update.
|
|
*/
|
|
where: VendorWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Vendor updateMany
|
|
*/
|
|
export type VendorUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to update Vendors.
|
|
*/
|
|
data: XOR<VendorUpdateManyMutationInput, VendorUncheckedUpdateManyInput>
|
|
/**
|
|
* Filter which Vendors to update
|
|
*/
|
|
where?: VendorWhereInput
|
|
}
|
|
|
|
/**
|
|
* Vendor upsert
|
|
*/
|
|
export type VendorUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* The filter to search for the Vendor to update in case it exists.
|
|
*/
|
|
where: VendorWhereUniqueInput
|
|
/**
|
|
* In case the Vendor found by the `where` argument doesn't exist, create a new Vendor with this data.
|
|
*/
|
|
create: XOR<VendorCreateInput, VendorUncheckedCreateInput>
|
|
/**
|
|
* In case the Vendor was found with the provided `where` argument, update it with this data.
|
|
*/
|
|
update: XOR<VendorUpdateInput, VendorUncheckedUpdateInput>
|
|
}
|
|
|
|
/**
|
|
* Vendor delete
|
|
*/
|
|
export type VendorDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
/**
|
|
* Filter which Vendor to delete.
|
|
*/
|
|
where: VendorWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Vendor deleteMany
|
|
*/
|
|
export type VendorDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Vendors to delete
|
|
*/
|
|
where?: VendorWhereInput
|
|
}
|
|
|
|
/**
|
|
* Vendor.users
|
|
*/
|
|
export type Vendor$usersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
where?: UserWhereInput
|
|
orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
|
|
cursor?: UserWhereUniqueInput
|
|
take?: number
|
|
skip?: number
|
|
distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Vendor.categories
|
|
*/
|
|
export type Vendor$categoriesArgs<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[]
|
|
}
|
|
|
|
/**
|
|
* Vendor.products
|
|
*/
|
|
export type Vendor$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[]
|
|
}
|
|
|
|
/**
|
|
* Vendor.taxes
|
|
*/
|
|
export type Vendor$taxesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
where?: TaxWhereInput
|
|
orderBy?: TaxOrderByWithRelationInput | TaxOrderByWithRelationInput[]
|
|
cursor?: TaxWhereUniqueInput
|
|
take?: number
|
|
skip?: number
|
|
distinct?: TaxScalarFieldEnum | TaxScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Vendor.transactions
|
|
*/
|
|
export type Vendor$transactionsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
where?: TransactionWhereInput
|
|
orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
|
|
cursor?: TransactionWhereUniqueInput
|
|
take?: number
|
|
skip?: number
|
|
distinct?: TransactionScalarFieldEnum | TransactionScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Vendor without action
|
|
*/
|
|
export type VendorDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Vendor
|
|
*/
|
|
select?: VendorSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: VendorInclude<ExtArgs> | null
|
|
}
|
|
|
|
|
|
/**
|
|
* Model Role
|
|
*/
|
|
|
|
export type AggregateRole = {
|
|
_count: RoleCountAggregateOutputType | null
|
|
_min: RoleMinAggregateOutputType | null
|
|
_max: RoleMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type RoleMinAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
}
|
|
|
|
export type RoleMaxAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
}
|
|
|
|
export type RoleCountAggregateOutputType = {
|
|
id: number
|
|
name: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type RoleMinAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
}
|
|
|
|
export type RoleMaxAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
}
|
|
|
|
export type RoleCountAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
_all?: true
|
|
}
|
|
|
|
export type RoleAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Role to aggregate.
|
|
*/
|
|
where?: RoleWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Roles to fetch.
|
|
*/
|
|
orderBy?: RoleOrderByWithRelationInput | RoleOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the start position
|
|
*/
|
|
cursor?: RoleWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Roles 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` Roles.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Count returned Roles
|
|
**/
|
|
_count?: true | RoleCountAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the minimum value
|
|
**/
|
|
_min?: RoleMinAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the maximum value
|
|
**/
|
|
_max?: RoleMaxAggregateInputType
|
|
}
|
|
|
|
export type GetRoleAggregateType<T extends RoleAggregateArgs> = {
|
|
[P in keyof T & keyof AggregateRole]: P extends '_count' | 'count'
|
|
? T[P] extends true
|
|
? number
|
|
: GetScalarType<T[P], AggregateRole[P]>
|
|
: GetScalarType<T[P], AggregateRole[P]>
|
|
}
|
|
|
|
|
|
|
|
|
|
export type RoleGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: RoleWhereInput
|
|
orderBy?: RoleOrderByWithAggregationInput | RoleOrderByWithAggregationInput[]
|
|
by: RoleScalarFieldEnum[] | RoleScalarFieldEnum
|
|
having?: RoleScalarWhereWithAggregatesInput
|
|
take?: number
|
|
skip?: number
|
|
_count?: RoleCountAggregateInputType | true
|
|
_min?: RoleMinAggregateInputType
|
|
_max?: RoleMaxAggregateInputType
|
|
}
|
|
|
|
export type RoleGroupByOutputType = {
|
|
id: string
|
|
name: string
|
|
_count: RoleCountAggregateOutputType | null
|
|
_min: RoleMinAggregateOutputType | null
|
|
_max: RoleMaxAggregateOutputType | null
|
|
}
|
|
|
|
type GetRoleGroupByPayload<T extends RoleGroupByArgs> = Prisma.PrismaPromise<
|
|
Array<
|
|
PickEnumerable<RoleGroupByOutputType, T['by']> &
|
|
{
|
|
[P in ((keyof T) & (keyof RoleGroupByOutputType))]: P extends '_count'
|
|
? T[P] extends boolean
|
|
? number
|
|
: GetScalarType<T[P], RoleGroupByOutputType[P]>
|
|
: GetScalarType<T[P], RoleGroupByOutputType[P]>
|
|
}
|
|
>
|
|
>
|
|
|
|
|
|
export type RoleSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
name?: boolean
|
|
users?: boolean | Role$usersArgs<ExtArgs>
|
|
_count?: boolean | RoleCountOutputTypeDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["role"]>
|
|
|
|
export type RoleSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
name?: boolean
|
|
}, ExtArgs["result"]["role"]>
|
|
|
|
export type RoleSelectScalar = {
|
|
id?: boolean
|
|
name?: boolean
|
|
}
|
|
|
|
export type RoleInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
users?: boolean | Role$usersArgs<ExtArgs>
|
|
_count?: boolean | RoleCountOutputTypeDefaultArgs<ExtArgs>
|
|
}
|
|
export type RoleIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {}
|
|
|
|
export type $RolePayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "Role"
|
|
objects: {
|
|
users: Prisma.$UserPayload<ExtArgs>[]
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
name: string
|
|
}, ExtArgs["result"]["role"]>
|
|
composites: {}
|
|
}
|
|
|
|
type RoleGetPayload<S extends boolean | null | undefined | RoleDefaultArgs> = $Result.GetResult<Prisma.$RolePayload, S>
|
|
|
|
type RoleCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
|
|
Omit<RoleFindManyArgs, 'select' | 'include' | 'distinct'> & {
|
|
select?: RoleCountAggregateInputType | true
|
|
}
|
|
|
|
export interface RoleDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
|
|
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Role'], meta: { name: 'Role' } }
|
|
/**
|
|
* Find zero or one Role that matches the filter.
|
|
* @param {RoleFindUniqueArgs} args - Arguments to find a Role
|
|
* @example
|
|
* // Get one Role
|
|
* const role = await prisma.role.findUnique({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUnique<T extends RoleFindUniqueArgs>(args: SelectSubset<T, RoleFindUniqueArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findUnique"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find one Role that matches the filter or throw an error with `error.code='P2025'`
|
|
* if no matches were found.
|
|
* @param {RoleFindUniqueOrThrowArgs} args - Arguments to find a Role
|
|
* @example
|
|
* // Get one Role
|
|
* const role = await prisma.role.findUniqueOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUniqueOrThrow<T extends RoleFindUniqueOrThrowArgs>(args: SelectSubset<T, RoleFindUniqueOrThrowArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findUniqueOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find the first Role 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 {RoleFindFirstArgs} args - Arguments to find a Role
|
|
* @example
|
|
* // Get one Role
|
|
* const role = await prisma.role.findFirst({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirst<T extends RoleFindFirstArgs>(args?: SelectSubset<T, RoleFindFirstArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find the first Role 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 {RoleFindFirstOrThrowArgs} args - Arguments to find a Role
|
|
* @example
|
|
* // Get one Role
|
|
* const role = await prisma.role.findFirstOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirstOrThrow<T extends RoleFindFirstOrThrowArgs>(args?: SelectSubset<T, RoleFindFirstOrThrowArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find zero or more Roles 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 {RoleFindManyArgs} args - Arguments to filter and select certain fields only.
|
|
* @example
|
|
* // Get all Roles
|
|
* const roles = await prisma.role.findMany()
|
|
*
|
|
* // Get first 10 Roles
|
|
* const roles = await prisma.role.findMany({ take: 10 })
|
|
*
|
|
* // Only select the `id`
|
|
* const roleWithIdOnly = await prisma.role.findMany({ select: { id: true } })
|
|
*
|
|
*/
|
|
findMany<T extends RoleFindManyArgs>(args?: SelectSubset<T, RoleFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findMany">>
|
|
|
|
/**
|
|
* Create a Role.
|
|
* @param {RoleCreateArgs} args - Arguments to create a Role.
|
|
* @example
|
|
* // Create one Role
|
|
* const Role = await prisma.role.create({
|
|
* data: {
|
|
* // ... data to create a Role
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
create<T extends RoleCreateArgs>(args: SelectSubset<T, RoleCreateArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "create">, never, ExtArgs>
|
|
|
|
/**
|
|
* Create many Roles.
|
|
* @param {RoleCreateManyArgs} args - Arguments to create many Roles.
|
|
* @example
|
|
* // Create many Roles
|
|
* const role = await prisma.role.createMany({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
*/
|
|
createMany<T extends RoleCreateManyArgs>(args?: SelectSubset<T, RoleCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create many Roles and returns the data saved in the database.
|
|
* @param {RoleCreateManyAndReturnArgs} args - Arguments to create many Roles.
|
|
* @example
|
|
* // Create many Roles
|
|
* const role = await prisma.role.createManyAndReturn({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
* // Create many Roles and only return the `id`
|
|
* const roleWithIdOnly = await prisma.role.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 RoleCreateManyAndReturnArgs>(args?: SelectSubset<T, RoleCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "createManyAndReturn">>
|
|
|
|
/**
|
|
* Delete a Role.
|
|
* @param {RoleDeleteArgs} args - Arguments to delete one Role.
|
|
* @example
|
|
* // Delete one Role
|
|
* const Role = await prisma.role.delete({
|
|
* where: {
|
|
* // ... filter to delete one Role
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
delete<T extends RoleDeleteArgs>(args: SelectSubset<T, RoleDeleteArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "delete">, never, ExtArgs>
|
|
|
|
/**
|
|
* Update one Role.
|
|
* @param {RoleUpdateArgs} args - Arguments to update one Role.
|
|
* @example
|
|
* // Update one Role
|
|
* const role = await prisma.role.update({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
update<T extends RoleUpdateArgs>(args: SelectSubset<T, RoleUpdateArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "update">, never, ExtArgs>
|
|
|
|
/**
|
|
* Delete zero or more Roles.
|
|
* @param {RoleDeleteManyArgs} args - Arguments to filter Roles to delete.
|
|
* @example
|
|
* // Delete a few Roles
|
|
* const { count } = await prisma.role.deleteMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
deleteMany<T extends RoleDeleteManyArgs>(args?: SelectSubset<T, RoleDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Update zero or more Roles.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {RoleUpdateManyArgs} args - Arguments to update one or more rows.
|
|
* @example
|
|
* // Update many Roles
|
|
* const role = await prisma.role.updateMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
updateMany<T extends RoleUpdateManyArgs>(args: SelectSubset<T, RoleUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create or update one Role.
|
|
* @param {RoleUpsertArgs} args - Arguments to update or create a Role.
|
|
* @example
|
|
* // Update or create a Role
|
|
* const role = await prisma.role.upsert({
|
|
* create: {
|
|
* // ... data to create a Role
|
|
* },
|
|
* update: {
|
|
* // ... in case it already exists, update
|
|
* },
|
|
* where: {
|
|
* // ... the filter for the Role we want to update
|
|
* }
|
|
* })
|
|
*/
|
|
upsert<T extends RoleUpsertArgs>(args: SelectSubset<T, RoleUpsertArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "upsert">, never, ExtArgs>
|
|
|
|
|
|
/**
|
|
* Count the number of Roles.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {RoleCountArgs} args - Arguments to filter Roles to count.
|
|
* @example
|
|
* // Count the number of Roles
|
|
* const count = await prisma.role.count({
|
|
* where: {
|
|
* // ... the filter for the Roles we want to count
|
|
* }
|
|
* })
|
|
**/
|
|
count<T extends RoleCountArgs>(
|
|
args?: Subset<T, RoleCountArgs>,
|
|
): Prisma.PrismaPromise<
|
|
T extends $Utils.Record<'select', any>
|
|
? T['select'] extends true
|
|
? number
|
|
: GetScalarType<T['select'], RoleCountAggregateOutputType>
|
|
: number
|
|
>
|
|
|
|
/**
|
|
* Allows you to perform aggregations operations on a Role.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {RoleAggregateArgs} 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 RoleAggregateArgs>(args: Subset<T, RoleAggregateArgs>): Prisma.PrismaPromise<GetRoleAggregateType<T>>
|
|
|
|
/**
|
|
* Group by Role.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {RoleGroupByArgs} 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 RoleGroupByArgs,
|
|
HasSelectOrTake extends Or<
|
|
Extends<'skip', Keys<T>>,
|
|
Extends<'take', Keys<T>>
|
|
>,
|
|
OrderByArg extends True extends HasSelectOrTake
|
|
? { orderBy: RoleGroupByArgs['orderBy'] }
|
|
: { orderBy?: RoleGroupByArgs['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, RoleGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetRoleGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
|
|
/**
|
|
* Fields of the Role model
|
|
*/
|
|
readonly fields: RoleFieldRefs;
|
|
}
|
|
|
|
/**
|
|
* The delegate class that acts as a "Promise-like" for Role.
|
|
* 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__RoleClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
|
|
readonly [Symbol.toStringTag]: "PrismaPromise"
|
|
users<T extends Role$usersArgs<ExtArgs> = {}>(args?: Subset<T, Role$usersArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<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 Role model
|
|
*/
|
|
interface RoleFieldRefs {
|
|
readonly id: FieldRef<"Role", 'String'>
|
|
readonly name: FieldRef<"Role", 'String'>
|
|
}
|
|
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* Role findUnique
|
|
*/
|
|
export type RoleFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Role to fetch.
|
|
*/
|
|
where: RoleWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Role findUniqueOrThrow
|
|
*/
|
|
export type RoleFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Role to fetch.
|
|
*/
|
|
where: RoleWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Role findFirst
|
|
*/
|
|
export type RoleFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Role to fetch.
|
|
*/
|
|
where?: RoleWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Roles to fetch.
|
|
*/
|
|
orderBy?: RoleOrderByWithRelationInput | RoleOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Roles.
|
|
*/
|
|
cursor?: RoleWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Roles 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` Roles.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Roles.
|
|
*/
|
|
distinct?: RoleScalarFieldEnum | RoleScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Role findFirstOrThrow
|
|
*/
|
|
export type RoleFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Role to fetch.
|
|
*/
|
|
where?: RoleWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Roles to fetch.
|
|
*/
|
|
orderBy?: RoleOrderByWithRelationInput | RoleOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Roles.
|
|
*/
|
|
cursor?: RoleWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Roles 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` Roles.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Roles.
|
|
*/
|
|
distinct?: RoleScalarFieldEnum | RoleScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Role findMany
|
|
*/
|
|
export type RoleFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Roles to fetch.
|
|
*/
|
|
where?: RoleWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Roles to fetch.
|
|
*/
|
|
orderBy?: RoleOrderByWithRelationInput | RoleOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for listing Roles.
|
|
*/
|
|
cursor?: RoleWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Roles 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` Roles.
|
|
*/
|
|
skip?: number
|
|
distinct?: RoleScalarFieldEnum | RoleScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Role create
|
|
*/
|
|
export type RoleCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to create a Role.
|
|
*/
|
|
data: XOR<RoleCreateInput, RoleUncheckedCreateInput>
|
|
}
|
|
|
|
/**
|
|
* Role createMany
|
|
*/
|
|
export type RoleCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to create many Roles.
|
|
*/
|
|
data: RoleCreateManyInput | RoleCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* Role createManyAndReturn
|
|
*/
|
|
export type RoleCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelectCreateManyAndReturn<ExtArgs> | null
|
|
/**
|
|
* The data used to create many Roles.
|
|
*/
|
|
data: RoleCreateManyInput | RoleCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* Role update
|
|
*/
|
|
export type RoleUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to update a Role.
|
|
*/
|
|
data: XOR<RoleUpdateInput, RoleUncheckedUpdateInput>
|
|
/**
|
|
* Choose, which Role to update.
|
|
*/
|
|
where: RoleWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Role updateMany
|
|
*/
|
|
export type RoleUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to update Roles.
|
|
*/
|
|
data: XOR<RoleUpdateManyMutationInput, RoleUncheckedUpdateManyInput>
|
|
/**
|
|
* Filter which Roles to update
|
|
*/
|
|
where?: RoleWhereInput
|
|
}
|
|
|
|
/**
|
|
* Role upsert
|
|
*/
|
|
export type RoleUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* The filter to search for the Role to update in case it exists.
|
|
*/
|
|
where: RoleWhereUniqueInput
|
|
/**
|
|
* In case the Role found by the `where` argument doesn't exist, create a new Role with this data.
|
|
*/
|
|
create: XOR<RoleCreateInput, RoleUncheckedCreateInput>
|
|
/**
|
|
* In case the Role was found with the provided `where` argument, update it with this data.
|
|
*/
|
|
update: XOR<RoleUpdateInput, RoleUncheckedUpdateInput>
|
|
}
|
|
|
|
/**
|
|
* Role delete
|
|
*/
|
|
export type RoleDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
/**
|
|
* Filter which Role to delete.
|
|
*/
|
|
where: RoleWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Role deleteMany
|
|
*/
|
|
export type RoleDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Roles to delete
|
|
*/
|
|
where?: RoleWhereInput
|
|
}
|
|
|
|
/**
|
|
* Role.users
|
|
*/
|
|
export type Role$usersArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
where?: UserWhereInput
|
|
orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
|
|
cursor?: UserWhereUniqueInput
|
|
take?: number
|
|
skip?: number
|
|
distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Role without action
|
|
*/
|
|
export type RoleDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Role
|
|
*/
|
|
select?: RoleSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RoleInclude<ExtArgs> | null
|
|
}
|
|
|
|
|
|
/**
|
|
* Model User
|
|
*/
|
|
|
|
export type AggregateUser = {
|
|
_count: UserCountAggregateOutputType | null
|
|
_min: UserMinAggregateOutputType | null
|
|
_max: UserMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type UserMinAggregateOutputType = {
|
|
id: string | null
|
|
email: string | null
|
|
passwordHash: string | null
|
|
name: string | null
|
|
vendorId: string | null
|
|
roleId: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type UserMaxAggregateOutputType = {
|
|
id: string | null
|
|
email: string | null
|
|
passwordHash: string | null
|
|
name: string | null
|
|
vendorId: string | null
|
|
roleId: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type UserCountAggregateOutputType = {
|
|
id: number
|
|
email: number
|
|
passwordHash: number
|
|
name: number
|
|
vendorId: number
|
|
roleId: number
|
|
createdAt: number
|
|
updatedAt: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type UserMinAggregateInputType = {
|
|
id?: true
|
|
email?: true
|
|
passwordHash?: true
|
|
name?: true
|
|
vendorId?: true
|
|
roleId?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type UserMaxAggregateInputType = {
|
|
id?: true
|
|
email?: true
|
|
passwordHash?: true
|
|
name?: true
|
|
vendorId?: true
|
|
roleId?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type UserCountAggregateInputType = {
|
|
id?: true
|
|
email?: true
|
|
passwordHash?: true
|
|
name?: true
|
|
vendorId?: true
|
|
roleId?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
_all?: true
|
|
}
|
|
|
|
export type UserAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which User to aggregate.
|
|
*/
|
|
where?: UserWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Users to fetch.
|
|
*/
|
|
orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the start position
|
|
*/
|
|
cursor?: UserWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Users 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` Users.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Count returned Users
|
|
**/
|
|
_count?: true | UserCountAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the minimum value
|
|
**/
|
|
_min?: UserMinAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the maximum value
|
|
**/
|
|
_max?: UserMaxAggregateInputType
|
|
}
|
|
|
|
export type GetUserAggregateType<T extends UserAggregateArgs> = {
|
|
[P in keyof T & keyof AggregateUser]: P extends '_count' | 'count'
|
|
? T[P] extends true
|
|
? number
|
|
: GetScalarType<T[P], AggregateUser[P]>
|
|
: GetScalarType<T[P], AggregateUser[P]>
|
|
}
|
|
|
|
|
|
|
|
|
|
export type UserGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: UserWhereInput
|
|
orderBy?: UserOrderByWithAggregationInput | UserOrderByWithAggregationInput[]
|
|
by: UserScalarFieldEnum[] | UserScalarFieldEnum
|
|
having?: UserScalarWhereWithAggregatesInput
|
|
take?: number
|
|
skip?: number
|
|
_count?: UserCountAggregateInputType | true
|
|
_min?: UserMinAggregateInputType
|
|
_max?: UserMaxAggregateInputType
|
|
}
|
|
|
|
export type UserGroupByOutputType = {
|
|
id: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
vendorId: string
|
|
roleId: string
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
_count: UserCountAggregateOutputType | null
|
|
_min: UserMinAggregateOutputType | null
|
|
_max: UserMaxAggregateOutputType | null
|
|
}
|
|
|
|
type GetUserGroupByPayload<T extends UserGroupByArgs> = Prisma.PrismaPromise<
|
|
Array<
|
|
PickEnumerable<UserGroupByOutputType, T['by']> &
|
|
{
|
|
[P in ((keyof T) & (keyof UserGroupByOutputType))]: P extends '_count'
|
|
? T[P] extends boolean
|
|
? number
|
|
: GetScalarType<T[P], UserGroupByOutputType[P]>
|
|
: GetScalarType<T[P], UserGroupByOutputType[P]>
|
|
}
|
|
>
|
|
>
|
|
|
|
|
|
export type UserSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
email?: boolean
|
|
passwordHash?: boolean
|
|
name?: boolean
|
|
vendorId?: boolean
|
|
roleId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
role?: boolean | RoleDefaultArgs<ExtArgs>
|
|
refreshTokens?: boolean | User$refreshTokensArgs<ExtArgs>
|
|
transactions?: boolean | User$transactionsArgs<ExtArgs>
|
|
_count?: boolean | UserCountOutputTypeDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["user"]>
|
|
|
|
export type UserSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
email?: boolean
|
|
passwordHash?: boolean
|
|
name?: boolean
|
|
vendorId?: boolean
|
|
roleId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
role?: boolean | RoleDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["user"]>
|
|
|
|
export type UserSelectScalar = {
|
|
id?: boolean
|
|
email?: boolean
|
|
passwordHash?: boolean
|
|
name?: boolean
|
|
vendorId?: boolean
|
|
roleId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
}
|
|
|
|
export type UserInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
role?: boolean | RoleDefaultArgs<ExtArgs>
|
|
refreshTokens?: boolean | User$refreshTokensArgs<ExtArgs>
|
|
transactions?: boolean | User$transactionsArgs<ExtArgs>
|
|
_count?: boolean | UserCountOutputTypeDefaultArgs<ExtArgs>
|
|
}
|
|
export type UserIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
role?: boolean | RoleDefaultArgs<ExtArgs>
|
|
}
|
|
|
|
export type $UserPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "User"
|
|
objects: {
|
|
vendor: Prisma.$VendorPayload<ExtArgs>
|
|
role: Prisma.$RolePayload<ExtArgs>
|
|
refreshTokens: Prisma.$RefreshTokenPayload<ExtArgs>[]
|
|
transactions: Prisma.$TransactionPayload<ExtArgs>[]
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
vendorId: string
|
|
roleId: string
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
}, ExtArgs["result"]["user"]>
|
|
composites: {}
|
|
}
|
|
|
|
type UserGetPayload<S extends boolean | null | undefined | UserDefaultArgs> = $Result.GetResult<Prisma.$UserPayload, S>
|
|
|
|
type UserCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
|
|
Omit<UserFindManyArgs, 'select' | 'include' | 'distinct'> & {
|
|
select?: UserCountAggregateInputType | true
|
|
}
|
|
|
|
export interface UserDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
|
|
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['User'], meta: { name: 'User' } }
|
|
/**
|
|
* Find zero or one User that matches the filter.
|
|
* @param {UserFindUniqueArgs} args - Arguments to find a User
|
|
* @example
|
|
* // Get one User
|
|
* const user = await prisma.user.findUnique({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUnique<T extends UserFindUniqueArgs>(args: SelectSubset<T, UserFindUniqueArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUnique"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find one User that matches the filter or throw an error with `error.code='P2025'`
|
|
* if no matches were found.
|
|
* @param {UserFindUniqueOrThrowArgs} args - Arguments to find a User
|
|
* @example
|
|
* // Get one User
|
|
* const user = await prisma.user.findUniqueOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUniqueOrThrow<T extends UserFindUniqueOrThrowArgs>(args: SelectSubset<T, UserFindUniqueOrThrowArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find the first User 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 {UserFindFirstArgs} args - Arguments to find a User
|
|
* @example
|
|
* // Get one User
|
|
* const user = await prisma.user.findFirst({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirst<T extends UserFindFirstArgs>(args?: SelectSubset<T, UserFindFirstArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find the first User 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 {UserFindFirstOrThrowArgs} args - Arguments to find a User
|
|
* @example
|
|
* // Get one User
|
|
* const user = await prisma.user.findFirstOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirstOrThrow<T extends UserFindFirstOrThrowArgs>(args?: SelectSubset<T, UserFindFirstOrThrowArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find zero or more Users 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 {UserFindManyArgs} args - Arguments to filter and select certain fields only.
|
|
* @example
|
|
* // Get all Users
|
|
* const users = await prisma.user.findMany()
|
|
*
|
|
* // Get first 10 Users
|
|
* const users = await prisma.user.findMany({ take: 10 })
|
|
*
|
|
* // Only select the `id`
|
|
* const userWithIdOnly = await prisma.user.findMany({ select: { id: true } })
|
|
*
|
|
*/
|
|
findMany<T extends UserFindManyArgs>(args?: SelectSubset<T, UserFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findMany">>
|
|
|
|
/**
|
|
* Create a User.
|
|
* @param {UserCreateArgs} args - Arguments to create a User.
|
|
* @example
|
|
* // Create one User
|
|
* const User = await prisma.user.create({
|
|
* data: {
|
|
* // ... data to create a User
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
create<T extends UserCreateArgs>(args: SelectSubset<T, UserCreateArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "create">, never, ExtArgs>
|
|
|
|
/**
|
|
* Create many Users.
|
|
* @param {UserCreateManyArgs} args - Arguments to create many Users.
|
|
* @example
|
|
* // Create many Users
|
|
* const user = await prisma.user.createMany({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
*/
|
|
createMany<T extends UserCreateManyArgs>(args?: SelectSubset<T, UserCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create many Users and returns the data saved in the database.
|
|
* @param {UserCreateManyAndReturnArgs} args - Arguments to create many Users.
|
|
* @example
|
|
* // Create many Users
|
|
* const user = await prisma.user.createManyAndReturn({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
* // Create many Users and only return the `id`
|
|
* const userWithIdOnly = await prisma.user.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 UserCreateManyAndReturnArgs>(args?: SelectSubset<T, UserCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "createManyAndReturn">>
|
|
|
|
/**
|
|
* Delete a User.
|
|
* @param {UserDeleteArgs} args - Arguments to delete one User.
|
|
* @example
|
|
* // Delete one User
|
|
* const User = await prisma.user.delete({
|
|
* where: {
|
|
* // ... filter to delete one User
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
delete<T extends UserDeleteArgs>(args: SelectSubset<T, UserDeleteArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "delete">, never, ExtArgs>
|
|
|
|
/**
|
|
* Update one User.
|
|
* @param {UserUpdateArgs} args - Arguments to update one User.
|
|
* @example
|
|
* // Update one User
|
|
* const user = await prisma.user.update({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
update<T extends UserUpdateArgs>(args: SelectSubset<T, UserUpdateArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "update">, never, ExtArgs>
|
|
|
|
/**
|
|
* Delete zero or more Users.
|
|
* @param {UserDeleteManyArgs} args - Arguments to filter Users to delete.
|
|
* @example
|
|
* // Delete a few Users
|
|
* const { count } = await prisma.user.deleteMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
deleteMany<T extends UserDeleteManyArgs>(args?: SelectSubset<T, UserDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Update zero or more Users.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {UserUpdateManyArgs} args - Arguments to update one or more rows.
|
|
* @example
|
|
* // Update many Users
|
|
* const user = await prisma.user.updateMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
updateMany<T extends UserUpdateManyArgs>(args: SelectSubset<T, UserUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create or update one User.
|
|
* @param {UserUpsertArgs} args - Arguments to update or create a User.
|
|
* @example
|
|
* // Update or create a User
|
|
* const user = await prisma.user.upsert({
|
|
* create: {
|
|
* // ... data to create a User
|
|
* },
|
|
* update: {
|
|
* // ... in case it already exists, update
|
|
* },
|
|
* where: {
|
|
* // ... the filter for the User we want to update
|
|
* }
|
|
* })
|
|
*/
|
|
upsert<T extends UserUpsertArgs>(args: SelectSubset<T, UserUpsertArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "upsert">, never, ExtArgs>
|
|
|
|
|
|
/**
|
|
* Count the number of Users.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {UserCountArgs} args - Arguments to filter Users to count.
|
|
* @example
|
|
* // Count the number of Users
|
|
* const count = await prisma.user.count({
|
|
* where: {
|
|
* // ... the filter for the Users we want to count
|
|
* }
|
|
* })
|
|
**/
|
|
count<T extends UserCountArgs>(
|
|
args?: Subset<T, UserCountArgs>,
|
|
): Prisma.PrismaPromise<
|
|
T extends $Utils.Record<'select', any>
|
|
? T['select'] extends true
|
|
? number
|
|
: GetScalarType<T['select'], UserCountAggregateOutputType>
|
|
: number
|
|
>
|
|
|
|
/**
|
|
* Allows you to perform aggregations operations on a User.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {UserAggregateArgs} 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 UserAggregateArgs>(args: Subset<T, UserAggregateArgs>): Prisma.PrismaPromise<GetUserAggregateType<T>>
|
|
|
|
/**
|
|
* Group by User.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {UserGroupByArgs} 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 UserGroupByArgs,
|
|
HasSelectOrTake extends Or<
|
|
Extends<'skip', Keys<T>>,
|
|
Extends<'take', Keys<T>>
|
|
>,
|
|
OrderByArg extends True extends HasSelectOrTake
|
|
? { orderBy: UserGroupByArgs['orderBy'] }
|
|
: { orderBy?: UserGroupByArgs['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, UserGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetUserGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
|
|
/**
|
|
* Fields of the User model
|
|
*/
|
|
readonly fields: UserFieldRefs;
|
|
}
|
|
|
|
/**
|
|
* The delegate class that acts as a "Promise-like" for User.
|
|
* 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__UserClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
|
|
readonly [Symbol.toStringTag]: "PrismaPromise"
|
|
vendor<T extends VendorDefaultArgs<ExtArgs> = {}>(args?: Subset<T, VendorDefaultArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
|
|
role<T extends RoleDefaultArgs<ExtArgs> = {}>(args?: Subset<T, RoleDefaultArgs<ExtArgs>>): Prisma__RoleClient<$Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
|
|
refreshTokens<T extends User$refreshTokensArgs<ExtArgs> = {}>(args?: Subset<T, User$refreshTokensArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findMany"> | Null>
|
|
transactions<T extends User$transactionsArgs<ExtArgs> = {}>(args?: Subset<T, User$transactionsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionPayload<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 User model
|
|
*/
|
|
interface UserFieldRefs {
|
|
readonly id: FieldRef<"User", 'String'>
|
|
readonly email: FieldRef<"User", 'String'>
|
|
readonly passwordHash: FieldRef<"User", 'String'>
|
|
readonly name: FieldRef<"User", 'String'>
|
|
readonly vendorId: FieldRef<"User", 'String'>
|
|
readonly roleId: FieldRef<"User", 'String'>
|
|
readonly createdAt: FieldRef<"User", 'DateTime'>
|
|
readonly updatedAt: FieldRef<"User", 'DateTime'>
|
|
}
|
|
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* User findUnique
|
|
*/
|
|
export type UserFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which User to fetch.
|
|
*/
|
|
where: UserWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* User findUniqueOrThrow
|
|
*/
|
|
export type UserFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which User to fetch.
|
|
*/
|
|
where: UserWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* User findFirst
|
|
*/
|
|
export type UserFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which User to fetch.
|
|
*/
|
|
where?: UserWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Users to fetch.
|
|
*/
|
|
orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Users.
|
|
*/
|
|
cursor?: UserWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Users 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` Users.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Users.
|
|
*/
|
|
distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* User findFirstOrThrow
|
|
*/
|
|
export type UserFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which User to fetch.
|
|
*/
|
|
where?: UserWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Users to fetch.
|
|
*/
|
|
orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Users.
|
|
*/
|
|
cursor?: UserWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Users 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` Users.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Users.
|
|
*/
|
|
distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* User findMany
|
|
*/
|
|
export type UserFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Users to fetch.
|
|
*/
|
|
where?: UserWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Users to fetch.
|
|
*/
|
|
orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for listing Users.
|
|
*/
|
|
cursor?: UserWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Users 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` Users.
|
|
*/
|
|
skip?: number
|
|
distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* User create
|
|
*/
|
|
export type UserCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to create a User.
|
|
*/
|
|
data: XOR<UserCreateInput, UserUncheckedCreateInput>
|
|
}
|
|
|
|
/**
|
|
* User createMany
|
|
*/
|
|
export type UserCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to create many Users.
|
|
*/
|
|
data: UserCreateManyInput | UserCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* User createManyAndReturn
|
|
*/
|
|
export type UserCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelectCreateManyAndReturn<ExtArgs> | null
|
|
/**
|
|
* The data used to create many Users.
|
|
*/
|
|
data: UserCreateManyInput | UserCreateManyInput[]
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserIncludeCreateManyAndReturn<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* User update
|
|
*/
|
|
export type UserUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to update a User.
|
|
*/
|
|
data: XOR<UserUpdateInput, UserUncheckedUpdateInput>
|
|
/**
|
|
* Choose, which User to update.
|
|
*/
|
|
where: UserWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* User updateMany
|
|
*/
|
|
export type UserUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to update Users.
|
|
*/
|
|
data: XOR<UserUpdateManyMutationInput, UserUncheckedUpdateManyInput>
|
|
/**
|
|
* Filter which Users to update
|
|
*/
|
|
where?: UserWhereInput
|
|
}
|
|
|
|
/**
|
|
* User upsert
|
|
*/
|
|
export type UserUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* The filter to search for the User to update in case it exists.
|
|
*/
|
|
where: UserWhereUniqueInput
|
|
/**
|
|
* In case the User found by the `where` argument doesn't exist, create a new User with this data.
|
|
*/
|
|
create: XOR<UserCreateInput, UserUncheckedCreateInput>
|
|
/**
|
|
* In case the User was found with the provided `where` argument, update it with this data.
|
|
*/
|
|
update: XOR<UserUpdateInput, UserUncheckedUpdateInput>
|
|
}
|
|
|
|
/**
|
|
* User delete
|
|
*/
|
|
export type UserDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
/**
|
|
* Filter which User to delete.
|
|
*/
|
|
where: UserWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* User deleteMany
|
|
*/
|
|
export type UserDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Users to delete
|
|
*/
|
|
where?: UserWhereInput
|
|
}
|
|
|
|
/**
|
|
* User.refreshTokens
|
|
*/
|
|
export type User$refreshTokensArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
where?: RefreshTokenWhereInput
|
|
orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
|
|
cursor?: RefreshTokenWhereUniqueInput
|
|
take?: number
|
|
skip?: number
|
|
distinct?: RefreshTokenScalarFieldEnum | RefreshTokenScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* User.transactions
|
|
*/
|
|
export type User$transactionsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
where?: TransactionWhereInput
|
|
orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
|
|
cursor?: TransactionWhereUniqueInput
|
|
take?: number
|
|
skip?: number
|
|
distinct?: TransactionScalarFieldEnum | TransactionScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* User without action
|
|
*/
|
|
export type UserDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the User
|
|
*/
|
|
select?: UserSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: UserInclude<ExtArgs> | null
|
|
}
|
|
|
|
|
|
/**
|
|
* Model RefreshToken
|
|
*/
|
|
|
|
export type AggregateRefreshToken = {
|
|
_count: RefreshTokenCountAggregateOutputType | null
|
|
_min: RefreshTokenMinAggregateOutputType | null
|
|
_max: RefreshTokenMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type RefreshTokenMinAggregateOutputType = {
|
|
id: string | null
|
|
token: string | null
|
|
userId: string | null
|
|
expiresAt: Date | null
|
|
createdAt: Date | null
|
|
}
|
|
|
|
export type RefreshTokenMaxAggregateOutputType = {
|
|
id: string | null
|
|
token: string | null
|
|
userId: string | null
|
|
expiresAt: Date | null
|
|
createdAt: Date | null
|
|
}
|
|
|
|
export type RefreshTokenCountAggregateOutputType = {
|
|
id: number
|
|
token: number
|
|
userId: number
|
|
expiresAt: number
|
|
createdAt: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type RefreshTokenMinAggregateInputType = {
|
|
id?: true
|
|
token?: true
|
|
userId?: true
|
|
expiresAt?: true
|
|
createdAt?: true
|
|
}
|
|
|
|
export type RefreshTokenMaxAggregateInputType = {
|
|
id?: true
|
|
token?: true
|
|
userId?: true
|
|
expiresAt?: true
|
|
createdAt?: true
|
|
}
|
|
|
|
export type RefreshTokenCountAggregateInputType = {
|
|
id?: true
|
|
token?: true
|
|
userId?: true
|
|
expiresAt?: true
|
|
createdAt?: true
|
|
_all?: true
|
|
}
|
|
|
|
export type RefreshTokenAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which RefreshToken to aggregate.
|
|
*/
|
|
where?: RefreshTokenWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of RefreshTokens to fetch.
|
|
*/
|
|
orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the start position
|
|
*/
|
|
cursor?: RefreshTokenWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` RefreshTokens 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` RefreshTokens.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Count returned RefreshTokens
|
|
**/
|
|
_count?: true | RefreshTokenCountAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the minimum value
|
|
**/
|
|
_min?: RefreshTokenMinAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the maximum value
|
|
**/
|
|
_max?: RefreshTokenMaxAggregateInputType
|
|
}
|
|
|
|
export type GetRefreshTokenAggregateType<T extends RefreshTokenAggregateArgs> = {
|
|
[P in keyof T & keyof AggregateRefreshToken]: P extends '_count' | 'count'
|
|
? T[P] extends true
|
|
? number
|
|
: GetScalarType<T[P], AggregateRefreshToken[P]>
|
|
: GetScalarType<T[P], AggregateRefreshToken[P]>
|
|
}
|
|
|
|
|
|
|
|
|
|
export type RefreshTokenGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: RefreshTokenWhereInput
|
|
orderBy?: RefreshTokenOrderByWithAggregationInput | RefreshTokenOrderByWithAggregationInput[]
|
|
by: RefreshTokenScalarFieldEnum[] | RefreshTokenScalarFieldEnum
|
|
having?: RefreshTokenScalarWhereWithAggregatesInput
|
|
take?: number
|
|
skip?: number
|
|
_count?: RefreshTokenCountAggregateInputType | true
|
|
_min?: RefreshTokenMinAggregateInputType
|
|
_max?: RefreshTokenMaxAggregateInputType
|
|
}
|
|
|
|
export type RefreshTokenGroupByOutputType = {
|
|
id: string
|
|
token: string
|
|
userId: string
|
|
expiresAt: Date
|
|
createdAt: Date
|
|
_count: RefreshTokenCountAggregateOutputType | null
|
|
_min: RefreshTokenMinAggregateOutputType | null
|
|
_max: RefreshTokenMaxAggregateOutputType | null
|
|
}
|
|
|
|
type GetRefreshTokenGroupByPayload<T extends RefreshTokenGroupByArgs> = Prisma.PrismaPromise<
|
|
Array<
|
|
PickEnumerable<RefreshTokenGroupByOutputType, T['by']> &
|
|
{
|
|
[P in ((keyof T) & (keyof RefreshTokenGroupByOutputType))]: P extends '_count'
|
|
? T[P] extends boolean
|
|
? number
|
|
: GetScalarType<T[P], RefreshTokenGroupByOutputType[P]>
|
|
: GetScalarType<T[P], RefreshTokenGroupByOutputType[P]>
|
|
}
|
|
>
|
|
>
|
|
|
|
|
|
export type RefreshTokenSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
token?: boolean
|
|
userId?: boolean
|
|
expiresAt?: boolean
|
|
createdAt?: boolean
|
|
user?: boolean | UserDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["refreshToken"]>
|
|
|
|
export type RefreshTokenSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
token?: boolean
|
|
userId?: boolean
|
|
expiresAt?: boolean
|
|
createdAt?: boolean
|
|
user?: boolean | UserDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["refreshToken"]>
|
|
|
|
export type RefreshTokenSelectScalar = {
|
|
id?: boolean
|
|
token?: boolean
|
|
userId?: boolean
|
|
expiresAt?: boolean
|
|
createdAt?: boolean
|
|
}
|
|
|
|
export type RefreshTokenInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
user?: boolean | UserDefaultArgs<ExtArgs>
|
|
}
|
|
export type RefreshTokenIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
user?: boolean | UserDefaultArgs<ExtArgs>
|
|
}
|
|
|
|
export type $RefreshTokenPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "RefreshToken"
|
|
objects: {
|
|
user: Prisma.$UserPayload<ExtArgs>
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
token: string
|
|
userId: string
|
|
expiresAt: Date
|
|
createdAt: Date
|
|
}, ExtArgs["result"]["refreshToken"]>
|
|
composites: {}
|
|
}
|
|
|
|
type RefreshTokenGetPayload<S extends boolean | null | undefined | RefreshTokenDefaultArgs> = $Result.GetResult<Prisma.$RefreshTokenPayload, S>
|
|
|
|
type RefreshTokenCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
|
|
Omit<RefreshTokenFindManyArgs, 'select' | 'include' | 'distinct'> & {
|
|
select?: RefreshTokenCountAggregateInputType | true
|
|
}
|
|
|
|
export interface RefreshTokenDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
|
|
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['RefreshToken'], meta: { name: 'RefreshToken' } }
|
|
/**
|
|
* Find zero or one RefreshToken that matches the filter.
|
|
* @param {RefreshTokenFindUniqueArgs} args - Arguments to find a RefreshToken
|
|
* @example
|
|
* // Get one RefreshToken
|
|
* const refreshToken = await prisma.refreshToken.findUnique({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUnique<T extends RefreshTokenFindUniqueArgs>(args: SelectSubset<T, RefreshTokenFindUniqueArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findUnique"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find one RefreshToken that matches the filter or throw an error with `error.code='P2025'`
|
|
* if no matches were found.
|
|
* @param {RefreshTokenFindUniqueOrThrowArgs} args - Arguments to find a RefreshToken
|
|
* @example
|
|
* // Get one RefreshToken
|
|
* const refreshToken = await prisma.refreshToken.findUniqueOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUniqueOrThrow<T extends RefreshTokenFindUniqueOrThrowArgs>(args: SelectSubset<T, RefreshTokenFindUniqueOrThrowArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findUniqueOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find the first RefreshToken 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 {RefreshTokenFindFirstArgs} args - Arguments to find a RefreshToken
|
|
* @example
|
|
* // Get one RefreshToken
|
|
* const refreshToken = await prisma.refreshToken.findFirst({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirst<T extends RefreshTokenFindFirstArgs>(args?: SelectSubset<T, RefreshTokenFindFirstArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find the first RefreshToken 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 {RefreshTokenFindFirstOrThrowArgs} args - Arguments to find a RefreshToken
|
|
* @example
|
|
* // Get one RefreshToken
|
|
* const refreshToken = await prisma.refreshToken.findFirstOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirstOrThrow<T extends RefreshTokenFindFirstOrThrowArgs>(args?: SelectSubset<T, RefreshTokenFindFirstOrThrowArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find zero or more RefreshTokens 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 {RefreshTokenFindManyArgs} args - Arguments to filter and select certain fields only.
|
|
* @example
|
|
* // Get all RefreshTokens
|
|
* const refreshTokens = await prisma.refreshToken.findMany()
|
|
*
|
|
* // Get first 10 RefreshTokens
|
|
* const refreshTokens = await prisma.refreshToken.findMany({ take: 10 })
|
|
*
|
|
* // Only select the `id`
|
|
* const refreshTokenWithIdOnly = await prisma.refreshToken.findMany({ select: { id: true } })
|
|
*
|
|
*/
|
|
findMany<T extends RefreshTokenFindManyArgs>(args?: SelectSubset<T, RefreshTokenFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findMany">>
|
|
|
|
/**
|
|
* Create a RefreshToken.
|
|
* @param {RefreshTokenCreateArgs} args - Arguments to create a RefreshToken.
|
|
* @example
|
|
* // Create one RefreshToken
|
|
* const RefreshToken = await prisma.refreshToken.create({
|
|
* data: {
|
|
* // ... data to create a RefreshToken
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
create<T extends RefreshTokenCreateArgs>(args: SelectSubset<T, RefreshTokenCreateArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "create">, never, ExtArgs>
|
|
|
|
/**
|
|
* Create many RefreshTokens.
|
|
* @param {RefreshTokenCreateManyArgs} args - Arguments to create many RefreshTokens.
|
|
* @example
|
|
* // Create many RefreshTokens
|
|
* const refreshToken = await prisma.refreshToken.createMany({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
*/
|
|
createMany<T extends RefreshTokenCreateManyArgs>(args?: SelectSubset<T, RefreshTokenCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create many RefreshTokens and returns the data saved in the database.
|
|
* @param {RefreshTokenCreateManyAndReturnArgs} args - Arguments to create many RefreshTokens.
|
|
* @example
|
|
* // Create many RefreshTokens
|
|
* const refreshToken = await prisma.refreshToken.createManyAndReturn({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
* // Create many RefreshTokens and only return the `id`
|
|
* const refreshTokenWithIdOnly = await prisma.refreshToken.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 RefreshTokenCreateManyAndReturnArgs>(args?: SelectSubset<T, RefreshTokenCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "createManyAndReturn">>
|
|
|
|
/**
|
|
* Delete a RefreshToken.
|
|
* @param {RefreshTokenDeleteArgs} args - Arguments to delete one RefreshToken.
|
|
* @example
|
|
* // Delete one RefreshToken
|
|
* const RefreshToken = await prisma.refreshToken.delete({
|
|
* where: {
|
|
* // ... filter to delete one RefreshToken
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
delete<T extends RefreshTokenDeleteArgs>(args: SelectSubset<T, RefreshTokenDeleteArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "delete">, never, ExtArgs>
|
|
|
|
/**
|
|
* Update one RefreshToken.
|
|
* @param {RefreshTokenUpdateArgs} args - Arguments to update one RefreshToken.
|
|
* @example
|
|
* // Update one RefreshToken
|
|
* const refreshToken = await prisma.refreshToken.update({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
update<T extends RefreshTokenUpdateArgs>(args: SelectSubset<T, RefreshTokenUpdateArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "update">, never, ExtArgs>
|
|
|
|
/**
|
|
* Delete zero or more RefreshTokens.
|
|
* @param {RefreshTokenDeleteManyArgs} args - Arguments to filter RefreshTokens to delete.
|
|
* @example
|
|
* // Delete a few RefreshTokens
|
|
* const { count } = await prisma.refreshToken.deleteMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
deleteMany<T extends RefreshTokenDeleteManyArgs>(args?: SelectSubset<T, RefreshTokenDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Update zero or more RefreshTokens.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {RefreshTokenUpdateManyArgs} args - Arguments to update one or more rows.
|
|
* @example
|
|
* // Update many RefreshTokens
|
|
* const refreshToken = await prisma.refreshToken.updateMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
updateMany<T extends RefreshTokenUpdateManyArgs>(args: SelectSubset<T, RefreshTokenUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create or update one RefreshToken.
|
|
* @param {RefreshTokenUpsertArgs} args - Arguments to update or create a RefreshToken.
|
|
* @example
|
|
* // Update or create a RefreshToken
|
|
* const refreshToken = await prisma.refreshToken.upsert({
|
|
* create: {
|
|
* // ... data to create a RefreshToken
|
|
* },
|
|
* update: {
|
|
* // ... in case it already exists, update
|
|
* },
|
|
* where: {
|
|
* // ... the filter for the RefreshToken we want to update
|
|
* }
|
|
* })
|
|
*/
|
|
upsert<T extends RefreshTokenUpsertArgs>(args: SelectSubset<T, RefreshTokenUpsertArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "upsert">, never, ExtArgs>
|
|
|
|
|
|
/**
|
|
* Count the number of RefreshTokens.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {RefreshTokenCountArgs} args - Arguments to filter RefreshTokens to count.
|
|
* @example
|
|
* // Count the number of RefreshTokens
|
|
* const count = await prisma.refreshToken.count({
|
|
* where: {
|
|
* // ... the filter for the RefreshTokens we want to count
|
|
* }
|
|
* })
|
|
**/
|
|
count<T extends RefreshTokenCountArgs>(
|
|
args?: Subset<T, RefreshTokenCountArgs>,
|
|
): Prisma.PrismaPromise<
|
|
T extends $Utils.Record<'select', any>
|
|
? T['select'] extends true
|
|
? number
|
|
: GetScalarType<T['select'], RefreshTokenCountAggregateOutputType>
|
|
: number
|
|
>
|
|
|
|
/**
|
|
* Allows you to perform aggregations operations on a RefreshToken.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {RefreshTokenAggregateArgs} 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 RefreshTokenAggregateArgs>(args: Subset<T, RefreshTokenAggregateArgs>): Prisma.PrismaPromise<GetRefreshTokenAggregateType<T>>
|
|
|
|
/**
|
|
* Group by RefreshToken.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {RefreshTokenGroupByArgs} 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 RefreshTokenGroupByArgs,
|
|
HasSelectOrTake extends Or<
|
|
Extends<'skip', Keys<T>>,
|
|
Extends<'take', Keys<T>>
|
|
>,
|
|
OrderByArg extends True extends HasSelectOrTake
|
|
? { orderBy: RefreshTokenGroupByArgs['orderBy'] }
|
|
: { orderBy?: RefreshTokenGroupByArgs['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, RefreshTokenGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetRefreshTokenGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
|
|
/**
|
|
* Fields of the RefreshToken model
|
|
*/
|
|
readonly fields: RefreshTokenFieldRefs;
|
|
}
|
|
|
|
/**
|
|
* The delegate class that acts as a "Promise-like" for RefreshToken.
|
|
* 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__RefreshTokenClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
|
|
readonly [Symbol.toStringTag]: "PrismaPromise"
|
|
user<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<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 RefreshToken model
|
|
*/
|
|
interface RefreshTokenFieldRefs {
|
|
readonly id: FieldRef<"RefreshToken", 'String'>
|
|
readonly token: FieldRef<"RefreshToken", 'String'>
|
|
readonly userId: FieldRef<"RefreshToken", 'String'>
|
|
readonly expiresAt: FieldRef<"RefreshToken", 'DateTime'>
|
|
readonly createdAt: FieldRef<"RefreshToken", 'DateTime'>
|
|
}
|
|
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* RefreshToken findUnique
|
|
*/
|
|
export type RefreshTokenFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which RefreshToken to fetch.
|
|
*/
|
|
where: RefreshTokenWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* RefreshToken findUniqueOrThrow
|
|
*/
|
|
export type RefreshTokenFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which RefreshToken to fetch.
|
|
*/
|
|
where: RefreshTokenWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* RefreshToken findFirst
|
|
*/
|
|
export type RefreshTokenFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which RefreshToken to fetch.
|
|
*/
|
|
where?: RefreshTokenWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of RefreshTokens to fetch.
|
|
*/
|
|
orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for RefreshTokens.
|
|
*/
|
|
cursor?: RefreshTokenWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` RefreshTokens 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` RefreshTokens.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of RefreshTokens.
|
|
*/
|
|
distinct?: RefreshTokenScalarFieldEnum | RefreshTokenScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* RefreshToken findFirstOrThrow
|
|
*/
|
|
export type RefreshTokenFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which RefreshToken to fetch.
|
|
*/
|
|
where?: RefreshTokenWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of RefreshTokens to fetch.
|
|
*/
|
|
orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for RefreshTokens.
|
|
*/
|
|
cursor?: RefreshTokenWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` RefreshTokens 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` RefreshTokens.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of RefreshTokens.
|
|
*/
|
|
distinct?: RefreshTokenScalarFieldEnum | RefreshTokenScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* RefreshToken findMany
|
|
*/
|
|
export type RefreshTokenFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which RefreshTokens to fetch.
|
|
*/
|
|
where?: RefreshTokenWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of RefreshTokens to fetch.
|
|
*/
|
|
orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for listing RefreshTokens.
|
|
*/
|
|
cursor?: RefreshTokenWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` RefreshTokens 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` RefreshTokens.
|
|
*/
|
|
skip?: number
|
|
distinct?: RefreshTokenScalarFieldEnum | RefreshTokenScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* RefreshToken create
|
|
*/
|
|
export type RefreshTokenCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to create a RefreshToken.
|
|
*/
|
|
data: XOR<RefreshTokenCreateInput, RefreshTokenUncheckedCreateInput>
|
|
}
|
|
|
|
/**
|
|
* RefreshToken createMany
|
|
*/
|
|
export type RefreshTokenCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to create many RefreshTokens.
|
|
*/
|
|
data: RefreshTokenCreateManyInput | RefreshTokenCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* RefreshToken createManyAndReturn
|
|
*/
|
|
export type RefreshTokenCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelectCreateManyAndReturn<ExtArgs> | null
|
|
/**
|
|
* The data used to create many RefreshTokens.
|
|
*/
|
|
data: RefreshTokenCreateManyInput | RefreshTokenCreateManyInput[]
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenIncludeCreateManyAndReturn<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* RefreshToken update
|
|
*/
|
|
export type RefreshTokenUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to update a RefreshToken.
|
|
*/
|
|
data: XOR<RefreshTokenUpdateInput, RefreshTokenUncheckedUpdateInput>
|
|
/**
|
|
* Choose, which RefreshToken to update.
|
|
*/
|
|
where: RefreshTokenWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* RefreshToken updateMany
|
|
*/
|
|
export type RefreshTokenUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to update RefreshTokens.
|
|
*/
|
|
data: XOR<RefreshTokenUpdateManyMutationInput, RefreshTokenUncheckedUpdateManyInput>
|
|
/**
|
|
* Filter which RefreshTokens to update
|
|
*/
|
|
where?: RefreshTokenWhereInput
|
|
}
|
|
|
|
/**
|
|
* RefreshToken upsert
|
|
*/
|
|
export type RefreshTokenUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* The filter to search for the RefreshToken to update in case it exists.
|
|
*/
|
|
where: RefreshTokenWhereUniqueInput
|
|
/**
|
|
* In case the RefreshToken found by the `where` argument doesn't exist, create a new RefreshToken with this data.
|
|
*/
|
|
create: XOR<RefreshTokenCreateInput, RefreshTokenUncheckedCreateInput>
|
|
/**
|
|
* In case the RefreshToken was found with the provided `where` argument, update it with this data.
|
|
*/
|
|
update: XOR<RefreshTokenUpdateInput, RefreshTokenUncheckedUpdateInput>
|
|
}
|
|
|
|
/**
|
|
* RefreshToken delete
|
|
*/
|
|
export type RefreshTokenDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
/**
|
|
* Filter which RefreshToken to delete.
|
|
*/
|
|
where: RefreshTokenWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* RefreshToken deleteMany
|
|
*/
|
|
export type RefreshTokenDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which RefreshTokens to delete
|
|
*/
|
|
where?: RefreshTokenWhereInput
|
|
}
|
|
|
|
/**
|
|
* RefreshToken without action
|
|
*/
|
|
export type RefreshTokenDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the RefreshToken
|
|
*/
|
|
select?: RefreshTokenSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: RefreshTokenInclude<ExtArgs> | null
|
|
}
|
|
|
|
|
|
/**
|
|
* Model Category
|
|
*/
|
|
|
|
export type AggregateCategory = {
|
|
_count: CategoryCountAggregateOutputType | null
|
|
_min: CategoryMinAggregateOutputType | null
|
|
_max: CategoryMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type CategoryMinAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
vendorId: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type CategoryMaxAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
vendorId: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type CategoryCountAggregateOutputType = {
|
|
id: number
|
|
name: number
|
|
vendorId: number
|
|
createdAt: number
|
|
updatedAt: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type CategoryMinAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
vendorId?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type CategoryMaxAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
vendorId?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type CategoryCountAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
vendorId?: true
|
|
createdAt?: true
|
|
updatedAt?: 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
|
|
name: string
|
|
vendorId: string
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
_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
|
|
name?: boolean
|
|
vendorId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<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
|
|
name?: boolean
|
|
vendorId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["category"]>
|
|
|
|
export type CategorySelectScalar = {
|
|
id?: boolean
|
|
name?: boolean
|
|
vendorId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
}
|
|
|
|
export type CategoryInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
products?: boolean | Category$productsArgs<ExtArgs>
|
|
_count?: boolean | CategoryCountOutputTypeDefaultArgs<ExtArgs>
|
|
}
|
|
export type CategoryIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
}
|
|
|
|
export type $CategoryPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "Category"
|
|
objects: {
|
|
vendor: Prisma.$VendorPayload<ExtArgs>
|
|
products: Prisma.$ProductPayload<ExtArgs>[]
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
name: string
|
|
vendorId: string
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
}, 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"
|
|
vendor<T extends VendorDefaultArgs<ExtArgs> = {}>(args?: Subset<T, VendorDefaultArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
|
|
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 name: FieldRef<"Category", 'String'>
|
|
readonly vendorId: FieldRef<"Category", 'String'>
|
|
readonly createdAt: FieldRef<"Category", 'DateTime'>
|
|
readonly updatedAt: FieldRef<"Category", 'DateTime'>
|
|
}
|
|
|
|
|
|
// 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[]
|
|
}
|
|
|
|
/**
|
|
* 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[]
|
|
/**
|
|
* 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.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 Tax
|
|
*/
|
|
|
|
export type AggregateTax = {
|
|
_count: TaxCountAggregateOutputType | null
|
|
_avg: TaxAvgAggregateOutputType | null
|
|
_sum: TaxSumAggregateOutputType | null
|
|
_min: TaxMinAggregateOutputType | null
|
|
_max: TaxMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type TaxAvgAggregateOutputType = {
|
|
rate: number | null
|
|
}
|
|
|
|
export type TaxSumAggregateOutputType = {
|
|
rate: number | null
|
|
}
|
|
|
|
export type TaxMinAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
rate: number | null
|
|
vendorId: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type TaxMaxAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
rate: number | null
|
|
vendorId: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type TaxCountAggregateOutputType = {
|
|
id: number
|
|
name: number
|
|
rate: number
|
|
vendorId: number
|
|
createdAt: number
|
|
updatedAt: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type TaxAvgAggregateInputType = {
|
|
rate?: true
|
|
}
|
|
|
|
export type TaxSumAggregateInputType = {
|
|
rate?: true
|
|
}
|
|
|
|
export type TaxMinAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
rate?: true
|
|
vendorId?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type TaxMaxAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
rate?: true
|
|
vendorId?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type TaxCountAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
rate?: true
|
|
vendorId?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
_all?: true
|
|
}
|
|
|
|
export type TaxAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Tax to aggregate.
|
|
*/
|
|
where?: TaxWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Taxes to fetch.
|
|
*/
|
|
orderBy?: TaxOrderByWithRelationInput | TaxOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the start position
|
|
*/
|
|
cursor?: TaxWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Taxes 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` Taxes.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Count returned Taxes
|
|
**/
|
|
_count?: true | TaxCountAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to average
|
|
**/
|
|
_avg?: TaxAvgAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to sum
|
|
**/
|
|
_sum?: TaxSumAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the minimum value
|
|
**/
|
|
_min?: TaxMinAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the maximum value
|
|
**/
|
|
_max?: TaxMaxAggregateInputType
|
|
}
|
|
|
|
export type GetTaxAggregateType<T extends TaxAggregateArgs> = {
|
|
[P in keyof T & keyof AggregateTax]: P extends '_count' | 'count'
|
|
? T[P] extends true
|
|
? number
|
|
: GetScalarType<T[P], AggregateTax[P]>
|
|
: GetScalarType<T[P], AggregateTax[P]>
|
|
}
|
|
|
|
|
|
|
|
|
|
export type TaxGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: TaxWhereInput
|
|
orderBy?: TaxOrderByWithAggregationInput | TaxOrderByWithAggregationInput[]
|
|
by: TaxScalarFieldEnum[] | TaxScalarFieldEnum
|
|
having?: TaxScalarWhereWithAggregatesInput
|
|
take?: number
|
|
skip?: number
|
|
_count?: TaxCountAggregateInputType | true
|
|
_avg?: TaxAvgAggregateInputType
|
|
_sum?: TaxSumAggregateInputType
|
|
_min?: TaxMinAggregateInputType
|
|
_max?: TaxMaxAggregateInputType
|
|
}
|
|
|
|
export type TaxGroupByOutputType = {
|
|
id: string
|
|
name: string
|
|
rate: number
|
|
vendorId: string
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
_count: TaxCountAggregateOutputType | null
|
|
_avg: TaxAvgAggregateOutputType | null
|
|
_sum: TaxSumAggregateOutputType | null
|
|
_min: TaxMinAggregateOutputType | null
|
|
_max: TaxMaxAggregateOutputType | null
|
|
}
|
|
|
|
type GetTaxGroupByPayload<T extends TaxGroupByArgs> = Prisma.PrismaPromise<
|
|
Array<
|
|
PickEnumerable<TaxGroupByOutputType, T['by']> &
|
|
{
|
|
[P in ((keyof T) & (keyof TaxGroupByOutputType))]: P extends '_count'
|
|
? T[P] extends boolean
|
|
? number
|
|
: GetScalarType<T[P], TaxGroupByOutputType[P]>
|
|
: GetScalarType<T[P], TaxGroupByOutputType[P]>
|
|
}
|
|
>
|
|
>
|
|
|
|
|
|
export type TaxSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
name?: boolean
|
|
rate?: boolean
|
|
vendorId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
products?: boolean | Tax$productsArgs<ExtArgs>
|
|
_count?: boolean | TaxCountOutputTypeDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["tax"]>
|
|
|
|
export type TaxSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
name?: boolean
|
|
rate?: boolean
|
|
vendorId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["tax"]>
|
|
|
|
export type TaxSelectScalar = {
|
|
id?: boolean
|
|
name?: boolean
|
|
rate?: boolean
|
|
vendorId?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
}
|
|
|
|
export type TaxInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
products?: boolean | Tax$productsArgs<ExtArgs>
|
|
_count?: boolean | TaxCountOutputTypeDefaultArgs<ExtArgs>
|
|
}
|
|
export type TaxIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
}
|
|
|
|
export type $TaxPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "Tax"
|
|
objects: {
|
|
vendor: Prisma.$VendorPayload<ExtArgs>
|
|
products: Prisma.$ProductPayload<ExtArgs>[]
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
name: string
|
|
rate: number
|
|
vendorId: string
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
}, ExtArgs["result"]["tax"]>
|
|
composites: {}
|
|
}
|
|
|
|
type TaxGetPayload<S extends boolean | null | undefined | TaxDefaultArgs> = $Result.GetResult<Prisma.$TaxPayload, S>
|
|
|
|
type TaxCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
|
|
Omit<TaxFindManyArgs, 'select' | 'include' | 'distinct'> & {
|
|
select?: TaxCountAggregateInputType | true
|
|
}
|
|
|
|
export interface TaxDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
|
|
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Tax'], meta: { name: 'Tax' } }
|
|
/**
|
|
* Find zero or one Tax that matches the filter.
|
|
* @param {TaxFindUniqueArgs} args - Arguments to find a Tax
|
|
* @example
|
|
* // Get one Tax
|
|
* const tax = await prisma.tax.findUnique({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUnique<T extends TaxFindUniqueArgs>(args: SelectSubset<T, TaxFindUniqueArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "findUnique"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find one Tax that matches the filter or throw an error with `error.code='P2025'`
|
|
* if no matches were found.
|
|
* @param {TaxFindUniqueOrThrowArgs} args - Arguments to find a Tax
|
|
* @example
|
|
* // Get one Tax
|
|
* const tax = await prisma.tax.findUniqueOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUniqueOrThrow<T extends TaxFindUniqueOrThrowArgs>(args: SelectSubset<T, TaxFindUniqueOrThrowArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "findUniqueOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find the first Tax 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 {TaxFindFirstArgs} args - Arguments to find a Tax
|
|
* @example
|
|
* // Get one Tax
|
|
* const tax = await prisma.tax.findFirst({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirst<T extends TaxFindFirstArgs>(args?: SelectSubset<T, TaxFindFirstArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find the first Tax 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 {TaxFindFirstOrThrowArgs} args - Arguments to find a Tax
|
|
* @example
|
|
* // Get one Tax
|
|
* const tax = await prisma.tax.findFirstOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirstOrThrow<T extends TaxFindFirstOrThrowArgs>(args?: SelectSubset<T, TaxFindFirstOrThrowArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find zero or more Taxes 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 {TaxFindManyArgs} args - Arguments to filter and select certain fields only.
|
|
* @example
|
|
* // Get all Taxes
|
|
* const taxes = await prisma.tax.findMany()
|
|
*
|
|
* // Get first 10 Taxes
|
|
* const taxes = await prisma.tax.findMany({ take: 10 })
|
|
*
|
|
* // Only select the `id`
|
|
* const taxWithIdOnly = await prisma.tax.findMany({ select: { id: true } })
|
|
*
|
|
*/
|
|
findMany<T extends TaxFindManyArgs>(args?: SelectSubset<T, TaxFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "findMany">>
|
|
|
|
/**
|
|
* Create a Tax.
|
|
* @param {TaxCreateArgs} args - Arguments to create a Tax.
|
|
* @example
|
|
* // Create one Tax
|
|
* const Tax = await prisma.tax.create({
|
|
* data: {
|
|
* // ... data to create a Tax
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
create<T extends TaxCreateArgs>(args: SelectSubset<T, TaxCreateArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "create">, never, ExtArgs>
|
|
|
|
/**
|
|
* Create many Taxes.
|
|
* @param {TaxCreateManyArgs} args - Arguments to create many Taxes.
|
|
* @example
|
|
* // Create many Taxes
|
|
* const tax = await prisma.tax.createMany({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
*/
|
|
createMany<T extends TaxCreateManyArgs>(args?: SelectSubset<T, TaxCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create many Taxes and returns the data saved in the database.
|
|
* @param {TaxCreateManyAndReturnArgs} args - Arguments to create many Taxes.
|
|
* @example
|
|
* // Create many Taxes
|
|
* const tax = await prisma.tax.createManyAndReturn({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
* // Create many Taxes and only return the `id`
|
|
* const taxWithIdOnly = await prisma.tax.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 TaxCreateManyAndReturnArgs>(args?: SelectSubset<T, TaxCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "createManyAndReturn">>
|
|
|
|
/**
|
|
* Delete a Tax.
|
|
* @param {TaxDeleteArgs} args - Arguments to delete one Tax.
|
|
* @example
|
|
* // Delete one Tax
|
|
* const Tax = await prisma.tax.delete({
|
|
* where: {
|
|
* // ... filter to delete one Tax
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
delete<T extends TaxDeleteArgs>(args: SelectSubset<T, TaxDeleteArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "delete">, never, ExtArgs>
|
|
|
|
/**
|
|
* Update one Tax.
|
|
* @param {TaxUpdateArgs} args - Arguments to update one Tax.
|
|
* @example
|
|
* // Update one Tax
|
|
* const tax = await prisma.tax.update({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
update<T extends TaxUpdateArgs>(args: SelectSubset<T, TaxUpdateArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "update">, never, ExtArgs>
|
|
|
|
/**
|
|
* Delete zero or more Taxes.
|
|
* @param {TaxDeleteManyArgs} args - Arguments to filter Taxes to delete.
|
|
* @example
|
|
* // Delete a few Taxes
|
|
* const { count } = await prisma.tax.deleteMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
deleteMany<T extends TaxDeleteManyArgs>(args?: SelectSubset<T, TaxDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Update zero or more Taxes.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TaxUpdateManyArgs} args - Arguments to update one or more rows.
|
|
* @example
|
|
* // Update many Taxes
|
|
* const tax = await prisma.tax.updateMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
updateMany<T extends TaxUpdateManyArgs>(args: SelectSubset<T, TaxUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create or update one Tax.
|
|
* @param {TaxUpsertArgs} args - Arguments to update or create a Tax.
|
|
* @example
|
|
* // Update or create a Tax
|
|
* const tax = await prisma.tax.upsert({
|
|
* create: {
|
|
* // ... data to create a Tax
|
|
* },
|
|
* update: {
|
|
* // ... in case it already exists, update
|
|
* },
|
|
* where: {
|
|
* // ... the filter for the Tax we want to update
|
|
* }
|
|
* })
|
|
*/
|
|
upsert<T extends TaxUpsertArgs>(args: SelectSubset<T, TaxUpsertArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "upsert">, never, ExtArgs>
|
|
|
|
|
|
/**
|
|
* Count the number of Taxes.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TaxCountArgs} args - Arguments to filter Taxes to count.
|
|
* @example
|
|
* // Count the number of Taxes
|
|
* const count = await prisma.tax.count({
|
|
* where: {
|
|
* // ... the filter for the Taxes we want to count
|
|
* }
|
|
* })
|
|
**/
|
|
count<T extends TaxCountArgs>(
|
|
args?: Subset<T, TaxCountArgs>,
|
|
): Prisma.PrismaPromise<
|
|
T extends $Utils.Record<'select', any>
|
|
? T['select'] extends true
|
|
? number
|
|
: GetScalarType<T['select'], TaxCountAggregateOutputType>
|
|
: number
|
|
>
|
|
|
|
/**
|
|
* Allows you to perform aggregations operations on a Tax.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TaxAggregateArgs} 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 TaxAggregateArgs>(args: Subset<T, TaxAggregateArgs>): Prisma.PrismaPromise<GetTaxAggregateType<T>>
|
|
|
|
/**
|
|
* Group by Tax.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TaxGroupByArgs} 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 TaxGroupByArgs,
|
|
HasSelectOrTake extends Or<
|
|
Extends<'skip', Keys<T>>,
|
|
Extends<'take', Keys<T>>
|
|
>,
|
|
OrderByArg extends True extends HasSelectOrTake
|
|
? { orderBy: TaxGroupByArgs['orderBy'] }
|
|
: { orderBy?: TaxGroupByArgs['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, TaxGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetTaxGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
|
|
/**
|
|
* Fields of the Tax model
|
|
*/
|
|
readonly fields: TaxFieldRefs;
|
|
}
|
|
|
|
/**
|
|
* The delegate class that acts as a "Promise-like" for Tax.
|
|
* 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__TaxClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
|
|
readonly [Symbol.toStringTag]: "PrismaPromise"
|
|
vendor<T extends VendorDefaultArgs<ExtArgs> = {}>(args?: Subset<T, VendorDefaultArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
|
|
products<T extends Tax$productsArgs<ExtArgs> = {}>(args?: Subset<T, Tax$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 Tax model
|
|
*/
|
|
interface TaxFieldRefs {
|
|
readonly id: FieldRef<"Tax", 'String'>
|
|
readonly name: FieldRef<"Tax", 'String'>
|
|
readonly rate: FieldRef<"Tax", 'Float'>
|
|
readonly vendorId: FieldRef<"Tax", 'String'>
|
|
readonly createdAt: FieldRef<"Tax", 'DateTime'>
|
|
readonly updatedAt: FieldRef<"Tax", 'DateTime'>
|
|
}
|
|
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* Tax findUnique
|
|
*/
|
|
export type TaxFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Tax to fetch.
|
|
*/
|
|
where: TaxWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Tax findUniqueOrThrow
|
|
*/
|
|
export type TaxFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Tax to fetch.
|
|
*/
|
|
where: TaxWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Tax findFirst
|
|
*/
|
|
export type TaxFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Tax to fetch.
|
|
*/
|
|
where?: TaxWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Taxes to fetch.
|
|
*/
|
|
orderBy?: TaxOrderByWithRelationInput | TaxOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Taxes.
|
|
*/
|
|
cursor?: TaxWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Taxes 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` Taxes.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Taxes.
|
|
*/
|
|
distinct?: TaxScalarFieldEnum | TaxScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Tax findFirstOrThrow
|
|
*/
|
|
export type TaxFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Tax to fetch.
|
|
*/
|
|
where?: TaxWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Taxes to fetch.
|
|
*/
|
|
orderBy?: TaxOrderByWithRelationInput | TaxOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Taxes.
|
|
*/
|
|
cursor?: TaxWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Taxes 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` Taxes.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Taxes.
|
|
*/
|
|
distinct?: TaxScalarFieldEnum | TaxScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Tax findMany
|
|
*/
|
|
export type TaxFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Taxes to fetch.
|
|
*/
|
|
where?: TaxWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Taxes to fetch.
|
|
*/
|
|
orderBy?: TaxOrderByWithRelationInput | TaxOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for listing Taxes.
|
|
*/
|
|
cursor?: TaxWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Taxes 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` Taxes.
|
|
*/
|
|
skip?: number
|
|
distinct?: TaxScalarFieldEnum | TaxScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Tax create
|
|
*/
|
|
export type TaxCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to create a Tax.
|
|
*/
|
|
data: XOR<TaxCreateInput, TaxUncheckedCreateInput>
|
|
}
|
|
|
|
/**
|
|
* Tax createMany
|
|
*/
|
|
export type TaxCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to create many Taxes.
|
|
*/
|
|
data: TaxCreateManyInput | TaxCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* Tax createManyAndReturn
|
|
*/
|
|
export type TaxCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelectCreateManyAndReturn<ExtArgs> | null
|
|
/**
|
|
* The data used to create many Taxes.
|
|
*/
|
|
data: TaxCreateManyInput | TaxCreateManyInput[]
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxIncludeCreateManyAndReturn<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* Tax update
|
|
*/
|
|
export type TaxUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to update a Tax.
|
|
*/
|
|
data: XOR<TaxUpdateInput, TaxUncheckedUpdateInput>
|
|
/**
|
|
* Choose, which Tax to update.
|
|
*/
|
|
where: TaxWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Tax updateMany
|
|
*/
|
|
export type TaxUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to update Taxes.
|
|
*/
|
|
data: XOR<TaxUpdateManyMutationInput, TaxUncheckedUpdateManyInput>
|
|
/**
|
|
* Filter which Taxes to update
|
|
*/
|
|
where?: TaxWhereInput
|
|
}
|
|
|
|
/**
|
|
* Tax upsert
|
|
*/
|
|
export type TaxUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* The filter to search for the Tax to update in case it exists.
|
|
*/
|
|
where: TaxWhereUniqueInput
|
|
/**
|
|
* In case the Tax found by the `where` argument doesn't exist, create a new Tax with this data.
|
|
*/
|
|
create: XOR<TaxCreateInput, TaxUncheckedCreateInput>
|
|
/**
|
|
* In case the Tax was found with the provided `where` argument, update it with this data.
|
|
*/
|
|
update: XOR<TaxUpdateInput, TaxUncheckedUpdateInput>
|
|
}
|
|
|
|
/**
|
|
* Tax delete
|
|
*/
|
|
export type TaxDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
/**
|
|
* Filter which Tax to delete.
|
|
*/
|
|
where: TaxWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Tax deleteMany
|
|
*/
|
|
export type TaxDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Taxes to delete
|
|
*/
|
|
where?: TaxWhereInput
|
|
}
|
|
|
|
/**
|
|
* Tax.products
|
|
*/
|
|
export type Tax$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[]
|
|
}
|
|
|
|
/**
|
|
* Tax without action
|
|
*/
|
|
export type TaxDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
}
|
|
|
|
|
|
/**
|
|
* Model Product
|
|
*/
|
|
|
|
export type AggregateProduct = {
|
|
_count: ProductCountAggregateOutputType | null
|
|
_avg: ProductAvgAggregateOutputType | null
|
|
_sum: ProductSumAggregateOutputType | null
|
|
_min: ProductMinAggregateOutputType | null
|
|
_max: ProductMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type ProductAvgAggregateOutputType = {
|
|
price: number | null
|
|
version: number | null
|
|
}
|
|
|
|
export type ProductSumAggregateOutputType = {
|
|
price: number | null
|
|
version: number | null
|
|
}
|
|
|
|
export type ProductMinAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
sku: string | null
|
|
description: string | null
|
|
price: number | null
|
|
vendorId: string | null
|
|
categoryId: string | null
|
|
taxId: string | null
|
|
tags: string | null
|
|
version: number | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type ProductMaxAggregateOutputType = {
|
|
id: string | null
|
|
name: string | null
|
|
sku: string | null
|
|
description: string | null
|
|
price: number | null
|
|
vendorId: string | null
|
|
categoryId: string | null
|
|
taxId: string | null
|
|
tags: string | null
|
|
version: number | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type ProductCountAggregateOutputType = {
|
|
id: number
|
|
name: number
|
|
sku: number
|
|
description: number
|
|
price: number
|
|
vendorId: number
|
|
categoryId: number
|
|
taxId: number
|
|
tags: number
|
|
version: number
|
|
createdAt: number
|
|
updatedAt: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type ProductAvgAggregateInputType = {
|
|
price?: true
|
|
version?: true
|
|
}
|
|
|
|
export type ProductSumAggregateInputType = {
|
|
price?: true
|
|
version?: true
|
|
}
|
|
|
|
export type ProductMinAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
sku?: true
|
|
description?: true
|
|
price?: true
|
|
vendorId?: true
|
|
categoryId?: true
|
|
taxId?: true
|
|
tags?: true
|
|
version?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type ProductMaxAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
sku?: true
|
|
description?: true
|
|
price?: true
|
|
vendorId?: true
|
|
categoryId?: true
|
|
taxId?: true
|
|
tags?: true
|
|
version?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type ProductCountAggregateInputType = {
|
|
id?: true
|
|
name?: true
|
|
sku?: true
|
|
description?: true
|
|
price?: true
|
|
vendorId?: true
|
|
categoryId?: true
|
|
taxId?: true
|
|
tags?: true
|
|
version?: true
|
|
createdAt?: true
|
|
updatedAt?: 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 average
|
|
**/
|
|
_avg?: ProductAvgAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to sum
|
|
**/
|
|
_sum?: ProductSumAggregateInputType
|
|
/**
|
|
* {@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
|
|
_avg?: ProductAvgAggregateInputType
|
|
_sum?: ProductSumAggregateInputType
|
|
_min?: ProductMinAggregateInputType
|
|
_max?: ProductMaxAggregateInputType
|
|
}
|
|
|
|
export type ProductGroupByOutputType = {
|
|
id: string
|
|
name: string
|
|
sku: string | null
|
|
description: string | null
|
|
price: number
|
|
vendorId: string
|
|
categoryId: string | null
|
|
taxId: string | null
|
|
tags: string | null
|
|
version: number
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
_count: ProductCountAggregateOutputType | null
|
|
_avg: ProductAvgAggregateOutputType | null
|
|
_sum: ProductSumAggregateOutputType | 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
|
|
name?: boolean
|
|
sku?: boolean
|
|
description?: boolean
|
|
price?: boolean
|
|
vendorId?: boolean
|
|
categoryId?: boolean
|
|
taxId?: boolean
|
|
tags?: boolean
|
|
version?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
category?: boolean | Product$categoryArgs<ExtArgs>
|
|
tax?: boolean | Product$taxArgs<ExtArgs>
|
|
transactionItems?: boolean | Product$transactionItemsArgs<ExtArgs>
|
|
_count?: boolean | ProductCountOutputTypeDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["product"]>
|
|
|
|
export type ProductSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
name?: boolean
|
|
sku?: boolean
|
|
description?: boolean
|
|
price?: boolean
|
|
vendorId?: boolean
|
|
categoryId?: boolean
|
|
taxId?: boolean
|
|
tags?: boolean
|
|
version?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
category?: boolean | Product$categoryArgs<ExtArgs>
|
|
tax?: boolean | Product$taxArgs<ExtArgs>
|
|
}, ExtArgs["result"]["product"]>
|
|
|
|
export type ProductSelectScalar = {
|
|
id?: boolean
|
|
name?: boolean
|
|
sku?: boolean
|
|
description?: boolean
|
|
price?: boolean
|
|
vendorId?: boolean
|
|
categoryId?: boolean
|
|
taxId?: boolean
|
|
tags?: boolean
|
|
version?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
}
|
|
|
|
export type ProductInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
category?: boolean | Product$categoryArgs<ExtArgs>
|
|
tax?: boolean | Product$taxArgs<ExtArgs>
|
|
transactionItems?: boolean | Product$transactionItemsArgs<ExtArgs>
|
|
_count?: boolean | ProductCountOutputTypeDefaultArgs<ExtArgs>
|
|
}
|
|
export type ProductIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
category?: boolean | Product$categoryArgs<ExtArgs>
|
|
tax?: boolean | Product$taxArgs<ExtArgs>
|
|
}
|
|
|
|
export type $ProductPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "Product"
|
|
objects: {
|
|
vendor: Prisma.$VendorPayload<ExtArgs>
|
|
category: Prisma.$CategoryPayload<ExtArgs> | null
|
|
tax: Prisma.$TaxPayload<ExtArgs> | null
|
|
transactionItems: Prisma.$TransactionItemPayload<ExtArgs>[]
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
name: string
|
|
sku: string | null
|
|
description: string | null
|
|
price: number
|
|
vendorId: string
|
|
categoryId: string | null
|
|
taxId: string | null
|
|
tags: string | null
|
|
version: number
|
|
createdAt: Date
|
|
updatedAt: 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"
|
|
vendor<T extends VendorDefaultArgs<ExtArgs> = {}>(args?: Subset<T, VendorDefaultArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
|
|
category<T extends Product$categoryArgs<ExtArgs> = {}>(args?: Subset<T, Product$categoryArgs<ExtArgs>>): Prisma__CategoryClient<$Result.GetResult<Prisma.$CategoryPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
|
|
tax<T extends Product$taxArgs<ExtArgs> = {}>(args?: Subset<T, Product$taxArgs<ExtArgs>>): Prisma__TaxClient<$Result.GetResult<Prisma.$TaxPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
|
|
transactionItems<T extends Product$transactionItemsArgs<ExtArgs> = {}>(args?: Subset<T, Product$transactionItemsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionItemPayload<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 name: FieldRef<"Product", 'String'>
|
|
readonly sku: FieldRef<"Product", 'String'>
|
|
readonly description: FieldRef<"Product", 'String'>
|
|
readonly price: FieldRef<"Product", 'Float'>
|
|
readonly vendorId: FieldRef<"Product", 'String'>
|
|
readonly categoryId: FieldRef<"Product", 'String'>
|
|
readonly taxId: FieldRef<"Product", 'String'>
|
|
readonly tags: FieldRef<"Product", 'String'>
|
|
readonly version: FieldRef<"Product", 'Int'>
|
|
readonly createdAt: FieldRef<"Product", 'DateTime'>
|
|
readonly updatedAt: 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[]
|
|
}
|
|
|
|
/**
|
|
* 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[]
|
|
/**
|
|
* 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.tax
|
|
*/
|
|
export type Product$taxArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Tax
|
|
*/
|
|
select?: TaxSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TaxInclude<ExtArgs> | null
|
|
where?: TaxWhereInput
|
|
}
|
|
|
|
/**
|
|
* Product.transactionItems
|
|
*/
|
|
export type Product$transactionItemsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
where?: TransactionItemWhereInput
|
|
orderBy?: TransactionItemOrderByWithRelationInput | TransactionItemOrderByWithRelationInput[]
|
|
cursor?: TransactionItemWhereUniqueInput
|
|
take?: number
|
|
skip?: number
|
|
distinct?: TransactionItemScalarFieldEnum | TransactionItemScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* 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 Transaction
|
|
*/
|
|
|
|
export type AggregateTransaction = {
|
|
_count: TransactionCountAggregateOutputType | null
|
|
_avg: TransactionAvgAggregateOutputType | null
|
|
_sum: TransactionSumAggregateOutputType | null
|
|
_min: TransactionMinAggregateOutputType | null
|
|
_max: TransactionMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type TransactionAvgAggregateOutputType = {
|
|
subtotal: number | null
|
|
taxTotal: number | null
|
|
discountTotal: number | null
|
|
total: number | null
|
|
}
|
|
|
|
export type TransactionSumAggregateOutputType = {
|
|
subtotal: number | null
|
|
taxTotal: number | null
|
|
discountTotal: number | null
|
|
total: number | null
|
|
}
|
|
|
|
export type TransactionMinAggregateOutputType = {
|
|
id: string | null
|
|
idempotencyKey: string | null
|
|
vendorId: string | null
|
|
userId: string | null
|
|
status: string | null
|
|
paymentMethod: string | null
|
|
subtotal: number | null
|
|
taxTotal: number | null
|
|
discountTotal: number | null
|
|
total: number | null
|
|
notes: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type TransactionMaxAggregateOutputType = {
|
|
id: string | null
|
|
idempotencyKey: string | null
|
|
vendorId: string | null
|
|
userId: string | null
|
|
status: string | null
|
|
paymentMethod: string | null
|
|
subtotal: number | null
|
|
taxTotal: number | null
|
|
discountTotal: number | null
|
|
total: number | null
|
|
notes: string | null
|
|
createdAt: Date | null
|
|
updatedAt: Date | null
|
|
}
|
|
|
|
export type TransactionCountAggregateOutputType = {
|
|
id: number
|
|
idempotencyKey: number
|
|
vendorId: number
|
|
userId: number
|
|
status: number
|
|
paymentMethod: number
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes: number
|
|
createdAt: number
|
|
updatedAt: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type TransactionAvgAggregateInputType = {
|
|
subtotal?: true
|
|
taxTotal?: true
|
|
discountTotal?: true
|
|
total?: true
|
|
}
|
|
|
|
export type TransactionSumAggregateInputType = {
|
|
subtotal?: true
|
|
taxTotal?: true
|
|
discountTotal?: true
|
|
total?: true
|
|
}
|
|
|
|
export type TransactionMinAggregateInputType = {
|
|
id?: true
|
|
idempotencyKey?: true
|
|
vendorId?: true
|
|
userId?: true
|
|
status?: true
|
|
paymentMethod?: true
|
|
subtotal?: true
|
|
taxTotal?: true
|
|
discountTotal?: true
|
|
total?: true
|
|
notes?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type TransactionMaxAggregateInputType = {
|
|
id?: true
|
|
idempotencyKey?: true
|
|
vendorId?: true
|
|
userId?: true
|
|
status?: true
|
|
paymentMethod?: true
|
|
subtotal?: true
|
|
taxTotal?: true
|
|
discountTotal?: true
|
|
total?: true
|
|
notes?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
}
|
|
|
|
export type TransactionCountAggregateInputType = {
|
|
id?: true
|
|
idempotencyKey?: true
|
|
vendorId?: true
|
|
userId?: true
|
|
status?: true
|
|
paymentMethod?: true
|
|
subtotal?: true
|
|
taxTotal?: true
|
|
discountTotal?: true
|
|
total?: true
|
|
notes?: true
|
|
createdAt?: true
|
|
updatedAt?: true
|
|
_all?: true
|
|
}
|
|
|
|
export type TransactionAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Transaction to aggregate.
|
|
*/
|
|
where?: TransactionWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Transactions to fetch.
|
|
*/
|
|
orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the start position
|
|
*/
|
|
cursor?: TransactionWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Transactions 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` Transactions.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Count returned Transactions
|
|
**/
|
|
_count?: true | TransactionCountAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to average
|
|
**/
|
|
_avg?: TransactionAvgAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to sum
|
|
**/
|
|
_sum?: TransactionSumAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the minimum value
|
|
**/
|
|
_min?: TransactionMinAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the maximum value
|
|
**/
|
|
_max?: TransactionMaxAggregateInputType
|
|
}
|
|
|
|
export type GetTransactionAggregateType<T extends TransactionAggregateArgs> = {
|
|
[P in keyof T & keyof AggregateTransaction]: P extends '_count' | 'count'
|
|
? T[P] extends true
|
|
? number
|
|
: GetScalarType<T[P], AggregateTransaction[P]>
|
|
: GetScalarType<T[P], AggregateTransaction[P]>
|
|
}
|
|
|
|
|
|
|
|
|
|
export type TransactionGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: TransactionWhereInput
|
|
orderBy?: TransactionOrderByWithAggregationInput | TransactionOrderByWithAggregationInput[]
|
|
by: TransactionScalarFieldEnum[] | TransactionScalarFieldEnum
|
|
having?: TransactionScalarWhereWithAggregatesInput
|
|
take?: number
|
|
skip?: number
|
|
_count?: TransactionCountAggregateInputType | true
|
|
_avg?: TransactionAvgAggregateInputType
|
|
_sum?: TransactionSumAggregateInputType
|
|
_min?: TransactionMinAggregateInputType
|
|
_max?: TransactionMaxAggregateInputType
|
|
}
|
|
|
|
export type TransactionGroupByOutputType = {
|
|
id: string
|
|
idempotencyKey: string
|
|
vendorId: string
|
|
userId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes: string | null
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
_count: TransactionCountAggregateOutputType | null
|
|
_avg: TransactionAvgAggregateOutputType | null
|
|
_sum: TransactionSumAggregateOutputType | null
|
|
_min: TransactionMinAggregateOutputType | null
|
|
_max: TransactionMaxAggregateOutputType | null
|
|
}
|
|
|
|
type GetTransactionGroupByPayload<T extends TransactionGroupByArgs> = Prisma.PrismaPromise<
|
|
Array<
|
|
PickEnumerable<TransactionGroupByOutputType, T['by']> &
|
|
{
|
|
[P in ((keyof T) & (keyof TransactionGroupByOutputType))]: P extends '_count'
|
|
? T[P] extends boolean
|
|
? number
|
|
: GetScalarType<T[P], TransactionGroupByOutputType[P]>
|
|
: GetScalarType<T[P], TransactionGroupByOutputType[P]>
|
|
}
|
|
>
|
|
>
|
|
|
|
|
|
export type TransactionSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
idempotencyKey?: boolean
|
|
vendorId?: boolean
|
|
userId?: boolean
|
|
status?: boolean
|
|
paymentMethod?: boolean
|
|
subtotal?: boolean
|
|
taxTotal?: boolean
|
|
discountTotal?: boolean
|
|
total?: boolean
|
|
notes?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
user?: boolean | UserDefaultArgs<ExtArgs>
|
|
items?: boolean | Transaction$itemsArgs<ExtArgs>
|
|
_count?: boolean | TransactionCountOutputTypeDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["transaction"]>
|
|
|
|
export type TransactionSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
idempotencyKey?: boolean
|
|
vendorId?: boolean
|
|
userId?: boolean
|
|
status?: boolean
|
|
paymentMethod?: boolean
|
|
subtotal?: boolean
|
|
taxTotal?: boolean
|
|
discountTotal?: boolean
|
|
total?: boolean
|
|
notes?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
user?: boolean | UserDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["transaction"]>
|
|
|
|
export type TransactionSelectScalar = {
|
|
id?: boolean
|
|
idempotencyKey?: boolean
|
|
vendorId?: boolean
|
|
userId?: boolean
|
|
status?: boolean
|
|
paymentMethod?: boolean
|
|
subtotal?: boolean
|
|
taxTotal?: boolean
|
|
discountTotal?: boolean
|
|
total?: boolean
|
|
notes?: boolean
|
|
createdAt?: boolean
|
|
updatedAt?: boolean
|
|
}
|
|
|
|
export type TransactionInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
user?: boolean | UserDefaultArgs<ExtArgs>
|
|
items?: boolean | Transaction$itemsArgs<ExtArgs>
|
|
_count?: boolean | TransactionCountOutputTypeDefaultArgs<ExtArgs>
|
|
}
|
|
export type TransactionIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
vendor?: boolean | VendorDefaultArgs<ExtArgs>
|
|
user?: boolean | UserDefaultArgs<ExtArgs>
|
|
}
|
|
|
|
export type $TransactionPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "Transaction"
|
|
objects: {
|
|
vendor: Prisma.$VendorPayload<ExtArgs>
|
|
user: Prisma.$UserPayload<ExtArgs>
|
|
items: Prisma.$TransactionItemPayload<ExtArgs>[]
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
idempotencyKey: string
|
|
vendorId: string
|
|
userId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes: string | null
|
|
createdAt: Date
|
|
updatedAt: Date
|
|
}, ExtArgs["result"]["transaction"]>
|
|
composites: {}
|
|
}
|
|
|
|
type TransactionGetPayload<S extends boolean | null | undefined | TransactionDefaultArgs> = $Result.GetResult<Prisma.$TransactionPayload, S>
|
|
|
|
type TransactionCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
|
|
Omit<TransactionFindManyArgs, 'select' | 'include' | 'distinct'> & {
|
|
select?: TransactionCountAggregateInputType | true
|
|
}
|
|
|
|
export interface TransactionDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
|
|
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Transaction'], meta: { name: 'Transaction' } }
|
|
/**
|
|
* Find zero or one Transaction that matches the filter.
|
|
* @param {TransactionFindUniqueArgs} args - Arguments to find a Transaction
|
|
* @example
|
|
* // Get one Transaction
|
|
* const transaction = await prisma.transaction.findUnique({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUnique<T extends TransactionFindUniqueArgs>(args: SelectSubset<T, TransactionFindUniqueArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findUnique"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find one Transaction that matches the filter or throw an error with `error.code='P2025'`
|
|
* if no matches were found.
|
|
* @param {TransactionFindUniqueOrThrowArgs} args - Arguments to find a Transaction
|
|
* @example
|
|
* // Get one Transaction
|
|
* const transaction = await prisma.transaction.findUniqueOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUniqueOrThrow<T extends TransactionFindUniqueOrThrowArgs>(args: SelectSubset<T, TransactionFindUniqueOrThrowArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findUniqueOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find the first Transaction 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 {TransactionFindFirstArgs} args - Arguments to find a Transaction
|
|
* @example
|
|
* // Get one Transaction
|
|
* const transaction = await prisma.transaction.findFirst({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirst<T extends TransactionFindFirstArgs>(args?: SelectSubset<T, TransactionFindFirstArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find the first Transaction 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 {TransactionFindFirstOrThrowArgs} args - Arguments to find a Transaction
|
|
* @example
|
|
* // Get one Transaction
|
|
* const transaction = await prisma.transaction.findFirstOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirstOrThrow<T extends TransactionFindFirstOrThrowArgs>(args?: SelectSubset<T, TransactionFindFirstOrThrowArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find zero or more Transactions 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 {TransactionFindManyArgs} args - Arguments to filter and select certain fields only.
|
|
* @example
|
|
* // Get all Transactions
|
|
* const transactions = await prisma.transaction.findMany()
|
|
*
|
|
* // Get first 10 Transactions
|
|
* const transactions = await prisma.transaction.findMany({ take: 10 })
|
|
*
|
|
* // Only select the `id`
|
|
* const transactionWithIdOnly = await prisma.transaction.findMany({ select: { id: true } })
|
|
*
|
|
*/
|
|
findMany<T extends TransactionFindManyArgs>(args?: SelectSubset<T, TransactionFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findMany">>
|
|
|
|
/**
|
|
* Create a Transaction.
|
|
* @param {TransactionCreateArgs} args - Arguments to create a Transaction.
|
|
* @example
|
|
* // Create one Transaction
|
|
* const Transaction = await prisma.transaction.create({
|
|
* data: {
|
|
* // ... data to create a Transaction
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
create<T extends TransactionCreateArgs>(args: SelectSubset<T, TransactionCreateArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "create">, never, ExtArgs>
|
|
|
|
/**
|
|
* Create many Transactions.
|
|
* @param {TransactionCreateManyArgs} args - Arguments to create many Transactions.
|
|
* @example
|
|
* // Create many Transactions
|
|
* const transaction = await prisma.transaction.createMany({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
*/
|
|
createMany<T extends TransactionCreateManyArgs>(args?: SelectSubset<T, TransactionCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create many Transactions and returns the data saved in the database.
|
|
* @param {TransactionCreateManyAndReturnArgs} args - Arguments to create many Transactions.
|
|
* @example
|
|
* // Create many Transactions
|
|
* const transaction = await prisma.transaction.createManyAndReturn({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
* // Create many Transactions and only return the `id`
|
|
* const transactionWithIdOnly = await prisma.transaction.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 TransactionCreateManyAndReturnArgs>(args?: SelectSubset<T, TransactionCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "createManyAndReturn">>
|
|
|
|
/**
|
|
* Delete a Transaction.
|
|
* @param {TransactionDeleteArgs} args - Arguments to delete one Transaction.
|
|
* @example
|
|
* // Delete one Transaction
|
|
* const Transaction = await prisma.transaction.delete({
|
|
* where: {
|
|
* // ... filter to delete one Transaction
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
delete<T extends TransactionDeleteArgs>(args: SelectSubset<T, TransactionDeleteArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "delete">, never, ExtArgs>
|
|
|
|
/**
|
|
* Update one Transaction.
|
|
* @param {TransactionUpdateArgs} args - Arguments to update one Transaction.
|
|
* @example
|
|
* // Update one Transaction
|
|
* const transaction = await prisma.transaction.update({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
update<T extends TransactionUpdateArgs>(args: SelectSubset<T, TransactionUpdateArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "update">, never, ExtArgs>
|
|
|
|
/**
|
|
* Delete zero or more Transactions.
|
|
* @param {TransactionDeleteManyArgs} args - Arguments to filter Transactions to delete.
|
|
* @example
|
|
* // Delete a few Transactions
|
|
* const { count } = await prisma.transaction.deleteMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
deleteMany<T extends TransactionDeleteManyArgs>(args?: SelectSubset<T, TransactionDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Update zero or more Transactions.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TransactionUpdateManyArgs} args - Arguments to update one or more rows.
|
|
* @example
|
|
* // Update many Transactions
|
|
* const transaction = await prisma.transaction.updateMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
updateMany<T extends TransactionUpdateManyArgs>(args: SelectSubset<T, TransactionUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create or update one Transaction.
|
|
* @param {TransactionUpsertArgs} args - Arguments to update or create a Transaction.
|
|
* @example
|
|
* // Update or create a Transaction
|
|
* const transaction = await prisma.transaction.upsert({
|
|
* create: {
|
|
* // ... data to create a Transaction
|
|
* },
|
|
* update: {
|
|
* // ... in case it already exists, update
|
|
* },
|
|
* where: {
|
|
* // ... the filter for the Transaction we want to update
|
|
* }
|
|
* })
|
|
*/
|
|
upsert<T extends TransactionUpsertArgs>(args: SelectSubset<T, TransactionUpsertArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "upsert">, never, ExtArgs>
|
|
|
|
|
|
/**
|
|
* Count the number of Transactions.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TransactionCountArgs} args - Arguments to filter Transactions to count.
|
|
* @example
|
|
* // Count the number of Transactions
|
|
* const count = await prisma.transaction.count({
|
|
* where: {
|
|
* // ... the filter for the Transactions we want to count
|
|
* }
|
|
* })
|
|
**/
|
|
count<T extends TransactionCountArgs>(
|
|
args?: Subset<T, TransactionCountArgs>,
|
|
): Prisma.PrismaPromise<
|
|
T extends $Utils.Record<'select', any>
|
|
? T['select'] extends true
|
|
? number
|
|
: GetScalarType<T['select'], TransactionCountAggregateOutputType>
|
|
: number
|
|
>
|
|
|
|
/**
|
|
* Allows you to perform aggregations operations on a Transaction.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TransactionAggregateArgs} 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 TransactionAggregateArgs>(args: Subset<T, TransactionAggregateArgs>): Prisma.PrismaPromise<GetTransactionAggregateType<T>>
|
|
|
|
/**
|
|
* Group by Transaction.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TransactionGroupByArgs} 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 TransactionGroupByArgs,
|
|
HasSelectOrTake extends Or<
|
|
Extends<'skip', Keys<T>>,
|
|
Extends<'take', Keys<T>>
|
|
>,
|
|
OrderByArg extends True extends HasSelectOrTake
|
|
? { orderBy: TransactionGroupByArgs['orderBy'] }
|
|
: { orderBy?: TransactionGroupByArgs['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, TransactionGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetTransactionGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
|
|
/**
|
|
* Fields of the Transaction model
|
|
*/
|
|
readonly fields: TransactionFieldRefs;
|
|
}
|
|
|
|
/**
|
|
* The delegate class that acts as a "Promise-like" for Transaction.
|
|
* 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__TransactionClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
|
|
readonly [Symbol.toStringTag]: "PrismaPromise"
|
|
vendor<T extends VendorDefaultArgs<ExtArgs> = {}>(args?: Subset<T, VendorDefaultArgs<ExtArgs>>): Prisma__VendorClient<$Result.GetResult<Prisma.$VendorPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
|
|
user<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
|
|
items<T extends Transaction$itemsArgs<ExtArgs> = {}>(args?: Subset<T, Transaction$itemsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionItemPayload<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 Transaction model
|
|
*/
|
|
interface TransactionFieldRefs {
|
|
readonly id: FieldRef<"Transaction", 'String'>
|
|
readonly idempotencyKey: FieldRef<"Transaction", 'String'>
|
|
readonly vendorId: FieldRef<"Transaction", 'String'>
|
|
readonly userId: FieldRef<"Transaction", 'String'>
|
|
readonly status: FieldRef<"Transaction", 'String'>
|
|
readonly paymentMethod: FieldRef<"Transaction", 'String'>
|
|
readonly subtotal: FieldRef<"Transaction", 'Float'>
|
|
readonly taxTotal: FieldRef<"Transaction", 'Float'>
|
|
readonly discountTotal: FieldRef<"Transaction", 'Float'>
|
|
readonly total: FieldRef<"Transaction", 'Float'>
|
|
readonly notes: FieldRef<"Transaction", 'String'>
|
|
readonly createdAt: FieldRef<"Transaction", 'DateTime'>
|
|
readonly updatedAt: FieldRef<"Transaction", 'DateTime'>
|
|
}
|
|
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* Transaction findUnique
|
|
*/
|
|
export type TransactionFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Transaction to fetch.
|
|
*/
|
|
where: TransactionWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Transaction findUniqueOrThrow
|
|
*/
|
|
export type TransactionFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Transaction to fetch.
|
|
*/
|
|
where: TransactionWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Transaction findFirst
|
|
*/
|
|
export type TransactionFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Transaction to fetch.
|
|
*/
|
|
where?: TransactionWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Transactions to fetch.
|
|
*/
|
|
orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Transactions.
|
|
*/
|
|
cursor?: TransactionWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Transactions 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` Transactions.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Transactions.
|
|
*/
|
|
distinct?: TransactionScalarFieldEnum | TransactionScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Transaction findFirstOrThrow
|
|
*/
|
|
export type TransactionFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Transaction to fetch.
|
|
*/
|
|
where?: TransactionWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Transactions to fetch.
|
|
*/
|
|
orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for Transactions.
|
|
*/
|
|
cursor?: TransactionWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Transactions 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` Transactions.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of Transactions.
|
|
*/
|
|
distinct?: TransactionScalarFieldEnum | TransactionScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Transaction findMany
|
|
*/
|
|
export type TransactionFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which Transactions to fetch.
|
|
*/
|
|
where?: TransactionWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of Transactions to fetch.
|
|
*/
|
|
orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for listing Transactions.
|
|
*/
|
|
cursor?: TransactionWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` Transactions 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` Transactions.
|
|
*/
|
|
skip?: number
|
|
distinct?: TransactionScalarFieldEnum | TransactionScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Transaction create
|
|
*/
|
|
export type TransactionCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to create a Transaction.
|
|
*/
|
|
data: XOR<TransactionCreateInput, TransactionUncheckedCreateInput>
|
|
}
|
|
|
|
/**
|
|
* Transaction createMany
|
|
*/
|
|
export type TransactionCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to create many Transactions.
|
|
*/
|
|
data: TransactionCreateManyInput | TransactionCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* Transaction createManyAndReturn
|
|
*/
|
|
export type TransactionCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelectCreateManyAndReturn<ExtArgs> | null
|
|
/**
|
|
* The data used to create many Transactions.
|
|
*/
|
|
data: TransactionCreateManyInput | TransactionCreateManyInput[]
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionIncludeCreateManyAndReturn<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* Transaction update
|
|
*/
|
|
export type TransactionUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to update a Transaction.
|
|
*/
|
|
data: XOR<TransactionUpdateInput, TransactionUncheckedUpdateInput>
|
|
/**
|
|
* Choose, which Transaction to update.
|
|
*/
|
|
where: TransactionWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Transaction updateMany
|
|
*/
|
|
export type TransactionUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to update Transactions.
|
|
*/
|
|
data: XOR<TransactionUpdateManyMutationInput, TransactionUncheckedUpdateManyInput>
|
|
/**
|
|
* Filter which Transactions to update
|
|
*/
|
|
where?: TransactionWhereInput
|
|
}
|
|
|
|
/**
|
|
* Transaction upsert
|
|
*/
|
|
export type TransactionUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* The filter to search for the Transaction to update in case it exists.
|
|
*/
|
|
where: TransactionWhereUniqueInput
|
|
/**
|
|
* In case the Transaction found by the `where` argument doesn't exist, create a new Transaction with this data.
|
|
*/
|
|
create: XOR<TransactionCreateInput, TransactionUncheckedCreateInput>
|
|
/**
|
|
* In case the Transaction was found with the provided `where` argument, update it with this data.
|
|
*/
|
|
update: XOR<TransactionUpdateInput, TransactionUncheckedUpdateInput>
|
|
}
|
|
|
|
/**
|
|
* Transaction delete
|
|
*/
|
|
export type TransactionDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
/**
|
|
* Filter which Transaction to delete.
|
|
*/
|
|
where: TransactionWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* Transaction deleteMany
|
|
*/
|
|
export type TransactionDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which Transactions to delete
|
|
*/
|
|
where?: TransactionWhereInput
|
|
}
|
|
|
|
/**
|
|
* Transaction.items
|
|
*/
|
|
export type Transaction$itemsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
where?: TransactionItemWhereInput
|
|
orderBy?: TransactionItemOrderByWithRelationInput | TransactionItemOrderByWithRelationInput[]
|
|
cursor?: TransactionItemWhereUniqueInput
|
|
take?: number
|
|
skip?: number
|
|
distinct?: TransactionItemScalarFieldEnum | TransactionItemScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* Transaction without action
|
|
*/
|
|
export type TransactionDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the Transaction
|
|
*/
|
|
select?: TransactionSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionInclude<ExtArgs> | null
|
|
}
|
|
|
|
|
|
/**
|
|
* Model TransactionItem
|
|
*/
|
|
|
|
export type AggregateTransactionItem = {
|
|
_count: TransactionItemCountAggregateOutputType | null
|
|
_avg: TransactionItemAvgAggregateOutputType | null
|
|
_sum: TransactionItemSumAggregateOutputType | null
|
|
_min: TransactionItemMinAggregateOutputType | null
|
|
_max: TransactionItemMaxAggregateOutputType | null
|
|
}
|
|
|
|
export type TransactionItemAvgAggregateOutputType = {
|
|
quantity: number | null
|
|
unitPrice: number | null
|
|
taxRate: number | null
|
|
discount: number | null
|
|
total: number | null
|
|
}
|
|
|
|
export type TransactionItemSumAggregateOutputType = {
|
|
quantity: number | null
|
|
unitPrice: number | null
|
|
taxRate: number | null
|
|
discount: number | null
|
|
total: number | null
|
|
}
|
|
|
|
export type TransactionItemMinAggregateOutputType = {
|
|
id: string | null
|
|
transactionId: string | null
|
|
productId: string | null
|
|
productName: string | null
|
|
quantity: number | null
|
|
unitPrice: number | null
|
|
taxRate: number | null
|
|
discount: number | null
|
|
total: number | null
|
|
}
|
|
|
|
export type TransactionItemMaxAggregateOutputType = {
|
|
id: string | null
|
|
transactionId: string | null
|
|
productId: string | null
|
|
productName: string | null
|
|
quantity: number | null
|
|
unitPrice: number | null
|
|
taxRate: number | null
|
|
discount: number | null
|
|
total: number | null
|
|
}
|
|
|
|
export type TransactionItemCountAggregateOutputType = {
|
|
id: number
|
|
transactionId: number
|
|
productId: number
|
|
productName: number
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
_all: number
|
|
}
|
|
|
|
|
|
export type TransactionItemAvgAggregateInputType = {
|
|
quantity?: true
|
|
unitPrice?: true
|
|
taxRate?: true
|
|
discount?: true
|
|
total?: true
|
|
}
|
|
|
|
export type TransactionItemSumAggregateInputType = {
|
|
quantity?: true
|
|
unitPrice?: true
|
|
taxRate?: true
|
|
discount?: true
|
|
total?: true
|
|
}
|
|
|
|
export type TransactionItemMinAggregateInputType = {
|
|
id?: true
|
|
transactionId?: true
|
|
productId?: true
|
|
productName?: true
|
|
quantity?: true
|
|
unitPrice?: true
|
|
taxRate?: true
|
|
discount?: true
|
|
total?: true
|
|
}
|
|
|
|
export type TransactionItemMaxAggregateInputType = {
|
|
id?: true
|
|
transactionId?: true
|
|
productId?: true
|
|
productName?: true
|
|
quantity?: true
|
|
unitPrice?: true
|
|
taxRate?: true
|
|
discount?: true
|
|
total?: true
|
|
}
|
|
|
|
export type TransactionItemCountAggregateInputType = {
|
|
id?: true
|
|
transactionId?: true
|
|
productId?: true
|
|
productName?: true
|
|
quantity?: true
|
|
unitPrice?: true
|
|
taxRate?: true
|
|
discount?: true
|
|
total?: true
|
|
_all?: true
|
|
}
|
|
|
|
export type TransactionItemAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which TransactionItem to aggregate.
|
|
*/
|
|
where?: TransactionItemWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of TransactionItems to fetch.
|
|
*/
|
|
orderBy?: TransactionItemOrderByWithRelationInput | TransactionItemOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the start position
|
|
*/
|
|
cursor?: TransactionItemWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` TransactionItems 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` TransactionItems.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Count returned TransactionItems
|
|
**/
|
|
_count?: true | TransactionItemCountAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to average
|
|
**/
|
|
_avg?: TransactionItemAvgAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to sum
|
|
**/
|
|
_sum?: TransactionItemSumAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the minimum value
|
|
**/
|
|
_min?: TransactionItemMinAggregateInputType
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
|
*
|
|
* Select which fields to find the maximum value
|
|
**/
|
|
_max?: TransactionItemMaxAggregateInputType
|
|
}
|
|
|
|
export type GetTransactionItemAggregateType<T extends TransactionItemAggregateArgs> = {
|
|
[P in keyof T & keyof AggregateTransactionItem]: P extends '_count' | 'count'
|
|
? T[P] extends true
|
|
? number
|
|
: GetScalarType<T[P], AggregateTransactionItem[P]>
|
|
: GetScalarType<T[P], AggregateTransactionItem[P]>
|
|
}
|
|
|
|
|
|
|
|
|
|
export type TransactionItemGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
where?: TransactionItemWhereInput
|
|
orderBy?: TransactionItemOrderByWithAggregationInput | TransactionItemOrderByWithAggregationInput[]
|
|
by: TransactionItemScalarFieldEnum[] | TransactionItemScalarFieldEnum
|
|
having?: TransactionItemScalarWhereWithAggregatesInput
|
|
take?: number
|
|
skip?: number
|
|
_count?: TransactionItemCountAggregateInputType | true
|
|
_avg?: TransactionItemAvgAggregateInputType
|
|
_sum?: TransactionItemSumAggregateInputType
|
|
_min?: TransactionItemMinAggregateInputType
|
|
_max?: TransactionItemMaxAggregateInputType
|
|
}
|
|
|
|
export type TransactionItemGroupByOutputType = {
|
|
id: string
|
|
transactionId: string
|
|
productId: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
_count: TransactionItemCountAggregateOutputType | null
|
|
_avg: TransactionItemAvgAggregateOutputType | null
|
|
_sum: TransactionItemSumAggregateOutputType | null
|
|
_min: TransactionItemMinAggregateOutputType | null
|
|
_max: TransactionItemMaxAggregateOutputType | null
|
|
}
|
|
|
|
type GetTransactionItemGroupByPayload<T extends TransactionItemGroupByArgs> = Prisma.PrismaPromise<
|
|
Array<
|
|
PickEnumerable<TransactionItemGroupByOutputType, T['by']> &
|
|
{
|
|
[P in ((keyof T) & (keyof TransactionItemGroupByOutputType))]: P extends '_count'
|
|
? T[P] extends boolean
|
|
? number
|
|
: GetScalarType<T[P], TransactionItemGroupByOutputType[P]>
|
|
: GetScalarType<T[P], TransactionItemGroupByOutputType[P]>
|
|
}
|
|
>
|
|
>
|
|
|
|
|
|
export type TransactionItemSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
transactionId?: boolean
|
|
productId?: boolean
|
|
productName?: boolean
|
|
quantity?: boolean
|
|
unitPrice?: boolean
|
|
taxRate?: boolean
|
|
discount?: boolean
|
|
total?: boolean
|
|
transaction?: boolean | TransactionDefaultArgs<ExtArgs>
|
|
product?: boolean | ProductDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["transactionItem"]>
|
|
|
|
export type TransactionItemSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
|
|
id?: boolean
|
|
transactionId?: boolean
|
|
productId?: boolean
|
|
productName?: boolean
|
|
quantity?: boolean
|
|
unitPrice?: boolean
|
|
taxRate?: boolean
|
|
discount?: boolean
|
|
total?: boolean
|
|
transaction?: boolean | TransactionDefaultArgs<ExtArgs>
|
|
product?: boolean | ProductDefaultArgs<ExtArgs>
|
|
}, ExtArgs["result"]["transactionItem"]>
|
|
|
|
export type TransactionItemSelectScalar = {
|
|
id?: boolean
|
|
transactionId?: boolean
|
|
productId?: boolean
|
|
productName?: boolean
|
|
quantity?: boolean
|
|
unitPrice?: boolean
|
|
taxRate?: boolean
|
|
discount?: boolean
|
|
total?: boolean
|
|
}
|
|
|
|
export type TransactionItemInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
transaction?: boolean | TransactionDefaultArgs<ExtArgs>
|
|
product?: boolean | ProductDefaultArgs<ExtArgs>
|
|
}
|
|
export type TransactionItemIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
transaction?: boolean | TransactionDefaultArgs<ExtArgs>
|
|
product?: boolean | ProductDefaultArgs<ExtArgs>
|
|
}
|
|
|
|
export type $TransactionItemPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
name: "TransactionItem"
|
|
objects: {
|
|
transaction: Prisma.$TransactionPayload<ExtArgs>
|
|
product: Prisma.$ProductPayload<ExtArgs>
|
|
}
|
|
scalars: $Extensions.GetPayloadResult<{
|
|
id: string
|
|
transactionId: string
|
|
productId: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
}, ExtArgs["result"]["transactionItem"]>
|
|
composites: {}
|
|
}
|
|
|
|
type TransactionItemGetPayload<S extends boolean | null | undefined | TransactionItemDefaultArgs> = $Result.GetResult<Prisma.$TransactionItemPayload, S>
|
|
|
|
type TransactionItemCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
|
|
Omit<TransactionItemFindManyArgs, 'select' | 'include' | 'distinct'> & {
|
|
select?: TransactionItemCountAggregateInputType | true
|
|
}
|
|
|
|
export interface TransactionItemDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
|
|
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['TransactionItem'], meta: { name: 'TransactionItem' } }
|
|
/**
|
|
* Find zero or one TransactionItem that matches the filter.
|
|
* @param {TransactionItemFindUniqueArgs} args - Arguments to find a TransactionItem
|
|
* @example
|
|
* // Get one TransactionItem
|
|
* const transactionItem = await prisma.transactionItem.findUnique({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUnique<T extends TransactionItemFindUniqueArgs>(args: SelectSubset<T, TransactionItemFindUniqueArgs<ExtArgs>>): Prisma__TransactionItemClient<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "findUnique"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find one TransactionItem that matches the filter or throw an error with `error.code='P2025'`
|
|
* if no matches were found.
|
|
* @param {TransactionItemFindUniqueOrThrowArgs} args - Arguments to find a TransactionItem
|
|
* @example
|
|
* // Get one TransactionItem
|
|
* const transactionItem = await prisma.transactionItem.findUniqueOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findUniqueOrThrow<T extends TransactionItemFindUniqueOrThrowArgs>(args: SelectSubset<T, TransactionItemFindUniqueOrThrowArgs<ExtArgs>>): Prisma__TransactionItemClient<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "findUniqueOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find the first TransactionItem 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 {TransactionItemFindFirstArgs} args - Arguments to find a TransactionItem
|
|
* @example
|
|
* // Get one TransactionItem
|
|
* const transactionItem = await prisma.transactionItem.findFirst({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirst<T extends TransactionItemFindFirstArgs>(args?: SelectSubset<T, TransactionItemFindFirstArgs<ExtArgs>>): Prisma__TransactionItemClient<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>
|
|
|
|
/**
|
|
* Find the first TransactionItem 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 {TransactionItemFindFirstOrThrowArgs} args - Arguments to find a TransactionItem
|
|
* @example
|
|
* // Get one TransactionItem
|
|
* const transactionItem = await prisma.transactionItem.findFirstOrThrow({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*/
|
|
findFirstOrThrow<T extends TransactionItemFindFirstOrThrowArgs>(args?: SelectSubset<T, TransactionItemFindFirstOrThrowArgs<ExtArgs>>): Prisma__TransactionItemClient<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>
|
|
|
|
/**
|
|
* Find zero or more TransactionItems 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 {TransactionItemFindManyArgs} args - Arguments to filter and select certain fields only.
|
|
* @example
|
|
* // Get all TransactionItems
|
|
* const transactionItems = await prisma.transactionItem.findMany()
|
|
*
|
|
* // Get first 10 TransactionItems
|
|
* const transactionItems = await prisma.transactionItem.findMany({ take: 10 })
|
|
*
|
|
* // Only select the `id`
|
|
* const transactionItemWithIdOnly = await prisma.transactionItem.findMany({ select: { id: true } })
|
|
*
|
|
*/
|
|
findMany<T extends TransactionItemFindManyArgs>(args?: SelectSubset<T, TransactionItemFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "findMany">>
|
|
|
|
/**
|
|
* Create a TransactionItem.
|
|
* @param {TransactionItemCreateArgs} args - Arguments to create a TransactionItem.
|
|
* @example
|
|
* // Create one TransactionItem
|
|
* const TransactionItem = await prisma.transactionItem.create({
|
|
* data: {
|
|
* // ... data to create a TransactionItem
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
create<T extends TransactionItemCreateArgs>(args: SelectSubset<T, TransactionItemCreateArgs<ExtArgs>>): Prisma__TransactionItemClient<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "create">, never, ExtArgs>
|
|
|
|
/**
|
|
* Create many TransactionItems.
|
|
* @param {TransactionItemCreateManyArgs} args - Arguments to create many TransactionItems.
|
|
* @example
|
|
* // Create many TransactionItems
|
|
* const transactionItem = await prisma.transactionItem.createMany({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
*/
|
|
createMany<T extends TransactionItemCreateManyArgs>(args?: SelectSubset<T, TransactionItemCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create many TransactionItems and returns the data saved in the database.
|
|
* @param {TransactionItemCreateManyAndReturnArgs} args - Arguments to create many TransactionItems.
|
|
* @example
|
|
* // Create many TransactionItems
|
|
* const transactionItem = await prisma.transactionItem.createManyAndReturn({
|
|
* data: [
|
|
* // ... provide data here
|
|
* ]
|
|
* })
|
|
*
|
|
* // Create many TransactionItems and only return the `id`
|
|
* const transactionItemWithIdOnly = await prisma.transactionItem.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 TransactionItemCreateManyAndReturnArgs>(args?: SelectSubset<T, TransactionItemCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "createManyAndReturn">>
|
|
|
|
/**
|
|
* Delete a TransactionItem.
|
|
* @param {TransactionItemDeleteArgs} args - Arguments to delete one TransactionItem.
|
|
* @example
|
|
* // Delete one TransactionItem
|
|
* const TransactionItem = await prisma.transactionItem.delete({
|
|
* where: {
|
|
* // ... filter to delete one TransactionItem
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
delete<T extends TransactionItemDeleteArgs>(args: SelectSubset<T, TransactionItemDeleteArgs<ExtArgs>>): Prisma__TransactionItemClient<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "delete">, never, ExtArgs>
|
|
|
|
/**
|
|
* Update one TransactionItem.
|
|
* @param {TransactionItemUpdateArgs} args - Arguments to update one TransactionItem.
|
|
* @example
|
|
* // Update one TransactionItem
|
|
* const transactionItem = await prisma.transactionItem.update({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
update<T extends TransactionItemUpdateArgs>(args: SelectSubset<T, TransactionItemUpdateArgs<ExtArgs>>): Prisma__TransactionItemClient<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "update">, never, ExtArgs>
|
|
|
|
/**
|
|
* Delete zero or more TransactionItems.
|
|
* @param {TransactionItemDeleteManyArgs} args - Arguments to filter TransactionItems to delete.
|
|
* @example
|
|
* // Delete a few TransactionItems
|
|
* const { count } = await prisma.transactionItem.deleteMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
deleteMany<T extends TransactionItemDeleteManyArgs>(args?: SelectSubset<T, TransactionItemDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Update zero or more TransactionItems.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TransactionItemUpdateManyArgs} args - Arguments to update one or more rows.
|
|
* @example
|
|
* // Update many TransactionItems
|
|
* const transactionItem = await prisma.transactionItem.updateMany({
|
|
* where: {
|
|
* // ... provide filter here
|
|
* },
|
|
* data: {
|
|
* // ... provide data here
|
|
* }
|
|
* })
|
|
*
|
|
*/
|
|
updateMany<T extends TransactionItemUpdateManyArgs>(args: SelectSubset<T, TransactionItemUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>
|
|
|
|
/**
|
|
* Create or update one TransactionItem.
|
|
* @param {TransactionItemUpsertArgs} args - Arguments to update or create a TransactionItem.
|
|
* @example
|
|
* // Update or create a TransactionItem
|
|
* const transactionItem = await prisma.transactionItem.upsert({
|
|
* create: {
|
|
* // ... data to create a TransactionItem
|
|
* },
|
|
* update: {
|
|
* // ... in case it already exists, update
|
|
* },
|
|
* where: {
|
|
* // ... the filter for the TransactionItem we want to update
|
|
* }
|
|
* })
|
|
*/
|
|
upsert<T extends TransactionItemUpsertArgs>(args: SelectSubset<T, TransactionItemUpsertArgs<ExtArgs>>): Prisma__TransactionItemClient<$Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "upsert">, never, ExtArgs>
|
|
|
|
|
|
/**
|
|
* Count the number of TransactionItems.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TransactionItemCountArgs} args - Arguments to filter TransactionItems to count.
|
|
* @example
|
|
* // Count the number of TransactionItems
|
|
* const count = await prisma.transactionItem.count({
|
|
* where: {
|
|
* // ... the filter for the TransactionItems we want to count
|
|
* }
|
|
* })
|
|
**/
|
|
count<T extends TransactionItemCountArgs>(
|
|
args?: Subset<T, TransactionItemCountArgs>,
|
|
): Prisma.PrismaPromise<
|
|
T extends $Utils.Record<'select', any>
|
|
? T['select'] extends true
|
|
? number
|
|
: GetScalarType<T['select'], TransactionItemCountAggregateOutputType>
|
|
: number
|
|
>
|
|
|
|
/**
|
|
* Allows you to perform aggregations operations on a TransactionItem.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TransactionItemAggregateArgs} 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 TransactionItemAggregateArgs>(args: Subset<T, TransactionItemAggregateArgs>): Prisma.PrismaPromise<GetTransactionItemAggregateType<T>>
|
|
|
|
/**
|
|
* Group by TransactionItem.
|
|
* Note, that providing `undefined` is treated as the value not being there.
|
|
* Read more here: https://pris.ly/d/null-undefined
|
|
* @param {TransactionItemGroupByArgs} 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 TransactionItemGroupByArgs,
|
|
HasSelectOrTake extends Or<
|
|
Extends<'skip', Keys<T>>,
|
|
Extends<'take', Keys<T>>
|
|
>,
|
|
OrderByArg extends True extends HasSelectOrTake
|
|
? { orderBy: TransactionItemGroupByArgs['orderBy'] }
|
|
: { orderBy?: TransactionItemGroupByArgs['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, TransactionItemGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetTransactionItemGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
|
|
/**
|
|
* Fields of the TransactionItem model
|
|
*/
|
|
readonly fields: TransactionItemFieldRefs;
|
|
}
|
|
|
|
/**
|
|
* The delegate class that acts as a "Promise-like" for TransactionItem.
|
|
* 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__TransactionItemClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
|
|
readonly [Symbol.toStringTag]: "PrismaPromise"
|
|
transaction<T extends TransactionDefaultArgs<ExtArgs> = {}>(args?: Subset<T, TransactionDefaultArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<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 TransactionItem model
|
|
*/
|
|
interface TransactionItemFieldRefs {
|
|
readonly id: FieldRef<"TransactionItem", 'String'>
|
|
readonly transactionId: FieldRef<"TransactionItem", 'String'>
|
|
readonly productId: FieldRef<"TransactionItem", 'String'>
|
|
readonly productName: FieldRef<"TransactionItem", 'String'>
|
|
readonly quantity: FieldRef<"TransactionItem", 'Int'>
|
|
readonly unitPrice: FieldRef<"TransactionItem", 'Float'>
|
|
readonly taxRate: FieldRef<"TransactionItem", 'Float'>
|
|
readonly discount: FieldRef<"TransactionItem", 'Float'>
|
|
readonly total: FieldRef<"TransactionItem", 'Float'>
|
|
}
|
|
|
|
|
|
// Custom InputTypes
|
|
/**
|
|
* TransactionItem findUnique
|
|
*/
|
|
export type TransactionItemFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which TransactionItem to fetch.
|
|
*/
|
|
where: TransactionItemWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* TransactionItem findUniqueOrThrow
|
|
*/
|
|
export type TransactionItemFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which TransactionItem to fetch.
|
|
*/
|
|
where: TransactionItemWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* TransactionItem findFirst
|
|
*/
|
|
export type TransactionItemFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which TransactionItem to fetch.
|
|
*/
|
|
where?: TransactionItemWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of TransactionItems to fetch.
|
|
*/
|
|
orderBy?: TransactionItemOrderByWithRelationInput | TransactionItemOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for TransactionItems.
|
|
*/
|
|
cursor?: TransactionItemWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` TransactionItems 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` TransactionItems.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of TransactionItems.
|
|
*/
|
|
distinct?: TransactionItemScalarFieldEnum | TransactionItemScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* TransactionItem findFirstOrThrow
|
|
*/
|
|
export type TransactionItemFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which TransactionItem to fetch.
|
|
*/
|
|
where?: TransactionItemWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of TransactionItems to fetch.
|
|
*/
|
|
orderBy?: TransactionItemOrderByWithRelationInput | TransactionItemOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for searching for TransactionItems.
|
|
*/
|
|
cursor?: TransactionItemWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` TransactionItems 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` TransactionItems.
|
|
*/
|
|
skip?: number
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
|
*
|
|
* Filter by unique combinations of TransactionItems.
|
|
*/
|
|
distinct?: TransactionItemScalarFieldEnum | TransactionItemScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* TransactionItem findMany
|
|
*/
|
|
export type TransactionItemFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* Filter, which TransactionItems to fetch.
|
|
*/
|
|
where?: TransactionItemWhereInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
|
*
|
|
* Determine the order of TransactionItems to fetch.
|
|
*/
|
|
orderBy?: TransactionItemOrderByWithRelationInput | TransactionItemOrderByWithRelationInput[]
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
|
|
*
|
|
* Sets the position for listing TransactionItems.
|
|
*/
|
|
cursor?: TransactionItemWhereUniqueInput
|
|
/**
|
|
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
|
*
|
|
* Take `±n` TransactionItems 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` TransactionItems.
|
|
*/
|
|
skip?: number
|
|
distinct?: TransactionItemScalarFieldEnum | TransactionItemScalarFieldEnum[]
|
|
}
|
|
|
|
/**
|
|
* TransactionItem create
|
|
*/
|
|
export type TransactionItemCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to create a TransactionItem.
|
|
*/
|
|
data: XOR<TransactionItemCreateInput, TransactionItemUncheckedCreateInput>
|
|
}
|
|
|
|
/**
|
|
* TransactionItem createMany
|
|
*/
|
|
export type TransactionItemCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to create many TransactionItems.
|
|
*/
|
|
data: TransactionItemCreateManyInput | TransactionItemCreateManyInput[]
|
|
}
|
|
|
|
/**
|
|
* TransactionItem createManyAndReturn
|
|
*/
|
|
export type TransactionItemCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelectCreateManyAndReturn<ExtArgs> | null
|
|
/**
|
|
* The data used to create many TransactionItems.
|
|
*/
|
|
data: TransactionItemCreateManyInput | TransactionItemCreateManyInput[]
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemIncludeCreateManyAndReturn<ExtArgs> | null
|
|
}
|
|
|
|
/**
|
|
* TransactionItem update
|
|
*/
|
|
export type TransactionItemUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* The data needed to update a TransactionItem.
|
|
*/
|
|
data: XOR<TransactionItemUpdateInput, TransactionItemUncheckedUpdateInput>
|
|
/**
|
|
* Choose, which TransactionItem to update.
|
|
*/
|
|
where: TransactionItemWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* TransactionItem updateMany
|
|
*/
|
|
export type TransactionItemUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* The data used to update TransactionItems.
|
|
*/
|
|
data: XOR<TransactionItemUpdateManyMutationInput, TransactionItemUncheckedUpdateManyInput>
|
|
/**
|
|
* Filter which TransactionItems to update
|
|
*/
|
|
where?: TransactionItemWhereInput
|
|
}
|
|
|
|
/**
|
|
* TransactionItem upsert
|
|
*/
|
|
export type TransactionItemUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* The filter to search for the TransactionItem to update in case it exists.
|
|
*/
|
|
where: TransactionItemWhereUniqueInput
|
|
/**
|
|
* In case the TransactionItem found by the `where` argument doesn't exist, create a new TransactionItem with this data.
|
|
*/
|
|
create: XOR<TransactionItemCreateInput, TransactionItemUncheckedCreateInput>
|
|
/**
|
|
* In case the TransactionItem was found with the provided `where` argument, update it with this data.
|
|
*/
|
|
update: XOR<TransactionItemUpdateInput, TransactionItemUncheckedUpdateInput>
|
|
}
|
|
|
|
/**
|
|
* TransactionItem delete
|
|
*/
|
|
export type TransactionItemDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
/**
|
|
* Filter which TransactionItem to delete.
|
|
*/
|
|
where: TransactionItemWhereUniqueInput
|
|
}
|
|
|
|
/**
|
|
* TransactionItem deleteMany
|
|
*/
|
|
export type TransactionItemDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Filter which TransactionItems to delete
|
|
*/
|
|
where?: TransactionItemWhereInput
|
|
}
|
|
|
|
/**
|
|
* TransactionItem without action
|
|
*/
|
|
export type TransactionItemDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
|
|
/**
|
|
* Select specific fields to fetch from the TransactionItem
|
|
*/
|
|
select?: TransactionItemSelect<ExtArgs> | null
|
|
/**
|
|
* Choose, which related nodes to fetch as well
|
|
*/
|
|
include?: TransactionItemInclude<ExtArgs> | null
|
|
}
|
|
|
|
|
|
/**
|
|
* Enums
|
|
*/
|
|
|
|
export const TransactionIsolationLevel: {
|
|
Serializable: 'Serializable'
|
|
};
|
|
|
|
export type TransactionIsolationLevel = (typeof TransactionIsolationLevel)[keyof typeof TransactionIsolationLevel]
|
|
|
|
|
|
export const VendorScalarFieldEnum: {
|
|
id: 'id',
|
|
name: 'name',
|
|
businessNum: 'businessNum',
|
|
taxSettings: 'taxSettings',
|
|
createdAt: 'createdAt',
|
|
updatedAt: 'updatedAt'
|
|
};
|
|
|
|
export type VendorScalarFieldEnum = (typeof VendorScalarFieldEnum)[keyof typeof VendorScalarFieldEnum]
|
|
|
|
|
|
export const RoleScalarFieldEnum: {
|
|
id: 'id',
|
|
name: 'name'
|
|
};
|
|
|
|
export type RoleScalarFieldEnum = (typeof RoleScalarFieldEnum)[keyof typeof RoleScalarFieldEnum]
|
|
|
|
|
|
export const UserScalarFieldEnum: {
|
|
id: 'id',
|
|
email: 'email',
|
|
passwordHash: 'passwordHash',
|
|
name: 'name',
|
|
vendorId: 'vendorId',
|
|
roleId: 'roleId',
|
|
createdAt: 'createdAt',
|
|
updatedAt: 'updatedAt'
|
|
};
|
|
|
|
export type UserScalarFieldEnum = (typeof UserScalarFieldEnum)[keyof typeof UserScalarFieldEnum]
|
|
|
|
|
|
export const RefreshTokenScalarFieldEnum: {
|
|
id: 'id',
|
|
token: 'token',
|
|
userId: 'userId',
|
|
expiresAt: 'expiresAt',
|
|
createdAt: 'createdAt'
|
|
};
|
|
|
|
export type RefreshTokenScalarFieldEnum = (typeof RefreshTokenScalarFieldEnum)[keyof typeof RefreshTokenScalarFieldEnum]
|
|
|
|
|
|
export const CategoryScalarFieldEnum: {
|
|
id: 'id',
|
|
name: 'name',
|
|
vendorId: 'vendorId',
|
|
createdAt: 'createdAt',
|
|
updatedAt: 'updatedAt'
|
|
};
|
|
|
|
export type CategoryScalarFieldEnum = (typeof CategoryScalarFieldEnum)[keyof typeof CategoryScalarFieldEnum]
|
|
|
|
|
|
export const TaxScalarFieldEnum: {
|
|
id: 'id',
|
|
name: 'name',
|
|
rate: 'rate',
|
|
vendorId: 'vendorId',
|
|
createdAt: 'createdAt',
|
|
updatedAt: 'updatedAt'
|
|
};
|
|
|
|
export type TaxScalarFieldEnum = (typeof TaxScalarFieldEnum)[keyof typeof TaxScalarFieldEnum]
|
|
|
|
|
|
export const ProductScalarFieldEnum: {
|
|
id: 'id',
|
|
name: 'name',
|
|
sku: 'sku',
|
|
description: 'description',
|
|
price: 'price',
|
|
vendorId: 'vendorId',
|
|
categoryId: 'categoryId',
|
|
taxId: 'taxId',
|
|
tags: 'tags',
|
|
version: 'version',
|
|
createdAt: 'createdAt',
|
|
updatedAt: 'updatedAt'
|
|
};
|
|
|
|
export type ProductScalarFieldEnum = (typeof ProductScalarFieldEnum)[keyof typeof ProductScalarFieldEnum]
|
|
|
|
|
|
export const TransactionScalarFieldEnum: {
|
|
id: 'id',
|
|
idempotencyKey: 'idempotencyKey',
|
|
vendorId: 'vendorId',
|
|
userId: 'userId',
|
|
status: 'status',
|
|
paymentMethod: 'paymentMethod',
|
|
subtotal: 'subtotal',
|
|
taxTotal: 'taxTotal',
|
|
discountTotal: 'discountTotal',
|
|
total: 'total',
|
|
notes: 'notes',
|
|
createdAt: 'createdAt',
|
|
updatedAt: 'updatedAt'
|
|
};
|
|
|
|
export type TransactionScalarFieldEnum = (typeof TransactionScalarFieldEnum)[keyof typeof TransactionScalarFieldEnum]
|
|
|
|
|
|
export const TransactionItemScalarFieldEnum: {
|
|
id: 'id',
|
|
transactionId: 'transactionId',
|
|
productId: 'productId',
|
|
productName: 'productName',
|
|
quantity: 'quantity',
|
|
unitPrice: 'unitPrice',
|
|
taxRate: 'taxRate',
|
|
discount: 'discount',
|
|
total: 'total'
|
|
};
|
|
|
|
export type TransactionItemScalarFieldEnum = (typeof TransactionItemScalarFieldEnum)[keyof typeof TransactionItemScalarFieldEnum]
|
|
|
|
|
|
export const SortOrder: {
|
|
asc: 'asc',
|
|
desc: 'desc'
|
|
};
|
|
|
|
export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder]
|
|
|
|
|
|
export const NullsOrder: {
|
|
first: 'first',
|
|
last: 'last'
|
|
};
|
|
|
|
export type NullsOrder = (typeof NullsOrder)[keyof typeof NullsOrder]
|
|
|
|
|
|
/**
|
|
* Field references
|
|
*/
|
|
|
|
|
|
/**
|
|
* Reference to a field of type 'String'
|
|
*/
|
|
export type StringFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'String'>
|
|
|
|
|
|
|
|
/**
|
|
* Reference to a field of type 'DateTime'
|
|
*/
|
|
export type DateTimeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'DateTime'>
|
|
|
|
|
|
|
|
/**
|
|
* Reference to a field of type 'Float'
|
|
*/
|
|
export type FloatFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Float'>
|
|
|
|
|
|
|
|
/**
|
|
* Reference to a field of type 'Int'
|
|
*/
|
|
export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'>
|
|
|
|
/**
|
|
* Deep Input Types
|
|
*/
|
|
|
|
|
|
export type VendorWhereInput = {
|
|
AND?: VendorWhereInput | VendorWhereInput[]
|
|
OR?: VendorWhereInput[]
|
|
NOT?: VendorWhereInput | VendorWhereInput[]
|
|
id?: StringFilter<"Vendor"> | string
|
|
name?: StringFilter<"Vendor"> | string
|
|
businessNum?: StringNullableFilter<"Vendor"> | string | null
|
|
taxSettings?: StringNullableFilter<"Vendor"> | string | null
|
|
createdAt?: DateTimeFilter<"Vendor"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Vendor"> | Date | string
|
|
users?: UserListRelationFilter
|
|
categories?: CategoryListRelationFilter
|
|
products?: ProductListRelationFilter
|
|
taxes?: TaxListRelationFilter
|
|
transactions?: TransactionListRelationFilter
|
|
}
|
|
|
|
export type VendorOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
businessNum?: SortOrderInput | SortOrder
|
|
taxSettings?: SortOrderInput | SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
users?: UserOrderByRelationAggregateInput
|
|
categories?: CategoryOrderByRelationAggregateInput
|
|
products?: ProductOrderByRelationAggregateInput
|
|
taxes?: TaxOrderByRelationAggregateInput
|
|
transactions?: TransactionOrderByRelationAggregateInput
|
|
}
|
|
|
|
export type VendorWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
AND?: VendorWhereInput | VendorWhereInput[]
|
|
OR?: VendorWhereInput[]
|
|
NOT?: VendorWhereInput | VendorWhereInput[]
|
|
name?: StringFilter<"Vendor"> | string
|
|
businessNum?: StringNullableFilter<"Vendor"> | string | null
|
|
taxSettings?: StringNullableFilter<"Vendor"> | string | null
|
|
createdAt?: DateTimeFilter<"Vendor"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Vendor"> | Date | string
|
|
users?: UserListRelationFilter
|
|
categories?: CategoryListRelationFilter
|
|
products?: ProductListRelationFilter
|
|
taxes?: TaxListRelationFilter
|
|
transactions?: TransactionListRelationFilter
|
|
}, "id">
|
|
|
|
export type VendorOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
businessNum?: SortOrderInput | SortOrder
|
|
taxSettings?: SortOrderInput | SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
_count?: VendorCountOrderByAggregateInput
|
|
_max?: VendorMaxOrderByAggregateInput
|
|
_min?: VendorMinOrderByAggregateInput
|
|
}
|
|
|
|
export type VendorScalarWhereWithAggregatesInput = {
|
|
AND?: VendorScalarWhereWithAggregatesInput | VendorScalarWhereWithAggregatesInput[]
|
|
OR?: VendorScalarWhereWithAggregatesInput[]
|
|
NOT?: VendorScalarWhereWithAggregatesInput | VendorScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"Vendor"> | string
|
|
name?: StringWithAggregatesFilter<"Vendor"> | string
|
|
businessNum?: StringNullableWithAggregatesFilter<"Vendor"> | string | null
|
|
taxSettings?: StringNullableWithAggregatesFilter<"Vendor"> | string | null
|
|
createdAt?: DateTimeWithAggregatesFilter<"Vendor"> | Date | string
|
|
updatedAt?: DateTimeWithAggregatesFilter<"Vendor"> | Date | string
|
|
}
|
|
|
|
export type RoleWhereInput = {
|
|
AND?: RoleWhereInput | RoleWhereInput[]
|
|
OR?: RoleWhereInput[]
|
|
NOT?: RoleWhereInput | RoleWhereInput[]
|
|
id?: StringFilter<"Role"> | string
|
|
name?: StringFilter<"Role"> | string
|
|
users?: UserListRelationFilter
|
|
}
|
|
|
|
export type RoleOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
users?: UserOrderByRelationAggregateInput
|
|
}
|
|
|
|
export type RoleWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
name?: string
|
|
AND?: RoleWhereInput | RoleWhereInput[]
|
|
OR?: RoleWhereInput[]
|
|
NOT?: RoleWhereInput | RoleWhereInput[]
|
|
users?: UserListRelationFilter
|
|
}, "id" | "name">
|
|
|
|
export type RoleOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
_count?: RoleCountOrderByAggregateInput
|
|
_max?: RoleMaxOrderByAggregateInput
|
|
_min?: RoleMinOrderByAggregateInput
|
|
}
|
|
|
|
export type RoleScalarWhereWithAggregatesInput = {
|
|
AND?: RoleScalarWhereWithAggregatesInput | RoleScalarWhereWithAggregatesInput[]
|
|
OR?: RoleScalarWhereWithAggregatesInput[]
|
|
NOT?: RoleScalarWhereWithAggregatesInput | RoleScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"Role"> | string
|
|
name?: StringWithAggregatesFilter<"Role"> | string
|
|
}
|
|
|
|
export type UserWhereInput = {
|
|
AND?: UserWhereInput | UserWhereInput[]
|
|
OR?: UserWhereInput[]
|
|
NOT?: UserWhereInput | UserWhereInput[]
|
|
id?: StringFilter<"User"> | string
|
|
email?: StringFilter<"User"> | string
|
|
passwordHash?: StringFilter<"User"> | string
|
|
name?: StringFilter<"User"> | string
|
|
vendorId?: StringFilter<"User"> | string
|
|
roleId?: StringFilter<"User"> | string
|
|
createdAt?: DateTimeFilter<"User"> | Date | string
|
|
updatedAt?: DateTimeFilter<"User"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
role?: XOR<RoleRelationFilter, RoleWhereInput>
|
|
refreshTokens?: RefreshTokenListRelationFilter
|
|
transactions?: TransactionListRelationFilter
|
|
}
|
|
|
|
export type UserOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
email?: SortOrder
|
|
passwordHash?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
roleId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
vendor?: VendorOrderByWithRelationInput
|
|
role?: RoleOrderByWithRelationInput
|
|
refreshTokens?: RefreshTokenOrderByRelationAggregateInput
|
|
transactions?: TransactionOrderByRelationAggregateInput
|
|
}
|
|
|
|
export type UserWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
email?: string
|
|
AND?: UserWhereInput | UserWhereInput[]
|
|
OR?: UserWhereInput[]
|
|
NOT?: UserWhereInput | UserWhereInput[]
|
|
passwordHash?: StringFilter<"User"> | string
|
|
name?: StringFilter<"User"> | string
|
|
vendorId?: StringFilter<"User"> | string
|
|
roleId?: StringFilter<"User"> | string
|
|
createdAt?: DateTimeFilter<"User"> | Date | string
|
|
updatedAt?: DateTimeFilter<"User"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
role?: XOR<RoleRelationFilter, RoleWhereInput>
|
|
refreshTokens?: RefreshTokenListRelationFilter
|
|
transactions?: TransactionListRelationFilter
|
|
}, "id" | "email">
|
|
|
|
export type UserOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
email?: SortOrder
|
|
passwordHash?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
roleId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
_count?: UserCountOrderByAggregateInput
|
|
_max?: UserMaxOrderByAggregateInput
|
|
_min?: UserMinOrderByAggregateInput
|
|
}
|
|
|
|
export type UserScalarWhereWithAggregatesInput = {
|
|
AND?: UserScalarWhereWithAggregatesInput | UserScalarWhereWithAggregatesInput[]
|
|
OR?: UserScalarWhereWithAggregatesInput[]
|
|
NOT?: UserScalarWhereWithAggregatesInput | UserScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"User"> | string
|
|
email?: StringWithAggregatesFilter<"User"> | string
|
|
passwordHash?: StringWithAggregatesFilter<"User"> | string
|
|
name?: StringWithAggregatesFilter<"User"> | string
|
|
vendorId?: StringWithAggregatesFilter<"User"> | string
|
|
roleId?: StringWithAggregatesFilter<"User"> | string
|
|
createdAt?: DateTimeWithAggregatesFilter<"User"> | Date | string
|
|
updatedAt?: DateTimeWithAggregatesFilter<"User"> | Date | string
|
|
}
|
|
|
|
export type RefreshTokenWhereInput = {
|
|
AND?: RefreshTokenWhereInput | RefreshTokenWhereInput[]
|
|
OR?: RefreshTokenWhereInput[]
|
|
NOT?: RefreshTokenWhereInput | RefreshTokenWhereInput[]
|
|
id?: StringFilter<"RefreshToken"> | string
|
|
token?: StringFilter<"RefreshToken"> | string
|
|
userId?: StringFilter<"RefreshToken"> | string
|
|
expiresAt?: DateTimeFilter<"RefreshToken"> | Date | string
|
|
createdAt?: DateTimeFilter<"RefreshToken"> | Date | string
|
|
user?: XOR<UserRelationFilter, UserWhereInput>
|
|
}
|
|
|
|
export type RefreshTokenOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
token?: SortOrder
|
|
userId?: SortOrder
|
|
expiresAt?: SortOrder
|
|
createdAt?: SortOrder
|
|
user?: UserOrderByWithRelationInput
|
|
}
|
|
|
|
export type RefreshTokenWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
token?: string
|
|
AND?: RefreshTokenWhereInput | RefreshTokenWhereInput[]
|
|
OR?: RefreshTokenWhereInput[]
|
|
NOT?: RefreshTokenWhereInput | RefreshTokenWhereInput[]
|
|
userId?: StringFilter<"RefreshToken"> | string
|
|
expiresAt?: DateTimeFilter<"RefreshToken"> | Date | string
|
|
createdAt?: DateTimeFilter<"RefreshToken"> | Date | string
|
|
user?: XOR<UserRelationFilter, UserWhereInput>
|
|
}, "id" | "token">
|
|
|
|
export type RefreshTokenOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
token?: SortOrder
|
|
userId?: SortOrder
|
|
expiresAt?: SortOrder
|
|
createdAt?: SortOrder
|
|
_count?: RefreshTokenCountOrderByAggregateInput
|
|
_max?: RefreshTokenMaxOrderByAggregateInput
|
|
_min?: RefreshTokenMinOrderByAggregateInput
|
|
}
|
|
|
|
export type RefreshTokenScalarWhereWithAggregatesInput = {
|
|
AND?: RefreshTokenScalarWhereWithAggregatesInput | RefreshTokenScalarWhereWithAggregatesInput[]
|
|
OR?: RefreshTokenScalarWhereWithAggregatesInput[]
|
|
NOT?: RefreshTokenScalarWhereWithAggregatesInput | RefreshTokenScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"RefreshToken"> | string
|
|
token?: StringWithAggregatesFilter<"RefreshToken"> | string
|
|
userId?: StringWithAggregatesFilter<"RefreshToken"> | string
|
|
expiresAt?: DateTimeWithAggregatesFilter<"RefreshToken"> | Date | string
|
|
createdAt?: DateTimeWithAggregatesFilter<"RefreshToken"> | Date | string
|
|
}
|
|
|
|
export type CategoryWhereInput = {
|
|
AND?: CategoryWhereInput | CategoryWhereInput[]
|
|
OR?: CategoryWhereInput[]
|
|
NOT?: CategoryWhereInput | CategoryWhereInput[]
|
|
id?: StringFilter<"Category"> | string
|
|
name?: StringFilter<"Category"> | string
|
|
vendorId?: StringFilter<"Category"> | string
|
|
createdAt?: DateTimeFilter<"Category"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Category"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
products?: ProductListRelationFilter
|
|
}
|
|
|
|
export type CategoryOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
vendor?: VendorOrderByWithRelationInput
|
|
products?: ProductOrderByRelationAggregateInput
|
|
}
|
|
|
|
export type CategoryWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
AND?: CategoryWhereInput | CategoryWhereInput[]
|
|
OR?: CategoryWhereInput[]
|
|
NOT?: CategoryWhereInput | CategoryWhereInput[]
|
|
name?: StringFilter<"Category"> | string
|
|
vendorId?: StringFilter<"Category"> | string
|
|
createdAt?: DateTimeFilter<"Category"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Category"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
products?: ProductListRelationFilter
|
|
}, "id">
|
|
|
|
export type CategoryOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
_count?: CategoryCountOrderByAggregateInput
|
|
_max?: CategoryMaxOrderByAggregateInput
|
|
_min?: CategoryMinOrderByAggregateInput
|
|
}
|
|
|
|
export type CategoryScalarWhereWithAggregatesInput = {
|
|
AND?: CategoryScalarWhereWithAggregatesInput | CategoryScalarWhereWithAggregatesInput[]
|
|
OR?: CategoryScalarWhereWithAggregatesInput[]
|
|
NOT?: CategoryScalarWhereWithAggregatesInput | CategoryScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"Category"> | string
|
|
name?: StringWithAggregatesFilter<"Category"> | string
|
|
vendorId?: StringWithAggregatesFilter<"Category"> | string
|
|
createdAt?: DateTimeWithAggregatesFilter<"Category"> | Date | string
|
|
updatedAt?: DateTimeWithAggregatesFilter<"Category"> | Date | string
|
|
}
|
|
|
|
export type TaxWhereInput = {
|
|
AND?: TaxWhereInput | TaxWhereInput[]
|
|
OR?: TaxWhereInput[]
|
|
NOT?: TaxWhereInput | TaxWhereInput[]
|
|
id?: StringFilter<"Tax"> | string
|
|
name?: StringFilter<"Tax"> | string
|
|
rate?: FloatFilter<"Tax"> | number
|
|
vendorId?: StringFilter<"Tax"> | string
|
|
createdAt?: DateTimeFilter<"Tax"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Tax"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
products?: ProductListRelationFilter
|
|
}
|
|
|
|
export type TaxOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
rate?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
vendor?: VendorOrderByWithRelationInput
|
|
products?: ProductOrderByRelationAggregateInput
|
|
}
|
|
|
|
export type TaxWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
AND?: TaxWhereInput | TaxWhereInput[]
|
|
OR?: TaxWhereInput[]
|
|
NOT?: TaxWhereInput | TaxWhereInput[]
|
|
name?: StringFilter<"Tax"> | string
|
|
rate?: FloatFilter<"Tax"> | number
|
|
vendorId?: StringFilter<"Tax"> | string
|
|
createdAt?: DateTimeFilter<"Tax"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Tax"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
products?: ProductListRelationFilter
|
|
}, "id">
|
|
|
|
export type TaxOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
rate?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
_count?: TaxCountOrderByAggregateInput
|
|
_avg?: TaxAvgOrderByAggregateInput
|
|
_max?: TaxMaxOrderByAggregateInput
|
|
_min?: TaxMinOrderByAggregateInput
|
|
_sum?: TaxSumOrderByAggregateInput
|
|
}
|
|
|
|
export type TaxScalarWhereWithAggregatesInput = {
|
|
AND?: TaxScalarWhereWithAggregatesInput | TaxScalarWhereWithAggregatesInput[]
|
|
OR?: TaxScalarWhereWithAggregatesInput[]
|
|
NOT?: TaxScalarWhereWithAggregatesInput | TaxScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"Tax"> | string
|
|
name?: StringWithAggregatesFilter<"Tax"> | string
|
|
rate?: FloatWithAggregatesFilter<"Tax"> | number
|
|
vendorId?: StringWithAggregatesFilter<"Tax"> | string
|
|
createdAt?: DateTimeWithAggregatesFilter<"Tax"> | Date | string
|
|
updatedAt?: DateTimeWithAggregatesFilter<"Tax"> | Date | string
|
|
}
|
|
|
|
export type ProductWhereInput = {
|
|
AND?: ProductWhereInput | ProductWhereInput[]
|
|
OR?: ProductWhereInput[]
|
|
NOT?: ProductWhereInput | ProductWhereInput[]
|
|
id?: StringFilter<"Product"> | string
|
|
name?: StringFilter<"Product"> | string
|
|
sku?: StringNullableFilter<"Product"> | string | null
|
|
description?: StringNullableFilter<"Product"> | string | null
|
|
price?: FloatFilter<"Product"> | number
|
|
vendorId?: StringFilter<"Product"> | string
|
|
categoryId?: StringNullableFilter<"Product"> | string | null
|
|
taxId?: StringNullableFilter<"Product"> | string | null
|
|
tags?: StringNullableFilter<"Product"> | string | null
|
|
version?: IntFilter<"Product"> | number
|
|
createdAt?: DateTimeFilter<"Product"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Product"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
category?: XOR<CategoryNullableRelationFilter, CategoryWhereInput> | null
|
|
tax?: XOR<TaxNullableRelationFilter, TaxWhereInput> | null
|
|
transactionItems?: TransactionItemListRelationFilter
|
|
}
|
|
|
|
export type ProductOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
sku?: SortOrderInput | SortOrder
|
|
description?: SortOrderInput | SortOrder
|
|
price?: SortOrder
|
|
vendorId?: SortOrder
|
|
categoryId?: SortOrderInput | SortOrder
|
|
taxId?: SortOrderInput | SortOrder
|
|
tags?: SortOrderInput | SortOrder
|
|
version?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
vendor?: VendorOrderByWithRelationInput
|
|
category?: CategoryOrderByWithRelationInput
|
|
tax?: TaxOrderByWithRelationInput
|
|
transactionItems?: TransactionItemOrderByRelationAggregateInput
|
|
}
|
|
|
|
export type ProductWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
AND?: ProductWhereInput | ProductWhereInput[]
|
|
OR?: ProductWhereInput[]
|
|
NOT?: ProductWhereInput | ProductWhereInput[]
|
|
name?: StringFilter<"Product"> | string
|
|
sku?: StringNullableFilter<"Product"> | string | null
|
|
description?: StringNullableFilter<"Product"> | string | null
|
|
price?: FloatFilter<"Product"> | number
|
|
vendorId?: StringFilter<"Product"> | string
|
|
categoryId?: StringNullableFilter<"Product"> | string | null
|
|
taxId?: StringNullableFilter<"Product"> | string | null
|
|
tags?: StringNullableFilter<"Product"> | string | null
|
|
version?: IntFilter<"Product"> | number
|
|
createdAt?: DateTimeFilter<"Product"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Product"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
category?: XOR<CategoryNullableRelationFilter, CategoryWhereInput> | null
|
|
tax?: XOR<TaxNullableRelationFilter, TaxWhereInput> | null
|
|
transactionItems?: TransactionItemListRelationFilter
|
|
}, "id">
|
|
|
|
export type ProductOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
sku?: SortOrderInput | SortOrder
|
|
description?: SortOrderInput | SortOrder
|
|
price?: SortOrder
|
|
vendorId?: SortOrder
|
|
categoryId?: SortOrderInput | SortOrder
|
|
taxId?: SortOrderInput | SortOrder
|
|
tags?: SortOrderInput | SortOrder
|
|
version?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
_count?: ProductCountOrderByAggregateInput
|
|
_avg?: ProductAvgOrderByAggregateInput
|
|
_max?: ProductMaxOrderByAggregateInput
|
|
_min?: ProductMinOrderByAggregateInput
|
|
_sum?: ProductSumOrderByAggregateInput
|
|
}
|
|
|
|
export type ProductScalarWhereWithAggregatesInput = {
|
|
AND?: ProductScalarWhereWithAggregatesInput | ProductScalarWhereWithAggregatesInput[]
|
|
OR?: ProductScalarWhereWithAggregatesInput[]
|
|
NOT?: ProductScalarWhereWithAggregatesInput | ProductScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"Product"> | string
|
|
name?: StringWithAggregatesFilter<"Product"> | string
|
|
sku?: StringNullableWithAggregatesFilter<"Product"> | string | null
|
|
description?: StringNullableWithAggregatesFilter<"Product"> | string | null
|
|
price?: FloatWithAggregatesFilter<"Product"> | number
|
|
vendorId?: StringWithAggregatesFilter<"Product"> | string
|
|
categoryId?: StringNullableWithAggregatesFilter<"Product"> | string | null
|
|
taxId?: StringNullableWithAggregatesFilter<"Product"> | string | null
|
|
tags?: StringNullableWithAggregatesFilter<"Product"> | string | null
|
|
version?: IntWithAggregatesFilter<"Product"> | number
|
|
createdAt?: DateTimeWithAggregatesFilter<"Product"> | Date | string
|
|
updatedAt?: DateTimeWithAggregatesFilter<"Product"> | Date | string
|
|
}
|
|
|
|
export type TransactionWhereInput = {
|
|
AND?: TransactionWhereInput | TransactionWhereInput[]
|
|
OR?: TransactionWhereInput[]
|
|
NOT?: TransactionWhereInput | TransactionWhereInput[]
|
|
id?: StringFilter<"Transaction"> | string
|
|
idempotencyKey?: StringFilter<"Transaction"> | string
|
|
vendorId?: StringFilter<"Transaction"> | string
|
|
userId?: StringFilter<"Transaction"> | string
|
|
status?: StringFilter<"Transaction"> | string
|
|
paymentMethod?: StringFilter<"Transaction"> | string
|
|
subtotal?: FloatFilter<"Transaction"> | number
|
|
taxTotal?: FloatFilter<"Transaction"> | number
|
|
discountTotal?: FloatFilter<"Transaction"> | number
|
|
total?: FloatFilter<"Transaction"> | number
|
|
notes?: StringNullableFilter<"Transaction"> | string | null
|
|
createdAt?: DateTimeFilter<"Transaction"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Transaction"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
user?: XOR<UserRelationFilter, UserWhereInput>
|
|
items?: TransactionItemListRelationFilter
|
|
}
|
|
|
|
export type TransactionOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
idempotencyKey?: SortOrder
|
|
vendorId?: SortOrder
|
|
userId?: SortOrder
|
|
status?: SortOrder
|
|
paymentMethod?: SortOrder
|
|
subtotal?: SortOrder
|
|
taxTotal?: SortOrder
|
|
discountTotal?: SortOrder
|
|
total?: SortOrder
|
|
notes?: SortOrderInput | SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
vendor?: VendorOrderByWithRelationInput
|
|
user?: UserOrderByWithRelationInput
|
|
items?: TransactionItemOrderByRelationAggregateInput
|
|
}
|
|
|
|
export type TransactionWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
idempotencyKey?: string
|
|
AND?: TransactionWhereInput | TransactionWhereInput[]
|
|
OR?: TransactionWhereInput[]
|
|
NOT?: TransactionWhereInput | TransactionWhereInput[]
|
|
vendorId?: StringFilter<"Transaction"> | string
|
|
userId?: StringFilter<"Transaction"> | string
|
|
status?: StringFilter<"Transaction"> | string
|
|
paymentMethod?: StringFilter<"Transaction"> | string
|
|
subtotal?: FloatFilter<"Transaction"> | number
|
|
taxTotal?: FloatFilter<"Transaction"> | number
|
|
discountTotal?: FloatFilter<"Transaction"> | number
|
|
total?: FloatFilter<"Transaction"> | number
|
|
notes?: StringNullableFilter<"Transaction"> | string | null
|
|
createdAt?: DateTimeFilter<"Transaction"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Transaction"> | Date | string
|
|
vendor?: XOR<VendorRelationFilter, VendorWhereInput>
|
|
user?: XOR<UserRelationFilter, UserWhereInput>
|
|
items?: TransactionItemListRelationFilter
|
|
}, "id" | "idempotencyKey">
|
|
|
|
export type TransactionOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
idempotencyKey?: SortOrder
|
|
vendorId?: SortOrder
|
|
userId?: SortOrder
|
|
status?: SortOrder
|
|
paymentMethod?: SortOrder
|
|
subtotal?: SortOrder
|
|
taxTotal?: SortOrder
|
|
discountTotal?: SortOrder
|
|
total?: SortOrder
|
|
notes?: SortOrderInput | SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
_count?: TransactionCountOrderByAggregateInput
|
|
_avg?: TransactionAvgOrderByAggregateInput
|
|
_max?: TransactionMaxOrderByAggregateInput
|
|
_min?: TransactionMinOrderByAggregateInput
|
|
_sum?: TransactionSumOrderByAggregateInput
|
|
}
|
|
|
|
export type TransactionScalarWhereWithAggregatesInput = {
|
|
AND?: TransactionScalarWhereWithAggregatesInput | TransactionScalarWhereWithAggregatesInput[]
|
|
OR?: TransactionScalarWhereWithAggregatesInput[]
|
|
NOT?: TransactionScalarWhereWithAggregatesInput | TransactionScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"Transaction"> | string
|
|
idempotencyKey?: StringWithAggregatesFilter<"Transaction"> | string
|
|
vendorId?: StringWithAggregatesFilter<"Transaction"> | string
|
|
userId?: StringWithAggregatesFilter<"Transaction"> | string
|
|
status?: StringWithAggregatesFilter<"Transaction"> | string
|
|
paymentMethod?: StringWithAggregatesFilter<"Transaction"> | string
|
|
subtotal?: FloatWithAggregatesFilter<"Transaction"> | number
|
|
taxTotal?: FloatWithAggregatesFilter<"Transaction"> | number
|
|
discountTotal?: FloatWithAggregatesFilter<"Transaction"> | number
|
|
total?: FloatWithAggregatesFilter<"Transaction"> | number
|
|
notes?: StringNullableWithAggregatesFilter<"Transaction"> | string | null
|
|
createdAt?: DateTimeWithAggregatesFilter<"Transaction"> | Date | string
|
|
updatedAt?: DateTimeWithAggregatesFilter<"Transaction"> | Date | string
|
|
}
|
|
|
|
export type TransactionItemWhereInput = {
|
|
AND?: TransactionItemWhereInput | TransactionItemWhereInput[]
|
|
OR?: TransactionItemWhereInput[]
|
|
NOT?: TransactionItemWhereInput | TransactionItemWhereInput[]
|
|
id?: StringFilter<"TransactionItem"> | string
|
|
transactionId?: StringFilter<"TransactionItem"> | string
|
|
productId?: StringFilter<"TransactionItem"> | string
|
|
productName?: StringFilter<"TransactionItem"> | string
|
|
quantity?: IntFilter<"TransactionItem"> | number
|
|
unitPrice?: FloatFilter<"TransactionItem"> | number
|
|
taxRate?: FloatFilter<"TransactionItem"> | number
|
|
discount?: FloatFilter<"TransactionItem"> | number
|
|
total?: FloatFilter<"TransactionItem"> | number
|
|
transaction?: XOR<TransactionRelationFilter, TransactionWhereInput>
|
|
product?: XOR<ProductRelationFilter, ProductWhereInput>
|
|
}
|
|
|
|
export type TransactionItemOrderByWithRelationInput = {
|
|
id?: SortOrder
|
|
transactionId?: SortOrder
|
|
productId?: SortOrder
|
|
productName?: SortOrder
|
|
quantity?: SortOrder
|
|
unitPrice?: SortOrder
|
|
taxRate?: SortOrder
|
|
discount?: SortOrder
|
|
total?: SortOrder
|
|
transaction?: TransactionOrderByWithRelationInput
|
|
product?: ProductOrderByWithRelationInput
|
|
}
|
|
|
|
export type TransactionItemWhereUniqueInput = Prisma.AtLeast<{
|
|
id?: string
|
|
AND?: TransactionItemWhereInput | TransactionItemWhereInput[]
|
|
OR?: TransactionItemWhereInput[]
|
|
NOT?: TransactionItemWhereInput | TransactionItemWhereInput[]
|
|
transactionId?: StringFilter<"TransactionItem"> | string
|
|
productId?: StringFilter<"TransactionItem"> | string
|
|
productName?: StringFilter<"TransactionItem"> | string
|
|
quantity?: IntFilter<"TransactionItem"> | number
|
|
unitPrice?: FloatFilter<"TransactionItem"> | number
|
|
taxRate?: FloatFilter<"TransactionItem"> | number
|
|
discount?: FloatFilter<"TransactionItem"> | number
|
|
total?: FloatFilter<"TransactionItem"> | number
|
|
transaction?: XOR<TransactionRelationFilter, TransactionWhereInput>
|
|
product?: XOR<ProductRelationFilter, ProductWhereInput>
|
|
}, "id">
|
|
|
|
export type TransactionItemOrderByWithAggregationInput = {
|
|
id?: SortOrder
|
|
transactionId?: SortOrder
|
|
productId?: SortOrder
|
|
productName?: SortOrder
|
|
quantity?: SortOrder
|
|
unitPrice?: SortOrder
|
|
taxRate?: SortOrder
|
|
discount?: SortOrder
|
|
total?: SortOrder
|
|
_count?: TransactionItemCountOrderByAggregateInput
|
|
_avg?: TransactionItemAvgOrderByAggregateInput
|
|
_max?: TransactionItemMaxOrderByAggregateInput
|
|
_min?: TransactionItemMinOrderByAggregateInput
|
|
_sum?: TransactionItemSumOrderByAggregateInput
|
|
}
|
|
|
|
export type TransactionItemScalarWhereWithAggregatesInput = {
|
|
AND?: TransactionItemScalarWhereWithAggregatesInput | TransactionItemScalarWhereWithAggregatesInput[]
|
|
OR?: TransactionItemScalarWhereWithAggregatesInput[]
|
|
NOT?: TransactionItemScalarWhereWithAggregatesInput | TransactionItemScalarWhereWithAggregatesInput[]
|
|
id?: StringWithAggregatesFilter<"TransactionItem"> | string
|
|
transactionId?: StringWithAggregatesFilter<"TransactionItem"> | string
|
|
productId?: StringWithAggregatesFilter<"TransactionItem"> | string
|
|
productName?: StringWithAggregatesFilter<"TransactionItem"> | string
|
|
quantity?: IntWithAggregatesFilter<"TransactionItem"> | number
|
|
unitPrice?: FloatWithAggregatesFilter<"TransactionItem"> | number
|
|
taxRate?: FloatWithAggregatesFilter<"TransactionItem"> | number
|
|
discount?: FloatWithAggregatesFilter<"TransactionItem"> | number
|
|
total?: FloatWithAggregatesFilter<"TransactionItem"> | number
|
|
}
|
|
|
|
export type VendorCreateInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserCreateNestedManyWithoutVendorInput
|
|
categories?: CategoryCreateNestedManyWithoutVendorInput
|
|
products?: ProductCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorUncheckedCreateInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserUncheckedCreateNestedManyWithoutVendorInput
|
|
categories?: CategoryUncheckedCreateNestedManyWithoutVendorInput
|
|
products?: ProductUncheckedCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxUncheckedCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUpdateManyWithoutVendorNestedInput
|
|
categories?: CategoryUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type VendorUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUncheckedUpdateManyWithoutVendorNestedInput
|
|
categories?: CategoryUncheckedUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUncheckedUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUncheckedUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUncheckedUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type VendorCreateManyInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type VendorUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type VendorUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type RoleCreateInput = {
|
|
id?: string
|
|
name: string
|
|
users?: UserCreateNestedManyWithoutRoleInput
|
|
}
|
|
|
|
export type RoleUncheckedCreateInput = {
|
|
id?: string
|
|
name: string
|
|
users?: UserUncheckedCreateNestedManyWithoutRoleInput
|
|
}
|
|
|
|
export type RoleUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
users?: UserUpdateManyWithoutRoleNestedInput
|
|
}
|
|
|
|
export type RoleUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
users?: UserUncheckedUpdateManyWithoutRoleNestedInput
|
|
}
|
|
|
|
export type RoleCreateManyInput = {
|
|
id?: string
|
|
name: string
|
|
}
|
|
|
|
export type RoleUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
}
|
|
|
|
export type RoleUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
}
|
|
|
|
export type UserCreateInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutUsersInput
|
|
role: RoleCreateNestedOneWithoutUsersInput
|
|
refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
|
|
transactions?: TransactionCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserUncheckedCreateInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
vendorId: string
|
|
roleId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutUsersNestedInput
|
|
role?: RoleUpdateOneRequiredWithoutUsersNestedInput
|
|
refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
|
|
transactions?: TransactionUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type UserUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
roleId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
|
|
transactions?: TransactionUncheckedUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type UserCreateManyInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
vendorId: string
|
|
roleId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type UserUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type UserUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
roleId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type RefreshTokenCreateInput = {
|
|
id?: string
|
|
token: string
|
|
expiresAt: Date | string
|
|
createdAt?: Date | string
|
|
user: UserCreateNestedOneWithoutRefreshTokensInput
|
|
}
|
|
|
|
export type RefreshTokenUncheckedCreateInput = {
|
|
id?: string
|
|
token: string
|
|
userId: string
|
|
expiresAt: Date | string
|
|
createdAt?: Date | string
|
|
}
|
|
|
|
export type RefreshTokenUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
token?: StringFieldUpdateOperationsInput | string
|
|
expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
user?: UserUpdateOneRequiredWithoutRefreshTokensNestedInput
|
|
}
|
|
|
|
export type RefreshTokenUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
token?: StringFieldUpdateOperationsInput | string
|
|
userId?: StringFieldUpdateOperationsInput | string
|
|
expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type RefreshTokenCreateManyInput = {
|
|
id?: string
|
|
token: string
|
|
userId: string
|
|
expiresAt: Date | string
|
|
createdAt?: Date | string
|
|
}
|
|
|
|
export type RefreshTokenUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
token?: StringFieldUpdateOperationsInput | string
|
|
expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type RefreshTokenUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
token?: StringFieldUpdateOperationsInput | string
|
|
userId?: StringFieldUpdateOperationsInput | string
|
|
expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type CategoryCreateInput = {
|
|
id?: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutCategoriesInput
|
|
products?: ProductCreateNestedManyWithoutCategoryInput
|
|
}
|
|
|
|
export type CategoryUncheckedCreateInput = {
|
|
id?: string
|
|
name: string
|
|
vendorId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
products?: ProductUncheckedCreateNestedManyWithoutCategoryInput
|
|
}
|
|
|
|
export type CategoryUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutCategoriesNestedInput
|
|
products?: ProductUpdateManyWithoutCategoryNestedInput
|
|
}
|
|
|
|
export type CategoryUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
products?: ProductUncheckedUpdateManyWithoutCategoryNestedInput
|
|
}
|
|
|
|
export type CategoryCreateManyInput = {
|
|
id?: string
|
|
name: string
|
|
vendorId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type CategoryUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type CategoryUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TaxCreateInput = {
|
|
id?: string
|
|
name: string
|
|
rate: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutTaxesInput
|
|
products?: ProductCreateNestedManyWithoutTaxInput
|
|
}
|
|
|
|
export type TaxUncheckedCreateInput = {
|
|
id?: string
|
|
name: string
|
|
rate: number
|
|
vendorId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
products?: ProductUncheckedCreateNestedManyWithoutTaxInput
|
|
}
|
|
|
|
export type TaxUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutTaxesNestedInput
|
|
products?: ProductUpdateManyWithoutTaxNestedInput
|
|
}
|
|
|
|
export type TaxUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
products?: ProductUncheckedUpdateManyWithoutTaxNestedInput
|
|
}
|
|
|
|
export type TaxCreateManyInput = {
|
|
id?: string
|
|
name: string
|
|
rate: number
|
|
vendorId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type TaxUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TaxUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type ProductCreateInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutProductsInput
|
|
category?: CategoryCreateNestedOneWithoutProductsInput
|
|
tax?: TaxCreateNestedOneWithoutProductsInput
|
|
transactionItems?: TransactionItemCreateNestedManyWithoutProductInput
|
|
}
|
|
|
|
export type ProductUncheckedCreateInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
vendorId: string
|
|
categoryId?: string | null
|
|
taxId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
transactionItems?: TransactionItemUncheckedCreateNestedManyWithoutProductInput
|
|
}
|
|
|
|
export type ProductUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutProductsNestedInput
|
|
category?: CategoryUpdateOneWithoutProductsNestedInput
|
|
tax?: TaxUpdateOneWithoutProductsNestedInput
|
|
transactionItems?: TransactionItemUpdateManyWithoutProductNestedInput
|
|
}
|
|
|
|
export type ProductUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
categoryId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
transactionItems?: TransactionItemUncheckedUpdateManyWithoutProductNestedInput
|
|
}
|
|
|
|
export type ProductCreateManyInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
vendorId: string
|
|
categoryId?: string | null
|
|
taxId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type ProductUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type ProductUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
categoryId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TransactionCreateInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutTransactionsInput
|
|
user: UserCreateNestedOneWithoutTransactionsInput
|
|
items?: TransactionItemCreateNestedManyWithoutTransactionInput
|
|
}
|
|
|
|
export type TransactionUncheckedCreateInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
vendorId: string
|
|
userId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
items?: TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
|
|
}
|
|
|
|
export type TransactionUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutTransactionsNestedInput
|
|
user?: UserUpdateOneRequiredWithoutTransactionsNestedInput
|
|
items?: TransactionItemUpdateManyWithoutTransactionNestedInput
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
userId?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
items?: TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
|
|
}
|
|
|
|
export type TransactionCreateManyInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
vendorId: string
|
|
userId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type TransactionUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
userId?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TransactionItemCreateInput = {
|
|
id?: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
transaction: TransactionCreateNestedOneWithoutItemsInput
|
|
product: ProductCreateNestedOneWithoutTransactionItemsInput
|
|
}
|
|
|
|
export type TransactionItemUncheckedCreateInput = {
|
|
id?: string
|
|
transactionId: string
|
|
productId: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
}
|
|
|
|
export type TransactionItemUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
transaction?: TransactionUpdateOneRequiredWithoutItemsNestedInput
|
|
product?: ProductUpdateOneRequiredWithoutTransactionItemsNestedInput
|
|
}
|
|
|
|
export type TransactionItemUncheckedUpdateInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
transactionId?: StringFieldUpdateOperationsInput | string
|
|
productId?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
}
|
|
|
|
export type TransactionItemCreateManyInput = {
|
|
id?: string
|
|
transactionId: string
|
|
productId: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
}
|
|
|
|
export type TransactionItemUpdateManyMutationInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
}
|
|
|
|
export type TransactionItemUncheckedUpdateManyInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
transactionId?: StringFieldUpdateOperationsInput | string
|
|
productId?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
}
|
|
|
|
export type StringFilter<$PrismaModel = never> = {
|
|
equals?: string | StringFieldRefInput<$PrismaModel>
|
|
in?: string[]
|
|
notIn?: string[]
|
|
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 StringNullableFilter<$PrismaModel = never> = {
|
|
equals?: string | StringFieldRefInput<$PrismaModel> | null
|
|
in?: string[] | null
|
|
notIn?: string[] | 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 DateTimeFilter<$PrismaModel = never> = {
|
|
equals?: Date | string | DateTimeFieldRefInput<$PrismaModel>
|
|
in?: Date[] | string[]
|
|
notIn?: Date[] | string[]
|
|
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 UserListRelationFilter = {
|
|
every?: UserWhereInput
|
|
some?: UserWhereInput
|
|
none?: UserWhereInput
|
|
}
|
|
|
|
export type CategoryListRelationFilter = {
|
|
every?: CategoryWhereInput
|
|
some?: CategoryWhereInput
|
|
none?: CategoryWhereInput
|
|
}
|
|
|
|
export type ProductListRelationFilter = {
|
|
every?: ProductWhereInput
|
|
some?: ProductWhereInput
|
|
none?: ProductWhereInput
|
|
}
|
|
|
|
export type TaxListRelationFilter = {
|
|
every?: TaxWhereInput
|
|
some?: TaxWhereInput
|
|
none?: TaxWhereInput
|
|
}
|
|
|
|
export type TransactionListRelationFilter = {
|
|
every?: TransactionWhereInput
|
|
some?: TransactionWhereInput
|
|
none?: TransactionWhereInput
|
|
}
|
|
|
|
export type SortOrderInput = {
|
|
sort: SortOrder
|
|
nulls?: NullsOrder
|
|
}
|
|
|
|
export type UserOrderByRelationAggregateInput = {
|
|
_count?: SortOrder
|
|
}
|
|
|
|
export type CategoryOrderByRelationAggregateInput = {
|
|
_count?: SortOrder
|
|
}
|
|
|
|
export type ProductOrderByRelationAggregateInput = {
|
|
_count?: SortOrder
|
|
}
|
|
|
|
export type TaxOrderByRelationAggregateInput = {
|
|
_count?: SortOrder
|
|
}
|
|
|
|
export type TransactionOrderByRelationAggregateInput = {
|
|
_count?: SortOrder
|
|
}
|
|
|
|
export type VendorCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
businessNum?: SortOrder
|
|
taxSettings?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type VendorMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
businessNum?: SortOrder
|
|
taxSettings?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type VendorMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
businessNum?: SortOrder
|
|
taxSettings?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type StringWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: string | StringFieldRefInput<$PrismaModel>
|
|
in?: string[]
|
|
notIn?: string[]
|
|
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 StringNullableWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: string | StringFieldRefInput<$PrismaModel> | null
|
|
in?: string[] | null
|
|
notIn?: string[] | 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 DateTimeWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: Date | string | DateTimeFieldRefInput<$PrismaModel>
|
|
in?: Date[] | string[]
|
|
notIn?: Date[] | string[]
|
|
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 RoleCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
}
|
|
|
|
export type RoleMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
}
|
|
|
|
export type RoleMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
}
|
|
|
|
export type VendorRelationFilter = {
|
|
is?: VendorWhereInput
|
|
isNot?: VendorWhereInput
|
|
}
|
|
|
|
export type RoleRelationFilter = {
|
|
is?: RoleWhereInput
|
|
isNot?: RoleWhereInput
|
|
}
|
|
|
|
export type RefreshTokenListRelationFilter = {
|
|
every?: RefreshTokenWhereInput
|
|
some?: RefreshTokenWhereInput
|
|
none?: RefreshTokenWhereInput
|
|
}
|
|
|
|
export type RefreshTokenOrderByRelationAggregateInput = {
|
|
_count?: SortOrder
|
|
}
|
|
|
|
export type UserCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
email?: SortOrder
|
|
passwordHash?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
roleId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type UserMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
email?: SortOrder
|
|
passwordHash?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
roleId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type UserMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
email?: SortOrder
|
|
passwordHash?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
roleId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type UserRelationFilter = {
|
|
is?: UserWhereInput
|
|
isNot?: UserWhereInput
|
|
}
|
|
|
|
export type RefreshTokenCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
token?: SortOrder
|
|
userId?: SortOrder
|
|
expiresAt?: SortOrder
|
|
createdAt?: SortOrder
|
|
}
|
|
|
|
export type RefreshTokenMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
token?: SortOrder
|
|
userId?: SortOrder
|
|
expiresAt?: SortOrder
|
|
createdAt?: SortOrder
|
|
}
|
|
|
|
export type RefreshTokenMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
token?: SortOrder
|
|
userId?: SortOrder
|
|
expiresAt?: SortOrder
|
|
createdAt?: SortOrder
|
|
}
|
|
|
|
export type CategoryCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type CategoryMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type CategoryMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type FloatFilter<$PrismaModel = never> = {
|
|
equals?: number | FloatFieldRefInput<$PrismaModel>
|
|
in?: number[]
|
|
notIn?: number[]
|
|
lt?: number | FloatFieldRefInput<$PrismaModel>
|
|
lte?: number | FloatFieldRefInput<$PrismaModel>
|
|
gt?: number | FloatFieldRefInput<$PrismaModel>
|
|
gte?: number | FloatFieldRefInput<$PrismaModel>
|
|
not?: NestedFloatFilter<$PrismaModel> | number
|
|
}
|
|
|
|
export type TaxCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
rate?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type TaxAvgOrderByAggregateInput = {
|
|
rate?: SortOrder
|
|
}
|
|
|
|
export type TaxMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
rate?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type TaxMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
rate?: SortOrder
|
|
vendorId?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type TaxSumOrderByAggregateInput = {
|
|
rate?: SortOrder
|
|
}
|
|
|
|
export type FloatWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: number | FloatFieldRefInput<$PrismaModel>
|
|
in?: number[]
|
|
notIn?: number[]
|
|
lt?: number | FloatFieldRefInput<$PrismaModel>
|
|
lte?: number | FloatFieldRefInput<$PrismaModel>
|
|
gt?: number | FloatFieldRefInput<$PrismaModel>
|
|
gte?: number | FloatFieldRefInput<$PrismaModel>
|
|
not?: NestedFloatWithAggregatesFilter<$PrismaModel> | number
|
|
_count?: NestedIntFilter<$PrismaModel>
|
|
_avg?: NestedFloatFilter<$PrismaModel>
|
|
_sum?: NestedFloatFilter<$PrismaModel>
|
|
_min?: NestedFloatFilter<$PrismaModel>
|
|
_max?: NestedFloatFilter<$PrismaModel>
|
|
}
|
|
|
|
export type IntFilter<$PrismaModel = never> = {
|
|
equals?: number | IntFieldRefInput<$PrismaModel>
|
|
in?: number[]
|
|
notIn?: number[]
|
|
lt?: number | IntFieldRefInput<$PrismaModel>
|
|
lte?: number | IntFieldRefInput<$PrismaModel>
|
|
gt?: number | IntFieldRefInput<$PrismaModel>
|
|
gte?: number | IntFieldRefInput<$PrismaModel>
|
|
not?: NestedIntFilter<$PrismaModel> | number
|
|
}
|
|
|
|
export type CategoryNullableRelationFilter = {
|
|
is?: CategoryWhereInput | null
|
|
isNot?: CategoryWhereInput | null
|
|
}
|
|
|
|
export type TaxNullableRelationFilter = {
|
|
is?: TaxWhereInput | null
|
|
isNot?: TaxWhereInput | null
|
|
}
|
|
|
|
export type TransactionItemListRelationFilter = {
|
|
every?: TransactionItemWhereInput
|
|
some?: TransactionItemWhereInput
|
|
none?: TransactionItemWhereInput
|
|
}
|
|
|
|
export type TransactionItemOrderByRelationAggregateInput = {
|
|
_count?: SortOrder
|
|
}
|
|
|
|
export type ProductCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
sku?: SortOrder
|
|
description?: SortOrder
|
|
price?: SortOrder
|
|
vendorId?: SortOrder
|
|
categoryId?: SortOrder
|
|
taxId?: SortOrder
|
|
tags?: SortOrder
|
|
version?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type ProductAvgOrderByAggregateInput = {
|
|
price?: SortOrder
|
|
version?: SortOrder
|
|
}
|
|
|
|
export type ProductMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
sku?: SortOrder
|
|
description?: SortOrder
|
|
price?: SortOrder
|
|
vendorId?: SortOrder
|
|
categoryId?: SortOrder
|
|
taxId?: SortOrder
|
|
tags?: SortOrder
|
|
version?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type ProductMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
name?: SortOrder
|
|
sku?: SortOrder
|
|
description?: SortOrder
|
|
price?: SortOrder
|
|
vendorId?: SortOrder
|
|
categoryId?: SortOrder
|
|
taxId?: SortOrder
|
|
tags?: SortOrder
|
|
version?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type ProductSumOrderByAggregateInput = {
|
|
price?: SortOrder
|
|
version?: SortOrder
|
|
}
|
|
|
|
export type IntWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: number | IntFieldRefInput<$PrismaModel>
|
|
in?: number[]
|
|
notIn?: number[]
|
|
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 TransactionCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
idempotencyKey?: SortOrder
|
|
vendorId?: SortOrder
|
|
userId?: SortOrder
|
|
status?: SortOrder
|
|
paymentMethod?: SortOrder
|
|
subtotal?: SortOrder
|
|
taxTotal?: SortOrder
|
|
discountTotal?: SortOrder
|
|
total?: SortOrder
|
|
notes?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type TransactionAvgOrderByAggregateInput = {
|
|
subtotal?: SortOrder
|
|
taxTotal?: SortOrder
|
|
discountTotal?: SortOrder
|
|
total?: SortOrder
|
|
}
|
|
|
|
export type TransactionMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
idempotencyKey?: SortOrder
|
|
vendorId?: SortOrder
|
|
userId?: SortOrder
|
|
status?: SortOrder
|
|
paymentMethod?: SortOrder
|
|
subtotal?: SortOrder
|
|
taxTotal?: SortOrder
|
|
discountTotal?: SortOrder
|
|
total?: SortOrder
|
|
notes?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type TransactionMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
idempotencyKey?: SortOrder
|
|
vendorId?: SortOrder
|
|
userId?: SortOrder
|
|
status?: SortOrder
|
|
paymentMethod?: SortOrder
|
|
subtotal?: SortOrder
|
|
taxTotal?: SortOrder
|
|
discountTotal?: SortOrder
|
|
total?: SortOrder
|
|
notes?: SortOrder
|
|
createdAt?: SortOrder
|
|
updatedAt?: SortOrder
|
|
}
|
|
|
|
export type TransactionSumOrderByAggregateInput = {
|
|
subtotal?: SortOrder
|
|
taxTotal?: SortOrder
|
|
discountTotal?: SortOrder
|
|
total?: SortOrder
|
|
}
|
|
|
|
export type TransactionRelationFilter = {
|
|
is?: TransactionWhereInput
|
|
isNot?: TransactionWhereInput
|
|
}
|
|
|
|
export type ProductRelationFilter = {
|
|
is?: ProductWhereInput
|
|
isNot?: ProductWhereInput
|
|
}
|
|
|
|
export type TransactionItemCountOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
transactionId?: SortOrder
|
|
productId?: SortOrder
|
|
productName?: SortOrder
|
|
quantity?: SortOrder
|
|
unitPrice?: SortOrder
|
|
taxRate?: SortOrder
|
|
discount?: SortOrder
|
|
total?: SortOrder
|
|
}
|
|
|
|
export type TransactionItemAvgOrderByAggregateInput = {
|
|
quantity?: SortOrder
|
|
unitPrice?: SortOrder
|
|
taxRate?: SortOrder
|
|
discount?: SortOrder
|
|
total?: SortOrder
|
|
}
|
|
|
|
export type TransactionItemMaxOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
transactionId?: SortOrder
|
|
productId?: SortOrder
|
|
productName?: SortOrder
|
|
quantity?: SortOrder
|
|
unitPrice?: SortOrder
|
|
taxRate?: SortOrder
|
|
discount?: SortOrder
|
|
total?: SortOrder
|
|
}
|
|
|
|
export type TransactionItemMinOrderByAggregateInput = {
|
|
id?: SortOrder
|
|
transactionId?: SortOrder
|
|
productId?: SortOrder
|
|
productName?: SortOrder
|
|
quantity?: SortOrder
|
|
unitPrice?: SortOrder
|
|
taxRate?: SortOrder
|
|
discount?: SortOrder
|
|
total?: SortOrder
|
|
}
|
|
|
|
export type TransactionItemSumOrderByAggregateInput = {
|
|
quantity?: SortOrder
|
|
unitPrice?: SortOrder
|
|
taxRate?: SortOrder
|
|
discount?: SortOrder
|
|
total?: SortOrder
|
|
}
|
|
|
|
export type UserCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<UserCreateWithoutVendorInput, UserUncheckedCreateWithoutVendorInput> | UserCreateWithoutVendorInput[] | UserUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: UserCreateOrConnectWithoutVendorInput | UserCreateOrConnectWithoutVendorInput[]
|
|
createMany?: UserCreateManyVendorInputEnvelope
|
|
connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
}
|
|
|
|
export type CategoryCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<CategoryCreateWithoutVendorInput, CategoryUncheckedCreateWithoutVendorInput> | CategoryCreateWithoutVendorInput[] | CategoryUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: CategoryCreateOrConnectWithoutVendorInput | CategoryCreateOrConnectWithoutVendorInput[]
|
|
createMany?: CategoryCreateManyVendorInputEnvelope
|
|
connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
}
|
|
|
|
export type ProductCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<ProductCreateWithoutVendorInput, ProductUncheckedCreateWithoutVendorInput> | ProductCreateWithoutVendorInput[] | ProductUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutVendorInput | ProductCreateOrConnectWithoutVendorInput[]
|
|
createMany?: ProductCreateManyVendorInputEnvelope
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
}
|
|
|
|
export type TaxCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<TaxCreateWithoutVendorInput, TaxUncheckedCreateWithoutVendorInput> | TaxCreateWithoutVendorInput[] | TaxUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: TaxCreateOrConnectWithoutVendorInput | TaxCreateOrConnectWithoutVendorInput[]
|
|
createMany?: TaxCreateManyVendorInputEnvelope
|
|
connect?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
}
|
|
|
|
export type TransactionCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<TransactionCreateWithoutVendorInput, TransactionUncheckedCreateWithoutVendorInput> | TransactionCreateWithoutVendorInput[] | TransactionUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutVendorInput | TransactionCreateOrConnectWithoutVendorInput[]
|
|
createMany?: TransactionCreateManyVendorInputEnvelope
|
|
connect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
}
|
|
|
|
export type UserUncheckedCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<UserCreateWithoutVendorInput, UserUncheckedCreateWithoutVendorInput> | UserCreateWithoutVendorInput[] | UserUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: UserCreateOrConnectWithoutVendorInput | UserCreateOrConnectWithoutVendorInput[]
|
|
createMany?: UserCreateManyVendorInputEnvelope
|
|
connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
}
|
|
|
|
export type CategoryUncheckedCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<CategoryCreateWithoutVendorInput, CategoryUncheckedCreateWithoutVendorInput> | CategoryCreateWithoutVendorInput[] | CategoryUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: CategoryCreateOrConnectWithoutVendorInput | CategoryCreateOrConnectWithoutVendorInput[]
|
|
createMany?: CategoryCreateManyVendorInputEnvelope
|
|
connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
}
|
|
|
|
export type ProductUncheckedCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<ProductCreateWithoutVendorInput, ProductUncheckedCreateWithoutVendorInput> | ProductCreateWithoutVendorInput[] | ProductUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutVendorInput | ProductCreateOrConnectWithoutVendorInput[]
|
|
createMany?: ProductCreateManyVendorInputEnvelope
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
}
|
|
|
|
export type TaxUncheckedCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<TaxCreateWithoutVendorInput, TaxUncheckedCreateWithoutVendorInput> | TaxCreateWithoutVendorInput[] | TaxUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: TaxCreateOrConnectWithoutVendorInput | TaxCreateOrConnectWithoutVendorInput[]
|
|
createMany?: TaxCreateManyVendorInputEnvelope
|
|
connect?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
}
|
|
|
|
export type TransactionUncheckedCreateNestedManyWithoutVendorInput = {
|
|
create?: XOR<TransactionCreateWithoutVendorInput, TransactionUncheckedCreateWithoutVendorInput> | TransactionCreateWithoutVendorInput[] | TransactionUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutVendorInput | TransactionCreateOrConnectWithoutVendorInput[]
|
|
createMany?: TransactionCreateManyVendorInputEnvelope
|
|
connect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
}
|
|
|
|
export type StringFieldUpdateOperationsInput = {
|
|
set?: string
|
|
}
|
|
|
|
export type NullableStringFieldUpdateOperationsInput = {
|
|
set?: string | null
|
|
}
|
|
|
|
export type DateTimeFieldUpdateOperationsInput = {
|
|
set?: Date | string
|
|
}
|
|
|
|
export type UserUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<UserCreateWithoutVendorInput, UserUncheckedCreateWithoutVendorInput> | UserCreateWithoutVendorInput[] | UserUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: UserCreateOrConnectWithoutVendorInput | UserCreateOrConnectWithoutVendorInput[]
|
|
upsert?: UserUpsertWithWhereUniqueWithoutVendorInput | UserUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: UserCreateManyVendorInputEnvelope
|
|
set?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
disconnect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
delete?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
update?: UserUpdateWithWhereUniqueWithoutVendorInput | UserUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: UserUpdateManyWithWhereWithoutVendorInput | UserUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: UserScalarWhereInput | UserScalarWhereInput[]
|
|
}
|
|
|
|
export type CategoryUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<CategoryCreateWithoutVendorInput, CategoryUncheckedCreateWithoutVendorInput> | CategoryCreateWithoutVendorInput[] | CategoryUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: CategoryCreateOrConnectWithoutVendorInput | CategoryCreateOrConnectWithoutVendorInput[]
|
|
upsert?: CategoryUpsertWithWhereUniqueWithoutVendorInput | CategoryUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: CategoryCreateManyVendorInputEnvelope
|
|
set?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
disconnect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
delete?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
update?: CategoryUpdateWithWhereUniqueWithoutVendorInput | CategoryUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: CategoryUpdateManyWithWhereWithoutVendorInput | CategoryUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: CategoryScalarWhereInput | CategoryScalarWhereInput[]
|
|
}
|
|
|
|
export type ProductUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<ProductCreateWithoutVendorInput, ProductUncheckedCreateWithoutVendorInput> | ProductCreateWithoutVendorInput[] | ProductUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutVendorInput | ProductCreateOrConnectWithoutVendorInput[]
|
|
upsert?: ProductUpsertWithWhereUniqueWithoutVendorInput | ProductUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: ProductCreateManyVendorInputEnvelope
|
|
set?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
disconnect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
delete?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
update?: ProductUpdateWithWhereUniqueWithoutVendorInput | ProductUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: ProductUpdateManyWithWhereWithoutVendorInput | ProductUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: ProductScalarWhereInput | ProductScalarWhereInput[]
|
|
}
|
|
|
|
export type TaxUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<TaxCreateWithoutVendorInput, TaxUncheckedCreateWithoutVendorInput> | TaxCreateWithoutVendorInput[] | TaxUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: TaxCreateOrConnectWithoutVendorInput | TaxCreateOrConnectWithoutVendorInput[]
|
|
upsert?: TaxUpsertWithWhereUniqueWithoutVendorInput | TaxUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: TaxCreateManyVendorInputEnvelope
|
|
set?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
disconnect?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
delete?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
connect?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
update?: TaxUpdateWithWhereUniqueWithoutVendorInput | TaxUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: TaxUpdateManyWithWhereWithoutVendorInput | TaxUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: TaxScalarWhereInput | TaxScalarWhereInput[]
|
|
}
|
|
|
|
export type TransactionUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<TransactionCreateWithoutVendorInput, TransactionUncheckedCreateWithoutVendorInput> | TransactionCreateWithoutVendorInput[] | TransactionUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutVendorInput | TransactionCreateOrConnectWithoutVendorInput[]
|
|
upsert?: TransactionUpsertWithWhereUniqueWithoutVendorInput | TransactionUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: TransactionCreateManyVendorInputEnvelope
|
|
set?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
disconnect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
delete?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
connect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
update?: TransactionUpdateWithWhereUniqueWithoutVendorInput | TransactionUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: TransactionUpdateManyWithWhereWithoutVendorInput | TransactionUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: TransactionScalarWhereInput | TransactionScalarWhereInput[]
|
|
}
|
|
|
|
export type UserUncheckedUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<UserCreateWithoutVendorInput, UserUncheckedCreateWithoutVendorInput> | UserCreateWithoutVendorInput[] | UserUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: UserCreateOrConnectWithoutVendorInput | UserCreateOrConnectWithoutVendorInput[]
|
|
upsert?: UserUpsertWithWhereUniqueWithoutVendorInput | UserUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: UserCreateManyVendorInputEnvelope
|
|
set?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
disconnect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
delete?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
update?: UserUpdateWithWhereUniqueWithoutVendorInput | UserUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: UserUpdateManyWithWhereWithoutVendorInput | UserUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: UserScalarWhereInput | UserScalarWhereInput[]
|
|
}
|
|
|
|
export type CategoryUncheckedUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<CategoryCreateWithoutVendorInput, CategoryUncheckedCreateWithoutVendorInput> | CategoryCreateWithoutVendorInput[] | CategoryUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: CategoryCreateOrConnectWithoutVendorInput | CategoryCreateOrConnectWithoutVendorInput[]
|
|
upsert?: CategoryUpsertWithWhereUniqueWithoutVendorInput | CategoryUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: CategoryCreateManyVendorInputEnvelope
|
|
set?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
disconnect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
delete?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
connect?: CategoryWhereUniqueInput | CategoryWhereUniqueInput[]
|
|
update?: CategoryUpdateWithWhereUniqueWithoutVendorInput | CategoryUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: CategoryUpdateManyWithWhereWithoutVendorInput | CategoryUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: CategoryScalarWhereInput | CategoryScalarWhereInput[]
|
|
}
|
|
|
|
export type ProductUncheckedUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<ProductCreateWithoutVendorInput, ProductUncheckedCreateWithoutVendorInput> | ProductCreateWithoutVendorInput[] | ProductUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutVendorInput | ProductCreateOrConnectWithoutVendorInput[]
|
|
upsert?: ProductUpsertWithWhereUniqueWithoutVendorInput | ProductUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: ProductCreateManyVendorInputEnvelope
|
|
set?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
disconnect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
delete?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
update?: ProductUpdateWithWhereUniqueWithoutVendorInput | ProductUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: ProductUpdateManyWithWhereWithoutVendorInput | ProductUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: ProductScalarWhereInput | ProductScalarWhereInput[]
|
|
}
|
|
|
|
export type TaxUncheckedUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<TaxCreateWithoutVendorInput, TaxUncheckedCreateWithoutVendorInput> | TaxCreateWithoutVendorInput[] | TaxUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: TaxCreateOrConnectWithoutVendorInput | TaxCreateOrConnectWithoutVendorInput[]
|
|
upsert?: TaxUpsertWithWhereUniqueWithoutVendorInput | TaxUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: TaxCreateManyVendorInputEnvelope
|
|
set?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
disconnect?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
delete?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
connect?: TaxWhereUniqueInput | TaxWhereUniqueInput[]
|
|
update?: TaxUpdateWithWhereUniqueWithoutVendorInput | TaxUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: TaxUpdateManyWithWhereWithoutVendorInput | TaxUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: TaxScalarWhereInput | TaxScalarWhereInput[]
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateManyWithoutVendorNestedInput = {
|
|
create?: XOR<TransactionCreateWithoutVendorInput, TransactionUncheckedCreateWithoutVendorInput> | TransactionCreateWithoutVendorInput[] | TransactionUncheckedCreateWithoutVendorInput[]
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutVendorInput | TransactionCreateOrConnectWithoutVendorInput[]
|
|
upsert?: TransactionUpsertWithWhereUniqueWithoutVendorInput | TransactionUpsertWithWhereUniqueWithoutVendorInput[]
|
|
createMany?: TransactionCreateManyVendorInputEnvelope
|
|
set?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
disconnect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
delete?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
connect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
update?: TransactionUpdateWithWhereUniqueWithoutVendorInput | TransactionUpdateWithWhereUniqueWithoutVendorInput[]
|
|
updateMany?: TransactionUpdateManyWithWhereWithoutVendorInput | TransactionUpdateManyWithWhereWithoutVendorInput[]
|
|
deleteMany?: TransactionScalarWhereInput | TransactionScalarWhereInput[]
|
|
}
|
|
|
|
export type UserCreateNestedManyWithoutRoleInput = {
|
|
create?: XOR<UserCreateWithoutRoleInput, UserUncheckedCreateWithoutRoleInput> | UserCreateWithoutRoleInput[] | UserUncheckedCreateWithoutRoleInput[]
|
|
connectOrCreate?: UserCreateOrConnectWithoutRoleInput | UserCreateOrConnectWithoutRoleInput[]
|
|
createMany?: UserCreateManyRoleInputEnvelope
|
|
connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
}
|
|
|
|
export type UserUncheckedCreateNestedManyWithoutRoleInput = {
|
|
create?: XOR<UserCreateWithoutRoleInput, UserUncheckedCreateWithoutRoleInput> | UserCreateWithoutRoleInput[] | UserUncheckedCreateWithoutRoleInput[]
|
|
connectOrCreate?: UserCreateOrConnectWithoutRoleInput | UserCreateOrConnectWithoutRoleInput[]
|
|
createMany?: UserCreateManyRoleInputEnvelope
|
|
connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
}
|
|
|
|
export type UserUpdateManyWithoutRoleNestedInput = {
|
|
create?: XOR<UserCreateWithoutRoleInput, UserUncheckedCreateWithoutRoleInput> | UserCreateWithoutRoleInput[] | UserUncheckedCreateWithoutRoleInput[]
|
|
connectOrCreate?: UserCreateOrConnectWithoutRoleInput | UserCreateOrConnectWithoutRoleInput[]
|
|
upsert?: UserUpsertWithWhereUniqueWithoutRoleInput | UserUpsertWithWhereUniqueWithoutRoleInput[]
|
|
createMany?: UserCreateManyRoleInputEnvelope
|
|
set?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
disconnect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
delete?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
update?: UserUpdateWithWhereUniqueWithoutRoleInput | UserUpdateWithWhereUniqueWithoutRoleInput[]
|
|
updateMany?: UserUpdateManyWithWhereWithoutRoleInput | UserUpdateManyWithWhereWithoutRoleInput[]
|
|
deleteMany?: UserScalarWhereInput | UserScalarWhereInput[]
|
|
}
|
|
|
|
export type UserUncheckedUpdateManyWithoutRoleNestedInput = {
|
|
create?: XOR<UserCreateWithoutRoleInput, UserUncheckedCreateWithoutRoleInput> | UserCreateWithoutRoleInput[] | UserUncheckedCreateWithoutRoleInput[]
|
|
connectOrCreate?: UserCreateOrConnectWithoutRoleInput | UserCreateOrConnectWithoutRoleInput[]
|
|
upsert?: UserUpsertWithWhereUniqueWithoutRoleInput | UserUpsertWithWhereUniqueWithoutRoleInput[]
|
|
createMany?: UserCreateManyRoleInputEnvelope
|
|
set?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
disconnect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
delete?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
|
|
update?: UserUpdateWithWhereUniqueWithoutRoleInput | UserUpdateWithWhereUniqueWithoutRoleInput[]
|
|
updateMany?: UserUpdateManyWithWhereWithoutRoleInput | UserUpdateManyWithWhereWithoutRoleInput[]
|
|
deleteMany?: UserScalarWhereInput | UserScalarWhereInput[]
|
|
}
|
|
|
|
export type VendorCreateNestedOneWithoutUsersInput = {
|
|
create?: XOR<VendorCreateWithoutUsersInput, VendorUncheckedCreateWithoutUsersInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutUsersInput
|
|
connect?: VendorWhereUniqueInput
|
|
}
|
|
|
|
export type RoleCreateNestedOneWithoutUsersInput = {
|
|
create?: XOR<RoleCreateWithoutUsersInput, RoleUncheckedCreateWithoutUsersInput>
|
|
connectOrCreate?: RoleCreateOrConnectWithoutUsersInput
|
|
connect?: RoleWhereUniqueInput
|
|
}
|
|
|
|
export type RefreshTokenCreateNestedManyWithoutUserInput = {
|
|
create?: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput> | RefreshTokenCreateWithoutUserInput[] | RefreshTokenUncheckedCreateWithoutUserInput[]
|
|
connectOrCreate?: RefreshTokenCreateOrConnectWithoutUserInput | RefreshTokenCreateOrConnectWithoutUserInput[]
|
|
createMany?: RefreshTokenCreateManyUserInputEnvelope
|
|
connect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
}
|
|
|
|
export type TransactionCreateNestedManyWithoutUserInput = {
|
|
create?: XOR<TransactionCreateWithoutUserInput, TransactionUncheckedCreateWithoutUserInput> | TransactionCreateWithoutUserInput[] | TransactionUncheckedCreateWithoutUserInput[]
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutUserInput | TransactionCreateOrConnectWithoutUserInput[]
|
|
createMany?: TransactionCreateManyUserInputEnvelope
|
|
connect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
}
|
|
|
|
export type RefreshTokenUncheckedCreateNestedManyWithoutUserInput = {
|
|
create?: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput> | RefreshTokenCreateWithoutUserInput[] | RefreshTokenUncheckedCreateWithoutUserInput[]
|
|
connectOrCreate?: RefreshTokenCreateOrConnectWithoutUserInput | RefreshTokenCreateOrConnectWithoutUserInput[]
|
|
createMany?: RefreshTokenCreateManyUserInputEnvelope
|
|
connect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
}
|
|
|
|
export type TransactionUncheckedCreateNestedManyWithoutUserInput = {
|
|
create?: XOR<TransactionCreateWithoutUserInput, TransactionUncheckedCreateWithoutUserInput> | TransactionCreateWithoutUserInput[] | TransactionUncheckedCreateWithoutUserInput[]
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutUserInput | TransactionCreateOrConnectWithoutUserInput[]
|
|
createMany?: TransactionCreateManyUserInputEnvelope
|
|
connect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
}
|
|
|
|
export type VendorUpdateOneRequiredWithoutUsersNestedInput = {
|
|
create?: XOR<VendorCreateWithoutUsersInput, VendorUncheckedCreateWithoutUsersInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutUsersInput
|
|
upsert?: VendorUpsertWithoutUsersInput
|
|
connect?: VendorWhereUniqueInput
|
|
update?: XOR<XOR<VendorUpdateToOneWithWhereWithoutUsersInput, VendorUpdateWithoutUsersInput>, VendorUncheckedUpdateWithoutUsersInput>
|
|
}
|
|
|
|
export type RoleUpdateOneRequiredWithoutUsersNestedInput = {
|
|
create?: XOR<RoleCreateWithoutUsersInput, RoleUncheckedCreateWithoutUsersInput>
|
|
connectOrCreate?: RoleCreateOrConnectWithoutUsersInput
|
|
upsert?: RoleUpsertWithoutUsersInput
|
|
connect?: RoleWhereUniqueInput
|
|
update?: XOR<XOR<RoleUpdateToOneWithWhereWithoutUsersInput, RoleUpdateWithoutUsersInput>, RoleUncheckedUpdateWithoutUsersInput>
|
|
}
|
|
|
|
export type RefreshTokenUpdateManyWithoutUserNestedInput = {
|
|
create?: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput> | RefreshTokenCreateWithoutUserInput[] | RefreshTokenUncheckedCreateWithoutUserInput[]
|
|
connectOrCreate?: RefreshTokenCreateOrConnectWithoutUserInput | RefreshTokenCreateOrConnectWithoutUserInput[]
|
|
upsert?: RefreshTokenUpsertWithWhereUniqueWithoutUserInput | RefreshTokenUpsertWithWhereUniqueWithoutUserInput[]
|
|
createMany?: RefreshTokenCreateManyUserInputEnvelope
|
|
set?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
disconnect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
delete?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
connect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
update?: RefreshTokenUpdateWithWhereUniqueWithoutUserInput | RefreshTokenUpdateWithWhereUniqueWithoutUserInput[]
|
|
updateMany?: RefreshTokenUpdateManyWithWhereWithoutUserInput | RefreshTokenUpdateManyWithWhereWithoutUserInput[]
|
|
deleteMany?: RefreshTokenScalarWhereInput | RefreshTokenScalarWhereInput[]
|
|
}
|
|
|
|
export type TransactionUpdateManyWithoutUserNestedInput = {
|
|
create?: XOR<TransactionCreateWithoutUserInput, TransactionUncheckedCreateWithoutUserInput> | TransactionCreateWithoutUserInput[] | TransactionUncheckedCreateWithoutUserInput[]
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutUserInput | TransactionCreateOrConnectWithoutUserInput[]
|
|
upsert?: TransactionUpsertWithWhereUniqueWithoutUserInput | TransactionUpsertWithWhereUniqueWithoutUserInput[]
|
|
createMany?: TransactionCreateManyUserInputEnvelope
|
|
set?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
disconnect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
delete?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
connect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
update?: TransactionUpdateWithWhereUniqueWithoutUserInput | TransactionUpdateWithWhereUniqueWithoutUserInput[]
|
|
updateMany?: TransactionUpdateManyWithWhereWithoutUserInput | TransactionUpdateManyWithWhereWithoutUserInput[]
|
|
deleteMany?: TransactionScalarWhereInput | TransactionScalarWhereInput[]
|
|
}
|
|
|
|
export type RefreshTokenUncheckedUpdateManyWithoutUserNestedInput = {
|
|
create?: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput> | RefreshTokenCreateWithoutUserInput[] | RefreshTokenUncheckedCreateWithoutUserInput[]
|
|
connectOrCreate?: RefreshTokenCreateOrConnectWithoutUserInput | RefreshTokenCreateOrConnectWithoutUserInput[]
|
|
upsert?: RefreshTokenUpsertWithWhereUniqueWithoutUserInput | RefreshTokenUpsertWithWhereUniqueWithoutUserInput[]
|
|
createMany?: RefreshTokenCreateManyUserInputEnvelope
|
|
set?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
disconnect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
delete?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
connect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
|
|
update?: RefreshTokenUpdateWithWhereUniqueWithoutUserInput | RefreshTokenUpdateWithWhereUniqueWithoutUserInput[]
|
|
updateMany?: RefreshTokenUpdateManyWithWhereWithoutUserInput | RefreshTokenUpdateManyWithWhereWithoutUserInput[]
|
|
deleteMany?: RefreshTokenScalarWhereInput | RefreshTokenScalarWhereInput[]
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateManyWithoutUserNestedInput = {
|
|
create?: XOR<TransactionCreateWithoutUserInput, TransactionUncheckedCreateWithoutUserInput> | TransactionCreateWithoutUserInput[] | TransactionUncheckedCreateWithoutUserInput[]
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutUserInput | TransactionCreateOrConnectWithoutUserInput[]
|
|
upsert?: TransactionUpsertWithWhereUniqueWithoutUserInput | TransactionUpsertWithWhereUniqueWithoutUserInput[]
|
|
createMany?: TransactionCreateManyUserInputEnvelope
|
|
set?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
disconnect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
delete?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
connect?: TransactionWhereUniqueInput | TransactionWhereUniqueInput[]
|
|
update?: TransactionUpdateWithWhereUniqueWithoutUserInput | TransactionUpdateWithWhereUniqueWithoutUserInput[]
|
|
updateMany?: TransactionUpdateManyWithWhereWithoutUserInput | TransactionUpdateManyWithWhereWithoutUserInput[]
|
|
deleteMany?: TransactionScalarWhereInput | TransactionScalarWhereInput[]
|
|
}
|
|
|
|
export type UserCreateNestedOneWithoutRefreshTokensInput = {
|
|
create?: XOR<UserCreateWithoutRefreshTokensInput, UserUncheckedCreateWithoutRefreshTokensInput>
|
|
connectOrCreate?: UserCreateOrConnectWithoutRefreshTokensInput
|
|
connect?: UserWhereUniqueInput
|
|
}
|
|
|
|
export type UserUpdateOneRequiredWithoutRefreshTokensNestedInput = {
|
|
create?: XOR<UserCreateWithoutRefreshTokensInput, UserUncheckedCreateWithoutRefreshTokensInput>
|
|
connectOrCreate?: UserCreateOrConnectWithoutRefreshTokensInput
|
|
upsert?: UserUpsertWithoutRefreshTokensInput
|
|
connect?: UserWhereUniqueInput
|
|
update?: XOR<XOR<UserUpdateToOneWithWhereWithoutRefreshTokensInput, UserUpdateWithoutRefreshTokensInput>, UserUncheckedUpdateWithoutRefreshTokensInput>
|
|
}
|
|
|
|
export type VendorCreateNestedOneWithoutCategoriesInput = {
|
|
create?: XOR<VendorCreateWithoutCategoriesInput, VendorUncheckedCreateWithoutCategoriesInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutCategoriesInput
|
|
connect?: VendorWhereUniqueInput
|
|
}
|
|
|
|
export type ProductCreateNestedManyWithoutCategoryInput = {
|
|
create?: XOR<ProductCreateWithoutCategoryInput, ProductUncheckedCreateWithoutCategoryInput> | ProductCreateWithoutCategoryInput[] | ProductUncheckedCreateWithoutCategoryInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutCategoryInput | ProductCreateOrConnectWithoutCategoryInput[]
|
|
createMany?: ProductCreateManyCategoryInputEnvelope
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
}
|
|
|
|
export type ProductUncheckedCreateNestedManyWithoutCategoryInput = {
|
|
create?: XOR<ProductCreateWithoutCategoryInput, ProductUncheckedCreateWithoutCategoryInput> | ProductCreateWithoutCategoryInput[] | ProductUncheckedCreateWithoutCategoryInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutCategoryInput | ProductCreateOrConnectWithoutCategoryInput[]
|
|
createMany?: ProductCreateManyCategoryInputEnvelope
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
}
|
|
|
|
export type VendorUpdateOneRequiredWithoutCategoriesNestedInput = {
|
|
create?: XOR<VendorCreateWithoutCategoriesInput, VendorUncheckedCreateWithoutCategoriesInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutCategoriesInput
|
|
upsert?: VendorUpsertWithoutCategoriesInput
|
|
connect?: VendorWhereUniqueInput
|
|
update?: XOR<XOR<VendorUpdateToOneWithWhereWithoutCategoriesInput, VendorUpdateWithoutCategoriesInput>, VendorUncheckedUpdateWithoutCategoriesInput>
|
|
}
|
|
|
|
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 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 VendorCreateNestedOneWithoutTaxesInput = {
|
|
create?: XOR<VendorCreateWithoutTaxesInput, VendorUncheckedCreateWithoutTaxesInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutTaxesInput
|
|
connect?: VendorWhereUniqueInput
|
|
}
|
|
|
|
export type ProductCreateNestedManyWithoutTaxInput = {
|
|
create?: XOR<ProductCreateWithoutTaxInput, ProductUncheckedCreateWithoutTaxInput> | ProductCreateWithoutTaxInput[] | ProductUncheckedCreateWithoutTaxInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutTaxInput | ProductCreateOrConnectWithoutTaxInput[]
|
|
createMany?: ProductCreateManyTaxInputEnvelope
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
}
|
|
|
|
export type ProductUncheckedCreateNestedManyWithoutTaxInput = {
|
|
create?: XOR<ProductCreateWithoutTaxInput, ProductUncheckedCreateWithoutTaxInput> | ProductCreateWithoutTaxInput[] | ProductUncheckedCreateWithoutTaxInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutTaxInput | ProductCreateOrConnectWithoutTaxInput[]
|
|
createMany?: ProductCreateManyTaxInputEnvelope
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
}
|
|
|
|
export type FloatFieldUpdateOperationsInput = {
|
|
set?: number
|
|
increment?: number
|
|
decrement?: number
|
|
multiply?: number
|
|
divide?: number
|
|
}
|
|
|
|
export type VendorUpdateOneRequiredWithoutTaxesNestedInput = {
|
|
create?: XOR<VendorCreateWithoutTaxesInput, VendorUncheckedCreateWithoutTaxesInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutTaxesInput
|
|
upsert?: VendorUpsertWithoutTaxesInput
|
|
connect?: VendorWhereUniqueInput
|
|
update?: XOR<XOR<VendorUpdateToOneWithWhereWithoutTaxesInput, VendorUpdateWithoutTaxesInput>, VendorUncheckedUpdateWithoutTaxesInput>
|
|
}
|
|
|
|
export type ProductUpdateManyWithoutTaxNestedInput = {
|
|
create?: XOR<ProductCreateWithoutTaxInput, ProductUncheckedCreateWithoutTaxInput> | ProductCreateWithoutTaxInput[] | ProductUncheckedCreateWithoutTaxInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutTaxInput | ProductCreateOrConnectWithoutTaxInput[]
|
|
upsert?: ProductUpsertWithWhereUniqueWithoutTaxInput | ProductUpsertWithWhereUniqueWithoutTaxInput[]
|
|
createMany?: ProductCreateManyTaxInputEnvelope
|
|
set?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
disconnect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
delete?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
update?: ProductUpdateWithWhereUniqueWithoutTaxInput | ProductUpdateWithWhereUniqueWithoutTaxInput[]
|
|
updateMany?: ProductUpdateManyWithWhereWithoutTaxInput | ProductUpdateManyWithWhereWithoutTaxInput[]
|
|
deleteMany?: ProductScalarWhereInput | ProductScalarWhereInput[]
|
|
}
|
|
|
|
export type ProductUncheckedUpdateManyWithoutTaxNestedInput = {
|
|
create?: XOR<ProductCreateWithoutTaxInput, ProductUncheckedCreateWithoutTaxInput> | ProductCreateWithoutTaxInput[] | ProductUncheckedCreateWithoutTaxInput[]
|
|
connectOrCreate?: ProductCreateOrConnectWithoutTaxInput | ProductCreateOrConnectWithoutTaxInput[]
|
|
upsert?: ProductUpsertWithWhereUniqueWithoutTaxInput | ProductUpsertWithWhereUniqueWithoutTaxInput[]
|
|
createMany?: ProductCreateManyTaxInputEnvelope
|
|
set?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
disconnect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
delete?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
connect?: ProductWhereUniqueInput | ProductWhereUniqueInput[]
|
|
update?: ProductUpdateWithWhereUniqueWithoutTaxInput | ProductUpdateWithWhereUniqueWithoutTaxInput[]
|
|
updateMany?: ProductUpdateManyWithWhereWithoutTaxInput | ProductUpdateManyWithWhereWithoutTaxInput[]
|
|
deleteMany?: ProductScalarWhereInput | ProductScalarWhereInput[]
|
|
}
|
|
|
|
export type VendorCreateNestedOneWithoutProductsInput = {
|
|
create?: XOR<VendorCreateWithoutProductsInput, VendorUncheckedCreateWithoutProductsInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutProductsInput
|
|
connect?: VendorWhereUniqueInput
|
|
}
|
|
|
|
export type CategoryCreateNestedOneWithoutProductsInput = {
|
|
create?: XOR<CategoryCreateWithoutProductsInput, CategoryUncheckedCreateWithoutProductsInput>
|
|
connectOrCreate?: CategoryCreateOrConnectWithoutProductsInput
|
|
connect?: CategoryWhereUniqueInput
|
|
}
|
|
|
|
export type TaxCreateNestedOneWithoutProductsInput = {
|
|
create?: XOR<TaxCreateWithoutProductsInput, TaxUncheckedCreateWithoutProductsInput>
|
|
connectOrCreate?: TaxCreateOrConnectWithoutProductsInput
|
|
connect?: TaxWhereUniqueInput
|
|
}
|
|
|
|
export type TransactionItemCreateNestedManyWithoutProductInput = {
|
|
create?: XOR<TransactionItemCreateWithoutProductInput, TransactionItemUncheckedCreateWithoutProductInput> | TransactionItemCreateWithoutProductInput[] | TransactionItemUncheckedCreateWithoutProductInput[]
|
|
connectOrCreate?: TransactionItemCreateOrConnectWithoutProductInput | TransactionItemCreateOrConnectWithoutProductInput[]
|
|
createMany?: TransactionItemCreateManyProductInputEnvelope
|
|
connect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
}
|
|
|
|
export type TransactionItemUncheckedCreateNestedManyWithoutProductInput = {
|
|
create?: XOR<TransactionItemCreateWithoutProductInput, TransactionItemUncheckedCreateWithoutProductInput> | TransactionItemCreateWithoutProductInput[] | TransactionItemUncheckedCreateWithoutProductInput[]
|
|
connectOrCreate?: TransactionItemCreateOrConnectWithoutProductInput | TransactionItemCreateOrConnectWithoutProductInput[]
|
|
createMany?: TransactionItemCreateManyProductInputEnvelope
|
|
connect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
}
|
|
|
|
export type IntFieldUpdateOperationsInput = {
|
|
set?: number
|
|
increment?: number
|
|
decrement?: number
|
|
multiply?: number
|
|
divide?: number
|
|
}
|
|
|
|
export type VendorUpdateOneRequiredWithoutProductsNestedInput = {
|
|
create?: XOR<VendorCreateWithoutProductsInput, VendorUncheckedCreateWithoutProductsInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutProductsInput
|
|
upsert?: VendorUpsertWithoutProductsInput
|
|
connect?: VendorWhereUniqueInput
|
|
update?: XOR<XOR<VendorUpdateToOneWithWhereWithoutProductsInput, VendorUpdateWithoutProductsInput>, VendorUncheckedUpdateWithoutProductsInput>
|
|
}
|
|
|
|
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 TaxUpdateOneWithoutProductsNestedInput = {
|
|
create?: XOR<TaxCreateWithoutProductsInput, TaxUncheckedCreateWithoutProductsInput>
|
|
connectOrCreate?: TaxCreateOrConnectWithoutProductsInput
|
|
upsert?: TaxUpsertWithoutProductsInput
|
|
disconnect?: TaxWhereInput | boolean
|
|
delete?: TaxWhereInput | boolean
|
|
connect?: TaxWhereUniqueInput
|
|
update?: XOR<XOR<TaxUpdateToOneWithWhereWithoutProductsInput, TaxUpdateWithoutProductsInput>, TaxUncheckedUpdateWithoutProductsInput>
|
|
}
|
|
|
|
export type TransactionItemUpdateManyWithoutProductNestedInput = {
|
|
create?: XOR<TransactionItemCreateWithoutProductInput, TransactionItemUncheckedCreateWithoutProductInput> | TransactionItemCreateWithoutProductInput[] | TransactionItemUncheckedCreateWithoutProductInput[]
|
|
connectOrCreate?: TransactionItemCreateOrConnectWithoutProductInput | TransactionItemCreateOrConnectWithoutProductInput[]
|
|
upsert?: TransactionItemUpsertWithWhereUniqueWithoutProductInput | TransactionItemUpsertWithWhereUniqueWithoutProductInput[]
|
|
createMany?: TransactionItemCreateManyProductInputEnvelope
|
|
set?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
disconnect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
delete?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
connect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
update?: TransactionItemUpdateWithWhereUniqueWithoutProductInput | TransactionItemUpdateWithWhereUniqueWithoutProductInput[]
|
|
updateMany?: TransactionItemUpdateManyWithWhereWithoutProductInput | TransactionItemUpdateManyWithWhereWithoutProductInput[]
|
|
deleteMany?: TransactionItemScalarWhereInput | TransactionItemScalarWhereInput[]
|
|
}
|
|
|
|
export type TransactionItemUncheckedUpdateManyWithoutProductNestedInput = {
|
|
create?: XOR<TransactionItemCreateWithoutProductInput, TransactionItemUncheckedCreateWithoutProductInput> | TransactionItemCreateWithoutProductInput[] | TransactionItemUncheckedCreateWithoutProductInput[]
|
|
connectOrCreate?: TransactionItemCreateOrConnectWithoutProductInput | TransactionItemCreateOrConnectWithoutProductInput[]
|
|
upsert?: TransactionItemUpsertWithWhereUniqueWithoutProductInput | TransactionItemUpsertWithWhereUniqueWithoutProductInput[]
|
|
createMany?: TransactionItemCreateManyProductInputEnvelope
|
|
set?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
disconnect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
delete?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
connect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
update?: TransactionItemUpdateWithWhereUniqueWithoutProductInput | TransactionItemUpdateWithWhereUniqueWithoutProductInput[]
|
|
updateMany?: TransactionItemUpdateManyWithWhereWithoutProductInput | TransactionItemUpdateManyWithWhereWithoutProductInput[]
|
|
deleteMany?: TransactionItemScalarWhereInput | TransactionItemScalarWhereInput[]
|
|
}
|
|
|
|
export type VendorCreateNestedOneWithoutTransactionsInput = {
|
|
create?: XOR<VendorCreateWithoutTransactionsInput, VendorUncheckedCreateWithoutTransactionsInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutTransactionsInput
|
|
connect?: VendorWhereUniqueInput
|
|
}
|
|
|
|
export type UserCreateNestedOneWithoutTransactionsInput = {
|
|
create?: XOR<UserCreateWithoutTransactionsInput, UserUncheckedCreateWithoutTransactionsInput>
|
|
connectOrCreate?: UserCreateOrConnectWithoutTransactionsInput
|
|
connect?: UserWhereUniqueInput
|
|
}
|
|
|
|
export type TransactionItemCreateNestedManyWithoutTransactionInput = {
|
|
create?: XOR<TransactionItemCreateWithoutTransactionInput, TransactionItemUncheckedCreateWithoutTransactionInput> | TransactionItemCreateWithoutTransactionInput[] | TransactionItemUncheckedCreateWithoutTransactionInput[]
|
|
connectOrCreate?: TransactionItemCreateOrConnectWithoutTransactionInput | TransactionItemCreateOrConnectWithoutTransactionInput[]
|
|
createMany?: TransactionItemCreateManyTransactionInputEnvelope
|
|
connect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
}
|
|
|
|
export type TransactionItemUncheckedCreateNestedManyWithoutTransactionInput = {
|
|
create?: XOR<TransactionItemCreateWithoutTransactionInput, TransactionItemUncheckedCreateWithoutTransactionInput> | TransactionItemCreateWithoutTransactionInput[] | TransactionItemUncheckedCreateWithoutTransactionInput[]
|
|
connectOrCreate?: TransactionItemCreateOrConnectWithoutTransactionInput | TransactionItemCreateOrConnectWithoutTransactionInput[]
|
|
createMany?: TransactionItemCreateManyTransactionInputEnvelope
|
|
connect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
}
|
|
|
|
export type VendorUpdateOneRequiredWithoutTransactionsNestedInput = {
|
|
create?: XOR<VendorCreateWithoutTransactionsInput, VendorUncheckedCreateWithoutTransactionsInput>
|
|
connectOrCreate?: VendorCreateOrConnectWithoutTransactionsInput
|
|
upsert?: VendorUpsertWithoutTransactionsInput
|
|
connect?: VendorWhereUniqueInput
|
|
update?: XOR<XOR<VendorUpdateToOneWithWhereWithoutTransactionsInput, VendorUpdateWithoutTransactionsInput>, VendorUncheckedUpdateWithoutTransactionsInput>
|
|
}
|
|
|
|
export type UserUpdateOneRequiredWithoutTransactionsNestedInput = {
|
|
create?: XOR<UserCreateWithoutTransactionsInput, UserUncheckedCreateWithoutTransactionsInput>
|
|
connectOrCreate?: UserCreateOrConnectWithoutTransactionsInput
|
|
upsert?: UserUpsertWithoutTransactionsInput
|
|
connect?: UserWhereUniqueInput
|
|
update?: XOR<XOR<UserUpdateToOneWithWhereWithoutTransactionsInput, UserUpdateWithoutTransactionsInput>, UserUncheckedUpdateWithoutTransactionsInput>
|
|
}
|
|
|
|
export type TransactionItemUpdateManyWithoutTransactionNestedInput = {
|
|
create?: XOR<TransactionItemCreateWithoutTransactionInput, TransactionItemUncheckedCreateWithoutTransactionInput> | TransactionItemCreateWithoutTransactionInput[] | TransactionItemUncheckedCreateWithoutTransactionInput[]
|
|
connectOrCreate?: TransactionItemCreateOrConnectWithoutTransactionInput | TransactionItemCreateOrConnectWithoutTransactionInput[]
|
|
upsert?: TransactionItemUpsertWithWhereUniqueWithoutTransactionInput | TransactionItemUpsertWithWhereUniqueWithoutTransactionInput[]
|
|
createMany?: TransactionItemCreateManyTransactionInputEnvelope
|
|
set?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
disconnect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
delete?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
connect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
update?: TransactionItemUpdateWithWhereUniqueWithoutTransactionInput | TransactionItemUpdateWithWhereUniqueWithoutTransactionInput[]
|
|
updateMany?: TransactionItemUpdateManyWithWhereWithoutTransactionInput | TransactionItemUpdateManyWithWhereWithoutTransactionInput[]
|
|
deleteMany?: TransactionItemScalarWhereInput | TransactionItemScalarWhereInput[]
|
|
}
|
|
|
|
export type TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput = {
|
|
create?: XOR<TransactionItemCreateWithoutTransactionInput, TransactionItemUncheckedCreateWithoutTransactionInput> | TransactionItemCreateWithoutTransactionInput[] | TransactionItemUncheckedCreateWithoutTransactionInput[]
|
|
connectOrCreate?: TransactionItemCreateOrConnectWithoutTransactionInput | TransactionItemCreateOrConnectWithoutTransactionInput[]
|
|
upsert?: TransactionItemUpsertWithWhereUniqueWithoutTransactionInput | TransactionItemUpsertWithWhereUniqueWithoutTransactionInput[]
|
|
createMany?: TransactionItemCreateManyTransactionInputEnvelope
|
|
set?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
disconnect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
delete?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
connect?: TransactionItemWhereUniqueInput | TransactionItemWhereUniqueInput[]
|
|
update?: TransactionItemUpdateWithWhereUniqueWithoutTransactionInput | TransactionItemUpdateWithWhereUniqueWithoutTransactionInput[]
|
|
updateMany?: TransactionItemUpdateManyWithWhereWithoutTransactionInput | TransactionItemUpdateManyWithWhereWithoutTransactionInput[]
|
|
deleteMany?: TransactionItemScalarWhereInput | TransactionItemScalarWhereInput[]
|
|
}
|
|
|
|
export type TransactionCreateNestedOneWithoutItemsInput = {
|
|
create?: XOR<TransactionCreateWithoutItemsInput, TransactionUncheckedCreateWithoutItemsInput>
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutItemsInput
|
|
connect?: TransactionWhereUniqueInput
|
|
}
|
|
|
|
export type ProductCreateNestedOneWithoutTransactionItemsInput = {
|
|
create?: XOR<ProductCreateWithoutTransactionItemsInput, ProductUncheckedCreateWithoutTransactionItemsInput>
|
|
connectOrCreate?: ProductCreateOrConnectWithoutTransactionItemsInput
|
|
connect?: ProductWhereUniqueInput
|
|
}
|
|
|
|
export type TransactionUpdateOneRequiredWithoutItemsNestedInput = {
|
|
create?: XOR<TransactionCreateWithoutItemsInput, TransactionUncheckedCreateWithoutItemsInput>
|
|
connectOrCreate?: TransactionCreateOrConnectWithoutItemsInput
|
|
upsert?: TransactionUpsertWithoutItemsInput
|
|
connect?: TransactionWhereUniqueInput
|
|
update?: XOR<XOR<TransactionUpdateToOneWithWhereWithoutItemsInput, TransactionUpdateWithoutItemsInput>, TransactionUncheckedUpdateWithoutItemsInput>
|
|
}
|
|
|
|
export type ProductUpdateOneRequiredWithoutTransactionItemsNestedInput = {
|
|
create?: XOR<ProductCreateWithoutTransactionItemsInput, ProductUncheckedCreateWithoutTransactionItemsInput>
|
|
connectOrCreate?: ProductCreateOrConnectWithoutTransactionItemsInput
|
|
upsert?: ProductUpsertWithoutTransactionItemsInput
|
|
connect?: ProductWhereUniqueInput
|
|
update?: XOR<XOR<ProductUpdateToOneWithWhereWithoutTransactionItemsInput, ProductUpdateWithoutTransactionItemsInput>, ProductUncheckedUpdateWithoutTransactionItemsInput>
|
|
}
|
|
|
|
export type NestedStringFilter<$PrismaModel = never> = {
|
|
equals?: string | StringFieldRefInput<$PrismaModel>
|
|
in?: string[]
|
|
notIn?: string[]
|
|
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[] | null
|
|
notIn?: string[] | 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 NestedDateTimeFilter<$PrismaModel = never> = {
|
|
equals?: Date | string | DateTimeFieldRefInput<$PrismaModel>
|
|
in?: Date[] | string[]
|
|
notIn?: Date[] | string[]
|
|
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 NestedStringWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: string | StringFieldRefInput<$PrismaModel>
|
|
in?: string[]
|
|
notIn?: string[]
|
|
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[]
|
|
notIn?: number[]
|
|
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[] | null
|
|
notIn?: string[] | 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[] | null
|
|
notIn?: number[] | null
|
|
lt?: number | IntFieldRefInput<$PrismaModel>
|
|
lte?: number | IntFieldRefInput<$PrismaModel>
|
|
gt?: number | IntFieldRefInput<$PrismaModel>
|
|
gte?: number | IntFieldRefInput<$PrismaModel>
|
|
not?: NestedIntNullableFilter<$PrismaModel> | number | null
|
|
}
|
|
|
|
export type NestedDateTimeWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: Date | string | DateTimeFieldRefInput<$PrismaModel>
|
|
in?: Date[] | string[]
|
|
notIn?: Date[] | string[]
|
|
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 NestedFloatFilter<$PrismaModel = never> = {
|
|
equals?: number | FloatFieldRefInput<$PrismaModel>
|
|
in?: number[]
|
|
notIn?: number[]
|
|
lt?: number | FloatFieldRefInput<$PrismaModel>
|
|
lte?: number | FloatFieldRefInput<$PrismaModel>
|
|
gt?: number | FloatFieldRefInput<$PrismaModel>
|
|
gte?: number | FloatFieldRefInput<$PrismaModel>
|
|
not?: NestedFloatFilter<$PrismaModel> | number
|
|
}
|
|
|
|
export type NestedFloatWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: number | FloatFieldRefInput<$PrismaModel>
|
|
in?: number[]
|
|
notIn?: number[]
|
|
lt?: number | FloatFieldRefInput<$PrismaModel>
|
|
lte?: number | FloatFieldRefInput<$PrismaModel>
|
|
gt?: number | FloatFieldRefInput<$PrismaModel>
|
|
gte?: number | FloatFieldRefInput<$PrismaModel>
|
|
not?: NestedFloatWithAggregatesFilter<$PrismaModel> | number
|
|
_count?: NestedIntFilter<$PrismaModel>
|
|
_avg?: NestedFloatFilter<$PrismaModel>
|
|
_sum?: NestedFloatFilter<$PrismaModel>
|
|
_min?: NestedFloatFilter<$PrismaModel>
|
|
_max?: NestedFloatFilter<$PrismaModel>
|
|
}
|
|
|
|
export type NestedIntWithAggregatesFilter<$PrismaModel = never> = {
|
|
equals?: number | IntFieldRefInput<$PrismaModel>
|
|
in?: number[]
|
|
notIn?: number[]
|
|
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 UserCreateWithoutVendorInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
role: RoleCreateNestedOneWithoutUsersInput
|
|
refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
|
|
transactions?: TransactionCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserUncheckedCreateWithoutVendorInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
roleId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserCreateOrConnectWithoutVendorInput = {
|
|
where: UserWhereUniqueInput
|
|
create: XOR<UserCreateWithoutVendorInput, UserUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type UserCreateManyVendorInputEnvelope = {
|
|
data: UserCreateManyVendorInput | UserCreateManyVendorInput[]
|
|
}
|
|
|
|
export type CategoryCreateWithoutVendorInput = {
|
|
id?: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
products?: ProductCreateNestedManyWithoutCategoryInput
|
|
}
|
|
|
|
export type CategoryUncheckedCreateWithoutVendorInput = {
|
|
id?: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
products?: ProductUncheckedCreateNestedManyWithoutCategoryInput
|
|
}
|
|
|
|
export type CategoryCreateOrConnectWithoutVendorInput = {
|
|
where: CategoryWhereUniqueInput
|
|
create: XOR<CategoryCreateWithoutVendorInput, CategoryUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type CategoryCreateManyVendorInputEnvelope = {
|
|
data: CategoryCreateManyVendorInput | CategoryCreateManyVendorInput[]
|
|
}
|
|
|
|
export type ProductCreateWithoutVendorInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
category?: CategoryCreateNestedOneWithoutProductsInput
|
|
tax?: TaxCreateNestedOneWithoutProductsInput
|
|
transactionItems?: TransactionItemCreateNestedManyWithoutProductInput
|
|
}
|
|
|
|
export type ProductUncheckedCreateWithoutVendorInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
categoryId?: string | null
|
|
taxId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
transactionItems?: TransactionItemUncheckedCreateNestedManyWithoutProductInput
|
|
}
|
|
|
|
export type ProductCreateOrConnectWithoutVendorInput = {
|
|
where: ProductWhereUniqueInput
|
|
create: XOR<ProductCreateWithoutVendorInput, ProductUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type ProductCreateManyVendorInputEnvelope = {
|
|
data: ProductCreateManyVendorInput | ProductCreateManyVendorInput[]
|
|
}
|
|
|
|
export type TaxCreateWithoutVendorInput = {
|
|
id?: string
|
|
name: string
|
|
rate: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
products?: ProductCreateNestedManyWithoutTaxInput
|
|
}
|
|
|
|
export type TaxUncheckedCreateWithoutVendorInput = {
|
|
id?: string
|
|
name: string
|
|
rate: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
products?: ProductUncheckedCreateNestedManyWithoutTaxInput
|
|
}
|
|
|
|
export type TaxCreateOrConnectWithoutVendorInput = {
|
|
where: TaxWhereUniqueInput
|
|
create: XOR<TaxCreateWithoutVendorInput, TaxUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type TaxCreateManyVendorInputEnvelope = {
|
|
data: TaxCreateManyVendorInput | TaxCreateManyVendorInput[]
|
|
}
|
|
|
|
export type TransactionCreateWithoutVendorInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
user: UserCreateNestedOneWithoutTransactionsInput
|
|
items?: TransactionItemCreateNestedManyWithoutTransactionInput
|
|
}
|
|
|
|
export type TransactionUncheckedCreateWithoutVendorInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
userId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
items?: TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
|
|
}
|
|
|
|
export type TransactionCreateOrConnectWithoutVendorInput = {
|
|
where: TransactionWhereUniqueInput
|
|
create: XOR<TransactionCreateWithoutVendorInput, TransactionUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type TransactionCreateManyVendorInputEnvelope = {
|
|
data: TransactionCreateManyVendorInput | TransactionCreateManyVendorInput[]
|
|
}
|
|
|
|
export type UserUpsertWithWhereUniqueWithoutVendorInput = {
|
|
where: UserWhereUniqueInput
|
|
update: XOR<UserUpdateWithoutVendorInput, UserUncheckedUpdateWithoutVendorInput>
|
|
create: XOR<UserCreateWithoutVendorInput, UserUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type UserUpdateWithWhereUniqueWithoutVendorInput = {
|
|
where: UserWhereUniqueInput
|
|
data: XOR<UserUpdateWithoutVendorInput, UserUncheckedUpdateWithoutVendorInput>
|
|
}
|
|
|
|
export type UserUpdateManyWithWhereWithoutVendorInput = {
|
|
where: UserScalarWhereInput
|
|
data: XOR<UserUpdateManyMutationInput, UserUncheckedUpdateManyWithoutVendorInput>
|
|
}
|
|
|
|
export type UserScalarWhereInput = {
|
|
AND?: UserScalarWhereInput | UserScalarWhereInput[]
|
|
OR?: UserScalarWhereInput[]
|
|
NOT?: UserScalarWhereInput | UserScalarWhereInput[]
|
|
id?: StringFilter<"User"> | string
|
|
email?: StringFilter<"User"> | string
|
|
passwordHash?: StringFilter<"User"> | string
|
|
name?: StringFilter<"User"> | string
|
|
vendorId?: StringFilter<"User"> | string
|
|
roleId?: StringFilter<"User"> | string
|
|
createdAt?: DateTimeFilter<"User"> | Date | string
|
|
updatedAt?: DateTimeFilter<"User"> | Date | string
|
|
}
|
|
|
|
export type CategoryUpsertWithWhereUniqueWithoutVendorInput = {
|
|
where: CategoryWhereUniqueInput
|
|
update: XOR<CategoryUpdateWithoutVendorInput, CategoryUncheckedUpdateWithoutVendorInput>
|
|
create: XOR<CategoryCreateWithoutVendorInput, CategoryUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type CategoryUpdateWithWhereUniqueWithoutVendorInput = {
|
|
where: CategoryWhereUniqueInput
|
|
data: XOR<CategoryUpdateWithoutVendorInput, CategoryUncheckedUpdateWithoutVendorInput>
|
|
}
|
|
|
|
export type CategoryUpdateManyWithWhereWithoutVendorInput = {
|
|
where: CategoryScalarWhereInput
|
|
data: XOR<CategoryUpdateManyMutationInput, CategoryUncheckedUpdateManyWithoutVendorInput>
|
|
}
|
|
|
|
export type CategoryScalarWhereInput = {
|
|
AND?: CategoryScalarWhereInput | CategoryScalarWhereInput[]
|
|
OR?: CategoryScalarWhereInput[]
|
|
NOT?: CategoryScalarWhereInput | CategoryScalarWhereInput[]
|
|
id?: StringFilter<"Category"> | string
|
|
name?: StringFilter<"Category"> | string
|
|
vendorId?: StringFilter<"Category"> | string
|
|
createdAt?: DateTimeFilter<"Category"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Category"> | Date | string
|
|
}
|
|
|
|
export type ProductUpsertWithWhereUniqueWithoutVendorInput = {
|
|
where: ProductWhereUniqueInput
|
|
update: XOR<ProductUpdateWithoutVendorInput, ProductUncheckedUpdateWithoutVendorInput>
|
|
create: XOR<ProductCreateWithoutVendorInput, ProductUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type ProductUpdateWithWhereUniqueWithoutVendorInput = {
|
|
where: ProductWhereUniqueInput
|
|
data: XOR<ProductUpdateWithoutVendorInput, ProductUncheckedUpdateWithoutVendorInput>
|
|
}
|
|
|
|
export type ProductUpdateManyWithWhereWithoutVendorInput = {
|
|
where: ProductScalarWhereInput
|
|
data: XOR<ProductUpdateManyMutationInput, ProductUncheckedUpdateManyWithoutVendorInput>
|
|
}
|
|
|
|
export type ProductScalarWhereInput = {
|
|
AND?: ProductScalarWhereInput | ProductScalarWhereInput[]
|
|
OR?: ProductScalarWhereInput[]
|
|
NOT?: ProductScalarWhereInput | ProductScalarWhereInput[]
|
|
id?: StringFilter<"Product"> | string
|
|
name?: StringFilter<"Product"> | string
|
|
sku?: StringNullableFilter<"Product"> | string | null
|
|
description?: StringNullableFilter<"Product"> | string | null
|
|
price?: FloatFilter<"Product"> | number
|
|
vendorId?: StringFilter<"Product"> | string
|
|
categoryId?: StringNullableFilter<"Product"> | string | null
|
|
taxId?: StringNullableFilter<"Product"> | string | null
|
|
tags?: StringNullableFilter<"Product"> | string | null
|
|
version?: IntFilter<"Product"> | number
|
|
createdAt?: DateTimeFilter<"Product"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Product"> | Date | string
|
|
}
|
|
|
|
export type TaxUpsertWithWhereUniqueWithoutVendorInput = {
|
|
where: TaxWhereUniqueInput
|
|
update: XOR<TaxUpdateWithoutVendorInput, TaxUncheckedUpdateWithoutVendorInput>
|
|
create: XOR<TaxCreateWithoutVendorInput, TaxUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type TaxUpdateWithWhereUniqueWithoutVendorInput = {
|
|
where: TaxWhereUniqueInput
|
|
data: XOR<TaxUpdateWithoutVendorInput, TaxUncheckedUpdateWithoutVendorInput>
|
|
}
|
|
|
|
export type TaxUpdateManyWithWhereWithoutVendorInput = {
|
|
where: TaxScalarWhereInput
|
|
data: XOR<TaxUpdateManyMutationInput, TaxUncheckedUpdateManyWithoutVendorInput>
|
|
}
|
|
|
|
export type TaxScalarWhereInput = {
|
|
AND?: TaxScalarWhereInput | TaxScalarWhereInput[]
|
|
OR?: TaxScalarWhereInput[]
|
|
NOT?: TaxScalarWhereInput | TaxScalarWhereInput[]
|
|
id?: StringFilter<"Tax"> | string
|
|
name?: StringFilter<"Tax"> | string
|
|
rate?: FloatFilter<"Tax"> | number
|
|
vendorId?: StringFilter<"Tax"> | string
|
|
createdAt?: DateTimeFilter<"Tax"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Tax"> | Date | string
|
|
}
|
|
|
|
export type TransactionUpsertWithWhereUniqueWithoutVendorInput = {
|
|
where: TransactionWhereUniqueInput
|
|
update: XOR<TransactionUpdateWithoutVendorInput, TransactionUncheckedUpdateWithoutVendorInput>
|
|
create: XOR<TransactionCreateWithoutVendorInput, TransactionUncheckedCreateWithoutVendorInput>
|
|
}
|
|
|
|
export type TransactionUpdateWithWhereUniqueWithoutVendorInput = {
|
|
where: TransactionWhereUniqueInput
|
|
data: XOR<TransactionUpdateWithoutVendorInput, TransactionUncheckedUpdateWithoutVendorInput>
|
|
}
|
|
|
|
export type TransactionUpdateManyWithWhereWithoutVendorInput = {
|
|
where: TransactionScalarWhereInput
|
|
data: XOR<TransactionUpdateManyMutationInput, TransactionUncheckedUpdateManyWithoutVendorInput>
|
|
}
|
|
|
|
export type TransactionScalarWhereInput = {
|
|
AND?: TransactionScalarWhereInput | TransactionScalarWhereInput[]
|
|
OR?: TransactionScalarWhereInput[]
|
|
NOT?: TransactionScalarWhereInput | TransactionScalarWhereInput[]
|
|
id?: StringFilter<"Transaction"> | string
|
|
idempotencyKey?: StringFilter<"Transaction"> | string
|
|
vendorId?: StringFilter<"Transaction"> | string
|
|
userId?: StringFilter<"Transaction"> | string
|
|
status?: StringFilter<"Transaction"> | string
|
|
paymentMethod?: StringFilter<"Transaction"> | string
|
|
subtotal?: FloatFilter<"Transaction"> | number
|
|
taxTotal?: FloatFilter<"Transaction"> | number
|
|
discountTotal?: FloatFilter<"Transaction"> | number
|
|
total?: FloatFilter<"Transaction"> | number
|
|
notes?: StringNullableFilter<"Transaction"> | string | null
|
|
createdAt?: DateTimeFilter<"Transaction"> | Date | string
|
|
updatedAt?: DateTimeFilter<"Transaction"> | Date | string
|
|
}
|
|
|
|
export type UserCreateWithoutRoleInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutUsersInput
|
|
refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
|
|
transactions?: TransactionCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserUncheckedCreateWithoutRoleInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
vendorId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserCreateOrConnectWithoutRoleInput = {
|
|
where: UserWhereUniqueInput
|
|
create: XOR<UserCreateWithoutRoleInput, UserUncheckedCreateWithoutRoleInput>
|
|
}
|
|
|
|
export type UserCreateManyRoleInputEnvelope = {
|
|
data: UserCreateManyRoleInput | UserCreateManyRoleInput[]
|
|
}
|
|
|
|
export type UserUpsertWithWhereUniqueWithoutRoleInput = {
|
|
where: UserWhereUniqueInput
|
|
update: XOR<UserUpdateWithoutRoleInput, UserUncheckedUpdateWithoutRoleInput>
|
|
create: XOR<UserCreateWithoutRoleInput, UserUncheckedCreateWithoutRoleInput>
|
|
}
|
|
|
|
export type UserUpdateWithWhereUniqueWithoutRoleInput = {
|
|
where: UserWhereUniqueInput
|
|
data: XOR<UserUpdateWithoutRoleInput, UserUncheckedUpdateWithoutRoleInput>
|
|
}
|
|
|
|
export type UserUpdateManyWithWhereWithoutRoleInput = {
|
|
where: UserScalarWhereInput
|
|
data: XOR<UserUpdateManyMutationInput, UserUncheckedUpdateManyWithoutRoleInput>
|
|
}
|
|
|
|
export type VendorCreateWithoutUsersInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
categories?: CategoryCreateNestedManyWithoutVendorInput
|
|
products?: ProductCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorUncheckedCreateWithoutUsersInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
categories?: CategoryUncheckedCreateNestedManyWithoutVendorInput
|
|
products?: ProductUncheckedCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxUncheckedCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorCreateOrConnectWithoutUsersInput = {
|
|
where: VendorWhereUniqueInput
|
|
create: XOR<VendorCreateWithoutUsersInput, VendorUncheckedCreateWithoutUsersInput>
|
|
}
|
|
|
|
export type RoleCreateWithoutUsersInput = {
|
|
id?: string
|
|
name: string
|
|
}
|
|
|
|
export type RoleUncheckedCreateWithoutUsersInput = {
|
|
id?: string
|
|
name: string
|
|
}
|
|
|
|
export type RoleCreateOrConnectWithoutUsersInput = {
|
|
where: RoleWhereUniqueInput
|
|
create: XOR<RoleCreateWithoutUsersInput, RoleUncheckedCreateWithoutUsersInput>
|
|
}
|
|
|
|
export type RefreshTokenCreateWithoutUserInput = {
|
|
id?: string
|
|
token: string
|
|
expiresAt: Date | string
|
|
createdAt?: Date | string
|
|
}
|
|
|
|
export type RefreshTokenUncheckedCreateWithoutUserInput = {
|
|
id?: string
|
|
token: string
|
|
expiresAt: Date | string
|
|
createdAt?: Date | string
|
|
}
|
|
|
|
export type RefreshTokenCreateOrConnectWithoutUserInput = {
|
|
where: RefreshTokenWhereUniqueInput
|
|
create: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput>
|
|
}
|
|
|
|
export type RefreshTokenCreateManyUserInputEnvelope = {
|
|
data: RefreshTokenCreateManyUserInput | RefreshTokenCreateManyUserInput[]
|
|
}
|
|
|
|
export type TransactionCreateWithoutUserInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutTransactionsInput
|
|
items?: TransactionItemCreateNestedManyWithoutTransactionInput
|
|
}
|
|
|
|
export type TransactionUncheckedCreateWithoutUserInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
vendorId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
items?: TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
|
|
}
|
|
|
|
export type TransactionCreateOrConnectWithoutUserInput = {
|
|
where: TransactionWhereUniqueInput
|
|
create: XOR<TransactionCreateWithoutUserInput, TransactionUncheckedCreateWithoutUserInput>
|
|
}
|
|
|
|
export type TransactionCreateManyUserInputEnvelope = {
|
|
data: TransactionCreateManyUserInput | TransactionCreateManyUserInput[]
|
|
}
|
|
|
|
export type VendorUpsertWithoutUsersInput = {
|
|
update: XOR<VendorUpdateWithoutUsersInput, VendorUncheckedUpdateWithoutUsersInput>
|
|
create: XOR<VendorCreateWithoutUsersInput, VendorUncheckedCreateWithoutUsersInput>
|
|
where?: VendorWhereInput
|
|
}
|
|
|
|
export type VendorUpdateToOneWithWhereWithoutUsersInput = {
|
|
where?: VendorWhereInput
|
|
data: XOR<VendorUpdateWithoutUsersInput, VendorUncheckedUpdateWithoutUsersInput>
|
|
}
|
|
|
|
export type VendorUpdateWithoutUsersInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
categories?: CategoryUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type VendorUncheckedUpdateWithoutUsersInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
categories?: CategoryUncheckedUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUncheckedUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUncheckedUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUncheckedUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type RoleUpsertWithoutUsersInput = {
|
|
update: XOR<RoleUpdateWithoutUsersInput, RoleUncheckedUpdateWithoutUsersInput>
|
|
create: XOR<RoleCreateWithoutUsersInput, RoleUncheckedCreateWithoutUsersInput>
|
|
where?: RoleWhereInput
|
|
}
|
|
|
|
export type RoleUpdateToOneWithWhereWithoutUsersInput = {
|
|
where?: RoleWhereInput
|
|
data: XOR<RoleUpdateWithoutUsersInput, RoleUncheckedUpdateWithoutUsersInput>
|
|
}
|
|
|
|
export type RoleUpdateWithoutUsersInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
}
|
|
|
|
export type RoleUncheckedUpdateWithoutUsersInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
}
|
|
|
|
export type RefreshTokenUpsertWithWhereUniqueWithoutUserInput = {
|
|
where: RefreshTokenWhereUniqueInput
|
|
update: XOR<RefreshTokenUpdateWithoutUserInput, RefreshTokenUncheckedUpdateWithoutUserInput>
|
|
create: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput>
|
|
}
|
|
|
|
export type RefreshTokenUpdateWithWhereUniqueWithoutUserInput = {
|
|
where: RefreshTokenWhereUniqueInput
|
|
data: XOR<RefreshTokenUpdateWithoutUserInput, RefreshTokenUncheckedUpdateWithoutUserInput>
|
|
}
|
|
|
|
export type RefreshTokenUpdateManyWithWhereWithoutUserInput = {
|
|
where: RefreshTokenScalarWhereInput
|
|
data: XOR<RefreshTokenUpdateManyMutationInput, RefreshTokenUncheckedUpdateManyWithoutUserInput>
|
|
}
|
|
|
|
export type RefreshTokenScalarWhereInput = {
|
|
AND?: RefreshTokenScalarWhereInput | RefreshTokenScalarWhereInput[]
|
|
OR?: RefreshTokenScalarWhereInput[]
|
|
NOT?: RefreshTokenScalarWhereInput | RefreshTokenScalarWhereInput[]
|
|
id?: StringFilter<"RefreshToken"> | string
|
|
token?: StringFilter<"RefreshToken"> | string
|
|
userId?: StringFilter<"RefreshToken"> | string
|
|
expiresAt?: DateTimeFilter<"RefreshToken"> | Date | string
|
|
createdAt?: DateTimeFilter<"RefreshToken"> | Date | string
|
|
}
|
|
|
|
export type TransactionUpsertWithWhereUniqueWithoutUserInput = {
|
|
where: TransactionWhereUniqueInput
|
|
update: XOR<TransactionUpdateWithoutUserInput, TransactionUncheckedUpdateWithoutUserInput>
|
|
create: XOR<TransactionCreateWithoutUserInput, TransactionUncheckedCreateWithoutUserInput>
|
|
}
|
|
|
|
export type TransactionUpdateWithWhereUniqueWithoutUserInput = {
|
|
where: TransactionWhereUniqueInput
|
|
data: XOR<TransactionUpdateWithoutUserInput, TransactionUncheckedUpdateWithoutUserInput>
|
|
}
|
|
|
|
export type TransactionUpdateManyWithWhereWithoutUserInput = {
|
|
where: TransactionScalarWhereInput
|
|
data: XOR<TransactionUpdateManyMutationInput, TransactionUncheckedUpdateManyWithoutUserInput>
|
|
}
|
|
|
|
export type UserCreateWithoutRefreshTokensInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutUsersInput
|
|
role: RoleCreateNestedOneWithoutUsersInput
|
|
transactions?: TransactionCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserUncheckedCreateWithoutRefreshTokensInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
vendorId: string
|
|
roleId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserCreateOrConnectWithoutRefreshTokensInput = {
|
|
where: UserWhereUniqueInput
|
|
create: XOR<UserCreateWithoutRefreshTokensInput, UserUncheckedCreateWithoutRefreshTokensInput>
|
|
}
|
|
|
|
export type UserUpsertWithoutRefreshTokensInput = {
|
|
update: XOR<UserUpdateWithoutRefreshTokensInput, UserUncheckedUpdateWithoutRefreshTokensInput>
|
|
create: XOR<UserCreateWithoutRefreshTokensInput, UserUncheckedCreateWithoutRefreshTokensInput>
|
|
where?: UserWhereInput
|
|
}
|
|
|
|
export type UserUpdateToOneWithWhereWithoutRefreshTokensInput = {
|
|
where?: UserWhereInput
|
|
data: XOR<UserUpdateWithoutRefreshTokensInput, UserUncheckedUpdateWithoutRefreshTokensInput>
|
|
}
|
|
|
|
export type UserUpdateWithoutRefreshTokensInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutUsersNestedInput
|
|
role?: RoleUpdateOneRequiredWithoutUsersNestedInput
|
|
transactions?: TransactionUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type UserUncheckedUpdateWithoutRefreshTokensInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
roleId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
transactions?: TransactionUncheckedUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type VendorCreateWithoutCategoriesInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserCreateNestedManyWithoutVendorInput
|
|
products?: ProductCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorUncheckedCreateWithoutCategoriesInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserUncheckedCreateNestedManyWithoutVendorInput
|
|
products?: ProductUncheckedCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxUncheckedCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorCreateOrConnectWithoutCategoriesInput = {
|
|
where: VendorWhereUniqueInput
|
|
create: XOR<VendorCreateWithoutCategoriesInput, VendorUncheckedCreateWithoutCategoriesInput>
|
|
}
|
|
|
|
export type ProductCreateWithoutCategoryInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutProductsInput
|
|
tax?: TaxCreateNestedOneWithoutProductsInput
|
|
transactionItems?: TransactionItemCreateNestedManyWithoutProductInput
|
|
}
|
|
|
|
export type ProductUncheckedCreateWithoutCategoryInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
vendorId: string
|
|
taxId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
transactionItems?: TransactionItemUncheckedCreateNestedManyWithoutProductInput
|
|
}
|
|
|
|
export type ProductCreateOrConnectWithoutCategoryInput = {
|
|
where: ProductWhereUniqueInput
|
|
create: XOR<ProductCreateWithoutCategoryInput, ProductUncheckedCreateWithoutCategoryInput>
|
|
}
|
|
|
|
export type ProductCreateManyCategoryInputEnvelope = {
|
|
data: ProductCreateManyCategoryInput | ProductCreateManyCategoryInput[]
|
|
}
|
|
|
|
export type VendorUpsertWithoutCategoriesInput = {
|
|
update: XOR<VendorUpdateWithoutCategoriesInput, VendorUncheckedUpdateWithoutCategoriesInput>
|
|
create: XOR<VendorCreateWithoutCategoriesInput, VendorUncheckedCreateWithoutCategoriesInput>
|
|
where?: VendorWhereInput
|
|
}
|
|
|
|
export type VendorUpdateToOneWithWhereWithoutCategoriesInput = {
|
|
where?: VendorWhereInput
|
|
data: XOR<VendorUpdateWithoutCategoriesInput, VendorUncheckedUpdateWithoutCategoriesInput>
|
|
}
|
|
|
|
export type VendorUpdateWithoutCategoriesInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type VendorUncheckedUpdateWithoutCategoriesInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUncheckedUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUncheckedUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUncheckedUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUncheckedUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
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 VendorCreateWithoutTaxesInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserCreateNestedManyWithoutVendorInput
|
|
categories?: CategoryCreateNestedManyWithoutVendorInput
|
|
products?: ProductCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorUncheckedCreateWithoutTaxesInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserUncheckedCreateNestedManyWithoutVendorInput
|
|
categories?: CategoryUncheckedCreateNestedManyWithoutVendorInput
|
|
products?: ProductUncheckedCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorCreateOrConnectWithoutTaxesInput = {
|
|
where: VendorWhereUniqueInput
|
|
create: XOR<VendorCreateWithoutTaxesInput, VendorUncheckedCreateWithoutTaxesInput>
|
|
}
|
|
|
|
export type ProductCreateWithoutTaxInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutProductsInput
|
|
category?: CategoryCreateNestedOneWithoutProductsInput
|
|
transactionItems?: TransactionItemCreateNestedManyWithoutProductInput
|
|
}
|
|
|
|
export type ProductUncheckedCreateWithoutTaxInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
vendorId: string
|
|
categoryId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
transactionItems?: TransactionItemUncheckedCreateNestedManyWithoutProductInput
|
|
}
|
|
|
|
export type ProductCreateOrConnectWithoutTaxInput = {
|
|
where: ProductWhereUniqueInput
|
|
create: XOR<ProductCreateWithoutTaxInput, ProductUncheckedCreateWithoutTaxInput>
|
|
}
|
|
|
|
export type ProductCreateManyTaxInputEnvelope = {
|
|
data: ProductCreateManyTaxInput | ProductCreateManyTaxInput[]
|
|
}
|
|
|
|
export type VendorUpsertWithoutTaxesInput = {
|
|
update: XOR<VendorUpdateWithoutTaxesInput, VendorUncheckedUpdateWithoutTaxesInput>
|
|
create: XOR<VendorCreateWithoutTaxesInput, VendorUncheckedCreateWithoutTaxesInput>
|
|
where?: VendorWhereInput
|
|
}
|
|
|
|
export type VendorUpdateToOneWithWhereWithoutTaxesInput = {
|
|
where?: VendorWhereInput
|
|
data: XOR<VendorUpdateWithoutTaxesInput, VendorUncheckedUpdateWithoutTaxesInput>
|
|
}
|
|
|
|
export type VendorUpdateWithoutTaxesInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUpdateManyWithoutVendorNestedInput
|
|
categories?: CategoryUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type VendorUncheckedUpdateWithoutTaxesInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUncheckedUpdateManyWithoutVendorNestedInput
|
|
categories?: CategoryUncheckedUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUncheckedUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUncheckedUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type ProductUpsertWithWhereUniqueWithoutTaxInput = {
|
|
where: ProductWhereUniqueInput
|
|
update: XOR<ProductUpdateWithoutTaxInput, ProductUncheckedUpdateWithoutTaxInput>
|
|
create: XOR<ProductCreateWithoutTaxInput, ProductUncheckedCreateWithoutTaxInput>
|
|
}
|
|
|
|
export type ProductUpdateWithWhereUniqueWithoutTaxInput = {
|
|
where: ProductWhereUniqueInput
|
|
data: XOR<ProductUpdateWithoutTaxInput, ProductUncheckedUpdateWithoutTaxInput>
|
|
}
|
|
|
|
export type ProductUpdateManyWithWhereWithoutTaxInput = {
|
|
where: ProductScalarWhereInput
|
|
data: XOR<ProductUpdateManyMutationInput, ProductUncheckedUpdateManyWithoutTaxInput>
|
|
}
|
|
|
|
export type VendorCreateWithoutProductsInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserCreateNestedManyWithoutVendorInput
|
|
categories?: CategoryCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorUncheckedCreateWithoutProductsInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserUncheckedCreateNestedManyWithoutVendorInput
|
|
categories?: CategoryUncheckedCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxUncheckedCreateNestedManyWithoutVendorInput
|
|
transactions?: TransactionUncheckedCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorCreateOrConnectWithoutProductsInput = {
|
|
where: VendorWhereUniqueInput
|
|
create: XOR<VendorCreateWithoutProductsInput, VendorUncheckedCreateWithoutProductsInput>
|
|
}
|
|
|
|
export type CategoryCreateWithoutProductsInput = {
|
|
id?: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutCategoriesInput
|
|
}
|
|
|
|
export type CategoryUncheckedCreateWithoutProductsInput = {
|
|
id?: string
|
|
name: string
|
|
vendorId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type CategoryCreateOrConnectWithoutProductsInput = {
|
|
where: CategoryWhereUniqueInput
|
|
create: XOR<CategoryCreateWithoutProductsInput, CategoryUncheckedCreateWithoutProductsInput>
|
|
}
|
|
|
|
export type TaxCreateWithoutProductsInput = {
|
|
id?: string
|
|
name: string
|
|
rate: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutTaxesInput
|
|
}
|
|
|
|
export type TaxUncheckedCreateWithoutProductsInput = {
|
|
id?: string
|
|
name: string
|
|
rate: number
|
|
vendorId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type TaxCreateOrConnectWithoutProductsInput = {
|
|
where: TaxWhereUniqueInput
|
|
create: XOR<TaxCreateWithoutProductsInput, TaxUncheckedCreateWithoutProductsInput>
|
|
}
|
|
|
|
export type TransactionItemCreateWithoutProductInput = {
|
|
id?: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
transaction: TransactionCreateNestedOneWithoutItemsInput
|
|
}
|
|
|
|
export type TransactionItemUncheckedCreateWithoutProductInput = {
|
|
id?: string
|
|
transactionId: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
}
|
|
|
|
export type TransactionItemCreateOrConnectWithoutProductInput = {
|
|
where: TransactionItemWhereUniqueInput
|
|
create: XOR<TransactionItemCreateWithoutProductInput, TransactionItemUncheckedCreateWithoutProductInput>
|
|
}
|
|
|
|
export type TransactionItemCreateManyProductInputEnvelope = {
|
|
data: TransactionItemCreateManyProductInput | TransactionItemCreateManyProductInput[]
|
|
}
|
|
|
|
export type VendorUpsertWithoutProductsInput = {
|
|
update: XOR<VendorUpdateWithoutProductsInput, VendorUncheckedUpdateWithoutProductsInput>
|
|
create: XOR<VendorCreateWithoutProductsInput, VendorUncheckedCreateWithoutProductsInput>
|
|
where?: VendorWhereInput
|
|
}
|
|
|
|
export type VendorUpdateToOneWithWhereWithoutProductsInput = {
|
|
where?: VendorWhereInput
|
|
data: XOR<VendorUpdateWithoutProductsInput, VendorUncheckedUpdateWithoutProductsInput>
|
|
}
|
|
|
|
export type VendorUpdateWithoutProductsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUpdateManyWithoutVendorNestedInput
|
|
categories?: CategoryUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type VendorUncheckedUpdateWithoutProductsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUncheckedUpdateManyWithoutVendorNestedInput
|
|
categories?: CategoryUncheckedUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUncheckedUpdateManyWithoutVendorNestedInput
|
|
transactions?: TransactionUncheckedUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
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
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutCategoriesNestedInput
|
|
}
|
|
|
|
export type CategoryUncheckedUpdateWithoutProductsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TaxUpsertWithoutProductsInput = {
|
|
update: XOR<TaxUpdateWithoutProductsInput, TaxUncheckedUpdateWithoutProductsInput>
|
|
create: XOR<TaxCreateWithoutProductsInput, TaxUncheckedCreateWithoutProductsInput>
|
|
where?: TaxWhereInput
|
|
}
|
|
|
|
export type TaxUpdateToOneWithWhereWithoutProductsInput = {
|
|
where?: TaxWhereInput
|
|
data: XOR<TaxUpdateWithoutProductsInput, TaxUncheckedUpdateWithoutProductsInput>
|
|
}
|
|
|
|
export type TaxUpdateWithoutProductsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutTaxesNestedInput
|
|
}
|
|
|
|
export type TaxUncheckedUpdateWithoutProductsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TransactionItemUpsertWithWhereUniqueWithoutProductInput = {
|
|
where: TransactionItemWhereUniqueInput
|
|
update: XOR<TransactionItemUpdateWithoutProductInput, TransactionItemUncheckedUpdateWithoutProductInput>
|
|
create: XOR<TransactionItemCreateWithoutProductInput, TransactionItemUncheckedCreateWithoutProductInput>
|
|
}
|
|
|
|
export type TransactionItemUpdateWithWhereUniqueWithoutProductInput = {
|
|
where: TransactionItemWhereUniqueInput
|
|
data: XOR<TransactionItemUpdateWithoutProductInput, TransactionItemUncheckedUpdateWithoutProductInput>
|
|
}
|
|
|
|
export type TransactionItemUpdateManyWithWhereWithoutProductInput = {
|
|
where: TransactionItemScalarWhereInput
|
|
data: XOR<TransactionItemUpdateManyMutationInput, TransactionItemUncheckedUpdateManyWithoutProductInput>
|
|
}
|
|
|
|
export type TransactionItemScalarWhereInput = {
|
|
AND?: TransactionItemScalarWhereInput | TransactionItemScalarWhereInput[]
|
|
OR?: TransactionItemScalarWhereInput[]
|
|
NOT?: TransactionItemScalarWhereInput | TransactionItemScalarWhereInput[]
|
|
id?: StringFilter<"TransactionItem"> | string
|
|
transactionId?: StringFilter<"TransactionItem"> | string
|
|
productId?: StringFilter<"TransactionItem"> | string
|
|
productName?: StringFilter<"TransactionItem"> | string
|
|
quantity?: IntFilter<"TransactionItem"> | number
|
|
unitPrice?: FloatFilter<"TransactionItem"> | number
|
|
taxRate?: FloatFilter<"TransactionItem"> | number
|
|
discount?: FloatFilter<"TransactionItem"> | number
|
|
total?: FloatFilter<"TransactionItem"> | number
|
|
}
|
|
|
|
export type VendorCreateWithoutTransactionsInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserCreateNestedManyWithoutVendorInput
|
|
categories?: CategoryCreateNestedManyWithoutVendorInput
|
|
products?: ProductCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorUncheckedCreateWithoutTransactionsInput = {
|
|
id?: string
|
|
name: string
|
|
businessNum?: string | null
|
|
taxSettings?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
users?: UserUncheckedCreateNestedManyWithoutVendorInput
|
|
categories?: CategoryUncheckedCreateNestedManyWithoutVendorInput
|
|
products?: ProductUncheckedCreateNestedManyWithoutVendorInput
|
|
taxes?: TaxUncheckedCreateNestedManyWithoutVendorInput
|
|
}
|
|
|
|
export type VendorCreateOrConnectWithoutTransactionsInput = {
|
|
where: VendorWhereUniqueInput
|
|
create: XOR<VendorCreateWithoutTransactionsInput, VendorUncheckedCreateWithoutTransactionsInput>
|
|
}
|
|
|
|
export type UserCreateWithoutTransactionsInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutUsersInput
|
|
role: RoleCreateNestedOneWithoutUsersInput
|
|
refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserUncheckedCreateWithoutTransactionsInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
vendorId: string
|
|
roleId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
|
|
}
|
|
|
|
export type UserCreateOrConnectWithoutTransactionsInput = {
|
|
where: UserWhereUniqueInput
|
|
create: XOR<UserCreateWithoutTransactionsInput, UserUncheckedCreateWithoutTransactionsInput>
|
|
}
|
|
|
|
export type TransactionItemCreateWithoutTransactionInput = {
|
|
id?: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
product: ProductCreateNestedOneWithoutTransactionItemsInput
|
|
}
|
|
|
|
export type TransactionItemUncheckedCreateWithoutTransactionInput = {
|
|
id?: string
|
|
productId: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
}
|
|
|
|
export type TransactionItemCreateOrConnectWithoutTransactionInput = {
|
|
where: TransactionItemWhereUniqueInput
|
|
create: XOR<TransactionItemCreateWithoutTransactionInput, TransactionItemUncheckedCreateWithoutTransactionInput>
|
|
}
|
|
|
|
export type TransactionItemCreateManyTransactionInputEnvelope = {
|
|
data: TransactionItemCreateManyTransactionInput | TransactionItemCreateManyTransactionInput[]
|
|
}
|
|
|
|
export type VendorUpsertWithoutTransactionsInput = {
|
|
update: XOR<VendorUpdateWithoutTransactionsInput, VendorUncheckedUpdateWithoutTransactionsInput>
|
|
create: XOR<VendorCreateWithoutTransactionsInput, VendorUncheckedCreateWithoutTransactionsInput>
|
|
where?: VendorWhereInput
|
|
}
|
|
|
|
export type VendorUpdateToOneWithWhereWithoutTransactionsInput = {
|
|
where?: VendorWhereInput
|
|
data: XOR<VendorUpdateWithoutTransactionsInput, VendorUncheckedUpdateWithoutTransactionsInput>
|
|
}
|
|
|
|
export type VendorUpdateWithoutTransactionsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUpdateManyWithoutVendorNestedInput
|
|
categories?: CategoryUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type VendorUncheckedUpdateWithoutTransactionsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
businessNum?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxSettings?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
users?: UserUncheckedUpdateManyWithoutVendorNestedInput
|
|
categories?: CategoryUncheckedUpdateManyWithoutVendorNestedInput
|
|
products?: ProductUncheckedUpdateManyWithoutVendorNestedInput
|
|
taxes?: TaxUncheckedUpdateManyWithoutVendorNestedInput
|
|
}
|
|
|
|
export type UserUpsertWithoutTransactionsInput = {
|
|
update: XOR<UserUpdateWithoutTransactionsInput, UserUncheckedUpdateWithoutTransactionsInput>
|
|
create: XOR<UserCreateWithoutTransactionsInput, UserUncheckedCreateWithoutTransactionsInput>
|
|
where?: UserWhereInput
|
|
}
|
|
|
|
export type UserUpdateToOneWithWhereWithoutTransactionsInput = {
|
|
where?: UserWhereInput
|
|
data: XOR<UserUpdateWithoutTransactionsInput, UserUncheckedUpdateWithoutTransactionsInput>
|
|
}
|
|
|
|
export type UserUpdateWithoutTransactionsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutUsersNestedInput
|
|
role?: RoleUpdateOneRequiredWithoutUsersNestedInput
|
|
refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type UserUncheckedUpdateWithoutTransactionsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
roleId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type TransactionItemUpsertWithWhereUniqueWithoutTransactionInput = {
|
|
where: TransactionItemWhereUniqueInput
|
|
update: XOR<TransactionItemUpdateWithoutTransactionInput, TransactionItemUncheckedUpdateWithoutTransactionInput>
|
|
create: XOR<TransactionItemCreateWithoutTransactionInput, TransactionItemUncheckedCreateWithoutTransactionInput>
|
|
}
|
|
|
|
export type TransactionItemUpdateWithWhereUniqueWithoutTransactionInput = {
|
|
where: TransactionItemWhereUniqueInput
|
|
data: XOR<TransactionItemUpdateWithoutTransactionInput, TransactionItemUncheckedUpdateWithoutTransactionInput>
|
|
}
|
|
|
|
export type TransactionItemUpdateManyWithWhereWithoutTransactionInput = {
|
|
where: TransactionItemScalarWhereInput
|
|
data: XOR<TransactionItemUpdateManyMutationInput, TransactionItemUncheckedUpdateManyWithoutTransactionInput>
|
|
}
|
|
|
|
export type TransactionCreateWithoutItemsInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutTransactionsInput
|
|
user: UserCreateNestedOneWithoutTransactionsInput
|
|
}
|
|
|
|
export type TransactionUncheckedCreateWithoutItemsInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
vendorId: string
|
|
userId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type TransactionCreateOrConnectWithoutItemsInput = {
|
|
where: TransactionWhereUniqueInput
|
|
create: XOR<TransactionCreateWithoutItemsInput, TransactionUncheckedCreateWithoutItemsInput>
|
|
}
|
|
|
|
export type ProductCreateWithoutTransactionItemsInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
vendor: VendorCreateNestedOneWithoutProductsInput
|
|
category?: CategoryCreateNestedOneWithoutProductsInput
|
|
tax?: TaxCreateNestedOneWithoutProductsInput
|
|
}
|
|
|
|
export type ProductUncheckedCreateWithoutTransactionItemsInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
vendorId: string
|
|
categoryId?: string | null
|
|
taxId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type ProductCreateOrConnectWithoutTransactionItemsInput = {
|
|
where: ProductWhereUniqueInput
|
|
create: XOR<ProductCreateWithoutTransactionItemsInput, ProductUncheckedCreateWithoutTransactionItemsInput>
|
|
}
|
|
|
|
export type TransactionUpsertWithoutItemsInput = {
|
|
update: XOR<TransactionUpdateWithoutItemsInput, TransactionUncheckedUpdateWithoutItemsInput>
|
|
create: XOR<TransactionCreateWithoutItemsInput, TransactionUncheckedCreateWithoutItemsInput>
|
|
where?: TransactionWhereInput
|
|
}
|
|
|
|
export type TransactionUpdateToOneWithWhereWithoutItemsInput = {
|
|
where?: TransactionWhereInput
|
|
data: XOR<TransactionUpdateWithoutItemsInput, TransactionUncheckedUpdateWithoutItemsInput>
|
|
}
|
|
|
|
export type TransactionUpdateWithoutItemsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutTransactionsNestedInput
|
|
user?: UserUpdateOneRequiredWithoutTransactionsNestedInput
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateWithoutItemsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
userId?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type ProductUpsertWithoutTransactionItemsInput = {
|
|
update: XOR<ProductUpdateWithoutTransactionItemsInput, ProductUncheckedUpdateWithoutTransactionItemsInput>
|
|
create: XOR<ProductCreateWithoutTransactionItemsInput, ProductUncheckedCreateWithoutTransactionItemsInput>
|
|
where?: ProductWhereInput
|
|
}
|
|
|
|
export type ProductUpdateToOneWithWhereWithoutTransactionItemsInput = {
|
|
where?: ProductWhereInput
|
|
data: XOR<ProductUpdateWithoutTransactionItemsInput, ProductUncheckedUpdateWithoutTransactionItemsInput>
|
|
}
|
|
|
|
export type ProductUpdateWithoutTransactionItemsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutProductsNestedInput
|
|
category?: CategoryUpdateOneWithoutProductsNestedInput
|
|
tax?: TaxUpdateOneWithoutProductsNestedInput
|
|
}
|
|
|
|
export type ProductUncheckedUpdateWithoutTransactionItemsInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
categoryId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type UserCreateManyVendorInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
roleId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type CategoryCreateManyVendorInput = {
|
|
id?: string
|
|
name: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type ProductCreateManyVendorInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
categoryId?: string | null
|
|
taxId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type TaxCreateManyVendorInput = {
|
|
id?: string
|
|
name: string
|
|
rate: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type TransactionCreateManyVendorInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
userId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type UserUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
role?: RoleUpdateOneRequiredWithoutUsersNestedInput
|
|
refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
|
|
transactions?: TransactionUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type UserUncheckedUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
roleId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
|
|
transactions?: TransactionUncheckedUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type UserUncheckedUpdateManyWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
roleId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type CategoryUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
products?: ProductUpdateManyWithoutCategoryNestedInput
|
|
}
|
|
|
|
export type CategoryUncheckedUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
products?: ProductUncheckedUpdateManyWithoutCategoryNestedInput
|
|
}
|
|
|
|
export type CategoryUncheckedUpdateManyWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type ProductUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
category?: CategoryUpdateOneWithoutProductsNestedInput
|
|
tax?: TaxUpdateOneWithoutProductsNestedInput
|
|
transactionItems?: TransactionItemUpdateManyWithoutProductNestedInput
|
|
}
|
|
|
|
export type ProductUncheckedUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
categoryId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
transactionItems?: TransactionItemUncheckedUpdateManyWithoutProductNestedInput
|
|
}
|
|
|
|
export type ProductUncheckedUpdateManyWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
categoryId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
taxId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TaxUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
products?: ProductUpdateManyWithoutTaxNestedInput
|
|
}
|
|
|
|
export type TaxUncheckedUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
products?: ProductUncheckedUpdateManyWithoutTaxNestedInput
|
|
}
|
|
|
|
export type TaxUncheckedUpdateManyWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
rate?: FloatFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TransactionUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
user?: UserUpdateOneRequiredWithoutTransactionsNestedInput
|
|
items?: TransactionItemUpdateManyWithoutTransactionNestedInput
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
userId?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
items?: TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateManyWithoutVendorInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
userId?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type UserCreateManyRoleInput = {
|
|
id?: string
|
|
email: string
|
|
passwordHash: string
|
|
name: string
|
|
vendorId: string
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type UserUpdateWithoutRoleInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutUsersNestedInput
|
|
refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
|
|
transactions?: TransactionUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type UserUncheckedUpdateWithoutRoleInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
|
|
transactions?: TransactionUncheckedUpdateManyWithoutUserNestedInput
|
|
}
|
|
|
|
export type UserUncheckedUpdateManyWithoutRoleInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
email?: StringFieldUpdateOperationsInput | string
|
|
passwordHash?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type RefreshTokenCreateManyUserInput = {
|
|
id?: string
|
|
token: string
|
|
expiresAt: Date | string
|
|
createdAt?: Date | string
|
|
}
|
|
|
|
export type TransactionCreateManyUserInput = {
|
|
id?: string
|
|
idempotencyKey: string
|
|
vendorId: string
|
|
status: string
|
|
paymentMethod: string
|
|
subtotal: number
|
|
taxTotal: number
|
|
discountTotal: number
|
|
total: number
|
|
notes?: string | null
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type RefreshTokenUpdateWithoutUserInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
token?: StringFieldUpdateOperationsInput | string
|
|
expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type RefreshTokenUncheckedUpdateWithoutUserInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
token?: StringFieldUpdateOperationsInput | string
|
|
expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type RefreshTokenUncheckedUpdateManyWithoutUserInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
token?: StringFieldUpdateOperationsInput | string
|
|
expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TransactionUpdateWithoutUserInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutTransactionsNestedInput
|
|
items?: TransactionItemUpdateManyWithoutTransactionNestedInput
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateWithoutUserInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
items?: TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
|
|
}
|
|
|
|
export type TransactionUncheckedUpdateManyWithoutUserInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
idempotencyKey?: StringFieldUpdateOperationsInput | string
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
status?: StringFieldUpdateOperationsInput | string
|
|
paymentMethod?: StringFieldUpdateOperationsInput | string
|
|
subtotal?: FloatFieldUpdateOperationsInput | number
|
|
taxTotal?: FloatFieldUpdateOperationsInput | number
|
|
discountTotal?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
notes?: NullableStringFieldUpdateOperationsInput | string | null
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type ProductCreateManyCategoryInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
vendorId: string
|
|
taxId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type ProductUpdateWithoutCategoryInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutProductsNestedInput
|
|
tax?: TaxUpdateOneWithoutProductsNestedInput
|
|
transactionItems?: TransactionItemUpdateManyWithoutProductNestedInput
|
|
}
|
|
|
|
export type ProductUncheckedUpdateWithoutCategoryInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
taxId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
transactionItems?: TransactionItemUncheckedUpdateManyWithoutProductNestedInput
|
|
}
|
|
|
|
export type ProductUncheckedUpdateManyWithoutCategoryInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
taxId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type ProductCreateManyTaxInput = {
|
|
id?: string
|
|
name: string
|
|
sku?: string | null
|
|
description?: string | null
|
|
price: number
|
|
vendorId: string
|
|
categoryId?: string | null
|
|
tags?: string | null
|
|
version?: number
|
|
createdAt?: Date | string
|
|
updatedAt?: Date | string
|
|
}
|
|
|
|
export type ProductUpdateWithoutTaxInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
vendor?: VendorUpdateOneRequiredWithoutProductsNestedInput
|
|
category?: CategoryUpdateOneWithoutProductsNestedInput
|
|
transactionItems?: TransactionItemUpdateManyWithoutProductNestedInput
|
|
}
|
|
|
|
export type ProductUncheckedUpdateWithoutTaxInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
categoryId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
transactionItems?: TransactionItemUncheckedUpdateManyWithoutProductNestedInput
|
|
}
|
|
|
|
export type ProductUncheckedUpdateManyWithoutTaxInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
name?: StringFieldUpdateOperationsInput | string
|
|
sku?: NullableStringFieldUpdateOperationsInput | string | null
|
|
description?: NullableStringFieldUpdateOperationsInput | string | null
|
|
price?: FloatFieldUpdateOperationsInput | number
|
|
vendorId?: StringFieldUpdateOperationsInput | string
|
|
categoryId?: NullableStringFieldUpdateOperationsInput | string | null
|
|
tags?: NullableStringFieldUpdateOperationsInput | string | null
|
|
version?: IntFieldUpdateOperationsInput | number
|
|
createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
|
|
}
|
|
|
|
export type TransactionItemCreateManyProductInput = {
|
|
id?: string
|
|
transactionId: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
}
|
|
|
|
export type TransactionItemUpdateWithoutProductInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
transaction?: TransactionUpdateOneRequiredWithoutItemsNestedInput
|
|
}
|
|
|
|
export type TransactionItemUncheckedUpdateWithoutProductInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
transactionId?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
}
|
|
|
|
export type TransactionItemUncheckedUpdateManyWithoutProductInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
transactionId?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
}
|
|
|
|
export type TransactionItemCreateManyTransactionInput = {
|
|
id?: string
|
|
productId: string
|
|
productName: string
|
|
quantity: number
|
|
unitPrice: number
|
|
taxRate: number
|
|
discount: number
|
|
total: number
|
|
}
|
|
|
|
export type TransactionItemUpdateWithoutTransactionInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
product?: ProductUpdateOneRequiredWithoutTransactionItemsNestedInput
|
|
}
|
|
|
|
export type TransactionItemUncheckedUpdateWithoutTransactionInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
productId?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
}
|
|
|
|
export type TransactionItemUncheckedUpdateManyWithoutTransactionInput = {
|
|
id?: StringFieldUpdateOperationsInput | string
|
|
productId?: StringFieldUpdateOperationsInput | string
|
|
productName?: StringFieldUpdateOperationsInput | string
|
|
quantity?: IntFieldUpdateOperationsInput | number
|
|
unitPrice?: FloatFieldUpdateOperationsInput | number
|
|
taxRate?: FloatFieldUpdateOperationsInput | number
|
|
discount?: FloatFieldUpdateOperationsInput | number
|
|
total?: FloatFieldUpdateOperationsInput | number
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
* Aliases for legacy arg types
|
|
*/
|
|
/**
|
|
* @deprecated Use VendorCountOutputTypeDefaultArgs instead
|
|
*/
|
|
export type VendorCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = VendorCountOutputTypeDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use RoleCountOutputTypeDefaultArgs instead
|
|
*/
|
|
export type RoleCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = RoleCountOutputTypeDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use UserCountOutputTypeDefaultArgs instead
|
|
*/
|
|
export type UserCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = UserCountOutputTypeDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use CategoryCountOutputTypeDefaultArgs instead
|
|
*/
|
|
export type CategoryCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CategoryCountOutputTypeDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use TaxCountOutputTypeDefaultArgs instead
|
|
*/
|
|
export type TaxCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = TaxCountOutputTypeDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use ProductCountOutputTypeDefaultArgs instead
|
|
*/
|
|
export type ProductCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ProductCountOutputTypeDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use TransactionCountOutputTypeDefaultArgs instead
|
|
*/
|
|
export type TransactionCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = TransactionCountOutputTypeDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use VendorDefaultArgs instead
|
|
*/
|
|
export type VendorArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = VendorDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use RoleDefaultArgs instead
|
|
*/
|
|
export type RoleArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = RoleDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use UserDefaultArgs instead
|
|
*/
|
|
export type UserArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = UserDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use RefreshTokenDefaultArgs instead
|
|
*/
|
|
export type RefreshTokenArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = RefreshTokenDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use CategoryDefaultArgs instead
|
|
*/
|
|
export type CategoryArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CategoryDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use TaxDefaultArgs instead
|
|
*/
|
|
export type TaxArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = TaxDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use ProductDefaultArgs instead
|
|
*/
|
|
export type ProductArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ProductDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use TransactionDefaultArgs instead
|
|
*/
|
|
export type TransactionArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = TransactionDefaultArgs<ExtArgs>
|
|
/**
|
|
* @deprecated Use TransactionItemDefaultArgs instead
|
|
*/
|
|
export type TransactionItemArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = TransactionItemDefaultArgs<ExtArgs>
|
|
|
|
/**
|
|
* Batch Payload for updateMany & deleteMany & createMany
|
|
*/
|
|
|
|
export type BatchPayload = {
|
|
count: number
|
|
}
|
|
|
|
/**
|
|
* DMMF
|
|
*/
|
|
export const dmmf: runtime.BaseDMMF
|
|
} |