init
This commit is contained in:
+6
-38
@@ -1,57 +1,25 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { AppController } from './app.controller'
|
||||
import { AppService } from './app.service'
|
||||
import { AuthModule } from './auth/auth.module'
|
||||
import { CustomersModule } from './customers/customers.module'
|
||||
import { InventoryTransferItemsModule } from './inventory-transfer-items/inventory-transfer-items.module'
|
||||
import { InventoryTransfersModule } from './inventory-transfers/inventory-transfers.module'
|
||||
import { BankAccountsModule } from './modules/bank-accounts/bank-accounts.module'
|
||||
import { BankBranchesModule } from './modules/bank-branches/bank-branches.module'
|
||||
import { BanksModule } from './modules/banks/banks.module'
|
||||
import { CardexModule } from './modules/cardex/cardex.module'
|
||||
import { InventoriesModule } from './modules/inventories/inventories.module'
|
||||
import { PosModule } from './modules/pos/pos.module'
|
||||
import { PurchaseReceiptsModule } from './modules/purchase-receipts/purchase-receipts.module'
|
||||
import { AuthModule } from './modules/auth/auth.module'
|
||||
import { CustomersModule } from './modules/customers/customers.module'
|
||||
import { ProductCategoriesModule } from './modules/product-categories/product-categories.module'
|
||||
import { ProductsModule } from './modules/products/products.module'
|
||||
import { SalesInvoicesModule } from './modules/sales-invoices/sales-invoices.module'
|
||||
import { StatisticsModule } from './modules/statistics/statistics.module'
|
||||
import { SuppliersModule } from './modules/suppliers/suppliers.module'
|
||||
import { UploadsModule } from './modules/uploads/uploads.module'
|
||||
import { PrismaModule } from './prisma/prisma.module'
|
||||
import { ProductBrandsModule } from './product-brands/product-brands.module'
|
||||
import { ProductCategoriesModule } from './product-categories/product-categories.module'
|
||||
import { ProductVariantsModule } from './product-variants/product-variants.module'
|
||||
import { ProductsModule } from './products/products.module'
|
||||
import { RolesModule } from './roles/roles.module'
|
||||
import { StockAdjustmentsModule } from './stock-adjustments/stock-adjustments.module'
|
||||
import { StockBalanceModule } from './stock-balance/stock-balance.module'
|
||||
import { StockMovementsModule } from './stock-movements/stock-movements.module'
|
||||
import { UsersModule } from './users/users.module'
|
||||
|
||||
@Module({
|
||||
imports: [
|
||||
PrismaModule,
|
||||
UsersModule,
|
||||
AuthModule,
|
||||
RolesModule,
|
||||
ProductsModule,
|
||||
ProductVariantsModule,
|
||||
ProductBrandsModule,
|
||||
ProductCategoriesModule,
|
||||
SuppliersModule,
|
||||
CustomersModule,
|
||||
InventoriesModule,
|
||||
PurchaseReceiptsModule,
|
||||
SalesInvoicesModule,
|
||||
InventoryTransfersModule,
|
||||
InventoryTransferItemsModule,
|
||||
StockMovementsModule,
|
||||
StockAdjustmentsModule,
|
||||
StockBalanceModule,
|
||||
PosModule,
|
||||
CardexModule,
|
||||
BanksModule,
|
||||
BankBranchesModule,
|
||||
BankAccountsModule,
|
||||
StatisticsModule,
|
||||
UploadsModule,
|
||||
],
|
||||
controllers: [AppController],
|
||||
providers: [AppService],
|
||||
|
||||
@@ -18,80 +18,15 @@ export { Prisma }
|
||||
export * as $Enums from './enums.js'
|
||||
export * from './enums.js';
|
||||
/**
|
||||
* Model User
|
||||
* Model Good
|
||||
*
|
||||
*/
|
||||
export type User = Prisma.UserModel
|
||||
export type Good = Prisma.GoodModel
|
||||
/**
|
||||
* Model Role
|
||||
* Model GoodCategory
|
||||
*
|
||||
*/
|
||||
export type Role = Prisma.RoleModel
|
||||
/**
|
||||
* Model OtpCode
|
||||
*
|
||||
*/
|
||||
export type OtpCode = Prisma.OtpCodeModel
|
||||
/**
|
||||
* Model RefreshToken
|
||||
*
|
||||
*/
|
||||
export type RefreshToken = Prisma.RefreshTokenModel
|
||||
/**
|
||||
* Model BankBranch
|
||||
*
|
||||
*/
|
||||
export type BankBranch = Prisma.BankBranchModel
|
||||
/**
|
||||
* Model BankAccount
|
||||
*
|
||||
*/
|
||||
export type BankAccount = Prisma.BankAccountModel
|
||||
/**
|
||||
* Model BankAccountTransaction
|
||||
*
|
||||
*/
|
||||
export type BankAccountTransaction = Prisma.BankAccountTransactionModel
|
||||
/**
|
||||
* Model Inventory
|
||||
*
|
||||
*/
|
||||
export type Inventory = Prisma.InventoryModel
|
||||
/**
|
||||
* Model InventoryBankAccount
|
||||
*
|
||||
*/
|
||||
export type InventoryBankAccount = Prisma.InventoryBankAccountModel
|
||||
/**
|
||||
* Model PosAccount
|
||||
*
|
||||
*/
|
||||
export type PosAccount = Prisma.PosAccountModel
|
||||
/**
|
||||
* Model InventoryTransfer
|
||||
*
|
||||
*/
|
||||
export type InventoryTransfer = Prisma.InventoryTransferModel
|
||||
/**
|
||||
* Model InventoryTransferItem
|
||||
*
|
||||
*/
|
||||
export type InventoryTransferItem = Prisma.InventoryTransferItemModel
|
||||
/**
|
||||
* Model Bank
|
||||
*
|
||||
*/
|
||||
export type Bank = Prisma.BankModel
|
||||
/**
|
||||
* Model Order
|
||||
*
|
||||
*/
|
||||
export type Order = Prisma.OrderModel
|
||||
/**
|
||||
* Model OrderItem
|
||||
*
|
||||
*/
|
||||
export type OrderItem = Prisma.OrderItemModel
|
||||
export type GoodCategory = Prisma.GoodCategoryModel
|
||||
/**
|
||||
* Model Customer
|
||||
*
|
||||
@@ -102,41 +37,6 @@ export type Customer = Prisma.CustomerModel
|
||||
*
|
||||
*/
|
||||
export type TriggerLog = Prisma.TriggerLogModel
|
||||
/**
|
||||
* Model ProductVariant
|
||||
*
|
||||
*/
|
||||
export type ProductVariant = Prisma.ProductVariantModel
|
||||
/**
|
||||
* Model Product
|
||||
*
|
||||
*/
|
||||
export type Product = Prisma.ProductModel
|
||||
/**
|
||||
* Model ProductBrand
|
||||
*
|
||||
*/
|
||||
export type ProductBrand = Prisma.ProductBrandModel
|
||||
/**
|
||||
* Model ProductCategory
|
||||
*
|
||||
*/
|
||||
export type ProductCategory = Prisma.ProductCategoryModel
|
||||
/**
|
||||
* Model PurchaseReceipt
|
||||
*
|
||||
*/
|
||||
export type PurchaseReceipt = Prisma.PurchaseReceiptModel
|
||||
/**
|
||||
* Model PurchaseReceiptItem
|
||||
*
|
||||
*/
|
||||
export type PurchaseReceiptItem = Prisma.PurchaseReceiptItemModel
|
||||
/**
|
||||
* Model PurchaseReceiptPayments
|
||||
*
|
||||
*/
|
||||
export type PurchaseReceiptPayments = Prisma.PurchaseReceiptPaymentsModel
|
||||
/**
|
||||
* Model SalesInvoice
|
||||
*
|
||||
@@ -153,37 +53,12 @@ export type SalesInvoiceItem = Prisma.SalesInvoiceItemModel
|
||||
*/
|
||||
export type SalesInvoicePayment = Prisma.SalesInvoicePaymentModel
|
||||
/**
|
||||
* Model StockMovement
|
||||
* Model Service
|
||||
*
|
||||
*/
|
||||
export type StockMovement = Prisma.StockMovementModel
|
||||
export type Service = Prisma.ServiceModel
|
||||
/**
|
||||
* Model StockBalance
|
||||
* Model ServiceCategory
|
||||
*
|
||||
*/
|
||||
export type StockBalance = Prisma.StockBalanceModel
|
||||
/**
|
||||
* Model StockAdjustment
|
||||
*
|
||||
*/
|
||||
export type StockAdjustment = Prisma.StockAdjustmentModel
|
||||
/**
|
||||
* Model StockReservation
|
||||
*
|
||||
*/
|
||||
export type StockReservation = Prisma.StockReservationModel
|
||||
/**
|
||||
* Model Supplier
|
||||
*
|
||||
*/
|
||||
export type Supplier = Prisma.SupplierModel
|
||||
/**
|
||||
* Model SupplierLedger
|
||||
*
|
||||
*/
|
||||
export type SupplierLedger = Prisma.SupplierLedgerModel
|
||||
/**
|
||||
* Model StockAvailableView
|
||||
*
|
||||
*/
|
||||
export type StockAvailableView = Prisma.StockAvailableViewModel
|
||||
export type ServiceCategory = Prisma.ServiceCategoryModel
|
||||
|
||||
+10
-135
@@ -27,8 +27,8 @@ export * from "./enums.js"
|
||||
* @example
|
||||
* ```
|
||||
* const prisma = new PrismaClient()
|
||||
* // Fetch zero or more Users
|
||||
* const users = await prisma.user.findMany()
|
||||
* // Fetch zero or more Goods
|
||||
* const goods = await prisma.good.findMany()
|
||||
* ```
|
||||
*
|
||||
* Read more in our [docs](https://pris.ly/d/client).
|
||||
@@ -38,80 +38,15 @@ export type PrismaClient<LogOpts extends Prisma.LogLevel = never, OmitOpts exten
|
||||
export { Prisma }
|
||||
|
||||
/**
|
||||
* Model User
|
||||
* Model Good
|
||||
*
|
||||
*/
|
||||
export type User = Prisma.UserModel
|
||||
export type Good = Prisma.GoodModel
|
||||
/**
|
||||
* Model Role
|
||||
* Model GoodCategory
|
||||
*
|
||||
*/
|
||||
export type Role = Prisma.RoleModel
|
||||
/**
|
||||
* Model OtpCode
|
||||
*
|
||||
*/
|
||||
export type OtpCode = Prisma.OtpCodeModel
|
||||
/**
|
||||
* Model RefreshToken
|
||||
*
|
||||
*/
|
||||
export type RefreshToken = Prisma.RefreshTokenModel
|
||||
/**
|
||||
* Model BankBranch
|
||||
*
|
||||
*/
|
||||
export type BankBranch = Prisma.BankBranchModel
|
||||
/**
|
||||
* Model BankAccount
|
||||
*
|
||||
*/
|
||||
export type BankAccount = Prisma.BankAccountModel
|
||||
/**
|
||||
* Model BankAccountTransaction
|
||||
*
|
||||
*/
|
||||
export type BankAccountTransaction = Prisma.BankAccountTransactionModel
|
||||
/**
|
||||
* Model Inventory
|
||||
*
|
||||
*/
|
||||
export type Inventory = Prisma.InventoryModel
|
||||
/**
|
||||
* Model InventoryBankAccount
|
||||
*
|
||||
*/
|
||||
export type InventoryBankAccount = Prisma.InventoryBankAccountModel
|
||||
/**
|
||||
* Model PosAccount
|
||||
*
|
||||
*/
|
||||
export type PosAccount = Prisma.PosAccountModel
|
||||
/**
|
||||
* Model InventoryTransfer
|
||||
*
|
||||
*/
|
||||
export type InventoryTransfer = Prisma.InventoryTransferModel
|
||||
/**
|
||||
* Model InventoryTransferItem
|
||||
*
|
||||
*/
|
||||
export type InventoryTransferItem = Prisma.InventoryTransferItemModel
|
||||
/**
|
||||
* Model Bank
|
||||
*
|
||||
*/
|
||||
export type Bank = Prisma.BankModel
|
||||
/**
|
||||
* Model Order
|
||||
*
|
||||
*/
|
||||
export type Order = Prisma.OrderModel
|
||||
/**
|
||||
* Model OrderItem
|
||||
*
|
||||
*/
|
||||
export type OrderItem = Prisma.OrderItemModel
|
||||
export type GoodCategory = Prisma.GoodCategoryModel
|
||||
/**
|
||||
* Model Customer
|
||||
*
|
||||
@@ -122,41 +57,6 @@ export type Customer = Prisma.CustomerModel
|
||||
*
|
||||
*/
|
||||
export type TriggerLog = Prisma.TriggerLogModel
|
||||
/**
|
||||
* Model ProductVariant
|
||||
*
|
||||
*/
|
||||
export type ProductVariant = Prisma.ProductVariantModel
|
||||
/**
|
||||
* Model Product
|
||||
*
|
||||
*/
|
||||
export type Product = Prisma.ProductModel
|
||||
/**
|
||||
* Model ProductBrand
|
||||
*
|
||||
*/
|
||||
export type ProductBrand = Prisma.ProductBrandModel
|
||||
/**
|
||||
* Model ProductCategory
|
||||
*
|
||||
*/
|
||||
export type ProductCategory = Prisma.ProductCategoryModel
|
||||
/**
|
||||
* Model PurchaseReceipt
|
||||
*
|
||||
*/
|
||||
export type PurchaseReceipt = Prisma.PurchaseReceiptModel
|
||||
/**
|
||||
* Model PurchaseReceiptItem
|
||||
*
|
||||
*/
|
||||
export type PurchaseReceiptItem = Prisma.PurchaseReceiptItemModel
|
||||
/**
|
||||
* Model PurchaseReceiptPayments
|
||||
*
|
||||
*/
|
||||
export type PurchaseReceiptPayments = Prisma.PurchaseReceiptPaymentsModel
|
||||
/**
|
||||
* Model SalesInvoice
|
||||
*
|
||||
@@ -173,37 +73,12 @@ export type SalesInvoiceItem = Prisma.SalesInvoiceItemModel
|
||||
*/
|
||||
export type SalesInvoicePayment = Prisma.SalesInvoicePaymentModel
|
||||
/**
|
||||
* Model StockMovement
|
||||
* Model Service
|
||||
*
|
||||
*/
|
||||
export type StockMovement = Prisma.StockMovementModel
|
||||
export type Service = Prisma.ServiceModel
|
||||
/**
|
||||
* Model StockBalance
|
||||
* Model ServiceCategory
|
||||
*
|
||||
*/
|
||||
export type StockBalance = Prisma.StockBalanceModel
|
||||
/**
|
||||
* Model StockAdjustment
|
||||
*
|
||||
*/
|
||||
export type StockAdjustment = Prisma.StockAdjustmentModel
|
||||
/**
|
||||
* Model StockReservation
|
||||
*
|
||||
*/
|
||||
export type StockReservation = Prisma.StockReservationModel
|
||||
/**
|
||||
* Model Supplier
|
||||
*
|
||||
*/
|
||||
export type Supplier = Prisma.SupplierModel
|
||||
/**
|
||||
* Model SupplierLedger
|
||||
*
|
||||
*/
|
||||
export type SupplierLedger = Prisma.SupplierLedgerModel
|
||||
/**
|
||||
* Model StockAvailableView
|
||||
*
|
||||
*/
|
||||
export type StockAvailableView = Prisma.StockAvailableViewModel
|
||||
export type ServiceCategory = Prisma.ServiceCategoryModel
|
||||
|
||||
@@ -40,6 +40,21 @@ export type StringFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedStringFilter<$PrismaModel> | string
|
||||
}
|
||||
|
||||
export type StringNullableFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel> | null
|
||||
in?: string[] | null
|
||||
notIn?: string[] | null
|
||||
lt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
lte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
startsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
endsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
search?: string
|
||||
not?: Prisma.NestedStringNullableFilter<$PrismaModel> | string | null
|
||||
}
|
||||
|
||||
export type DateTimeFilter<$PrismaModel = never> = {
|
||||
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
|
||||
in?: Date[] | string[]
|
||||
@@ -62,6 +77,28 @@ export type DateTimeNullableFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null
|
||||
}
|
||||
|
||||
export type IntNullableFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel> | null
|
||||
in?: number[] | null
|
||||
notIn?: number[] | null
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntNullableFilter<$PrismaModel> | number | null
|
||||
}
|
||||
|
||||
export type DecimalFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
}
|
||||
|
||||
export type SortOrderInput = {
|
||||
sort: Prisma.SortOrder
|
||||
nulls?: Prisma.NullsOrder
|
||||
@@ -101,6 +138,24 @@ export type StringWithAggregatesFilter<$PrismaModel = never> = {
|
||||
_max?: Prisma.NestedStringFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type StringNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel> | null
|
||||
in?: string[] | null
|
||||
notIn?: string[] | null
|
||||
lt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
lte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
startsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
endsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
search?: string
|
||||
not?: Prisma.NestedStringNullableWithAggregatesFilter<$PrismaModel> | string | null
|
||||
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedStringNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedStringNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type DateTimeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
|
||||
in?: Date[] | string[]
|
||||
@@ -129,136 +184,20 @@ export type DateTimeNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
_max?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type StringNullableFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel> | null
|
||||
in?: string[] | null
|
||||
notIn?: string[] | null
|
||||
lt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
lte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
startsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
endsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
search?: string
|
||||
not?: Prisma.NestedStringNullableFilter<$PrismaModel> | string | null
|
||||
}
|
||||
|
||||
export type JsonNullableFilter<$PrismaModel = never> =
|
||||
| Prisma.PatchUndefined<
|
||||
Prisma.Either<Required<JsonNullableFilterBase<$PrismaModel>>, Exclude<keyof Required<JsonNullableFilterBase<$PrismaModel>>, 'path'>>,
|
||||
Required<JsonNullableFilterBase<$PrismaModel>>
|
||||
>
|
||||
| Prisma.OptionalFlat<Omit<Required<JsonNullableFilterBase<$PrismaModel>>, 'path'>>
|
||||
|
||||
export type JsonNullableFilterBase<$PrismaModel = never> = {
|
||||
equals?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | Prisma.JsonNullValueFilter
|
||||
path?: string
|
||||
mode?: Prisma.QueryMode | Prisma.EnumQueryModeFieldRefInput<$PrismaModel>
|
||||
string_contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
string_starts_with?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
string_ends_with?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
array_starts_with?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
array_ends_with?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
array_contains?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
lt?: runtime.InputJsonValue
|
||||
lte?: runtime.InputJsonValue
|
||||
gt?: runtime.InputJsonValue
|
||||
gte?: runtime.InputJsonValue
|
||||
not?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | Prisma.JsonNullValueFilter
|
||||
}
|
||||
|
||||
export type StringNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel> | null
|
||||
in?: string[] | null
|
||||
notIn?: string[] | null
|
||||
lt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
lte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
startsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
endsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
search?: string
|
||||
not?: Prisma.NestedStringNullableWithAggregatesFilter<$PrismaModel> | string | null
|
||||
export type IntNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel> | null
|
||||
in?: number[] | null
|
||||
notIn?: number[] | null
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntNullableWithAggregatesFilter<$PrismaModel> | number | null
|
||||
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedStringNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedStringNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type JsonNullableWithAggregatesFilter<$PrismaModel = never> =
|
||||
| Prisma.PatchUndefined<
|
||||
Prisma.Either<Required<JsonNullableWithAggregatesFilterBase<$PrismaModel>>, Exclude<keyof Required<JsonNullableWithAggregatesFilterBase<$PrismaModel>>, 'path'>>,
|
||||
Required<JsonNullableWithAggregatesFilterBase<$PrismaModel>>
|
||||
>
|
||||
| Prisma.OptionalFlat<Omit<Required<JsonNullableWithAggregatesFilterBase<$PrismaModel>>, 'path'>>
|
||||
|
||||
export type JsonNullableWithAggregatesFilterBase<$PrismaModel = never> = {
|
||||
equals?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | Prisma.JsonNullValueFilter
|
||||
path?: string
|
||||
mode?: Prisma.QueryMode | Prisma.EnumQueryModeFieldRefInput<$PrismaModel>
|
||||
string_contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
string_starts_with?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
string_ends_with?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
array_starts_with?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
array_ends_with?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
array_contains?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
lt?: runtime.InputJsonValue
|
||||
lte?: runtime.InputJsonValue
|
||||
gt?: runtime.InputJsonValue
|
||||
gte?: runtime.InputJsonValue
|
||||
not?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | Prisma.JsonNullValueFilter
|
||||
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedJsonNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedJsonNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type BoolFilter<$PrismaModel = never> = {
|
||||
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBoolFilter<$PrismaModel> | boolean
|
||||
}
|
||||
|
||||
export type BoolWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBoolWithAggregatesFilter<$PrismaModel> | boolean
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedBoolFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedBoolFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumBankAccountTransactionTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.BankAccountTransactionType | Prisma.EnumBankAccountTransactionTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.BankAccountTransactionType[]
|
||||
notIn?: $Enums.BankAccountTransactionType[]
|
||||
not?: Prisma.NestedEnumBankAccountTransactionTypeFilter<$PrismaModel> | $Enums.BankAccountTransactionType
|
||||
}
|
||||
|
||||
export type DecimalFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
}
|
||||
|
||||
export type EnumBankTransactionRefTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.BankTransactionRefType | Prisma.EnumBankTransactionRefTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.BankTransactionRefType[]
|
||||
notIn?: $Enums.BankTransactionRefType[]
|
||||
not?: Prisma.NestedEnumBankTransactionRefTypeFilter<$PrismaModel> | $Enums.BankTransactionRefType
|
||||
}
|
||||
|
||||
export type EnumBankAccountTransactionTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.BankAccountTransactionType | Prisma.EnumBankAccountTransactionTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.BankAccountTransactionType[]
|
||||
notIn?: $Enums.BankAccountTransactionType[]
|
||||
not?: Prisma.NestedEnumBankAccountTransactionTypeWithAggregatesFilter<$PrismaModel> | $Enums.BankAccountTransactionType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumBankAccountTransactionTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumBankAccountTransactionTypeFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedFloatNullableFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type DecimalWithAggregatesFilter<$PrismaModel = never> = {
|
||||
@@ -277,102 +216,17 @@ export type DecimalWithAggregatesFilter<$PrismaModel = never> = {
|
||||
_max?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumBankTransactionRefTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.BankTransactionRefType | Prisma.EnumBankTransactionRefTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.BankTransactionRefType[]
|
||||
notIn?: $Enums.BankTransactionRefType[]
|
||||
not?: Prisma.NestedEnumBankTransactionRefTypeWithAggregatesFilter<$PrismaModel> | $Enums.BankTransactionRefType
|
||||
export type BoolFilter<$PrismaModel = never> = {
|
||||
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBoolFilter<$PrismaModel> | boolean
|
||||
}
|
||||
|
||||
export type BoolWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBoolWithAggregatesFilter<$PrismaModel> | boolean
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumBankTransactionRefTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumBankTransactionRefTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumOrderStatusFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.OrderStatus | Prisma.EnumOrderStatusFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.OrderStatus[]
|
||||
notIn?: $Enums.OrderStatus[]
|
||||
not?: Prisma.NestedEnumOrderStatusFilter<$PrismaModel> | $Enums.OrderStatus
|
||||
}
|
||||
|
||||
export type IntNullableFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel> | null
|
||||
in?: number[] | null
|
||||
notIn?: number[] | null
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntNullableFilter<$PrismaModel> | number | null
|
||||
}
|
||||
|
||||
export type EnumOrderStatusWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.OrderStatus | Prisma.EnumOrderStatusFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.OrderStatus[]
|
||||
notIn?: $Enums.OrderStatus[]
|
||||
not?: Prisma.NestedEnumOrderStatusWithAggregatesFilter<$PrismaModel> | $Enums.OrderStatus
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumOrderStatusFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumOrderStatusFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type IntNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel> | null
|
||||
in?: number[] | null
|
||||
notIn?: number[] | null
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntNullableWithAggregatesFilter<$PrismaModel> | number | null
|
||||
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedFloatNullableFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type DecimalNullableFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel> | null
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[] | null
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[] | null
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalNullableFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
|
||||
}
|
||||
|
||||
export type DecimalNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel> | null
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[] | null
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[] | null
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalNullableWithAggregatesFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
|
||||
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedDecimalNullableFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedDecimalNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedDecimalNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedDecimalNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumPurchaseReceiptStatusFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PurchaseReceiptStatus | Prisma.EnumPurchaseReceiptStatusFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PurchaseReceiptStatus[]
|
||||
notIn?: $Enums.PurchaseReceiptStatus[]
|
||||
not?: Prisma.NestedEnumPurchaseReceiptStatusFilter<$PrismaModel> | $Enums.PurchaseReceiptStatus
|
||||
}
|
||||
|
||||
export type EnumPurchaseReceiptStatusWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PurchaseReceiptStatus | Prisma.EnumPurchaseReceiptStatusFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PurchaseReceiptStatus[]
|
||||
notIn?: $Enums.PurchaseReceiptStatus[]
|
||||
not?: Prisma.NestedEnumPurchaseReceiptStatusWithAggregatesFilter<$PrismaModel> | $Enums.PurchaseReceiptStatus
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumPurchaseReceiptStatusFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumPurchaseReceiptStatusFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedBoolFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedBoolFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumPaymentMethodTypeFilter<$PrismaModel = never> = {
|
||||
@@ -382,13 +236,6 @@ export type EnumPaymentMethodTypeFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedEnumPaymentMethodTypeFilter<$PrismaModel> | $Enums.PaymentMethodType
|
||||
}
|
||||
|
||||
export type EnumPaymentTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PaymentType | Prisma.EnumPaymentTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PaymentType[]
|
||||
notIn?: $Enums.PaymentType[]
|
||||
not?: Prisma.NestedEnumPaymentTypeFilter<$PrismaModel> | $Enums.PaymentType
|
||||
}
|
||||
|
||||
export type EnumPaymentMethodTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PaymentMethodType | Prisma.EnumPaymentMethodTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PaymentMethodType[]
|
||||
@@ -399,67 +246,6 @@ export type EnumPaymentMethodTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
_max?: Prisma.NestedEnumPaymentMethodTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumPaymentTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PaymentType | Prisma.EnumPaymentTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PaymentType[]
|
||||
notIn?: $Enums.PaymentType[]
|
||||
not?: Prisma.NestedEnumPaymentTypeWithAggregatesFilter<$PrismaModel> | $Enums.PaymentType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumPaymentTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumPaymentTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumMovementTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.MovementType | Prisma.EnumMovementTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.MovementType[]
|
||||
notIn?: $Enums.MovementType[]
|
||||
not?: Prisma.NestedEnumMovementTypeFilter<$PrismaModel> | $Enums.MovementType
|
||||
}
|
||||
|
||||
export type EnumMovementReferenceTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.MovementReferenceType | Prisma.EnumMovementReferenceTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.MovementReferenceType[]
|
||||
notIn?: $Enums.MovementReferenceType[]
|
||||
not?: Prisma.NestedEnumMovementReferenceTypeFilter<$PrismaModel> | $Enums.MovementReferenceType
|
||||
}
|
||||
|
||||
export type EnumMovementTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.MovementType | Prisma.EnumMovementTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.MovementType[]
|
||||
notIn?: $Enums.MovementType[]
|
||||
not?: Prisma.NestedEnumMovementTypeWithAggregatesFilter<$PrismaModel> | $Enums.MovementType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumMovementTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumMovementTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumMovementReferenceTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.MovementReferenceType | Prisma.EnumMovementReferenceTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.MovementReferenceType[]
|
||||
notIn?: $Enums.MovementReferenceType[]
|
||||
not?: Prisma.NestedEnumMovementReferenceTypeWithAggregatesFilter<$PrismaModel> | $Enums.MovementReferenceType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumMovementReferenceTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumMovementReferenceTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type EnumLedgerSourceTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.LedgerSourceType | Prisma.EnumLedgerSourceTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.LedgerSourceType[]
|
||||
notIn?: $Enums.LedgerSourceType[]
|
||||
not?: Prisma.NestedEnumLedgerSourceTypeFilter<$PrismaModel> | $Enums.LedgerSourceType
|
||||
}
|
||||
|
||||
export type EnumLedgerSourceTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.LedgerSourceType | Prisma.EnumLedgerSourceTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.LedgerSourceType[]
|
||||
notIn?: $Enums.LedgerSourceType[]
|
||||
not?: Prisma.NestedEnumLedgerSourceTypeWithAggregatesFilter<$PrismaModel> | $Enums.LedgerSourceType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumLedgerSourceTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumLedgerSourceTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedIntFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
in?: number[]
|
||||
@@ -486,6 +272,21 @@ export type NestedStringFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedStringFilter<$PrismaModel> | string
|
||||
}
|
||||
|
||||
export type NestedStringNullableFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel> | null
|
||||
in?: string[] | null
|
||||
notIn?: string[] | null
|
||||
lt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
lte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
startsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
endsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
search?: string
|
||||
not?: Prisma.NestedStringNullableFilter<$PrismaModel> | string | null
|
||||
}
|
||||
|
||||
export type NestedDateTimeFilter<$PrismaModel = never> = {
|
||||
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
|
||||
in?: Date[] | string[]
|
||||
@@ -508,6 +309,28 @@ export type NestedDateTimeNullableFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null
|
||||
}
|
||||
|
||||
export type NestedIntNullableFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel> | null
|
||||
in?: number[] | null
|
||||
notIn?: number[] | null
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntNullableFilter<$PrismaModel> | number | null
|
||||
}
|
||||
|
||||
export type NestedDecimalFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
}
|
||||
|
||||
export type NestedIntWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
in?: number[]
|
||||
@@ -553,6 +376,24 @@ export type NestedStringWithAggregatesFilter<$PrismaModel = never> = {
|
||||
_max?: Prisma.NestedStringFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedStringNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel> | null
|
||||
in?: string[] | null
|
||||
notIn?: string[] | null
|
||||
lt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
lte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
startsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
endsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
search?: string
|
||||
not?: Prisma.NestedStringNullableWithAggregatesFilter<$PrismaModel> | string | null
|
||||
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedStringNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedStringNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedDateTimeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: Date | string | Prisma.DateTimeFieldRefInput<$PrismaModel>
|
||||
in?: Date[] | string[]
|
||||
@@ -581,165 +422,6 @@ export type NestedDateTimeNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
_max?: Prisma.NestedDateTimeNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedIntNullableFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel> | null
|
||||
in?: number[] | null
|
||||
notIn?: number[] | null
|
||||
lt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
lte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gt?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
gte?: number | Prisma.IntFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedIntNullableFilter<$PrismaModel> | number | null
|
||||
}
|
||||
|
||||
export type NestedStringNullableFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel> | null
|
||||
in?: string[] | null
|
||||
notIn?: string[] | null
|
||||
lt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
lte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
startsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
endsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
search?: string
|
||||
not?: Prisma.NestedStringNullableFilter<$PrismaModel> | string | null
|
||||
}
|
||||
|
||||
export type NestedStringNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: string | Prisma.StringFieldRefInput<$PrismaModel> | null
|
||||
in?: string[] | null
|
||||
notIn?: string[] | null
|
||||
lt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
lte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gt?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
gte?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
startsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
endsWith?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
search?: string
|
||||
not?: Prisma.NestedStringNullableWithAggregatesFilter<$PrismaModel> | string | null
|
||||
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedStringNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedStringNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedJsonNullableFilter<$PrismaModel = never> =
|
||||
| Prisma.PatchUndefined<
|
||||
Prisma.Either<Required<NestedJsonNullableFilterBase<$PrismaModel>>, Exclude<keyof Required<NestedJsonNullableFilterBase<$PrismaModel>>, 'path'>>,
|
||||
Required<NestedJsonNullableFilterBase<$PrismaModel>>
|
||||
>
|
||||
| Prisma.OptionalFlat<Omit<Required<NestedJsonNullableFilterBase<$PrismaModel>>, 'path'>>
|
||||
|
||||
export type NestedJsonNullableFilterBase<$PrismaModel = never> = {
|
||||
equals?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | Prisma.JsonNullValueFilter
|
||||
path?: string
|
||||
mode?: Prisma.QueryMode | Prisma.EnumQueryModeFieldRefInput<$PrismaModel>
|
||||
string_contains?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
string_starts_with?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
string_ends_with?: string | Prisma.StringFieldRefInput<$PrismaModel>
|
||||
array_starts_with?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
array_ends_with?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
array_contains?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | null
|
||||
lt?: runtime.InputJsonValue
|
||||
lte?: runtime.InputJsonValue
|
||||
gt?: runtime.InputJsonValue
|
||||
gte?: runtime.InputJsonValue
|
||||
not?: runtime.InputJsonValue | Prisma.JsonFieldRefInput<$PrismaModel> | Prisma.JsonNullValueFilter
|
||||
}
|
||||
|
||||
export type NestedBoolFilter<$PrismaModel = never> = {
|
||||
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBoolFilter<$PrismaModel> | boolean
|
||||
}
|
||||
|
||||
export type NestedBoolWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBoolWithAggregatesFilter<$PrismaModel> | boolean
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedBoolFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedBoolFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumBankAccountTransactionTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.BankAccountTransactionType | Prisma.EnumBankAccountTransactionTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.BankAccountTransactionType[]
|
||||
notIn?: $Enums.BankAccountTransactionType[]
|
||||
not?: Prisma.NestedEnumBankAccountTransactionTypeFilter<$PrismaModel> | $Enums.BankAccountTransactionType
|
||||
}
|
||||
|
||||
export type NestedDecimalFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
}
|
||||
|
||||
export type NestedEnumBankTransactionRefTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.BankTransactionRefType | Prisma.EnumBankTransactionRefTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.BankTransactionRefType[]
|
||||
notIn?: $Enums.BankTransactionRefType[]
|
||||
not?: Prisma.NestedEnumBankTransactionRefTypeFilter<$PrismaModel> | $Enums.BankTransactionRefType
|
||||
}
|
||||
|
||||
export type NestedEnumBankAccountTransactionTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.BankAccountTransactionType | Prisma.EnumBankAccountTransactionTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.BankAccountTransactionType[]
|
||||
notIn?: $Enums.BankAccountTransactionType[]
|
||||
not?: Prisma.NestedEnumBankAccountTransactionTypeWithAggregatesFilter<$PrismaModel> | $Enums.BankAccountTransactionType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumBankAccountTransactionTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumBankAccountTransactionTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedDecimalWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalWithAggregatesFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumBankTransactionRefTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.BankTransactionRefType | Prisma.EnumBankTransactionRefTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.BankTransactionRefType[]
|
||||
notIn?: $Enums.BankTransactionRefType[]
|
||||
not?: Prisma.NestedEnumBankTransactionRefTypeWithAggregatesFilter<$PrismaModel> | $Enums.BankTransactionRefType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumBankTransactionRefTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumBankTransactionRefTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumOrderStatusFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.OrderStatus | Prisma.EnumOrderStatusFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.OrderStatus[]
|
||||
notIn?: $Enums.OrderStatus[]
|
||||
not?: Prisma.NestedEnumOrderStatusFilter<$PrismaModel> | $Enums.OrderStatus
|
||||
}
|
||||
|
||||
export type NestedEnumOrderStatusWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.OrderStatus | Prisma.EnumOrderStatusFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.OrderStatus[]
|
||||
notIn?: $Enums.OrderStatus[]
|
||||
not?: Prisma.NestedEnumOrderStatusWithAggregatesFilter<$PrismaModel> | $Enums.OrderStatus
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumOrderStatusFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumOrderStatusFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedIntNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: number | Prisma.IntFieldRefInput<$PrismaModel> | null
|
||||
in?: number[] | null
|
||||
@@ -767,48 +449,33 @@ export type NestedFloatNullableFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedFloatNullableFilter<$PrismaModel> | number | null
|
||||
}
|
||||
|
||||
export type NestedDecimalNullableFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel> | null
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[] | null
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[] | null
|
||||
export type NestedDecimalWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[]
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalNullableFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
|
||||
}
|
||||
|
||||
export type NestedDecimalNullableWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel> | null
|
||||
in?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[] | null
|
||||
notIn?: runtime.Decimal[] | runtime.DecimalJsLike[] | number[] | string[] | null
|
||||
lt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
lte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gt?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
gte?: runtime.Decimal | runtime.DecimalJsLike | number | string | Prisma.DecimalFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedDecimalNullableWithAggregatesFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
|
||||
_count?: Prisma.NestedIntNullableFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedDecimalNullableFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedDecimalNullableFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedDecimalNullableFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedDecimalNullableFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumPurchaseReceiptStatusFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PurchaseReceiptStatus | Prisma.EnumPurchaseReceiptStatusFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PurchaseReceiptStatus[]
|
||||
notIn?: $Enums.PurchaseReceiptStatus[]
|
||||
not?: Prisma.NestedEnumPurchaseReceiptStatusFilter<$PrismaModel> | $Enums.PurchaseReceiptStatus
|
||||
}
|
||||
|
||||
export type NestedEnumPurchaseReceiptStatusWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PurchaseReceiptStatus | Prisma.EnumPurchaseReceiptStatusFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PurchaseReceiptStatus[]
|
||||
notIn?: $Enums.PurchaseReceiptStatus[]
|
||||
not?: Prisma.NestedEnumPurchaseReceiptStatusWithAggregatesFilter<$PrismaModel> | $Enums.PurchaseReceiptStatus
|
||||
not?: Prisma.NestedDecimalWithAggregatesFilter<$PrismaModel> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumPurchaseReceiptStatusFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumPurchaseReceiptStatusFilter<$PrismaModel>
|
||||
_avg?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
_sum?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedDecimalFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedBoolFilter<$PrismaModel = never> = {
|
||||
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBoolFilter<$PrismaModel> | boolean
|
||||
}
|
||||
|
||||
export type NestedBoolWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: boolean | Prisma.BooleanFieldRefInput<$PrismaModel>
|
||||
not?: Prisma.NestedBoolWithAggregatesFilter<$PrismaModel> | boolean
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedBoolFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedBoolFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumPaymentMethodTypeFilter<$PrismaModel = never> = {
|
||||
@@ -818,13 +485,6 @@ export type NestedEnumPaymentMethodTypeFilter<$PrismaModel = never> = {
|
||||
not?: Prisma.NestedEnumPaymentMethodTypeFilter<$PrismaModel> | $Enums.PaymentMethodType
|
||||
}
|
||||
|
||||
export type NestedEnumPaymentTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PaymentType | Prisma.EnumPaymentTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PaymentType[]
|
||||
notIn?: $Enums.PaymentType[]
|
||||
not?: Prisma.NestedEnumPaymentTypeFilter<$PrismaModel> | $Enums.PaymentType
|
||||
}
|
||||
|
||||
export type NestedEnumPaymentMethodTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PaymentMethodType | Prisma.EnumPaymentMethodTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PaymentMethodType[]
|
||||
@@ -835,65 +495,4 @@ export type NestedEnumPaymentMethodTypeWithAggregatesFilter<$PrismaModel = never
|
||||
_max?: Prisma.NestedEnumPaymentMethodTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumPaymentTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.PaymentType | Prisma.EnumPaymentTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.PaymentType[]
|
||||
notIn?: $Enums.PaymentType[]
|
||||
not?: Prisma.NestedEnumPaymentTypeWithAggregatesFilter<$PrismaModel> | $Enums.PaymentType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumPaymentTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumPaymentTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumMovementTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.MovementType | Prisma.EnumMovementTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.MovementType[]
|
||||
notIn?: $Enums.MovementType[]
|
||||
not?: Prisma.NestedEnumMovementTypeFilter<$PrismaModel> | $Enums.MovementType
|
||||
}
|
||||
|
||||
export type NestedEnumMovementReferenceTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.MovementReferenceType | Prisma.EnumMovementReferenceTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.MovementReferenceType[]
|
||||
notIn?: $Enums.MovementReferenceType[]
|
||||
not?: Prisma.NestedEnumMovementReferenceTypeFilter<$PrismaModel> | $Enums.MovementReferenceType
|
||||
}
|
||||
|
||||
export type NestedEnumMovementTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.MovementType | Prisma.EnumMovementTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.MovementType[]
|
||||
notIn?: $Enums.MovementType[]
|
||||
not?: Prisma.NestedEnumMovementTypeWithAggregatesFilter<$PrismaModel> | $Enums.MovementType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumMovementTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumMovementTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumMovementReferenceTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.MovementReferenceType | Prisma.EnumMovementReferenceTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.MovementReferenceType[]
|
||||
notIn?: $Enums.MovementReferenceType[]
|
||||
not?: Prisma.NestedEnumMovementReferenceTypeWithAggregatesFilter<$PrismaModel> | $Enums.MovementReferenceType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumMovementReferenceTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumMovementReferenceTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
export type NestedEnumLedgerSourceTypeFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.LedgerSourceType | Prisma.EnumLedgerSourceTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.LedgerSourceType[]
|
||||
notIn?: $Enums.LedgerSourceType[]
|
||||
not?: Prisma.NestedEnumLedgerSourceTypeFilter<$PrismaModel> | $Enums.LedgerSourceType
|
||||
}
|
||||
|
||||
export type NestedEnumLedgerSourceTypeWithAggregatesFilter<$PrismaModel = never> = {
|
||||
equals?: $Enums.LedgerSourceType | Prisma.EnumLedgerSourceTypeFieldRefInput<$PrismaModel>
|
||||
in?: $Enums.LedgerSourceType[]
|
||||
notIn?: $Enums.LedgerSourceType[]
|
||||
not?: Prisma.NestedEnumLedgerSourceTypeWithAggregatesFilter<$PrismaModel> | $Enums.LedgerSourceType
|
||||
_count?: Prisma.NestedIntFilter<$PrismaModel>
|
||||
_min?: Prisma.NestedEnumLedgerSourceTypeFilter<$PrismaModel>
|
||||
_max?: Prisma.NestedEnumLedgerSourceTypeFilter<$PrismaModel>
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -9,35 +9,6 @@
|
||||
* 🟢 You can import this file directly.
|
||||
*/
|
||||
|
||||
export const OrderStatus = {
|
||||
PENDING: 'PENDING',
|
||||
REJECTED: 'REJECTED',
|
||||
CANCELED: 'CANCELED',
|
||||
DONE: 'DONE'
|
||||
} as const
|
||||
|
||||
export type OrderStatus = (typeof OrderStatus)[keyof typeof OrderStatus]
|
||||
|
||||
|
||||
export const MovementType = {
|
||||
IN: 'IN',
|
||||
OUT: 'OUT',
|
||||
ADJUST: 'ADJUST'
|
||||
} as const
|
||||
|
||||
export type MovementType = (typeof MovementType)[keyof typeof MovementType]
|
||||
|
||||
|
||||
export const MovementReferenceType = {
|
||||
PURCHASE: 'PURCHASE',
|
||||
SALES: 'SALES',
|
||||
ADJUSTMENT: 'ADJUSTMENT',
|
||||
INVENTORY_TRANSFER: 'INVENTORY_TRANSFER'
|
||||
} as const
|
||||
|
||||
export type MovementReferenceType = (typeof MovementReferenceType)[keyof typeof MovementReferenceType]
|
||||
|
||||
|
||||
export const PaymentMethodType = {
|
||||
CASH: 'CASH',
|
||||
CARD: 'CARD',
|
||||
@@ -49,24 +20,6 @@ export const PaymentMethodType = {
|
||||
export type PaymentMethodType = (typeof PaymentMethodType)[keyof typeof PaymentMethodType]
|
||||
|
||||
|
||||
export const LedgerSourceType = {
|
||||
PURCHASE: 'PURCHASE',
|
||||
PAYMENT: 'PAYMENT',
|
||||
ADJUSTMENT: 'ADJUSTMENT',
|
||||
REFUND: 'REFUND'
|
||||
} as const
|
||||
|
||||
export type LedgerSourceType = (typeof LedgerSourceType)[keyof typeof LedgerSourceType]
|
||||
|
||||
|
||||
export const PaymentType = {
|
||||
PAYMENT: 'PAYMENT',
|
||||
REFUND: 'REFUND'
|
||||
} as const
|
||||
|
||||
export type PaymentType = (typeof PaymentType)[keyof typeof PaymentType]
|
||||
|
||||
|
||||
export const PurchaseReceiptStatus = {
|
||||
UNPAID: 'UNPAID',
|
||||
PARTIALLY_PAID: 'PARTIALLY_PAID',
|
||||
@@ -74,23 +27,3 @@ export const PurchaseReceiptStatus = {
|
||||
} as const
|
||||
|
||||
export type PurchaseReceiptStatus = (typeof PurchaseReceiptStatus)[keyof typeof PurchaseReceiptStatus]
|
||||
|
||||
|
||||
export const BankAccountTransactionType = {
|
||||
DEPOSIT: 'DEPOSIT',
|
||||
WITHDRAWAL: 'WITHDRAWAL'
|
||||
} as const
|
||||
|
||||
export type BankAccountTransactionType = (typeof BankAccountTransactionType)[keyof typeof BankAccountTransactionType]
|
||||
|
||||
|
||||
export const BankTransactionRefType = {
|
||||
PURCHASE_PAYMENT: 'PURCHASE_PAYMENT',
|
||||
PURCHASE_REFUND: 'PURCHASE_REFUND',
|
||||
POS_SALE: 'POS_SALE',
|
||||
POS_REFUND: 'POS_REFUND',
|
||||
BANK_TRANSFER: 'BANK_TRANSFER',
|
||||
MANUAL_ADJUSTMENT: 'MANUAL_ADJUSTMENT'
|
||||
} as const
|
||||
|
||||
export type BankTransactionRefType = (typeof BankTransactionRefType)[keyof typeof BankTransactionRefType]
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@@ -51,40 +51,15 @@ export const AnyNull = runtime.AnyNull
|
||||
|
||||
|
||||
export const ModelName = {
|
||||
User: 'User',
|
||||
Role: 'Role',
|
||||
OtpCode: 'OtpCode',
|
||||
RefreshToken: 'RefreshToken',
|
||||
BankBranch: 'BankBranch',
|
||||
BankAccount: 'BankAccount',
|
||||
BankAccountTransaction: 'BankAccountTransaction',
|
||||
Inventory: 'Inventory',
|
||||
InventoryBankAccount: 'InventoryBankAccount',
|
||||
PosAccount: 'PosAccount',
|
||||
InventoryTransfer: 'InventoryTransfer',
|
||||
InventoryTransferItem: 'InventoryTransferItem',
|
||||
Bank: 'Bank',
|
||||
Order: 'Order',
|
||||
OrderItem: 'OrderItem',
|
||||
Good: 'Good',
|
||||
GoodCategory: 'GoodCategory',
|
||||
Customer: 'Customer',
|
||||
TriggerLog: 'TriggerLog',
|
||||
ProductVariant: 'ProductVariant',
|
||||
Product: 'Product',
|
||||
ProductBrand: 'ProductBrand',
|
||||
ProductCategory: 'ProductCategory',
|
||||
PurchaseReceipt: 'PurchaseReceipt',
|
||||
PurchaseReceiptItem: 'PurchaseReceiptItem',
|
||||
PurchaseReceiptPayments: 'PurchaseReceiptPayments',
|
||||
SalesInvoice: 'SalesInvoice',
|
||||
SalesInvoiceItem: 'SalesInvoiceItem',
|
||||
SalesInvoicePayment: 'SalesInvoicePayment',
|
||||
StockMovement: 'StockMovement',
|
||||
StockBalance: 'StockBalance',
|
||||
StockAdjustment: 'StockAdjustment',
|
||||
StockReservation: 'StockReservation',
|
||||
Supplier: 'Supplier',
|
||||
SupplierLedger: 'SupplierLedger',
|
||||
StockAvailableView: 'StockAvailableView'
|
||||
Service: 'Service',
|
||||
ServiceCategory: 'ServiceCategory'
|
||||
} as const
|
||||
|
||||
export type ModelName = (typeof ModelName)[keyof typeof ModelName]
|
||||
@@ -103,200 +78,34 @@ export const TransactionIsolationLevel = {
|
||||
export type TransactionIsolationLevel = (typeof TransactionIsolationLevel)[keyof typeof TransactionIsolationLevel]
|
||||
|
||||
|
||||
export const UserScalarFieldEnum = {
|
||||
id: 'id',
|
||||
mobileNumber: 'mobileNumber',
|
||||
password: 'password',
|
||||
firstName: 'firstName',
|
||||
lastName: 'lastName',
|
||||
roleId: 'roleId',
|
||||
createdAt: 'createdAt',
|
||||
deletedAt: 'deletedAt',
|
||||
updatedAt: 'updatedAt'
|
||||
} as const
|
||||
|
||||
export type UserScalarFieldEnum = (typeof UserScalarFieldEnum)[keyof typeof UserScalarFieldEnum]
|
||||
|
||||
|
||||
export const RoleScalarFieldEnum = {
|
||||
export const GoodScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
permissions: 'permissions',
|
||||
sku: 'sku',
|
||||
localSku: 'localSku',
|
||||
barcode: 'barcode',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt',
|
||||
categoryId: 'categoryId',
|
||||
baseSalePrice: 'baseSalePrice'
|
||||
} as const
|
||||
|
||||
export type GoodScalarFieldEnum = (typeof GoodScalarFieldEnum)[keyof typeof GoodScalarFieldEnum]
|
||||
|
||||
|
||||
export const GoodCategoryScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
imageUrl: 'imageUrl',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt'
|
||||
} as const
|
||||
|
||||
export type RoleScalarFieldEnum = (typeof RoleScalarFieldEnum)[keyof typeof RoleScalarFieldEnum]
|
||||
|
||||
|
||||
export const OtpCodeScalarFieldEnum = {
|
||||
id: 'id',
|
||||
mobileNumber: 'mobileNumber',
|
||||
code: 'code',
|
||||
used: 'used',
|
||||
expiresAt: 'expiresAt',
|
||||
createdAt: 'createdAt'
|
||||
} as const
|
||||
|
||||
export type OtpCodeScalarFieldEnum = (typeof OtpCodeScalarFieldEnum)[keyof typeof OtpCodeScalarFieldEnum]
|
||||
|
||||
|
||||
export const RefreshTokenScalarFieldEnum = {
|
||||
id: 'id',
|
||||
tokenHash: 'tokenHash',
|
||||
userId: 'userId',
|
||||
revoked: 'revoked',
|
||||
expiresAt: 'expiresAt',
|
||||
createdAt: 'createdAt'
|
||||
} as const
|
||||
|
||||
export type RefreshTokenScalarFieldEnum = (typeof RefreshTokenScalarFieldEnum)[keyof typeof RefreshTokenScalarFieldEnum]
|
||||
|
||||
|
||||
export const BankBranchScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
code: 'code',
|
||||
address: 'address',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt',
|
||||
bankId: 'bankId'
|
||||
} as const
|
||||
|
||||
export type BankBranchScalarFieldEnum = (typeof BankBranchScalarFieldEnum)[keyof typeof BankBranchScalarFieldEnum]
|
||||
|
||||
|
||||
export const BankAccountScalarFieldEnum = {
|
||||
id: 'id',
|
||||
accountNumber: 'accountNumber',
|
||||
cardNumber: 'cardNumber',
|
||||
name: 'name',
|
||||
iban: 'iban',
|
||||
branchId: 'branchId',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt'
|
||||
} as const
|
||||
|
||||
export type BankAccountScalarFieldEnum = (typeof BankAccountScalarFieldEnum)[keyof typeof BankAccountScalarFieldEnum]
|
||||
|
||||
|
||||
export const BankAccountTransactionScalarFieldEnum = {
|
||||
id: 'id',
|
||||
bankAccountId: 'bankAccountId',
|
||||
type: 'type',
|
||||
amount: 'amount',
|
||||
balanceAfter: 'balanceAfter',
|
||||
referenceId: 'referenceId',
|
||||
referenceType: 'referenceType',
|
||||
description: 'description',
|
||||
createdAt: 'createdAt'
|
||||
} as const
|
||||
|
||||
export type BankAccountTransactionScalarFieldEnum = (typeof BankAccountTransactionScalarFieldEnum)[keyof typeof BankAccountTransactionScalarFieldEnum]
|
||||
|
||||
|
||||
export const InventoryScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
location: 'location',
|
||||
isActive: 'isActive',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt',
|
||||
isPointOfSale: 'isPointOfSale'
|
||||
} as const
|
||||
|
||||
export type InventoryScalarFieldEnum = (typeof InventoryScalarFieldEnum)[keyof typeof InventoryScalarFieldEnum]
|
||||
|
||||
|
||||
export const InventoryBankAccountScalarFieldEnum = {
|
||||
inventoryId: 'inventoryId',
|
||||
bankAccountId: 'bankAccountId'
|
||||
} as const
|
||||
|
||||
export type InventoryBankAccountScalarFieldEnum = (typeof InventoryBankAccountScalarFieldEnum)[keyof typeof InventoryBankAccountScalarFieldEnum]
|
||||
|
||||
|
||||
export const PosAccountScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
code: 'code',
|
||||
description: 'description',
|
||||
bankAccountId: 'bankAccountId',
|
||||
inventoryId: 'inventoryId',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt'
|
||||
} as const
|
||||
|
||||
export type PosAccountScalarFieldEnum = (typeof PosAccountScalarFieldEnum)[keyof typeof PosAccountScalarFieldEnum]
|
||||
|
||||
|
||||
export const InventoryTransferScalarFieldEnum = {
|
||||
id: 'id',
|
||||
code: 'code',
|
||||
description: 'description',
|
||||
createdAt: 'createdAt',
|
||||
fromInventoryId: 'fromInventoryId',
|
||||
toInventoryId: 'toInventoryId'
|
||||
} as const
|
||||
|
||||
export type InventoryTransferScalarFieldEnum = (typeof InventoryTransferScalarFieldEnum)[keyof typeof InventoryTransferScalarFieldEnum]
|
||||
|
||||
|
||||
export const InventoryTransferItemScalarFieldEnum = {
|
||||
id: 'id',
|
||||
count: 'count',
|
||||
productId: 'productId',
|
||||
transferId: 'transferId'
|
||||
} as const
|
||||
|
||||
export type InventoryTransferItemScalarFieldEnum = (typeof InventoryTransferItemScalarFieldEnum)[keyof typeof InventoryTransferItemScalarFieldEnum]
|
||||
|
||||
|
||||
export const BankScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
shortName: 'shortName',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt'
|
||||
} as const
|
||||
|
||||
export type BankScalarFieldEnum = (typeof BankScalarFieldEnum)[keyof typeof BankScalarFieldEnum]
|
||||
|
||||
|
||||
export const OrderScalarFieldEnum = {
|
||||
id: 'id',
|
||||
orderNumber: 'orderNumber',
|
||||
status: 'status',
|
||||
totalAmount: 'totalAmount',
|
||||
description: 'description',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt',
|
||||
customerId: 'customerId',
|
||||
posAccountId: 'posAccountId'
|
||||
} as const
|
||||
|
||||
export type OrderScalarFieldEnum = (typeof OrderScalarFieldEnum)[keyof typeof OrderScalarFieldEnum]
|
||||
|
||||
|
||||
export const OrderItemScalarFieldEnum = {
|
||||
id: 'id',
|
||||
quantity: 'quantity',
|
||||
unitPrice: 'unitPrice',
|
||||
totalAmount: 'totalAmount',
|
||||
createdAt: 'createdAt',
|
||||
orderId: 'orderId',
|
||||
productId: 'productId'
|
||||
} as const
|
||||
|
||||
export type OrderItemScalarFieldEnum = (typeof OrderItemScalarFieldEnum)[keyof typeof OrderItemScalarFieldEnum]
|
||||
export type GoodCategoryScalarFieldEnum = (typeof GoodCategoryScalarFieldEnum)[keyof typeof GoodCategoryScalarFieldEnum]
|
||||
|
||||
|
||||
export const CustomerScalarFieldEnum = {
|
||||
@@ -306,9 +115,6 @@ export const CustomerScalarFieldEnum = {
|
||||
email: 'email',
|
||||
mobileNumber: 'mobileNumber',
|
||||
address: 'address',
|
||||
city: 'city',
|
||||
state: 'state',
|
||||
country: 'country',
|
||||
isActive: 'isActive',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
@@ -328,119 +134,6 @@ export const TriggerLogScalarFieldEnum = {
|
||||
export type TriggerLogScalarFieldEnum = (typeof TriggerLogScalarFieldEnum)[keyof typeof TriggerLogScalarFieldEnum]
|
||||
|
||||
|
||||
export const ProductVariantScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
basePrice: 'basePrice',
|
||||
salePrice: 'salePrice',
|
||||
description: 'description',
|
||||
barcode: 'barcode',
|
||||
imageUrl: 'imageUrl',
|
||||
unit: 'unit',
|
||||
quantity: 'quantity',
|
||||
alertQuantity: 'alertQuantity',
|
||||
isActive: 'isActive',
|
||||
isFeatured: 'isFeatured',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt',
|
||||
productId: 'productId'
|
||||
} as const
|
||||
|
||||
export type ProductVariantScalarFieldEnum = (typeof ProductVariantScalarFieldEnum)[keyof typeof ProductVariantScalarFieldEnum]
|
||||
|
||||
|
||||
export const ProductScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
sku: 'sku',
|
||||
barcode: 'barcode',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt',
|
||||
brandId: 'brandId',
|
||||
categoryId: 'categoryId',
|
||||
salePrice: 'salePrice',
|
||||
minimumStockAlertLevel: 'minimumStockAlertLevel'
|
||||
} as const
|
||||
|
||||
export type ProductScalarFieldEnum = (typeof ProductScalarFieldEnum)[keyof typeof ProductScalarFieldEnum]
|
||||
|
||||
|
||||
export const ProductBrandScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
imageUrl: 'imageUrl',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt'
|
||||
} as const
|
||||
|
||||
export type ProductBrandScalarFieldEnum = (typeof ProductBrandScalarFieldEnum)[keyof typeof ProductBrandScalarFieldEnum]
|
||||
|
||||
|
||||
export const ProductCategoryScalarFieldEnum = {
|
||||
id: 'id',
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
imageUrl: 'imageUrl',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt'
|
||||
} as const
|
||||
|
||||
export type ProductCategoryScalarFieldEnum = (typeof ProductCategoryScalarFieldEnum)[keyof typeof ProductCategoryScalarFieldEnum]
|
||||
|
||||
|
||||
export const PurchaseReceiptScalarFieldEnum = {
|
||||
id: 'id',
|
||||
code: 'code',
|
||||
totalAmount: 'totalAmount',
|
||||
paidAmount: 'paidAmount',
|
||||
description: 'description',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
status: 'status',
|
||||
supplierId: 'supplierId',
|
||||
inventoryId: 'inventoryId'
|
||||
} as const
|
||||
|
||||
export type PurchaseReceiptScalarFieldEnum = (typeof PurchaseReceiptScalarFieldEnum)[keyof typeof PurchaseReceiptScalarFieldEnum]
|
||||
|
||||
|
||||
export const PurchaseReceiptItemScalarFieldEnum = {
|
||||
id: 'id',
|
||||
count: 'count',
|
||||
unitPrice: 'unitPrice',
|
||||
totalAmount: 'totalAmount',
|
||||
receiptId: 'receiptId',
|
||||
productId: 'productId',
|
||||
description: 'description',
|
||||
createdAt: 'createdAt'
|
||||
} as const
|
||||
|
||||
export type PurchaseReceiptItemScalarFieldEnum = (typeof PurchaseReceiptItemScalarFieldEnum)[keyof typeof PurchaseReceiptItemScalarFieldEnum]
|
||||
|
||||
|
||||
export const PurchaseReceiptPaymentsScalarFieldEnum = {
|
||||
id: 'id',
|
||||
amount: 'amount',
|
||||
paymentMethod: 'paymentMethod',
|
||||
type: 'type',
|
||||
bankAccountId: 'bankAccountId',
|
||||
receiptId: 'receiptId',
|
||||
payedAt: 'payedAt',
|
||||
description: 'description',
|
||||
createdAt: 'createdAt',
|
||||
inventoryBankAccountInventoryId: 'inventoryBankAccountInventoryId',
|
||||
inventoryBankAccountBankAccountId: 'inventoryBankAccountBankAccountId'
|
||||
} as const
|
||||
|
||||
export type PurchaseReceiptPaymentsScalarFieldEnum = (typeof PurchaseReceiptPaymentsScalarFieldEnum)[keyof typeof PurchaseReceiptPaymentsScalarFieldEnum]
|
||||
|
||||
|
||||
export const SalesInvoiceScalarFieldEnum = {
|
||||
id: 'id',
|
||||
code: 'code',
|
||||
@@ -448,8 +141,7 @@ export const SalesInvoiceScalarFieldEnum = {
|
||||
description: 'description',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
customerId: 'customerId',
|
||||
posAccountId: 'posAccountId'
|
||||
customerId: 'customerId'
|
||||
} as const
|
||||
|
||||
export type SalesInvoiceScalarFieldEnum = (typeof SalesInvoiceScalarFieldEnum)[keyof typeof SalesInvoiceScalarFieldEnum]
|
||||
@@ -462,7 +154,8 @@ export const SalesInvoiceItemScalarFieldEnum = {
|
||||
totalAmount: 'totalAmount',
|
||||
createdAt: 'createdAt',
|
||||
invoiceId: 'invoiceId',
|
||||
productId: 'productId'
|
||||
goodId: 'goodId',
|
||||
serviceId: 'serviceId'
|
||||
} as const
|
||||
|
||||
export type SalesInvoiceItemScalarFieldEnum = (typeof SalesInvoiceItemScalarFieldEnum)[keyof typeof SalesInvoiceItemScalarFieldEnum]
|
||||
@@ -480,107 +173,33 @@ export const SalesInvoicePaymentScalarFieldEnum = {
|
||||
export type SalesInvoicePaymentScalarFieldEnum = (typeof SalesInvoicePaymentScalarFieldEnum)[keyof typeof SalesInvoicePaymentScalarFieldEnum]
|
||||
|
||||
|
||||
export const StockMovementScalarFieldEnum = {
|
||||
export const ServiceScalarFieldEnum = {
|
||||
id: 'id',
|
||||
type: 'type',
|
||||
quantity: 'quantity',
|
||||
unitPrice: 'unitPrice',
|
||||
totalCost: 'totalCost',
|
||||
referenceType: 'referenceType',
|
||||
referenceId: 'referenceId',
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
sku: 'sku',
|
||||
barcode: 'barcode',
|
||||
createdAt: 'createdAt',
|
||||
productId: 'productId',
|
||||
inventoryId: 'inventoryId',
|
||||
avgCost: 'avgCost',
|
||||
supplierId: 'supplierId',
|
||||
remainedInStock: 'remainedInStock',
|
||||
counterInventoryId: 'counterInventoryId',
|
||||
customerId: 'customerId'
|
||||
} as const
|
||||
|
||||
export type StockMovementScalarFieldEnum = (typeof StockMovementScalarFieldEnum)[keyof typeof StockMovementScalarFieldEnum]
|
||||
|
||||
|
||||
export const StockBalanceScalarFieldEnum = {
|
||||
quantity: 'quantity',
|
||||
totalCost: 'totalCost',
|
||||
updatedAt: 'updatedAt',
|
||||
avgCost: 'avgCost',
|
||||
inventoryId: 'inventoryId',
|
||||
productId: 'productId',
|
||||
createdAt: 'createdAt',
|
||||
id: 'id'
|
||||
deletedAt: 'deletedAt',
|
||||
categoryId: 'categoryId',
|
||||
baseSalePrice: 'baseSalePrice'
|
||||
} as const
|
||||
|
||||
export type StockBalanceScalarFieldEnum = (typeof StockBalanceScalarFieldEnum)[keyof typeof StockBalanceScalarFieldEnum]
|
||||
export type ServiceScalarFieldEnum = (typeof ServiceScalarFieldEnum)[keyof typeof ServiceScalarFieldEnum]
|
||||
|
||||
|
||||
export const StockAdjustmentScalarFieldEnum = {
|
||||
export const ServiceCategoryScalarFieldEnum = {
|
||||
id: 'id',
|
||||
adjustedQuantity: 'adjustedQuantity',
|
||||
createdAt: 'createdAt',
|
||||
productId: 'productId',
|
||||
inventoryId: 'inventoryId'
|
||||
} as const
|
||||
|
||||
export type StockAdjustmentScalarFieldEnum = (typeof StockAdjustmentScalarFieldEnum)[keyof typeof StockAdjustmentScalarFieldEnum]
|
||||
|
||||
|
||||
export const StockReservationScalarFieldEnum = {
|
||||
id: 'id',
|
||||
quantity: 'quantity',
|
||||
createdAt: 'createdAt',
|
||||
productId: 'productId',
|
||||
inventoryId: 'inventoryId',
|
||||
orderId: 'orderId'
|
||||
} as const
|
||||
|
||||
export type StockReservationScalarFieldEnum = (typeof StockReservationScalarFieldEnum)[keyof typeof StockReservationScalarFieldEnum]
|
||||
|
||||
|
||||
export const SupplierScalarFieldEnum = {
|
||||
id: 'id',
|
||||
firstName: 'firstName',
|
||||
lastName: 'lastName',
|
||||
email: 'email',
|
||||
mobileNumber: 'mobileNumber',
|
||||
address: 'address',
|
||||
city: 'city',
|
||||
state: 'state',
|
||||
country: 'country',
|
||||
isActive: 'isActive',
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
imageUrl: 'imageUrl',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt',
|
||||
deletedAt: 'deletedAt'
|
||||
} as const
|
||||
|
||||
export type SupplierScalarFieldEnum = (typeof SupplierScalarFieldEnum)[keyof typeof SupplierScalarFieldEnum]
|
||||
|
||||
|
||||
export const SupplierLedgerScalarFieldEnum = {
|
||||
id: 'id',
|
||||
description: 'description',
|
||||
debit: 'debit',
|
||||
credit: 'credit',
|
||||
balance: 'balance',
|
||||
sourceType: 'sourceType',
|
||||
sourceId: 'sourceId',
|
||||
createdAt: 'createdAt',
|
||||
supplierId: 'supplierId'
|
||||
} as const
|
||||
|
||||
export type SupplierLedgerScalarFieldEnum = (typeof SupplierLedgerScalarFieldEnum)[keyof typeof SupplierLedgerScalarFieldEnum]
|
||||
|
||||
|
||||
export const StockAvailableViewScalarFieldEnum = {
|
||||
productId: 'productId',
|
||||
inventoryId: 'inventoryId',
|
||||
physicalQuantity: 'physicalQuantity',
|
||||
reservedQuantity: 'reservedQuantity',
|
||||
availableQuantity: 'availableQuantity'
|
||||
} as const
|
||||
|
||||
export type StockAvailableViewScalarFieldEnum = (typeof StockAvailableViewScalarFieldEnum)[keyof typeof StockAvailableViewScalarFieldEnum]
|
||||
export type ServiceCategoryScalarFieldEnum = (typeof ServiceCategoryScalarFieldEnum)[keyof typeof ServiceCategoryScalarFieldEnum]
|
||||
|
||||
|
||||
export const SortOrder = {
|
||||
@@ -591,14 +210,6 @@ export const SortOrder = {
|
||||
export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder]
|
||||
|
||||
|
||||
export const NullableJsonNullValueInput = {
|
||||
DbNull: 'DbNull',
|
||||
JsonNull: 'JsonNull'
|
||||
} as const
|
||||
|
||||
export type NullableJsonNullValueInput = (typeof NullableJsonNullValueInput)[keyof typeof NullableJsonNullValueInput]
|
||||
|
||||
|
||||
export const NullsOrder = {
|
||||
first: 'first',
|
||||
last: 'last'
|
||||
@@ -607,121 +218,24 @@ export const NullsOrder = {
|
||||
export type NullsOrder = (typeof NullsOrder)[keyof typeof NullsOrder]
|
||||
|
||||
|
||||
export const UserOrderByRelevanceFieldEnum = {
|
||||
mobileNumber: 'mobileNumber',
|
||||
password: 'password',
|
||||
firstName: 'firstName',
|
||||
lastName: 'lastName'
|
||||
} as const
|
||||
|
||||
export type UserOrderByRelevanceFieldEnum = (typeof UserOrderByRelevanceFieldEnum)[keyof typeof UserOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const JsonNullValueFilter = {
|
||||
DbNull: 'DbNull',
|
||||
JsonNull: 'JsonNull',
|
||||
AnyNull: 'AnyNull'
|
||||
} as const
|
||||
|
||||
export type JsonNullValueFilter = (typeof JsonNullValueFilter)[keyof typeof JsonNullValueFilter]
|
||||
|
||||
|
||||
export const QueryMode = {
|
||||
default: 'default',
|
||||
insensitive: 'insensitive'
|
||||
} as const
|
||||
|
||||
export type QueryMode = (typeof QueryMode)[keyof typeof QueryMode]
|
||||
|
||||
|
||||
export const RoleOrderByRelevanceFieldEnum = {
|
||||
export const GoodOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
description: 'description'
|
||||
description: 'description',
|
||||
sku: 'sku',
|
||||
localSku: 'localSku',
|
||||
barcode: 'barcode'
|
||||
} as const
|
||||
|
||||
export type RoleOrderByRelevanceFieldEnum = (typeof RoleOrderByRelevanceFieldEnum)[keyof typeof RoleOrderByRelevanceFieldEnum]
|
||||
export type GoodOrderByRelevanceFieldEnum = (typeof GoodOrderByRelevanceFieldEnum)[keyof typeof GoodOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const OtpCodeOrderByRelevanceFieldEnum = {
|
||||
mobileNumber: 'mobileNumber',
|
||||
code: 'code'
|
||||
} as const
|
||||
|
||||
export type OtpCodeOrderByRelevanceFieldEnum = (typeof OtpCodeOrderByRelevanceFieldEnum)[keyof typeof OtpCodeOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const RefreshTokenOrderByRelevanceFieldEnum = {
|
||||
tokenHash: 'tokenHash'
|
||||
} as const
|
||||
|
||||
export type RefreshTokenOrderByRelevanceFieldEnum = (typeof RefreshTokenOrderByRelevanceFieldEnum)[keyof typeof RefreshTokenOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const BankBranchOrderByRelevanceFieldEnum = {
|
||||
export const GoodCategoryOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
code: 'code',
|
||||
address: 'address'
|
||||
description: 'description',
|
||||
imageUrl: 'imageUrl'
|
||||
} as const
|
||||
|
||||
export type BankBranchOrderByRelevanceFieldEnum = (typeof BankBranchOrderByRelevanceFieldEnum)[keyof typeof BankBranchOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const BankAccountOrderByRelevanceFieldEnum = {
|
||||
accountNumber: 'accountNumber',
|
||||
cardNumber: 'cardNumber',
|
||||
name: 'name',
|
||||
iban: 'iban'
|
||||
} as const
|
||||
|
||||
export type BankAccountOrderByRelevanceFieldEnum = (typeof BankAccountOrderByRelevanceFieldEnum)[keyof typeof BankAccountOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const BankAccountTransactionOrderByRelevanceFieldEnum = {
|
||||
description: 'description'
|
||||
} as const
|
||||
|
||||
export type BankAccountTransactionOrderByRelevanceFieldEnum = (typeof BankAccountTransactionOrderByRelevanceFieldEnum)[keyof typeof BankAccountTransactionOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const InventoryOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
location: 'location'
|
||||
} as const
|
||||
|
||||
export type InventoryOrderByRelevanceFieldEnum = (typeof InventoryOrderByRelevanceFieldEnum)[keyof typeof InventoryOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const PosAccountOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
code: 'code',
|
||||
description: 'description'
|
||||
} as const
|
||||
|
||||
export type PosAccountOrderByRelevanceFieldEnum = (typeof PosAccountOrderByRelevanceFieldEnum)[keyof typeof PosAccountOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const InventoryTransferOrderByRelevanceFieldEnum = {
|
||||
code: 'code',
|
||||
description: 'description'
|
||||
} as const
|
||||
|
||||
export type InventoryTransferOrderByRelevanceFieldEnum = (typeof InventoryTransferOrderByRelevanceFieldEnum)[keyof typeof InventoryTransferOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const BankOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
shortName: 'shortName'
|
||||
} as const
|
||||
|
||||
export type BankOrderByRelevanceFieldEnum = (typeof BankOrderByRelevanceFieldEnum)[keyof typeof BankOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const OrderOrderByRelevanceFieldEnum = {
|
||||
orderNumber: 'orderNumber',
|
||||
description: 'description'
|
||||
} as const
|
||||
|
||||
export type OrderOrderByRelevanceFieldEnum = (typeof OrderOrderByRelevanceFieldEnum)[keyof typeof OrderOrderByRelevanceFieldEnum]
|
||||
export type GoodCategoryOrderByRelevanceFieldEnum = (typeof GoodCategoryOrderByRelevanceFieldEnum)[keyof typeof GoodCategoryOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const CustomerOrderByRelevanceFieldEnum = {
|
||||
@@ -729,10 +243,7 @@ export const CustomerOrderByRelevanceFieldEnum = {
|
||||
lastName: 'lastName',
|
||||
email: 'email',
|
||||
mobileNumber: 'mobileNumber',
|
||||
address: 'address',
|
||||
city: 'city',
|
||||
state: 'state',
|
||||
country: 'country'
|
||||
address: 'address'
|
||||
} as const
|
||||
|
||||
export type CustomerOrderByRelevanceFieldEnum = (typeof CustomerOrderByRelevanceFieldEnum)[keyof typeof CustomerOrderByRelevanceFieldEnum]
|
||||
@@ -746,67 +257,6 @@ export const TriggerLogOrderByRelevanceFieldEnum = {
|
||||
export type TriggerLogOrderByRelevanceFieldEnum = (typeof TriggerLogOrderByRelevanceFieldEnum)[keyof typeof TriggerLogOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const ProductVariantOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
barcode: 'barcode',
|
||||
imageUrl: 'imageUrl',
|
||||
unit: 'unit'
|
||||
} as const
|
||||
|
||||
export type ProductVariantOrderByRelevanceFieldEnum = (typeof ProductVariantOrderByRelevanceFieldEnum)[keyof typeof ProductVariantOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const ProductOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
sku: 'sku',
|
||||
barcode: 'barcode'
|
||||
} as const
|
||||
|
||||
export type ProductOrderByRelevanceFieldEnum = (typeof ProductOrderByRelevanceFieldEnum)[keyof typeof ProductOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const ProductBrandOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
imageUrl: 'imageUrl'
|
||||
} as const
|
||||
|
||||
export type ProductBrandOrderByRelevanceFieldEnum = (typeof ProductBrandOrderByRelevanceFieldEnum)[keyof typeof ProductBrandOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const ProductCategoryOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
imageUrl: 'imageUrl'
|
||||
} as const
|
||||
|
||||
export type ProductCategoryOrderByRelevanceFieldEnum = (typeof ProductCategoryOrderByRelevanceFieldEnum)[keyof typeof ProductCategoryOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const PurchaseReceiptOrderByRelevanceFieldEnum = {
|
||||
code: 'code',
|
||||
description: 'description'
|
||||
} as const
|
||||
|
||||
export type PurchaseReceiptOrderByRelevanceFieldEnum = (typeof PurchaseReceiptOrderByRelevanceFieldEnum)[keyof typeof PurchaseReceiptOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const PurchaseReceiptItemOrderByRelevanceFieldEnum = {
|
||||
description: 'description'
|
||||
} as const
|
||||
|
||||
export type PurchaseReceiptItemOrderByRelevanceFieldEnum = (typeof PurchaseReceiptItemOrderByRelevanceFieldEnum)[keyof typeof PurchaseReceiptItemOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const PurchaseReceiptPaymentsOrderByRelevanceFieldEnum = {
|
||||
description: 'description'
|
||||
} as const
|
||||
|
||||
export type PurchaseReceiptPaymentsOrderByRelevanceFieldEnum = (typeof PurchaseReceiptPaymentsOrderByRelevanceFieldEnum)[keyof typeof PurchaseReceiptPaymentsOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const SalesInvoiceOrderByRelevanceFieldEnum = {
|
||||
code: 'code',
|
||||
description: 'description'
|
||||
@@ -815,30 +265,21 @@ export const SalesInvoiceOrderByRelevanceFieldEnum = {
|
||||
export type SalesInvoiceOrderByRelevanceFieldEnum = (typeof SalesInvoiceOrderByRelevanceFieldEnum)[keyof typeof SalesInvoiceOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const StockMovementOrderByRelevanceFieldEnum = {
|
||||
referenceId: 'referenceId'
|
||||
export const ServiceOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
sku: 'sku',
|
||||
barcode: 'barcode'
|
||||
} as const
|
||||
|
||||
export type StockMovementOrderByRelevanceFieldEnum = (typeof StockMovementOrderByRelevanceFieldEnum)[keyof typeof StockMovementOrderByRelevanceFieldEnum]
|
||||
export type ServiceOrderByRelevanceFieldEnum = (typeof ServiceOrderByRelevanceFieldEnum)[keyof typeof ServiceOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const SupplierOrderByRelevanceFieldEnum = {
|
||||
firstName: 'firstName',
|
||||
lastName: 'lastName',
|
||||
email: 'email',
|
||||
mobileNumber: 'mobileNumber',
|
||||
address: 'address',
|
||||
city: 'city',
|
||||
state: 'state',
|
||||
country: 'country'
|
||||
export const ServiceCategoryOrderByRelevanceFieldEnum = {
|
||||
name: 'name',
|
||||
description: 'description',
|
||||
imageUrl: 'imageUrl'
|
||||
} as const
|
||||
|
||||
export type SupplierOrderByRelevanceFieldEnum = (typeof SupplierOrderByRelevanceFieldEnum)[keyof typeof SupplierOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
export const SupplierLedgerOrderByRelevanceFieldEnum = {
|
||||
description: 'description'
|
||||
} as const
|
||||
|
||||
export type SupplierLedgerOrderByRelevanceFieldEnum = (typeof SupplierLedgerOrderByRelevanceFieldEnum)[keyof typeof SupplierLedgerOrderByRelevanceFieldEnum]
|
||||
export type ServiceCategoryOrderByRelevanceFieldEnum = (typeof ServiceCategoryOrderByRelevanceFieldEnum)[keyof typeof ServiceCategoryOrderByRelevanceFieldEnum]
|
||||
|
||||
|
||||
@@ -8,38 +8,13 @@
|
||||
*
|
||||
* 🟢 You can import this file directly.
|
||||
*/
|
||||
export type * from './models/User.js'
|
||||
export type * from './models/Role.js'
|
||||
export type * from './models/OtpCode.js'
|
||||
export type * from './models/RefreshToken.js'
|
||||
export type * from './models/BankBranch.js'
|
||||
export type * from './models/BankAccount.js'
|
||||
export type * from './models/BankAccountTransaction.js'
|
||||
export type * from './models/Inventory.js'
|
||||
export type * from './models/InventoryBankAccount.js'
|
||||
export type * from './models/PosAccount.js'
|
||||
export type * from './models/InventoryTransfer.js'
|
||||
export type * from './models/InventoryTransferItem.js'
|
||||
export type * from './models/Bank.js'
|
||||
export type * from './models/Order.js'
|
||||
export type * from './models/OrderItem.js'
|
||||
export type * from './models/Good.js'
|
||||
export type * from './models/GoodCategory.js'
|
||||
export type * from './models/Customer.js'
|
||||
export type * from './models/TriggerLog.js'
|
||||
export type * from './models/ProductVariant.js'
|
||||
export type * from './models/Product.js'
|
||||
export type * from './models/ProductBrand.js'
|
||||
export type * from './models/ProductCategory.js'
|
||||
export type * from './models/PurchaseReceipt.js'
|
||||
export type * from './models/PurchaseReceiptItem.js'
|
||||
export type * from './models/PurchaseReceiptPayments.js'
|
||||
export type * from './models/SalesInvoice.js'
|
||||
export type * from './models/SalesInvoiceItem.js'
|
||||
export type * from './models/SalesInvoicePayment.js'
|
||||
export type * from './models/StockMovement.js'
|
||||
export type * from './models/StockBalance.js'
|
||||
export type * from './models/StockAdjustment.js'
|
||||
export type * from './models/StockReservation.js'
|
||||
export type * from './models/Supplier.js'
|
||||
export type * from './models/SupplierLedger.js'
|
||||
export type * from './models/StockAvailableView.js'
|
||||
export type * from './models/Service.js'
|
||||
export type * from './models/ServiceCategory.js'
|
||||
export type * from './commonInputTypes.js'
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -41,9 +41,6 @@ export type CustomerMinAggregateOutputType = {
|
||||
email: string | null
|
||||
mobileNumber: string | null
|
||||
address: string | null
|
||||
city: string | null
|
||||
state: string | null
|
||||
country: string | null
|
||||
isActive: boolean | null
|
||||
createdAt: Date | null
|
||||
updatedAt: Date | null
|
||||
@@ -57,9 +54,6 @@ export type CustomerMaxAggregateOutputType = {
|
||||
email: string | null
|
||||
mobileNumber: string | null
|
||||
address: string | null
|
||||
city: string | null
|
||||
state: string | null
|
||||
country: string | null
|
||||
isActive: boolean | null
|
||||
createdAt: Date | null
|
||||
updatedAt: Date | null
|
||||
@@ -73,9 +67,6 @@ export type CustomerCountAggregateOutputType = {
|
||||
email: number
|
||||
mobileNumber: number
|
||||
address: number
|
||||
city: number
|
||||
state: number
|
||||
country: number
|
||||
isActive: number
|
||||
createdAt: number
|
||||
updatedAt: number
|
||||
@@ -99,9 +90,6 @@ export type CustomerMinAggregateInputType = {
|
||||
email?: true
|
||||
mobileNumber?: true
|
||||
address?: true
|
||||
city?: true
|
||||
state?: true
|
||||
country?: true
|
||||
isActive?: true
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
@@ -115,9 +103,6 @@ export type CustomerMaxAggregateInputType = {
|
||||
email?: true
|
||||
mobileNumber?: true
|
||||
address?: true
|
||||
city?: true
|
||||
state?: true
|
||||
country?: true
|
||||
isActive?: true
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
@@ -131,9 +116,6 @@ export type CustomerCountAggregateInputType = {
|
||||
email?: true
|
||||
mobileNumber?: true
|
||||
address?: true
|
||||
city?: true
|
||||
state?: true
|
||||
country?: true
|
||||
isActive?: true
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
@@ -234,9 +216,6 @@ export type CustomerGroupByOutputType = {
|
||||
email: string | null
|
||||
mobileNumber: string
|
||||
address: string | null
|
||||
city: string | null
|
||||
state: string | null
|
||||
country: string | null
|
||||
isActive: boolean
|
||||
createdAt: Date
|
||||
updatedAt: Date
|
||||
@@ -273,15 +252,10 @@ export type CustomerWhereInput = {
|
||||
email?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
mobileNumber?: Prisma.StringFilter<"Customer"> | string
|
||||
address?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
city?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
state?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
country?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
isActive?: Prisma.BoolFilter<"Customer"> | boolean
|
||||
createdAt?: Prisma.DateTimeFilter<"Customer"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeFilter<"Customer"> | Date | string
|
||||
deletedAt?: Prisma.DateTimeNullableFilter<"Customer"> | Date | string | null
|
||||
orders?: Prisma.OrderListRelationFilter
|
||||
stockMovements?: Prisma.StockMovementListRelationFilter
|
||||
salesInvoices?: Prisma.SalesInvoiceListRelationFilter
|
||||
}
|
||||
|
||||
@@ -292,15 +266,10 @@ export type CustomerOrderByWithRelationInput = {
|
||||
email?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
mobileNumber?: Prisma.SortOrder
|
||||
address?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
city?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
state?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
country?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
isActive?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
deletedAt?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
orders?: Prisma.OrderOrderByRelationAggregateInput
|
||||
stockMovements?: Prisma.StockMovementOrderByRelationAggregateInput
|
||||
salesInvoices?: Prisma.SalesInvoiceOrderByRelationAggregateInput
|
||||
_relevance?: Prisma.CustomerOrderByRelevanceInput
|
||||
}
|
||||
@@ -315,15 +284,10 @@ export type CustomerWhereUniqueInput = Prisma.AtLeast<{
|
||||
lastName?: Prisma.StringFilter<"Customer"> | string
|
||||
email?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
address?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
city?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
state?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
country?: Prisma.StringNullableFilter<"Customer"> | string | null
|
||||
isActive?: Prisma.BoolFilter<"Customer"> | boolean
|
||||
createdAt?: Prisma.DateTimeFilter<"Customer"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeFilter<"Customer"> | Date | string
|
||||
deletedAt?: Prisma.DateTimeNullableFilter<"Customer"> | Date | string | null
|
||||
orders?: Prisma.OrderListRelationFilter
|
||||
stockMovements?: Prisma.StockMovementListRelationFilter
|
||||
salesInvoices?: Prisma.SalesInvoiceListRelationFilter
|
||||
}, "id" | "mobileNumber">
|
||||
|
||||
@@ -334,9 +298,6 @@ export type CustomerOrderByWithAggregationInput = {
|
||||
email?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
mobileNumber?: Prisma.SortOrder
|
||||
address?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
city?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
state?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
country?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
isActive?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
@@ -358,9 +319,6 @@ export type CustomerScalarWhereWithAggregatesInput = {
|
||||
email?: Prisma.StringNullableWithAggregatesFilter<"Customer"> | string | null
|
||||
mobileNumber?: Prisma.StringWithAggregatesFilter<"Customer"> | string
|
||||
address?: Prisma.StringNullableWithAggregatesFilter<"Customer"> | string | null
|
||||
city?: Prisma.StringNullableWithAggregatesFilter<"Customer"> | string | null
|
||||
state?: Prisma.StringNullableWithAggregatesFilter<"Customer"> | string | null
|
||||
country?: Prisma.StringNullableWithAggregatesFilter<"Customer"> | string | null
|
||||
isActive?: Prisma.BoolWithAggregatesFilter<"Customer"> | boolean
|
||||
createdAt?: Prisma.DateTimeWithAggregatesFilter<"Customer"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeWithAggregatesFilter<"Customer"> | Date | string
|
||||
@@ -373,15 +331,10 @@ export type CustomerCreateInput = {
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
deletedAt?: Date | string | null
|
||||
orders?: Prisma.OrderCreateNestedManyWithoutCustomerInput
|
||||
stockMovements?: Prisma.StockMovementCreateNestedManyWithoutCustomerInput
|
||||
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput
|
||||
}
|
||||
|
||||
@@ -392,15 +345,10 @@ export type CustomerUncheckedCreateInput = {
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
deletedAt?: Date | string | null
|
||||
orders?: Prisma.OrderUncheckedCreateNestedManyWithoutCustomerInput
|
||||
stockMovements?: Prisma.StockMovementUncheckedCreateNestedManyWithoutCustomerInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput
|
||||
}
|
||||
|
||||
@@ -410,15 +358,10 @@ export type CustomerUpdateInput = {
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
orders?: Prisma.OrderUpdateManyWithoutCustomerNestedInput
|
||||
stockMovements?: Prisma.StockMovementUpdateManyWithoutCustomerNestedInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput
|
||||
}
|
||||
|
||||
@@ -429,15 +372,10 @@ export type CustomerUncheckedUpdateInput = {
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
orders?: Prisma.OrderUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
stockMovements?: Prisma.StockMovementUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
}
|
||||
|
||||
@@ -448,9 +386,6 @@ export type CustomerCreateManyInput = {
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
@@ -463,9 +398,6 @@ export type CustomerUpdateManyMutationInput = {
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
@@ -479,20 +411,12 @@ export type CustomerUncheckedUpdateManyInput = {
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
}
|
||||
|
||||
export type CustomerNullableScalarRelationFilter = {
|
||||
is?: Prisma.CustomerWhereInput | null
|
||||
isNot?: Prisma.CustomerWhereInput | null
|
||||
}
|
||||
|
||||
export type CustomerOrderByRelevanceInput = {
|
||||
fields: Prisma.CustomerOrderByRelevanceFieldEnum | Prisma.CustomerOrderByRelevanceFieldEnum[]
|
||||
sort: Prisma.SortOrder
|
||||
@@ -506,9 +430,6 @@ export type CustomerCountOrderByAggregateInput = {
|
||||
email?: Prisma.SortOrder
|
||||
mobileNumber?: Prisma.SortOrder
|
||||
address?: Prisma.SortOrder
|
||||
city?: Prisma.SortOrder
|
||||
state?: Prisma.SortOrder
|
||||
country?: Prisma.SortOrder
|
||||
isActive?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
@@ -526,9 +447,6 @@ export type CustomerMaxOrderByAggregateInput = {
|
||||
email?: Prisma.SortOrder
|
||||
mobileNumber?: Prisma.SortOrder
|
||||
address?: Prisma.SortOrder
|
||||
city?: Prisma.SortOrder
|
||||
state?: Prisma.SortOrder
|
||||
country?: Prisma.SortOrder
|
||||
isActive?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
@@ -542,9 +460,6 @@ export type CustomerMinOrderByAggregateInput = {
|
||||
email?: Prisma.SortOrder
|
||||
mobileNumber?: Prisma.SortOrder
|
||||
address?: Prisma.SortOrder
|
||||
city?: Prisma.SortOrder
|
||||
state?: Prisma.SortOrder
|
||||
country?: Prisma.SortOrder
|
||||
isActive?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
@@ -555,20 +470,13 @@ export type CustomerSumOrderByAggregateInput = {
|
||||
id?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type CustomerCreateNestedOneWithoutOrdersInput = {
|
||||
create?: Prisma.XOR<Prisma.CustomerCreateWithoutOrdersInput, Prisma.CustomerUncheckedCreateWithoutOrdersInput>
|
||||
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutOrdersInput
|
||||
connect?: Prisma.CustomerWhereUniqueInput
|
||||
export type CustomerNullableScalarRelationFilter = {
|
||||
is?: Prisma.CustomerWhereInput | null
|
||||
isNot?: Prisma.CustomerWhereInput | null
|
||||
}
|
||||
|
||||
export type CustomerUpdateOneWithoutOrdersNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.CustomerCreateWithoutOrdersInput, Prisma.CustomerUncheckedCreateWithoutOrdersInput>
|
||||
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutOrdersInput
|
||||
upsert?: Prisma.CustomerUpsertWithoutOrdersInput
|
||||
disconnect?: Prisma.CustomerWhereInput | boolean
|
||||
delete?: Prisma.CustomerWhereInput | boolean
|
||||
connect?: Prisma.CustomerWhereUniqueInput
|
||||
update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutOrdersInput, Prisma.CustomerUpdateWithoutOrdersInput>, Prisma.CustomerUncheckedUpdateWithoutOrdersInput>
|
||||
export type BoolFieldUpdateOperationsInput = {
|
||||
set?: boolean
|
||||
}
|
||||
|
||||
export type CustomerCreateNestedOneWithoutSalesInvoicesInput = {
|
||||
@@ -587,123 +495,16 @@ export type CustomerUpdateOneWithoutSalesInvoicesNestedInput = {
|
||||
update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutSalesInvoicesInput, Prisma.CustomerUpdateWithoutSalesInvoicesInput>, Prisma.CustomerUncheckedUpdateWithoutSalesInvoicesInput>
|
||||
}
|
||||
|
||||
export type CustomerCreateNestedOneWithoutStockMovementsInput = {
|
||||
create?: Prisma.XOR<Prisma.CustomerCreateWithoutStockMovementsInput, Prisma.CustomerUncheckedCreateWithoutStockMovementsInput>
|
||||
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutStockMovementsInput
|
||||
connect?: Prisma.CustomerWhereUniqueInput
|
||||
}
|
||||
|
||||
export type CustomerUpdateOneWithoutStockMovementsNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.CustomerCreateWithoutStockMovementsInput, Prisma.CustomerUncheckedCreateWithoutStockMovementsInput>
|
||||
connectOrCreate?: Prisma.CustomerCreateOrConnectWithoutStockMovementsInput
|
||||
upsert?: Prisma.CustomerUpsertWithoutStockMovementsInput
|
||||
disconnect?: Prisma.CustomerWhereInput | boolean
|
||||
delete?: Prisma.CustomerWhereInput | boolean
|
||||
connect?: Prisma.CustomerWhereUniqueInput
|
||||
update?: Prisma.XOR<Prisma.XOR<Prisma.CustomerUpdateToOneWithWhereWithoutStockMovementsInput, Prisma.CustomerUpdateWithoutStockMovementsInput>, Prisma.CustomerUncheckedUpdateWithoutStockMovementsInput>
|
||||
}
|
||||
|
||||
export type CustomerCreateWithoutOrdersInput = {
|
||||
firstName: string
|
||||
lastName: string
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
deletedAt?: Date | string | null
|
||||
stockMovements?: Prisma.StockMovementCreateNestedManyWithoutCustomerInput
|
||||
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput
|
||||
}
|
||||
|
||||
export type CustomerUncheckedCreateWithoutOrdersInput = {
|
||||
id?: number
|
||||
firstName: string
|
||||
lastName: string
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
deletedAt?: Date | string | null
|
||||
stockMovements?: Prisma.StockMovementUncheckedCreateNestedManyWithoutCustomerInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput
|
||||
}
|
||||
|
||||
export type CustomerCreateOrConnectWithoutOrdersInput = {
|
||||
where: Prisma.CustomerWhereUniqueInput
|
||||
create: Prisma.XOR<Prisma.CustomerCreateWithoutOrdersInput, Prisma.CustomerUncheckedCreateWithoutOrdersInput>
|
||||
}
|
||||
|
||||
export type CustomerUpsertWithoutOrdersInput = {
|
||||
update: Prisma.XOR<Prisma.CustomerUpdateWithoutOrdersInput, Prisma.CustomerUncheckedUpdateWithoutOrdersInput>
|
||||
create: Prisma.XOR<Prisma.CustomerCreateWithoutOrdersInput, Prisma.CustomerUncheckedCreateWithoutOrdersInput>
|
||||
where?: Prisma.CustomerWhereInput
|
||||
}
|
||||
|
||||
export type CustomerUpdateToOneWithWhereWithoutOrdersInput = {
|
||||
where?: Prisma.CustomerWhereInput
|
||||
data: Prisma.XOR<Prisma.CustomerUpdateWithoutOrdersInput, Prisma.CustomerUncheckedUpdateWithoutOrdersInput>
|
||||
}
|
||||
|
||||
export type CustomerUpdateWithoutOrdersInput = {
|
||||
firstName?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
lastName?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
stockMovements?: Prisma.StockMovementUpdateManyWithoutCustomerNestedInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput
|
||||
}
|
||||
|
||||
export type CustomerUncheckedUpdateWithoutOrdersInput = {
|
||||
id?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
firstName?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
lastName?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
stockMovements?: Prisma.StockMovementUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
}
|
||||
|
||||
export type CustomerCreateWithoutSalesInvoicesInput = {
|
||||
firstName: string
|
||||
lastName: string
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
deletedAt?: Date | string | null
|
||||
orders?: Prisma.OrderCreateNestedManyWithoutCustomerInput
|
||||
stockMovements?: Prisma.StockMovementCreateNestedManyWithoutCustomerInput
|
||||
}
|
||||
|
||||
export type CustomerUncheckedCreateWithoutSalesInvoicesInput = {
|
||||
@@ -713,15 +514,10 @@ export type CustomerUncheckedCreateWithoutSalesInvoicesInput = {
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
deletedAt?: Date | string | null
|
||||
orders?: Prisma.OrderUncheckedCreateNestedManyWithoutCustomerInput
|
||||
stockMovements?: Prisma.StockMovementUncheckedCreateNestedManyWithoutCustomerInput
|
||||
}
|
||||
|
||||
export type CustomerCreateOrConnectWithoutSalesInvoicesInput = {
|
||||
@@ -746,15 +542,10 @@ export type CustomerUpdateWithoutSalesInvoicesInput = {
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
orders?: Prisma.OrderUpdateManyWithoutCustomerNestedInput
|
||||
stockMovements?: Prisma.StockMovementUpdateManyWithoutCustomerNestedInput
|
||||
}
|
||||
|
||||
export type CustomerUncheckedUpdateWithoutSalesInvoicesInput = {
|
||||
@@ -764,101 +555,10 @@ export type CustomerUncheckedUpdateWithoutSalesInvoicesInput = {
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
orders?: Prisma.OrderUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
stockMovements?: Prisma.StockMovementUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
}
|
||||
|
||||
export type CustomerCreateWithoutStockMovementsInput = {
|
||||
firstName: string
|
||||
lastName: string
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
deletedAt?: Date | string | null
|
||||
orders?: Prisma.OrderCreateNestedManyWithoutCustomerInput
|
||||
salesInvoices?: Prisma.SalesInvoiceCreateNestedManyWithoutCustomerInput
|
||||
}
|
||||
|
||||
export type CustomerUncheckedCreateWithoutStockMovementsInput = {
|
||||
id?: number
|
||||
firstName: string
|
||||
lastName: string
|
||||
email?: string | null
|
||||
mobileNumber: string
|
||||
address?: string | null
|
||||
city?: string | null
|
||||
state?: string | null
|
||||
country?: string | null
|
||||
isActive?: boolean
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
deletedAt?: Date | string | null
|
||||
orders?: Prisma.OrderUncheckedCreateNestedManyWithoutCustomerInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUncheckedCreateNestedManyWithoutCustomerInput
|
||||
}
|
||||
|
||||
export type CustomerCreateOrConnectWithoutStockMovementsInput = {
|
||||
where: Prisma.CustomerWhereUniqueInput
|
||||
create: Prisma.XOR<Prisma.CustomerCreateWithoutStockMovementsInput, Prisma.CustomerUncheckedCreateWithoutStockMovementsInput>
|
||||
}
|
||||
|
||||
export type CustomerUpsertWithoutStockMovementsInput = {
|
||||
update: Prisma.XOR<Prisma.CustomerUpdateWithoutStockMovementsInput, Prisma.CustomerUncheckedUpdateWithoutStockMovementsInput>
|
||||
create: Prisma.XOR<Prisma.CustomerCreateWithoutStockMovementsInput, Prisma.CustomerUncheckedCreateWithoutStockMovementsInput>
|
||||
where?: Prisma.CustomerWhereInput
|
||||
}
|
||||
|
||||
export type CustomerUpdateToOneWithWhereWithoutStockMovementsInput = {
|
||||
where?: Prisma.CustomerWhereInput
|
||||
data: Prisma.XOR<Prisma.CustomerUpdateWithoutStockMovementsInput, Prisma.CustomerUncheckedUpdateWithoutStockMovementsInput>
|
||||
}
|
||||
|
||||
export type CustomerUpdateWithoutStockMovementsInput = {
|
||||
firstName?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
lastName?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
orders?: Prisma.OrderUpdateManyWithoutCustomerNestedInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUpdateManyWithoutCustomerNestedInput
|
||||
}
|
||||
|
||||
export type CustomerUncheckedUpdateWithoutStockMovementsInput = {
|
||||
id?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
firstName?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
lastName?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
email?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
mobileNumber?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
address?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
city?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
state?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
country?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
deletedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
|
||||
orders?: Prisma.OrderUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
salesInvoices?: Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerNestedInput
|
||||
}
|
||||
|
||||
|
||||
@@ -867,14 +567,10 @@ export type CustomerUncheckedUpdateWithoutStockMovementsInput = {
|
||||
*/
|
||||
|
||||
export type CustomerCountOutputType = {
|
||||
orders: number
|
||||
stockMovements: number
|
||||
salesInvoices: number
|
||||
}
|
||||
|
||||
export type CustomerCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
orders?: boolean | CustomerCountOutputTypeCountOrdersArgs
|
||||
stockMovements?: boolean | CustomerCountOutputTypeCountStockMovementsArgs
|
||||
salesInvoices?: boolean | CustomerCountOutputTypeCountSalesInvoicesArgs
|
||||
}
|
||||
|
||||
@@ -888,20 +584,6 @@ export type CustomerCountOutputTypeDefaultArgs<ExtArgs extends runtime.Types.Ext
|
||||
select?: Prisma.CustomerCountOutputTypeSelect<ExtArgs> | null
|
||||
}
|
||||
|
||||
/**
|
||||
* CustomerCountOutputType without action
|
||||
*/
|
||||
export type CustomerCountOutputTypeCountOrdersArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
where?: Prisma.OrderWhereInput
|
||||
}
|
||||
|
||||
/**
|
||||
* CustomerCountOutputType without action
|
||||
*/
|
||||
export type CustomerCountOutputTypeCountStockMovementsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
where?: Prisma.StockMovementWhereInput
|
||||
}
|
||||
|
||||
/**
|
||||
* CustomerCountOutputType without action
|
||||
*/
|
||||
@@ -917,15 +599,10 @@ export type CustomerSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs
|
||||
email?: boolean
|
||||
mobileNumber?: boolean
|
||||
address?: boolean
|
||||
city?: boolean
|
||||
state?: boolean
|
||||
country?: boolean
|
||||
isActive?: boolean
|
||||
createdAt?: boolean
|
||||
updatedAt?: boolean
|
||||
deletedAt?: boolean
|
||||
orders?: boolean | Prisma.Customer$ordersArgs<ExtArgs>
|
||||
stockMovements?: boolean | Prisma.Customer$stockMovementsArgs<ExtArgs>
|
||||
salesInvoices?: boolean | Prisma.Customer$salesInvoicesArgs<ExtArgs>
|
||||
_count?: boolean | Prisma.CustomerCountOutputTypeDefaultArgs<ExtArgs>
|
||||
}, ExtArgs["result"]["customer"]>
|
||||
@@ -939,19 +616,14 @@ export type CustomerSelectScalar = {
|
||||
email?: boolean
|
||||
mobileNumber?: boolean
|
||||
address?: boolean
|
||||
city?: boolean
|
||||
state?: boolean
|
||||
country?: boolean
|
||||
isActive?: boolean
|
||||
createdAt?: boolean
|
||||
updatedAt?: boolean
|
||||
deletedAt?: boolean
|
||||
}
|
||||
|
||||
export type CustomerOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "firstName" | "lastName" | "email" | "mobileNumber" | "address" | "city" | "state" | "country" | "isActive" | "createdAt" | "updatedAt" | "deletedAt", ExtArgs["result"]["customer"]>
|
||||
export type CustomerOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "firstName" | "lastName" | "email" | "mobileNumber" | "address" | "isActive" | "createdAt" | "updatedAt" | "deletedAt", ExtArgs["result"]["customer"]>
|
||||
export type CustomerInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
orders?: boolean | Prisma.Customer$ordersArgs<ExtArgs>
|
||||
stockMovements?: boolean | Prisma.Customer$stockMovementsArgs<ExtArgs>
|
||||
salesInvoices?: boolean | Prisma.Customer$salesInvoicesArgs<ExtArgs>
|
||||
_count?: boolean | Prisma.CustomerCountOutputTypeDefaultArgs<ExtArgs>
|
||||
}
|
||||
@@ -959,8 +631,6 @@ export type CustomerInclude<ExtArgs extends runtime.Types.Extensions.InternalArg
|
||||
export type $CustomerPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
name: "Customer"
|
||||
objects: {
|
||||
orders: Prisma.$OrderPayload<ExtArgs>[]
|
||||
stockMovements: Prisma.$StockMovementPayload<ExtArgs>[]
|
||||
salesInvoices: Prisma.$SalesInvoicePayload<ExtArgs>[]
|
||||
}
|
||||
scalars: runtime.Types.Extensions.GetPayloadResult<{
|
||||
@@ -970,9 +640,6 @@ export type $CustomerPayload<ExtArgs extends runtime.Types.Extensions.InternalAr
|
||||
email: string | null
|
||||
mobileNumber: string
|
||||
address: string | null
|
||||
city: string | null
|
||||
state: string | null
|
||||
country: string | null
|
||||
isActive: boolean
|
||||
createdAt: Date
|
||||
updatedAt: Date
|
||||
@@ -1317,8 +984,6 @@ readonly fields: CustomerFieldRefs;
|
||||
*/
|
||||
export interface Prisma__CustomerClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
|
||||
readonly [Symbol.toStringTag]: "PrismaPromise"
|
||||
orders<T extends Prisma.Customer$ordersArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$ordersArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$OrderPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
|
||||
stockMovements<T extends Prisma.Customer$stockMovementsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$stockMovementsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$StockMovementPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
|
||||
salesInvoices<T extends Prisma.Customer$salesInvoicesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Customer$salesInvoicesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
|
||||
/**
|
||||
* Attaches callbacks for the resolution and/or rejection of the Promise.
|
||||
@@ -1355,9 +1020,6 @@ export interface CustomerFieldRefs {
|
||||
readonly email: Prisma.FieldRef<"Customer", 'String'>
|
||||
readonly mobileNumber: Prisma.FieldRef<"Customer", 'String'>
|
||||
readonly address: Prisma.FieldRef<"Customer", 'String'>
|
||||
readonly city: Prisma.FieldRef<"Customer", 'String'>
|
||||
readonly state: Prisma.FieldRef<"Customer", 'String'>
|
||||
readonly country: Prisma.FieldRef<"Customer", 'String'>
|
||||
readonly isActive: Prisma.FieldRef<"Customer", 'Boolean'>
|
||||
readonly createdAt: Prisma.FieldRef<"Customer", 'DateTime'>
|
||||
readonly updatedAt: Prisma.FieldRef<"Customer", 'DateTime'>
|
||||
@@ -1704,54 +1366,6 @@ export type CustomerDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.Inte
|
||||
limit?: number
|
||||
}
|
||||
|
||||
/**
|
||||
* Customer.orders
|
||||
*/
|
||||
export type Customer$ordersArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Select specific fields to fetch from the Order
|
||||
*/
|
||||
select?: Prisma.OrderSelect<ExtArgs> | null
|
||||
/**
|
||||
* Omit specific fields from the Order
|
||||
*/
|
||||
omit?: Prisma.OrderOmit<ExtArgs> | null
|
||||
/**
|
||||
* Choose, which related nodes to fetch as well
|
||||
*/
|
||||
include?: Prisma.OrderInclude<ExtArgs> | null
|
||||
where?: Prisma.OrderWhereInput
|
||||
orderBy?: Prisma.OrderOrderByWithRelationInput | Prisma.OrderOrderByWithRelationInput[]
|
||||
cursor?: Prisma.OrderWhereUniqueInput
|
||||
take?: number
|
||||
skip?: number
|
||||
distinct?: Prisma.OrderScalarFieldEnum | Prisma.OrderScalarFieldEnum[]
|
||||
}
|
||||
|
||||
/**
|
||||
* Customer.stockMovements
|
||||
*/
|
||||
export type Customer$stockMovementsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Select specific fields to fetch from the StockMovement
|
||||
*/
|
||||
select?: Prisma.StockMovementSelect<ExtArgs> | null
|
||||
/**
|
||||
* Omit specific fields from the StockMovement
|
||||
*/
|
||||
omit?: Prisma.StockMovementOmit<ExtArgs> | null
|
||||
/**
|
||||
* Choose, which related nodes to fetch as well
|
||||
*/
|
||||
include?: Prisma.StockMovementInclude<ExtArgs> | null
|
||||
where?: Prisma.StockMovementWhereInput
|
||||
orderBy?: Prisma.StockMovementOrderByWithRelationInput | Prisma.StockMovementOrderByWithRelationInput[]
|
||||
cursor?: Prisma.StockMovementWhereUniqueInput
|
||||
take?: number
|
||||
skip?: number
|
||||
distinct?: Prisma.StockMovementScalarFieldEnum | Prisma.StockMovementScalarFieldEnum[]
|
||||
}
|
||||
|
||||
/**
|
||||
* Customer.salesInvoices
|
||||
*/
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -30,14 +30,12 @@ export type SalesInvoiceAvgAggregateOutputType = {
|
||||
id: number | null
|
||||
totalAmount: runtime.Decimal | null
|
||||
customerId: number | null
|
||||
posAccountId: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceSumAggregateOutputType = {
|
||||
id: number | null
|
||||
totalAmount: runtime.Decimal | null
|
||||
customerId: number | null
|
||||
posAccountId: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceMinAggregateOutputType = {
|
||||
@@ -48,7 +46,6 @@ export type SalesInvoiceMinAggregateOutputType = {
|
||||
createdAt: Date | null
|
||||
updatedAt: Date | null
|
||||
customerId: number | null
|
||||
posAccountId: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceMaxAggregateOutputType = {
|
||||
@@ -59,7 +56,6 @@ export type SalesInvoiceMaxAggregateOutputType = {
|
||||
createdAt: Date | null
|
||||
updatedAt: Date | null
|
||||
customerId: number | null
|
||||
posAccountId: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceCountAggregateOutputType = {
|
||||
@@ -70,7 +66,6 @@ export type SalesInvoiceCountAggregateOutputType = {
|
||||
createdAt: number
|
||||
updatedAt: number
|
||||
customerId: number
|
||||
posAccountId: number
|
||||
_all: number
|
||||
}
|
||||
|
||||
@@ -79,14 +74,12 @@ export type SalesInvoiceAvgAggregateInputType = {
|
||||
id?: true
|
||||
totalAmount?: true
|
||||
customerId?: true
|
||||
posAccountId?: true
|
||||
}
|
||||
|
||||
export type SalesInvoiceSumAggregateInputType = {
|
||||
id?: true
|
||||
totalAmount?: true
|
||||
customerId?: true
|
||||
posAccountId?: true
|
||||
}
|
||||
|
||||
export type SalesInvoiceMinAggregateInputType = {
|
||||
@@ -97,7 +90,6 @@ export type SalesInvoiceMinAggregateInputType = {
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
customerId?: true
|
||||
posAccountId?: true
|
||||
}
|
||||
|
||||
export type SalesInvoiceMaxAggregateInputType = {
|
||||
@@ -108,7 +100,6 @@ export type SalesInvoiceMaxAggregateInputType = {
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
customerId?: true
|
||||
posAccountId?: true
|
||||
}
|
||||
|
||||
export type SalesInvoiceCountAggregateInputType = {
|
||||
@@ -119,7 +110,6 @@ export type SalesInvoiceCountAggregateInputType = {
|
||||
createdAt?: true
|
||||
updatedAt?: true
|
||||
customerId?: true
|
||||
posAccountId?: true
|
||||
_all?: true
|
||||
}
|
||||
|
||||
@@ -217,7 +207,6 @@ export type SalesInvoiceGroupByOutputType = {
|
||||
createdAt: Date
|
||||
updatedAt: Date
|
||||
customerId: number | null
|
||||
posAccountId: number
|
||||
_count: SalesInvoiceCountAggregateOutputType | null
|
||||
_avg: SalesInvoiceAvgAggregateOutputType | null
|
||||
_sum: SalesInvoiceSumAggregateOutputType | null
|
||||
@@ -251,9 +240,7 @@ export type SalesInvoiceWhereInput = {
|
||||
createdAt?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
|
||||
customerId?: Prisma.IntNullableFilter<"SalesInvoice"> | number | null
|
||||
posAccountId?: Prisma.IntFilter<"SalesInvoice"> | number
|
||||
customer?: Prisma.XOR<Prisma.CustomerNullableScalarRelationFilter, Prisma.CustomerWhereInput> | null
|
||||
posAccount?: Prisma.XOR<Prisma.PosAccountScalarRelationFilter, Prisma.PosAccountWhereInput>
|
||||
items?: Prisma.SalesInvoiceItemListRelationFilter
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentListRelationFilter
|
||||
}
|
||||
@@ -266,9 +253,7 @@ export type SalesInvoiceOrderByWithRelationInput = {
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
customerId?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
posAccountId?: Prisma.SortOrder
|
||||
customer?: Prisma.CustomerOrderByWithRelationInput
|
||||
posAccount?: Prisma.PosAccountOrderByWithRelationInput
|
||||
items?: Prisma.SalesInvoiceItemOrderByRelationAggregateInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentOrderByRelationAggregateInput
|
||||
_relevance?: Prisma.SalesInvoiceOrderByRelevanceInput
|
||||
@@ -285,9 +270,7 @@ export type SalesInvoiceWhereUniqueInput = Prisma.AtLeast<{
|
||||
createdAt?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
|
||||
customerId?: Prisma.IntNullableFilter<"SalesInvoice"> | number | null
|
||||
posAccountId?: Prisma.IntFilter<"SalesInvoice"> | number
|
||||
customer?: Prisma.XOR<Prisma.CustomerNullableScalarRelationFilter, Prisma.CustomerWhereInput> | null
|
||||
posAccount?: Prisma.XOR<Prisma.PosAccountScalarRelationFilter, Prisma.PosAccountWhereInput>
|
||||
items?: Prisma.SalesInvoiceItemListRelationFilter
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentListRelationFilter
|
||||
}, "id" | "code">
|
||||
@@ -300,7 +283,6 @@ export type SalesInvoiceOrderByWithAggregationInput = {
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
customerId?: Prisma.SortOrderInput | Prisma.SortOrder
|
||||
posAccountId?: Prisma.SortOrder
|
||||
_count?: Prisma.SalesInvoiceCountOrderByAggregateInput
|
||||
_avg?: Prisma.SalesInvoiceAvgOrderByAggregateInput
|
||||
_max?: Prisma.SalesInvoiceMaxOrderByAggregateInput
|
||||
@@ -319,7 +301,6 @@ export type SalesInvoiceScalarWhereWithAggregatesInput = {
|
||||
createdAt?: Prisma.DateTimeWithAggregatesFilter<"SalesInvoice"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeWithAggregatesFilter<"SalesInvoice"> | Date | string
|
||||
customerId?: Prisma.IntNullableWithAggregatesFilter<"SalesInvoice"> | number | null
|
||||
posAccountId?: Prisma.IntWithAggregatesFilter<"SalesInvoice"> | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateInput = {
|
||||
@@ -329,7 +310,6 @@ export type SalesInvoiceCreateInput = {
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customer?: Prisma.CustomerCreateNestedOneWithoutSalesInvoicesInput
|
||||
posAccount: Prisma.PosAccountCreateNestedOneWithoutSalesInvoicesInput
|
||||
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
@@ -342,7 +322,6 @@ export type SalesInvoiceUncheckedCreateInput = {
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customerId?: number | null
|
||||
posAccountId: number
|
||||
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
@@ -354,7 +333,6 @@ export type SalesInvoiceUpdateInput = {
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customer?: Prisma.CustomerUpdateOneWithoutSalesInvoicesNestedInput
|
||||
posAccount?: Prisma.PosAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
|
||||
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
@@ -367,7 +345,6 @@ export type SalesInvoiceUncheckedUpdateInput = {
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customerId?: Prisma.NullableIntFieldUpdateOperationsInput | number | null
|
||||
posAccountId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
@@ -380,7 +357,6 @@ export type SalesInvoiceCreateManyInput = {
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customerId?: number | null
|
||||
posAccountId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceUpdateManyMutationInput = {
|
||||
@@ -399,7 +375,6 @@ export type SalesInvoiceUncheckedUpdateManyInput = {
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customerId?: Prisma.NullableIntFieldUpdateOperationsInput | number | null
|
||||
posAccountId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceListRelationFilter = {
|
||||
@@ -426,14 +401,12 @@ export type SalesInvoiceCountOrderByAggregateInput = {
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
customerId?: Prisma.SortOrder
|
||||
posAccountId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceAvgOrderByAggregateInput = {
|
||||
id?: Prisma.SortOrder
|
||||
totalAmount?: Prisma.SortOrder
|
||||
customerId?: Prisma.SortOrder
|
||||
posAccountId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceMaxOrderByAggregateInput = {
|
||||
@@ -444,7 +417,6 @@ export type SalesInvoiceMaxOrderByAggregateInput = {
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
customerId?: Prisma.SortOrder
|
||||
posAccountId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceMinOrderByAggregateInput = {
|
||||
@@ -455,14 +427,12 @@ export type SalesInvoiceMinOrderByAggregateInput = {
|
||||
createdAt?: Prisma.SortOrder
|
||||
updatedAt?: Prisma.SortOrder
|
||||
customerId?: Prisma.SortOrder
|
||||
posAccountId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceSumOrderByAggregateInput = {
|
||||
id?: Prisma.SortOrder
|
||||
totalAmount?: Prisma.SortOrder
|
||||
customerId?: Prisma.SortOrder
|
||||
posAccountId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceScalarRelationFilter = {
|
||||
@@ -470,48 +440,6 @@ export type SalesInvoiceScalarRelationFilter = {
|
||||
isNot?: Prisma.SalesInvoiceWhereInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateNestedManyWithoutPosAccountInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput> | Prisma.SalesInvoiceCreateWithoutPosAccountInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutPosAccountInput | Prisma.SalesInvoiceCreateOrConnectWithoutPosAccountInput[]
|
||||
createMany?: Prisma.SalesInvoiceCreateManyPosAccountInputEnvelope
|
||||
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceUncheckedCreateNestedManyWithoutPosAccountInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput> | Prisma.SalesInvoiceCreateWithoutPosAccountInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutPosAccountInput | Prisma.SalesInvoiceCreateOrConnectWithoutPosAccountInput[]
|
||||
createMany?: Prisma.SalesInvoiceCreateManyPosAccountInputEnvelope
|
||||
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceUpdateManyWithoutPosAccountNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput> | Prisma.SalesInvoiceCreateWithoutPosAccountInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutPosAccountInput | Prisma.SalesInvoiceCreateOrConnectWithoutPosAccountInput[]
|
||||
upsert?: Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutPosAccountInput | Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutPosAccountInput[]
|
||||
createMany?: Prisma.SalesInvoiceCreateManyPosAccountInputEnvelope
|
||||
set?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
disconnect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
delete?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
update?: Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutPosAccountInput | Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutPosAccountInput[]
|
||||
updateMany?: Prisma.SalesInvoiceUpdateManyWithWhereWithoutPosAccountInput | Prisma.SalesInvoiceUpdateManyWithWhereWithoutPosAccountInput[]
|
||||
deleteMany?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceUncheckedUpdateManyWithoutPosAccountNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput> | Prisma.SalesInvoiceCreateWithoutPosAccountInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutPosAccountInput | Prisma.SalesInvoiceCreateOrConnectWithoutPosAccountInput[]
|
||||
upsert?: Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutPosAccountInput | Prisma.SalesInvoiceUpsertWithWhereUniqueWithoutPosAccountInput[]
|
||||
createMany?: Prisma.SalesInvoiceCreateManyPosAccountInputEnvelope
|
||||
set?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
disconnect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
delete?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
connect?: Prisma.SalesInvoiceWhereUniqueInput | Prisma.SalesInvoiceWhereUniqueInput[]
|
||||
update?: Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutPosAccountInput | Prisma.SalesInvoiceUpdateWithWhereUniqueWithoutPosAccountInput[]
|
||||
updateMany?: Prisma.SalesInvoiceUpdateManyWithWhereWithoutPosAccountInput | Prisma.SalesInvoiceUpdateManyWithWhereWithoutPosAccountInput[]
|
||||
deleteMany?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateNestedManyWithoutCustomerInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutCustomerInput, Prisma.SalesInvoiceUncheckedCreateWithoutCustomerInput> | Prisma.SalesInvoiceCreateWithoutCustomerInput[] | Prisma.SalesInvoiceUncheckedCreateWithoutCustomerInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceCreateOrConnectWithoutCustomerInput | Prisma.SalesInvoiceCreateOrConnectWithoutCustomerInput[]
|
||||
@@ -582,76 +510,12 @@ export type SalesInvoiceUpdateOneRequiredWithoutSalesInvoicePaymentsNestedInput
|
||||
update?: Prisma.XOR<Prisma.XOR<Prisma.SalesInvoiceUpdateToOneWithWhereWithoutSalesInvoicePaymentsInput, Prisma.SalesInvoiceUpdateWithoutSalesInvoicePaymentsInput>, Prisma.SalesInvoiceUncheckedUpdateWithoutSalesInvoicePaymentsInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateWithoutPosAccountInput = {
|
||||
code: string
|
||||
totalAmount: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: string | null
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customer?: Prisma.CustomerCreateNestedOneWithoutSalesInvoicesInput
|
||||
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceUncheckedCreateWithoutPosAccountInput = {
|
||||
id?: number
|
||||
code: string
|
||||
totalAmount: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: string | null
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customerId?: number | null
|
||||
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateOrConnectWithoutPosAccountInput = {
|
||||
where: Prisma.SalesInvoiceWhereUniqueInput
|
||||
create: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateManyPosAccountInputEnvelope = {
|
||||
data: Prisma.SalesInvoiceCreateManyPosAccountInput | Prisma.SalesInvoiceCreateManyPosAccountInput[]
|
||||
skipDuplicates?: boolean
|
||||
}
|
||||
|
||||
export type SalesInvoiceUpsertWithWhereUniqueWithoutPosAccountInput = {
|
||||
where: Prisma.SalesInvoiceWhereUniqueInput
|
||||
update: Prisma.XOR<Prisma.SalesInvoiceUpdateWithoutPosAccountInput, Prisma.SalesInvoiceUncheckedUpdateWithoutPosAccountInput>
|
||||
create: Prisma.XOR<Prisma.SalesInvoiceCreateWithoutPosAccountInput, Prisma.SalesInvoiceUncheckedCreateWithoutPosAccountInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceUpdateWithWhereUniqueWithoutPosAccountInput = {
|
||||
where: Prisma.SalesInvoiceWhereUniqueInput
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceUpdateWithoutPosAccountInput, Prisma.SalesInvoiceUncheckedUpdateWithoutPosAccountInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceUpdateManyWithWhereWithoutPosAccountInput = {
|
||||
where: Prisma.SalesInvoiceScalarWhereInput
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceUpdateManyMutationInput, Prisma.SalesInvoiceUncheckedUpdateManyWithoutPosAccountInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceScalarWhereInput = {
|
||||
AND?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
|
||||
OR?: Prisma.SalesInvoiceScalarWhereInput[]
|
||||
NOT?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
|
||||
id?: Prisma.IntFilter<"SalesInvoice"> | number
|
||||
code?: Prisma.StringFilter<"SalesInvoice"> | string
|
||||
totalAmount?: Prisma.DecimalFilter<"SalesInvoice"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null
|
||||
createdAt?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
|
||||
customerId?: Prisma.IntNullableFilter<"SalesInvoice"> | number | null
|
||||
posAccountId?: Prisma.IntFilter<"SalesInvoice"> | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateWithoutCustomerInput = {
|
||||
code: string
|
||||
totalAmount: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: string | null
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
posAccount: Prisma.PosAccountCreateNestedOneWithoutSalesInvoicesInput
|
||||
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
@@ -663,7 +527,6 @@ export type SalesInvoiceUncheckedCreateWithoutCustomerInput = {
|
||||
description?: string | null
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
posAccountId: number
|
||||
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
@@ -694,6 +557,19 @@ export type SalesInvoiceUpdateManyWithWhereWithoutCustomerInput = {
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceUpdateManyMutationInput, Prisma.SalesInvoiceUncheckedUpdateManyWithoutCustomerInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceScalarWhereInput = {
|
||||
AND?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
|
||||
OR?: Prisma.SalesInvoiceScalarWhereInput[]
|
||||
NOT?: Prisma.SalesInvoiceScalarWhereInput | Prisma.SalesInvoiceScalarWhereInput[]
|
||||
id?: Prisma.IntFilter<"SalesInvoice"> | number
|
||||
code?: Prisma.StringFilter<"SalesInvoice"> | string
|
||||
totalAmount?: Prisma.DecimalFilter<"SalesInvoice"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: Prisma.StringNullableFilter<"SalesInvoice"> | string | null
|
||||
createdAt?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
|
||||
updatedAt?: Prisma.DateTimeFilter<"SalesInvoice"> | Date | string
|
||||
customerId?: Prisma.IntNullableFilter<"SalesInvoice"> | number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateWithoutItemsInput = {
|
||||
code: string
|
||||
totalAmount: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
@@ -701,7 +577,6 @@ export type SalesInvoiceCreateWithoutItemsInput = {
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customer?: Prisma.CustomerCreateNestedOneWithoutSalesInvoicesInput
|
||||
posAccount: Prisma.PosAccountCreateNestedOneWithoutSalesInvoicesInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
|
||||
@@ -713,7 +588,6 @@ export type SalesInvoiceUncheckedCreateWithoutItemsInput = {
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customerId?: number | null
|
||||
posAccountId: number
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUncheckedCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
|
||||
@@ -740,7 +614,6 @@ export type SalesInvoiceUpdateWithoutItemsInput = {
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customer?: Prisma.CustomerUpdateOneWithoutSalesInvoicesNestedInput
|
||||
posAccount?: Prisma.PosAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
|
||||
@@ -752,7 +625,6 @@ export type SalesInvoiceUncheckedUpdateWithoutItemsInput = {
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customerId?: Prisma.NullableIntFieldUpdateOperationsInput | number | null
|
||||
posAccountId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
|
||||
@@ -763,7 +635,6 @@ export type SalesInvoiceCreateWithoutSalesInvoicePaymentsInput = {
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customer?: Prisma.CustomerCreateNestedOneWithoutSalesInvoicesInput
|
||||
posAccount: Prisma.PosAccountCreateNestedOneWithoutSalesInvoicesInput
|
||||
items?: Prisma.SalesInvoiceItemCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
|
||||
@@ -775,7 +646,6 @@ export type SalesInvoiceUncheckedCreateWithoutSalesInvoicePaymentsInput = {
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customerId?: number | null
|
||||
posAccountId: number
|
||||
items?: Prisma.SalesInvoiceItemUncheckedCreateNestedManyWithoutInvoiceInput
|
||||
}
|
||||
|
||||
@@ -802,7 +672,6 @@ export type SalesInvoiceUpdateWithoutSalesInvoicePaymentsInput = {
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customer?: Prisma.CustomerUpdateOneWithoutSalesInvoicesNestedInput
|
||||
posAccount?: Prisma.PosAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
|
||||
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
|
||||
@@ -814,53 +683,9 @@ export type SalesInvoiceUncheckedUpdateWithoutSalesInvoicePaymentsInput = {
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customerId?: Prisma.NullableIntFieldUpdateOperationsInput | number | null
|
||||
posAccountId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateManyPosAccountInput = {
|
||||
id?: number
|
||||
code: string
|
||||
totalAmount: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: string | null
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
customerId?: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceUpdateWithoutPosAccountInput = {
|
||||
code?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customer?: Prisma.CustomerUpdateOneWithoutSalesInvoicesNestedInput
|
||||
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceUncheckedUpdateWithoutPosAccountInput = {
|
||||
id?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
code?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customerId?: Prisma.NullableIntFieldUpdateOperationsInput | number | null
|
||||
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceUncheckedUpdateManyWithoutPosAccountInput = {
|
||||
id?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
code?: Prisma.StringFieldUpdateOperationsInput | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
customerId?: Prisma.NullableIntFieldUpdateOperationsInput | number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceCreateManyCustomerInput = {
|
||||
id?: number
|
||||
code: string
|
||||
@@ -868,7 +693,6 @@ export type SalesInvoiceCreateManyCustomerInput = {
|
||||
description?: string | null
|
||||
createdAt?: Date | string
|
||||
updatedAt?: Date | string
|
||||
posAccountId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceUpdateWithoutCustomerInput = {
|
||||
@@ -877,7 +701,6 @@ export type SalesInvoiceUpdateWithoutCustomerInput = {
|
||||
description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
posAccount?: Prisma.PosAccountUpdateOneRequiredWithoutSalesInvoicesNestedInput
|
||||
items?: Prisma.SalesInvoiceItemUpdateManyWithoutInvoiceNestedInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
@@ -889,7 +712,6 @@ export type SalesInvoiceUncheckedUpdateWithoutCustomerInput = {
|
||||
description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
posAccountId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
items?: Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput
|
||||
salesInvoicePayments?: Prisma.SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput
|
||||
}
|
||||
@@ -901,7 +723,6 @@ export type SalesInvoiceUncheckedUpdateManyWithoutCustomerInput = {
|
||||
description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
posAccountId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
|
||||
@@ -952,9 +773,7 @@ export type SalesInvoiceSelect<ExtArgs extends runtime.Types.Extensions.Internal
|
||||
createdAt?: boolean
|
||||
updatedAt?: boolean
|
||||
customerId?: boolean
|
||||
posAccountId?: boolean
|
||||
customer?: boolean | Prisma.SalesInvoice$customerArgs<ExtArgs>
|
||||
posAccount?: boolean | Prisma.PosAccountDefaultArgs<ExtArgs>
|
||||
items?: boolean | Prisma.SalesInvoice$itemsArgs<ExtArgs>
|
||||
salesInvoicePayments?: boolean | Prisma.SalesInvoice$salesInvoicePaymentsArgs<ExtArgs>
|
||||
_count?: boolean | Prisma.SalesInvoiceCountOutputTypeDefaultArgs<ExtArgs>
|
||||
@@ -970,13 +789,11 @@ export type SalesInvoiceSelectScalar = {
|
||||
createdAt?: boolean
|
||||
updatedAt?: boolean
|
||||
customerId?: boolean
|
||||
posAccountId?: boolean
|
||||
}
|
||||
|
||||
export type SalesInvoiceOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "code" | "totalAmount" | "description" | "createdAt" | "updatedAt" | "customerId" | "posAccountId", ExtArgs["result"]["salesInvoice"]>
|
||||
export type SalesInvoiceOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "code" | "totalAmount" | "description" | "createdAt" | "updatedAt" | "customerId", ExtArgs["result"]["salesInvoice"]>
|
||||
export type SalesInvoiceInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
customer?: boolean | Prisma.SalesInvoice$customerArgs<ExtArgs>
|
||||
posAccount?: boolean | Prisma.PosAccountDefaultArgs<ExtArgs>
|
||||
items?: boolean | Prisma.SalesInvoice$itemsArgs<ExtArgs>
|
||||
salesInvoicePayments?: boolean | Prisma.SalesInvoice$salesInvoicePaymentsArgs<ExtArgs>
|
||||
_count?: boolean | Prisma.SalesInvoiceCountOutputTypeDefaultArgs<ExtArgs>
|
||||
@@ -986,7 +803,6 @@ export type $SalesInvoicePayload<ExtArgs extends runtime.Types.Extensions.Intern
|
||||
name: "SalesInvoice"
|
||||
objects: {
|
||||
customer: Prisma.$CustomerPayload<ExtArgs> | null
|
||||
posAccount: Prisma.$PosAccountPayload<ExtArgs>
|
||||
items: Prisma.$SalesInvoiceItemPayload<ExtArgs>[]
|
||||
salesInvoicePayments: Prisma.$SalesInvoicePaymentPayload<ExtArgs>[]
|
||||
}
|
||||
@@ -998,7 +814,6 @@ export type $SalesInvoicePayload<ExtArgs extends runtime.Types.Extensions.Intern
|
||||
createdAt: Date
|
||||
updatedAt: Date
|
||||
customerId: number | null
|
||||
posAccountId: number
|
||||
}, ExtArgs["result"]["salesInvoice"]>
|
||||
composites: {}
|
||||
}
|
||||
@@ -1340,7 +1155,6 @@ readonly fields: SalesInvoiceFieldRefs;
|
||||
export interface Prisma__SalesInvoiceClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
|
||||
readonly [Symbol.toStringTag]: "PrismaPromise"
|
||||
customer<T extends Prisma.SalesInvoice$customerArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$customerArgs<ExtArgs>>): Prisma.Prisma__CustomerClient<runtime.Types.Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
|
||||
posAccount<T extends Prisma.PosAccountDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.PosAccountDefaultArgs<ExtArgs>>): Prisma.Prisma__PosAccountClient<runtime.Types.Result.GetResult<Prisma.$PosAccountPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
|
||||
items<T extends Prisma.SalesInvoice$itemsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$itemsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoiceItemPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
|
||||
salesInvoicePayments<T extends Prisma.SalesInvoice$salesInvoicePaymentsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoice$salesInvoicePaymentsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePaymentPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
|
||||
/**
|
||||
@@ -1379,7 +1193,6 @@ export interface SalesInvoiceFieldRefs {
|
||||
readonly createdAt: Prisma.FieldRef<"SalesInvoice", 'DateTime'>
|
||||
readonly updatedAt: Prisma.FieldRef<"SalesInvoice", 'DateTime'>
|
||||
readonly customerId: Prisma.FieldRef<"SalesInvoice", 'Int'>
|
||||
readonly posAccountId: Prisma.FieldRef<"SalesInvoice", 'Int'>
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -32,7 +32,8 @@ export type SalesInvoiceItemAvgAggregateOutputType = {
|
||||
unitPrice: runtime.Decimal | null
|
||||
totalAmount: runtime.Decimal | null
|
||||
invoiceId: number | null
|
||||
productId: number | null
|
||||
goodId: number | null
|
||||
serviceId: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemSumAggregateOutputType = {
|
||||
@@ -41,7 +42,8 @@ export type SalesInvoiceItemSumAggregateOutputType = {
|
||||
unitPrice: runtime.Decimal | null
|
||||
totalAmount: runtime.Decimal | null
|
||||
invoiceId: number | null
|
||||
productId: number | null
|
||||
goodId: number | null
|
||||
serviceId: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemMinAggregateOutputType = {
|
||||
@@ -51,7 +53,8 @@ export type SalesInvoiceItemMinAggregateOutputType = {
|
||||
totalAmount: runtime.Decimal | null
|
||||
createdAt: Date | null
|
||||
invoiceId: number | null
|
||||
productId: number | null
|
||||
goodId: number | null
|
||||
serviceId: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemMaxAggregateOutputType = {
|
||||
@@ -61,7 +64,8 @@ export type SalesInvoiceItemMaxAggregateOutputType = {
|
||||
totalAmount: runtime.Decimal | null
|
||||
createdAt: Date | null
|
||||
invoiceId: number | null
|
||||
productId: number | null
|
||||
goodId: number | null
|
||||
serviceId: number | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCountAggregateOutputType = {
|
||||
@@ -71,7 +75,8 @@ export type SalesInvoiceItemCountAggregateOutputType = {
|
||||
totalAmount: number
|
||||
createdAt: number
|
||||
invoiceId: number
|
||||
productId: number
|
||||
goodId: number
|
||||
serviceId: number
|
||||
_all: number
|
||||
}
|
||||
|
||||
@@ -82,7 +87,8 @@ export type SalesInvoiceItemAvgAggregateInputType = {
|
||||
unitPrice?: true
|
||||
totalAmount?: true
|
||||
invoiceId?: true
|
||||
productId?: true
|
||||
goodId?: true
|
||||
serviceId?: true
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemSumAggregateInputType = {
|
||||
@@ -91,7 +97,8 @@ export type SalesInvoiceItemSumAggregateInputType = {
|
||||
unitPrice?: true
|
||||
totalAmount?: true
|
||||
invoiceId?: true
|
||||
productId?: true
|
||||
goodId?: true
|
||||
serviceId?: true
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemMinAggregateInputType = {
|
||||
@@ -101,7 +108,8 @@ export type SalesInvoiceItemMinAggregateInputType = {
|
||||
totalAmount?: true
|
||||
createdAt?: true
|
||||
invoiceId?: true
|
||||
productId?: true
|
||||
goodId?: true
|
||||
serviceId?: true
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemMaxAggregateInputType = {
|
||||
@@ -111,7 +119,8 @@ export type SalesInvoiceItemMaxAggregateInputType = {
|
||||
totalAmount?: true
|
||||
createdAt?: true
|
||||
invoiceId?: true
|
||||
productId?: true
|
||||
goodId?: true
|
||||
serviceId?: true
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCountAggregateInputType = {
|
||||
@@ -121,7 +130,8 @@ export type SalesInvoiceItemCountAggregateInputType = {
|
||||
totalAmount?: true
|
||||
createdAt?: true
|
||||
invoiceId?: true
|
||||
productId?: true
|
||||
goodId?: true
|
||||
serviceId?: true
|
||||
_all?: true
|
||||
}
|
||||
|
||||
@@ -218,7 +228,8 @@ export type SalesInvoiceItemGroupByOutputType = {
|
||||
totalAmount: runtime.Decimal
|
||||
createdAt: Date
|
||||
invoiceId: number
|
||||
productId: number
|
||||
goodId: number
|
||||
serviceId: number
|
||||
_count: SalesInvoiceItemCountAggregateOutputType | null
|
||||
_avg: SalesInvoiceItemAvgAggregateOutputType | null
|
||||
_sum: SalesInvoiceItemSumAggregateOutputType | null
|
||||
@@ -251,9 +262,11 @@ export type SalesInvoiceItemWhereInput = {
|
||||
totalAmount?: Prisma.DecimalFilter<"SalesInvoiceItem"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFilter<"SalesInvoiceItem"> | Date | string
|
||||
invoiceId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
productId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
goodId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
serviceId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
invoice?: Prisma.XOR<Prisma.SalesInvoiceScalarRelationFilter, Prisma.SalesInvoiceWhereInput>
|
||||
product?: Prisma.XOR<Prisma.ProductScalarRelationFilter, Prisma.ProductWhereInput>
|
||||
good?: Prisma.XOR<Prisma.GoodNullableScalarRelationFilter, Prisma.GoodWhereInput> | null
|
||||
service?: Prisma.XOR<Prisma.ServiceNullableScalarRelationFilter, Prisma.ServiceWhereInput> | null
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemOrderByWithRelationInput = {
|
||||
@@ -263,9 +276,11 @@ export type SalesInvoiceItemOrderByWithRelationInput = {
|
||||
totalAmount?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
invoiceId?: Prisma.SortOrder
|
||||
productId?: Prisma.SortOrder
|
||||
goodId?: Prisma.SortOrder
|
||||
serviceId?: Prisma.SortOrder
|
||||
invoice?: Prisma.SalesInvoiceOrderByWithRelationInput
|
||||
product?: Prisma.ProductOrderByWithRelationInput
|
||||
good?: Prisma.GoodOrderByWithRelationInput
|
||||
service?: Prisma.ServiceOrderByWithRelationInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemWhereUniqueInput = Prisma.AtLeast<{
|
||||
@@ -278,9 +293,11 @@ export type SalesInvoiceItemWhereUniqueInput = Prisma.AtLeast<{
|
||||
totalAmount?: Prisma.DecimalFilter<"SalesInvoiceItem"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFilter<"SalesInvoiceItem"> | Date | string
|
||||
invoiceId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
productId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
goodId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
serviceId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
invoice?: Prisma.XOR<Prisma.SalesInvoiceScalarRelationFilter, Prisma.SalesInvoiceWhereInput>
|
||||
product?: Prisma.XOR<Prisma.ProductScalarRelationFilter, Prisma.ProductWhereInput>
|
||||
good?: Prisma.XOR<Prisma.GoodNullableScalarRelationFilter, Prisma.GoodWhereInput> | null
|
||||
service?: Prisma.XOR<Prisma.ServiceNullableScalarRelationFilter, Prisma.ServiceWhereInput> | null
|
||||
}, "id">
|
||||
|
||||
export type SalesInvoiceItemOrderByWithAggregationInput = {
|
||||
@@ -290,7 +307,8 @@ export type SalesInvoiceItemOrderByWithAggregationInput = {
|
||||
totalAmount?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
invoiceId?: Prisma.SortOrder
|
||||
productId?: Prisma.SortOrder
|
||||
goodId?: Prisma.SortOrder
|
||||
serviceId?: Prisma.SortOrder
|
||||
_count?: Prisma.SalesInvoiceItemCountOrderByAggregateInput
|
||||
_avg?: Prisma.SalesInvoiceItemAvgOrderByAggregateInput
|
||||
_max?: Prisma.SalesInvoiceItemMaxOrderByAggregateInput
|
||||
@@ -308,7 +326,8 @@ export type SalesInvoiceItemScalarWhereWithAggregatesInput = {
|
||||
totalAmount?: Prisma.DecimalWithAggregatesFilter<"SalesInvoiceItem"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeWithAggregatesFilter<"SalesInvoiceItem"> | Date | string
|
||||
invoiceId?: Prisma.IntWithAggregatesFilter<"SalesInvoiceItem"> | number
|
||||
productId?: Prisma.IntWithAggregatesFilter<"SalesInvoiceItem"> | number
|
||||
goodId?: Prisma.IntWithAggregatesFilter<"SalesInvoiceItem"> | number
|
||||
serviceId?: Prisma.IntWithAggregatesFilter<"SalesInvoiceItem"> | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateInput = {
|
||||
@@ -317,7 +336,8 @@ export type SalesInvoiceItemCreateInput = {
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoice: Prisma.SalesInvoiceCreateNestedOneWithoutItemsInput
|
||||
product: Prisma.ProductCreateNestedOneWithoutSalesInvoiceItemsInput
|
||||
good?: Prisma.GoodCreateNestedOneWithoutSalesInvoiceItemsInput
|
||||
service?: Prisma.ServiceCreateNestedOneWithoutSalesInvoiceItemsInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedCreateInput = {
|
||||
@@ -327,7 +347,8 @@ export type SalesInvoiceItemUncheckedCreateInput = {
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoiceId: number
|
||||
productId: number
|
||||
goodId: number
|
||||
serviceId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateInput = {
|
||||
@@ -336,7 +357,8 @@ export type SalesInvoiceItemUpdateInput = {
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoice?: Prisma.SalesInvoiceUpdateOneRequiredWithoutItemsNestedInput
|
||||
product?: Prisma.ProductUpdateOneRequiredWithoutSalesInvoiceItemsNestedInput
|
||||
good?: Prisma.GoodUpdateOneWithoutSalesInvoiceItemsNestedInput
|
||||
service?: Prisma.ServiceUpdateOneWithoutSalesInvoiceItemsNestedInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateInput = {
|
||||
@@ -346,7 +368,8 @@ export type SalesInvoiceItemUncheckedUpdateInput = {
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoiceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
productId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
goodId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
serviceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateManyInput = {
|
||||
@@ -356,7 +379,8 @@ export type SalesInvoiceItemCreateManyInput = {
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoiceId: number
|
||||
productId: number
|
||||
goodId: number
|
||||
serviceId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateManyMutationInput = {
|
||||
@@ -373,7 +397,8 @@ export type SalesInvoiceItemUncheckedUpdateManyInput = {
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoiceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
productId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
goodId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
serviceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemListRelationFilter = {
|
||||
@@ -393,7 +418,8 @@ export type SalesInvoiceItemCountOrderByAggregateInput = {
|
||||
totalAmount?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
invoiceId?: Prisma.SortOrder
|
||||
productId?: Prisma.SortOrder
|
||||
goodId?: Prisma.SortOrder
|
||||
serviceId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemAvgOrderByAggregateInput = {
|
||||
@@ -402,7 +428,8 @@ export type SalesInvoiceItemAvgOrderByAggregateInput = {
|
||||
unitPrice?: Prisma.SortOrder
|
||||
totalAmount?: Prisma.SortOrder
|
||||
invoiceId?: Prisma.SortOrder
|
||||
productId?: Prisma.SortOrder
|
||||
goodId?: Prisma.SortOrder
|
||||
serviceId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemMaxOrderByAggregateInput = {
|
||||
@@ -412,7 +439,8 @@ export type SalesInvoiceItemMaxOrderByAggregateInput = {
|
||||
totalAmount?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
invoiceId?: Prisma.SortOrder
|
||||
productId?: Prisma.SortOrder
|
||||
goodId?: Prisma.SortOrder
|
||||
serviceId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemMinOrderByAggregateInput = {
|
||||
@@ -422,7 +450,8 @@ export type SalesInvoiceItemMinOrderByAggregateInput = {
|
||||
totalAmount?: Prisma.SortOrder
|
||||
createdAt?: Prisma.SortOrder
|
||||
invoiceId?: Prisma.SortOrder
|
||||
productId?: Prisma.SortOrder
|
||||
goodId?: Prisma.SortOrder
|
||||
serviceId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemSumOrderByAggregateInput = {
|
||||
@@ -431,48 +460,49 @@ export type SalesInvoiceItemSumOrderByAggregateInput = {
|
||||
unitPrice?: Prisma.SortOrder
|
||||
totalAmount?: Prisma.SortOrder
|
||||
invoiceId?: Prisma.SortOrder
|
||||
productId?: Prisma.SortOrder
|
||||
goodId?: Prisma.SortOrder
|
||||
serviceId?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateNestedManyWithoutProductInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutProductInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput> | Prisma.SalesInvoiceItemCreateWithoutProductInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutProductInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutProductInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyProductInputEnvelope
|
||||
export type SalesInvoiceItemCreateNestedManyWithoutGoodInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutGoodInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput> | Prisma.SalesInvoiceItemCreateWithoutGoodInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutGoodInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutGoodInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyGoodInputEnvelope
|
||||
connect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedCreateNestedManyWithoutProductInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutProductInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput> | Prisma.SalesInvoiceItemCreateWithoutProductInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutProductInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutProductInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyProductInputEnvelope
|
||||
export type SalesInvoiceItemUncheckedCreateNestedManyWithoutGoodInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutGoodInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput> | Prisma.SalesInvoiceItemCreateWithoutGoodInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutGoodInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutGoodInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyGoodInputEnvelope
|
||||
connect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateManyWithoutProductNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutProductInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput> | Prisma.SalesInvoiceItemCreateWithoutProductInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutProductInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutProductInput[]
|
||||
upsert?: Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutProductInput | Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutProductInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyProductInputEnvelope
|
||||
export type SalesInvoiceItemUpdateManyWithoutGoodNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutGoodInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput> | Prisma.SalesInvoiceItemCreateWithoutGoodInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutGoodInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutGoodInput[]
|
||||
upsert?: Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutGoodInput | Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutGoodInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyGoodInputEnvelope
|
||||
set?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
disconnect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
delete?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
connect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
update?: Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutProductInput | Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutProductInput[]
|
||||
updateMany?: Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutProductInput | Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutProductInput[]
|
||||
update?: Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutGoodInput | Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutGoodInput[]
|
||||
updateMany?: Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutGoodInput | Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutGoodInput[]
|
||||
deleteMany?: Prisma.SalesInvoiceItemScalarWhereInput | Prisma.SalesInvoiceItemScalarWhereInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateManyWithoutProductNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutProductInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput> | Prisma.SalesInvoiceItemCreateWithoutProductInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutProductInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutProductInput[]
|
||||
upsert?: Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutProductInput | Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutProductInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyProductInputEnvelope
|
||||
export type SalesInvoiceItemUncheckedUpdateManyWithoutGoodNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutGoodInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput> | Prisma.SalesInvoiceItemCreateWithoutGoodInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutGoodInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutGoodInput[]
|
||||
upsert?: Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutGoodInput | Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutGoodInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyGoodInputEnvelope
|
||||
set?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
disconnect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
delete?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
connect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
update?: Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutProductInput | Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutProductInput[]
|
||||
updateMany?: Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutProductInput | Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutProductInput[]
|
||||
update?: Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutGoodInput | Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutGoodInput[]
|
||||
updateMany?: Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutGoodInput | Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutGoodInput[]
|
||||
deleteMany?: Prisma.SalesInvoiceItemScalarWhereInput | Prisma.SalesInvoiceItemScalarWhereInput[]
|
||||
}
|
||||
|
||||
@@ -518,47 +548,91 @@ export type SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceNestedInput = {
|
||||
deleteMany?: Prisma.SalesInvoiceItemScalarWhereInput | Prisma.SalesInvoiceItemScalarWhereInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateWithoutProductInput = {
|
||||
export type SalesInvoiceItemCreateNestedManyWithoutServiceInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutServiceInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput> | Prisma.SalesInvoiceItemCreateWithoutServiceInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutServiceInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutServiceInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyServiceInputEnvelope
|
||||
connect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedCreateNestedManyWithoutServiceInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutServiceInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput> | Prisma.SalesInvoiceItemCreateWithoutServiceInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutServiceInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutServiceInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyServiceInputEnvelope
|
||||
connect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateManyWithoutServiceNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutServiceInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput> | Prisma.SalesInvoiceItemCreateWithoutServiceInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutServiceInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutServiceInput[]
|
||||
upsert?: Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutServiceInput | Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutServiceInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyServiceInputEnvelope
|
||||
set?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
disconnect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
delete?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
connect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
update?: Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutServiceInput | Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutServiceInput[]
|
||||
updateMany?: Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutServiceInput | Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutServiceInput[]
|
||||
deleteMany?: Prisma.SalesInvoiceItemScalarWhereInput | Prisma.SalesInvoiceItemScalarWhereInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateManyWithoutServiceNestedInput = {
|
||||
create?: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutServiceInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput> | Prisma.SalesInvoiceItemCreateWithoutServiceInput[] | Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput[]
|
||||
connectOrCreate?: Prisma.SalesInvoiceItemCreateOrConnectWithoutServiceInput | Prisma.SalesInvoiceItemCreateOrConnectWithoutServiceInput[]
|
||||
upsert?: Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutServiceInput | Prisma.SalesInvoiceItemUpsertWithWhereUniqueWithoutServiceInput[]
|
||||
createMany?: Prisma.SalesInvoiceItemCreateManyServiceInputEnvelope
|
||||
set?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
disconnect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
delete?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
connect?: Prisma.SalesInvoiceItemWhereUniqueInput | Prisma.SalesInvoiceItemWhereUniqueInput[]
|
||||
update?: Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutServiceInput | Prisma.SalesInvoiceItemUpdateWithWhereUniqueWithoutServiceInput[]
|
||||
updateMany?: Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutServiceInput | Prisma.SalesInvoiceItemUpdateManyWithWhereWithoutServiceInput[]
|
||||
deleteMany?: Prisma.SalesInvoiceItemScalarWhereInput | Prisma.SalesInvoiceItemScalarWhereInput[]
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateWithoutGoodInput = {
|
||||
count: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoice: Prisma.SalesInvoiceCreateNestedOneWithoutItemsInput
|
||||
service?: Prisma.ServiceCreateNestedOneWithoutSalesInvoiceItemsInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedCreateWithoutProductInput = {
|
||||
export type SalesInvoiceItemUncheckedCreateWithoutGoodInput = {
|
||||
id?: number
|
||||
count: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoiceId: number
|
||||
serviceId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateOrConnectWithoutProductInput = {
|
||||
export type SalesInvoiceItemCreateOrConnectWithoutGoodInput = {
|
||||
where: Prisma.SalesInvoiceItemWhereUniqueInput
|
||||
create: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutProductInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput>
|
||||
create: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutGoodInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateManyProductInputEnvelope = {
|
||||
data: Prisma.SalesInvoiceItemCreateManyProductInput | Prisma.SalesInvoiceItemCreateManyProductInput[]
|
||||
export type SalesInvoiceItemCreateManyGoodInputEnvelope = {
|
||||
data: Prisma.SalesInvoiceItemCreateManyGoodInput | Prisma.SalesInvoiceItemCreateManyGoodInput[]
|
||||
skipDuplicates?: boolean
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpsertWithWhereUniqueWithoutProductInput = {
|
||||
export type SalesInvoiceItemUpsertWithWhereUniqueWithoutGoodInput = {
|
||||
where: Prisma.SalesInvoiceItemWhereUniqueInput
|
||||
update: Prisma.XOR<Prisma.SalesInvoiceItemUpdateWithoutProductInput, Prisma.SalesInvoiceItemUncheckedUpdateWithoutProductInput>
|
||||
create: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutProductInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutProductInput>
|
||||
update: Prisma.XOR<Prisma.SalesInvoiceItemUpdateWithoutGoodInput, Prisma.SalesInvoiceItemUncheckedUpdateWithoutGoodInput>
|
||||
create: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutGoodInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutGoodInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateWithWhereUniqueWithoutProductInput = {
|
||||
export type SalesInvoiceItemUpdateWithWhereUniqueWithoutGoodInput = {
|
||||
where: Prisma.SalesInvoiceItemWhereUniqueInput
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceItemUpdateWithoutProductInput, Prisma.SalesInvoiceItemUncheckedUpdateWithoutProductInput>
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceItemUpdateWithoutGoodInput, Prisma.SalesInvoiceItemUncheckedUpdateWithoutGoodInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateManyWithWhereWithoutProductInput = {
|
||||
export type SalesInvoiceItemUpdateManyWithWhereWithoutGoodInput = {
|
||||
where: Prisma.SalesInvoiceItemScalarWhereInput
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceItemUpdateManyMutationInput, Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutProductInput>
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceItemUpdateManyMutationInput, Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutGoodInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemScalarWhereInput = {
|
||||
@@ -571,7 +645,8 @@ export type SalesInvoiceItemScalarWhereInput = {
|
||||
totalAmount?: Prisma.DecimalFilter<"SalesInvoiceItem"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFilter<"SalesInvoiceItem"> | Date | string
|
||||
invoiceId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
productId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
goodId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
serviceId?: Prisma.IntFilter<"SalesInvoiceItem"> | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateWithoutInvoiceInput = {
|
||||
@@ -579,7 +654,8 @@ export type SalesInvoiceItemCreateWithoutInvoiceInput = {
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
product: Prisma.ProductCreateNestedOneWithoutSalesInvoiceItemsInput
|
||||
good?: Prisma.GoodCreateNestedOneWithoutSalesInvoiceItemsInput
|
||||
service?: Prisma.ServiceCreateNestedOneWithoutSalesInvoiceItemsInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedCreateWithoutInvoiceInput = {
|
||||
@@ -588,7 +664,8 @@ export type SalesInvoiceItemUncheckedCreateWithoutInvoiceInput = {
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
productId: number
|
||||
goodId: number
|
||||
serviceId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateOrConnectWithoutInvoiceInput = {
|
||||
@@ -617,39 +694,88 @@ export type SalesInvoiceItemUpdateManyWithWhereWithoutInvoiceInput = {
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceItemUpdateManyMutationInput, Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateManyProductInput = {
|
||||
export type SalesInvoiceItemCreateWithoutServiceInput = {
|
||||
count: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoice: Prisma.SalesInvoiceCreateNestedOneWithoutItemsInput
|
||||
good?: Prisma.GoodCreateNestedOneWithoutSalesInvoiceItemsInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedCreateWithoutServiceInput = {
|
||||
id?: number
|
||||
count: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoiceId: number
|
||||
goodId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateWithoutProductInput = {
|
||||
export type SalesInvoiceItemCreateOrConnectWithoutServiceInput = {
|
||||
where: Prisma.SalesInvoiceItemWhereUniqueInput
|
||||
create: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutServiceInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateManyServiceInputEnvelope = {
|
||||
data: Prisma.SalesInvoiceItemCreateManyServiceInput | Prisma.SalesInvoiceItemCreateManyServiceInput[]
|
||||
skipDuplicates?: boolean
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpsertWithWhereUniqueWithoutServiceInput = {
|
||||
where: Prisma.SalesInvoiceItemWhereUniqueInput
|
||||
update: Prisma.XOR<Prisma.SalesInvoiceItemUpdateWithoutServiceInput, Prisma.SalesInvoiceItemUncheckedUpdateWithoutServiceInput>
|
||||
create: Prisma.XOR<Prisma.SalesInvoiceItemCreateWithoutServiceInput, Prisma.SalesInvoiceItemUncheckedCreateWithoutServiceInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateWithWhereUniqueWithoutServiceInput = {
|
||||
where: Prisma.SalesInvoiceItemWhereUniqueInput
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceItemUpdateWithoutServiceInput, Prisma.SalesInvoiceItemUncheckedUpdateWithoutServiceInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateManyWithWhereWithoutServiceInput = {
|
||||
where: Prisma.SalesInvoiceItemScalarWhereInput
|
||||
data: Prisma.XOR<Prisma.SalesInvoiceItemUpdateManyMutationInput, Prisma.SalesInvoiceItemUncheckedUpdateManyWithoutServiceInput>
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateManyGoodInput = {
|
||||
id?: number
|
||||
count: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoiceId: number
|
||||
serviceId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateWithoutGoodInput = {
|
||||
count?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoice?: Prisma.SalesInvoiceUpdateOneRequiredWithoutItemsNestedInput
|
||||
service?: Prisma.ServiceUpdateOneWithoutSalesInvoiceItemsNestedInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateWithoutProductInput = {
|
||||
export type SalesInvoiceItemUncheckedUpdateWithoutGoodInput = {
|
||||
id?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
count?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoiceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
serviceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateManyWithoutProductInput = {
|
||||
export type SalesInvoiceItemUncheckedUpdateManyWithoutGoodInput = {
|
||||
id?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
count?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoiceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
serviceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateManyInvoiceInput = {
|
||||
@@ -658,7 +784,8 @@ export type SalesInvoiceItemCreateManyInvoiceInput = {
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
productId: number
|
||||
goodId: number
|
||||
serviceId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateWithoutInvoiceInput = {
|
||||
@@ -666,7 +793,8 @@ export type SalesInvoiceItemUpdateWithoutInvoiceInput = {
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
product?: Prisma.ProductUpdateOneRequiredWithoutSalesInvoiceItemsNestedInput
|
||||
good?: Prisma.GoodUpdateOneWithoutSalesInvoiceItemsNestedInput
|
||||
service?: Prisma.ServiceUpdateOneWithoutSalesInvoiceItemsNestedInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateWithoutInvoiceInput = {
|
||||
@@ -675,7 +803,8 @@ export type SalesInvoiceItemUncheckedUpdateWithoutInvoiceInput = {
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
productId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
goodId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
serviceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceInput = {
|
||||
@@ -684,7 +813,47 @@ export type SalesInvoiceItemUncheckedUpdateManyWithoutInvoiceInput = {
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
productId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
goodId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
serviceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemCreateManyServiceInput = {
|
||||
id?: number
|
||||
count: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Date | string
|
||||
invoiceId: number
|
||||
goodId: number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUpdateWithoutServiceInput = {
|
||||
count?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoice?: Prisma.SalesInvoiceUpdateOneRequiredWithoutItemsNestedInput
|
||||
good?: Prisma.GoodUpdateOneWithoutSalesInvoiceItemsNestedInput
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateWithoutServiceInput = {
|
||||
id?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
count?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoiceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
goodId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemUncheckedUpdateManyWithoutServiceInput = {
|
||||
id?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
count?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
unitPrice?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
totalAmount?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
|
||||
invoiceId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
goodId?: Prisma.IntFieldUpdateOperationsInput | number
|
||||
}
|
||||
|
||||
|
||||
@@ -696,9 +865,11 @@ export type SalesInvoiceItemSelect<ExtArgs extends runtime.Types.Extensions.Inte
|
||||
totalAmount?: boolean
|
||||
createdAt?: boolean
|
||||
invoiceId?: boolean
|
||||
productId?: boolean
|
||||
goodId?: boolean
|
||||
serviceId?: boolean
|
||||
invoice?: boolean | Prisma.SalesInvoiceDefaultArgs<ExtArgs>
|
||||
product?: boolean | Prisma.ProductDefaultArgs<ExtArgs>
|
||||
good?: boolean | Prisma.SalesInvoiceItem$goodArgs<ExtArgs>
|
||||
service?: boolean | Prisma.SalesInvoiceItem$serviceArgs<ExtArgs>
|
||||
}, ExtArgs["result"]["salesInvoiceItem"]>
|
||||
|
||||
|
||||
@@ -710,20 +881,23 @@ export type SalesInvoiceItemSelectScalar = {
|
||||
totalAmount?: boolean
|
||||
createdAt?: boolean
|
||||
invoiceId?: boolean
|
||||
productId?: boolean
|
||||
goodId?: boolean
|
||||
serviceId?: boolean
|
||||
}
|
||||
|
||||
export type SalesInvoiceItemOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "count" | "unitPrice" | "totalAmount" | "createdAt" | "invoiceId" | "productId", ExtArgs["result"]["salesInvoiceItem"]>
|
||||
export type SalesInvoiceItemOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "count" | "unitPrice" | "totalAmount" | "createdAt" | "invoiceId" | "goodId" | "serviceId", ExtArgs["result"]["salesInvoiceItem"]>
|
||||
export type SalesInvoiceItemInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
invoice?: boolean | Prisma.SalesInvoiceDefaultArgs<ExtArgs>
|
||||
product?: boolean | Prisma.ProductDefaultArgs<ExtArgs>
|
||||
good?: boolean | Prisma.SalesInvoiceItem$goodArgs<ExtArgs>
|
||||
service?: boolean | Prisma.SalesInvoiceItem$serviceArgs<ExtArgs>
|
||||
}
|
||||
|
||||
export type $SalesInvoiceItemPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
name: "SalesInvoiceItem"
|
||||
objects: {
|
||||
invoice: Prisma.$SalesInvoicePayload<ExtArgs>
|
||||
product: Prisma.$ProductPayload<ExtArgs>
|
||||
good: Prisma.$GoodPayload<ExtArgs> | null
|
||||
service: Prisma.$ServicePayload<ExtArgs> | null
|
||||
}
|
||||
scalars: runtime.Types.Extensions.GetPayloadResult<{
|
||||
id: number
|
||||
@@ -732,7 +906,8 @@ export type $SalesInvoiceItemPayload<ExtArgs extends runtime.Types.Extensions.In
|
||||
totalAmount: runtime.Decimal
|
||||
createdAt: Date
|
||||
invoiceId: number
|
||||
productId: number
|
||||
goodId: number
|
||||
serviceId: number
|
||||
}, ExtArgs["result"]["salesInvoiceItem"]>
|
||||
composites: {}
|
||||
}
|
||||
@@ -1074,7 +1249,8 @@ readonly fields: SalesInvoiceItemFieldRefs;
|
||||
export interface Prisma__SalesInvoiceItemClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
|
||||
readonly [Symbol.toStringTag]: "PrismaPromise"
|
||||
invoice<T extends Prisma.SalesInvoiceDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoiceDefaultArgs<ExtArgs>>): Prisma.Prisma__SalesInvoiceClient<runtime.Types.Result.GetResult<Prisma.$SalesInvoicePayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
|
||||
product<T extends Prisma.ProductDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ProductDefaultArgs<ExtArgs>>): Prisma.Prisma__ProductClient<runtime.Types.Result.GetResult<Prisma.$ProductPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
|
||||
good<T extends Prisma.SalesInvoiceItem$goodArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoiceItem$goodArgs<ExtArgs>>): Prisma.Prisma__GoodClient<runtime.Types.Result.GetResult<Prisma.$GoodPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
|
||||
service<T extends Prisma.SalesInvoiceItem$serviceArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.SalesInvoiceItem$serviceArgs<ExtArgs>>): Prisma.Prisma__ServiceClient<runtime.Types.Result.GetResult<Prisma.$ServicePayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
|
||||
/**
|
||||
* Attaches callbacks for the resolution and/or rejection of the Promise.
|
||||
* @param onfulfilled The callback to execute when the Promise is resolved.
|
||||
@@ -1110,7 +1286,8 @@ export interface SalesInvoiceItemFieldRefs {
|
||||
readonly totalAmount: Prisma.FieldRef<"SalesInvoiceItem", 'Decimal'>
|
||||
readonly createdAt: Prisma.FieldRef<"SalesInvoiceItem", 'DateTime'>
|
||||
readonly invoiceId: Prisma.FieldRef<"SalesInvoiceItem", 'Int'>
|
||||
readonly productId: Prisma.FieldRef<"SalesInvoiceItem", 'Int'>
|
||||
readonly goodId: Prisma.FieldRef<"SalesInvoiceItem", 'Int'>
|
||||
readonly serviceId: Prisma.FieldRef<"SalesInvoiceItem", 'Int'>
|
||||
}
|
||||
|
||||
|
||||
@@ -1453,6 +1630,44 @@ export type SalesInvoiceItemDeleteManyArgs<ExtArgs extends runtime.Types.Extensi
|
||||
limit?: number
|
||||
}
|
||||
|
||||
/**
|
||||
* SalesInvoiceItem.good
|
||||
*/
|
||||
export type SalesInvoiceItem$goodArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Select specific fields to fetch from the Good
|
||||
*/
|
||||
select?: Prisma.GoodSelect<ExtArgs> | null
|
||||
/**
|
||||
* Omit specific fields from the Good
|
||||
*/
|
||||
omit?: Prisma.GoodOmit<ExtArgs> | null
|
||||
/**
|
||||
* Choose, which related nodes to fetch as well
|
||||
*/
|
||||
include?: Prisma.GoodInclude<ExtArgs> | null
|
||||
where?: Prisma.GoodWhereInput
|
||||
}
|
||||
|
||||
/**
|
||||
* SalesInvoiceItem.service
|
||||
*/
|
||||
export type SalesInvoiceItem$serviceArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Select specific fields to fetch from the Service
|
||||
*/
|
||||
select?: Prisma.ServiceSelect<ExtArgs> | null
|
||||
/**
|
||||
* Omit specific fields from the Service
|
||||
*/
|
||||
omit?: Prisma.ServiceOmit<ExtArgs> | null
|
||||
/**
|
||||
* Choose, which related nodes to fetch as well
|
||||
*/
|
||||
include?: Prisma.ServiceInclude<ExtArgs> | null
|
||||
where?: Prisma.ServiceWhereInput
|
||||
}
|
||||
|
||||
/**
|
||||
* SalesInvoiceItem without action
|
||||
*/
|
||||
|
||||
@@ -434,6 +434,10 @@ export type SalesInvoicePaymentUncheckedUpdateManyWithoutInvoiceNestedInput = {
|
||||
deleteMany?: Prisma.SalesInvoicePaymentScalarWhereInput | Prisma.SalesInvoicePaymentScalarWhereInput[]
|
||||
}
|
||||
|
||||
export type EnumPaymentMethodTypeFieldUpdateOperationsInput = {
|
||||
set?: $Enums.PaymentMethodType
|
||||
}
|
||||
|
||||
export type SalesInvoicePaymentCreateWithoutInvoiceInput = {
|
||||
amount: runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
paymentMethod: $Enums.PaymentMethodType
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,719 +0,0 @@
|
||||
|
||||
/* !!! This is code generated by Prisma. Do not edit directly. !!! */
|
||||
/* eslint-disable */
|
||||
// biome-ignore-all lint: generated file
|
||||
// @ts-nocheck
|
||||
/*
|
||||
* This file exports the `StockAvailableView` model and its related types.
|
||||
*
|
||||
* 🟢 You can import this file directly.
|
||||
*/
|
||||
import type * as runtime from "@prisma/client/runtime/client"
|
||||
import type * as $Enums from "../enums.js"
|
||||
import type * as Prisma from "../internal/prismaNamespace.js"
|
||||
|
||||
/**
|
||||
* Model StockAvailableView
|
||||
*
|
||||
*/
|
||||
export type StockAvailableViewModel = runtime.Types.Result.DefaultSelection<Prisma.$StockAvailableViewPayload>
|
||||
|
||||
export type AggregateStockAvailableView = {
|
||||
_count: StockAvailableViewCountAggregateOutputType | null
|
||||
_avg: StockAvailableViewAvgAggregateOutputType | null
|
||||
_sum: StockAvailableViewSumAggregateOutputType | null
|
||||
_min: StockAvailableViewMinAggregateOutputType | null
|
||||
_max: StockAvailableViewMaxAggregateOutputType | null
|
||||
}
|
||||
|
||||
export type StockAvailableViewAvgAggregateOutputType = {
|
||||
productId: number | null
|
||||
inventoryId: number | null
|
||||
physicalQuantity: runtime.Decimal | null
|
||||
reservedQuantity: runtime.Decimal | null
|
||||
availableQuantity: runtime.Decimal | null
|
||||
}
|
||||
|
||||
export type StockAvailableViewSumAggregateOutputType = {
|
||||
productId: number | null
|
||||
inventoryId: number | null
|
||||
physicalQuantity: runtime.Decimal | null
|
||||
reservedQuantity: runtime.Decimal | null
|
||||
availableQuantity: runtime.Decimal | null
|
||||
}
|
||||
|
||||
export type StockAvailableViewMinAggregateOutputType = {
|
||||
productId: number | null
|
||||
inventoryId: number | null
|
||||
physicalQuantity: runtime.Decimal | null
|
||||
reservedQuantity: runtime.Decimal | null
|
||||
availableQuantity: runtime.Decimal | null
|
||||
}
|
||||
|
||||
export type StockAvailableViewMaxAggregateOutputType = {
|
||||
productId: number | null
|
||||
inventoryId: number | null
|
||||
physicalQuantity: runtime.Decimal | null
|
||||
reservedQuantity: runtime.Decimal | null
|
||||
availableQuantity: runtime.Decimal | null
|
||||
}
|
||||
|
||||
export type StockAvailableViewCountAggregateOutputType = {
|
||||
productId: number
|
||||
inventoryId: number
|
||||
physicalQuantity: number
|
||||
reservedQuantity: number
|
||||
availableQuantity: number
|
||||
_all: number
|
||||
}
|
||||
|
||||
|
||||
export type StockAvailableViewAvgAggregateInputType = {
|
||||
productId?: true
|
||||
inventoryId?: true
|
||||
physicalQuantity?: true
|
||||
reservedQuantity?: true
|
||||
availableQuantity?: true
|
||||
}
|
||||
|
||||
export type StockAvailableViewSumAggregateInputType = {
|
||||
productId?: true
|
||||
inventoryId?: true
|
||||
physicalQuantity?: true
|
||||
reservedQuantity?: true
|
||||
availableQuantity?: true
|
||||
}
|
||||
|
||||
export type StockAvailableViewMinAggregateInputType = {
|
||||
productId?: true
|
||||
inventoryId?: true
|
||||
physicalQuantity?: true
|
||||
reservedQuantity?: true
|
||||
availableQuantity?: true
|
||||
}
|
||||
|
||||
export type StockAvailableViewMaxAggregateInputType = {
|
||||
productId?: true
|
||||
inventoryId?: true
|
||||
physicalQuantity?: true
|
||||
reservedQuantity?: true
|
||||
availableQuantity?: true
|
||||
}
|
||||
|
||||
export type StockAvailableViewCountAggregateInputType = {
|
||||
productId?: true
|
||||
inventoryId?: true
|
||||
physicalQuantity?: true
|
||||
reservedQuantity?: true
|
||||
availableQuantity?: true
|
||||
_all?: true
|
||||
}
|
||||
|
||||
export type StockAvailableViewAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Filter which StockAvailableView to aggregate.
|
||||
*/
|
||||
where?: Prisma.StockAvailableViewWhereInput
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
||||
*
|
||||
* Determine the order of StockAvailableViews to fetch.
|
||||
*/
|
||||
orderBy?: Prisma.StockAvailableViewOrderByWithRelationInput | Prisma.StockAvailableViewOrderByWithRelationInput[]
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
||||
*
|
||||
* Take `±n` StockAvailableViews 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` StockAvailableViews.
|
||||
*/
|
||||
skip?: number
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
||||
*
|
||||
* Count returned StockAvailableViews
|
||||
**/
|
||||
_count?: true | StockAvailableViewCountAggregateInputType
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
||||
*
|
||||
* Select which fields to average
|
||||
**/
|
||||
_avg?: StockAvailableViewAvgAggregateInputType
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
||||
*
|
||||
* Select which fields to sum
|
||||
**/
|
||||
_sum?: StockAvailableViewSumAggregateInputType
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
||||
*
|
||||
* Select which fields to find the minimum value
|
||||
**/
|
||||
_min?: StockAvailableViewMinAggregateInputType
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
|
||||
*
|
||||
* Select which fields to find the maximum value
|
||||
**/
|
||||
_max?: StockAvailableViewMaxAggregateInputType
|
||||
}
|
||||
|
||||
export type GetStockAvailableViewAggregateType<T extends StockAvailableViewAggregateArgs> = {
|
||||
[P in keyof T & keyof AggregateStockAvailableView]: P extends '_count' | 'count'
|
||||
? T[P] extends true
|
||||
? number
|
||||
: Prisma.GetScalarType<T[P], AggregateStockAvailableView[P]>
|
||||
: Prisma.GetScalarType<T[P], AggregateStockAvailableView[P]>
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
export type StockAvailableViewGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
where?: Prisma.StockAvailableViewWhereInput
|
||||
orderBy?: Prisma.StockAvailableViewOrderByWithAggregationInput | Prisma.StockAvailableViewOrderByWithAggregationInput[]
|
||||
by: Prisma.StockAvailableViewScalarFieldEnum[] | Prisma.StockAvailableViewScalarFieldEnum
|
||||
having?: Prisma.StockAvailableViewScalarWhereWithAggregatesInput
|
||||
take?: number
|
||||
skip?: number
|
||||
_count?: StockAvailableViewCountAggregateInputType | true
|
||||
_avg?: StockAvailableViewAvgAggregateInputType
|
||||
_sum?: StockAvailableViewSumAggregateInputType
|
||||
_min?: StockAvailableViewMinAggregateInputType
|
||||
_max?: StockAvailableViewMaxAggregateInputType
|
||||
}
|
||||
|
||||
export type StockAvailableViewGroupByOutputType = {
|
||||
productId: number
|
||||
inventoryId: number
|
||||
physicalQuantity: runtime.Decimal
|
||||
reservedQuantity: runtime.Decimal
|
||||
availableQuantity: runtime.Decimal
|
||||
_count: StockAvailableViewCountAggregateOutputType | null
|
||||
_avg: StockAvailableViewAvgAggregateOutputType | null
|
||||
_sum: StockAvailableViewSumAggregateOutputType | null
|
||||
_min: StockAvailableViewMinAggregateOutputType | null
|
||||
_max: StockAvailableViewMaxAggregateOutputType | null
|
||||
}
|
||||
|
||||
type GetStockAvailableViewGroupByPayload<T extends StockAvailableViewGroupByArgs> = Prisma.PrismaPromise<
|
||||
Array<
|
||||
Prisma.PickEnumerable<StockAvailableViewGroupByOutputType, T['by']> &
|
||||
{
|
||||
[P in ((keyof T) & (keyof StockAvailableViewGroupByOutputType))]: P extends '_count'
|
||||
? T[P] extends boolean
|
||||
? number
|
||||
: Prisma.GetScalarType<T[P], StockAvailableViewGroupByOutputType[P]>
|
||||
: Prisma.GetScalarType<T[P], StockAvailableViewGroupByOutputType[P]>
|
||||
}
|
||||
>
|
||||
>
|
||||
|
||||
|
||||
|
||||
export type StockAvailableViewWhereInput = {
|
||||
AND?: Prisma.StockAvailableViewWhereInput | Prisma.StockAvailableViewWhereInput[]
|
||||
OR?: Prisma.StockAvailableViewWhereInput[]
|
||||
NOT?: Prisma.StockAvailableViewWhereInput | Prisma.StockAvailableViewWhereInput[]
|
||||
productId?: Prisma.IntFilter<"StockAvailableView"> | number
|
||||
inventoryId?: Prisma.IntFilter<"StockAvailableView"> | number
|
||||
physicalQuantity?: Prisma.DecimalFilter<"StockAvailableView"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
reservedQuantity?: Prisma.DecimalFilter<"StockAvailableView"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
availableQuantity?: Prisma.DecimalFilter<"StockAvailableView"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
}
|
||||
|
||||
export type StockAvailableViewOrderByWithRelationInput = {
|
||||
productId?: Prisma.SortOrder
|
||||
inventoryId?: Prisma.SortOrder
|
||||
physicalQuantity?: Prisma.SortOrder
|
||||
reservedQuantity?: Prisma.SortOrder
|
||||
availableQuantity?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type StockAvailableViewOrderByWithAggregationInput = {
|
||||
productId?: Prisma.SortOrder
|
||||
inventoryId?: Prisma.SortOrder
|
||||
physicalQuantity?: Prisma.SortOrder
|
||||
reservedQuantity?: Prisma.SortOrder
|
||||
availableQuantity?: Prisma.SortOrder
|
||||
_count?: Prisma.StockAvailableViewCountOrderByAggregateInput
|
||||
_avg?: Prisma.StockAvailableViewAvgOrderByAggregateInput
|
||||
_max?: Prisma.StockAvailableViewMaxOrderByAggregateInput
|
||||
_min?: Prisma.StockAvailableViewMinOrderByAggregateInput
|
||||
_sum?: Prisma.StockAvailableViewSumOrderByAggregateInput
|
||||
}
|
||||
|
||||
export type StockAvailableViewScalarWhereWithAggregatesInput = {
|
||||
AND?: Prisma.StockAvailableViewScalarWhereWithAggregatesInput | Prisma.StockAvailableViewScalarWhereWithAggregatesInput[]
|
||||
OR?: Prisma.StockAvailableViewScalarWhereWithAggregatesInput[]
|
||||
NOT?: Prisma.StockAvailableViewScalarWhereWithAggregatesInput | Prisma.StockAvailableViewScalarWhereWithAggregatesInput[]
|
||||
productId?: Prisma.IntWithAggregatesFilter<"StockAvailableView"> | number
|
||||
inventoryId?: Prisma.IntWithAggregatesFilter<"StockAvailableView"> | number
|
||||
physicalQuantity?: Prisma.DecimalWithAggregatesFilter<"StockAvailableView"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
reservedQuantity?: Prisma.DecimalWithAggregatesFilter<"StockAvailableView"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
availableQuantity?: Prisma.DecimalWithAggregatesFilter<"StockAvailableView"> | runtime.Decimal | runtime.DecimalJsLike | number | string
|
||||
}
|
||||
|
||||
export type StockAvailableViewCountOrderByAggregateInput = {
|
||||
productId?: Prisma.SortOrder
|
||||
inventoryId?: Prisma.SortOrder
|
||||
physicalQuantity?: Prisma.SortOrder
|
||||
reservedQuantity?: Prisma.SortOrder
|
||||
availableQuantity?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type StockAvailableViewAvgOrderByAggregateInput = {
|
||||
productId?: Prisma.SortOrder
|
||||
inventoryId?: Prisma.SortOrder
|
||||
physicalQuantity?: Prisma.SortOrder
|
||||
reservedQuantity?: Prisma.SortOrder
|
||||
availableQuantity?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type StockAvailableViewMaxOrderByAggregateInput = {
|
||||
productId?: Prisma.SortOrder
|
||||
inventoryId?: Prisma.SortOrder
|
||||
physicalQuantity?: Prisma.SortOrder
|
||||
reservedQuantity?: Prisma.SortOrder
|
||||
availableQuantity?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type StockAvailableViewMinOrderByAggregateInput = {
|
||||
productId?: Prisma.SortOrder
|
||||
inventoryId?: Prisma.SortOrder
|
||||
physicalQuantity?: Prisma.SortOrder
|
||||
reservedQuantity?: Prisma.SortOrder
|
||||
availableQuantity?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
export type StockAvailableViewSumOrderByAggregateInput = {
|
||||
productId?: Prisma.SortOrder
|
||||
inventoryId?: Prisma.SortOrder
|
||||
physicalQuantity?: Prisma.SortOrder
|
||||
reservedQuantity?: Prisma.SortOrder
|
||||
availableQuantity?: Prisma.SortOrder
|
||||
}
|
||||
|
||||
|
||||
|
||||
export type StockAvailableViewSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
|
||||
productId?: boolean
|
||||
inventoryId?: boolean
|
||||
physicalQuantity?: boolean
|
||||
reservedQuantity?: boolean
|
||||
availableQuantity?: boolean
|
||||
}, ExtArgs["result"]["stockAvailableView"]>
|
||||
|
||||
|
||||
|
||||
export type StockAvailableViewSelectScalar = {
|
||||
productId?: boolean
|
||||
inventoryId?: boolean
|
||||
physicalQuantity?: boolean
|
||||
reservedQuantity?: boolean
|
||||
availableQuantity?: boolean
|
||||
}
|
||||
|
||||
export type StockAvailableViewOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"productId" | "inventoryId" | "physicalQuantity" | "reservedQuantity" | "availableQuantity", ExtArgs["result"]["stockAvailableView"]>
|
||||
|
||||
export type $StockAvailableViewPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
name: "StockAvailableView"
|
||||
objects: {}
|
||||
scalars: runtime.Types.Extensions.GetPayloadResult<{
|
||||
productId: number
|
||||
inventoryId: number
|
||||
physicalQuantity: runtime.Decimal
|
||||
reservedQuantity: runtime.Decimal
|
||||
availableQuantity: runtime.Decimal
|
||||
}, ExtArgs["result"]["stockAvailableView"]>
|
||||
composites: {}
|
||||
}
|
||||
|
||||
export type StockAvailableViewGetPayload<S extends boolean | null | undefined | StockAvailableViewDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$StockAvailableViewPayload, S>
|
||||
|
||||
export type StockAvailableViewCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> =
|
||||
Omit<StockAvailableViewFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
|
||||
select?: StockAvailableViewCountAggregateInputType | true
|
||||
}
|
||||
|
||||
export interface StockAvailableViewDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
|
||||
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['StockAvailableView'], meta: { name: 'StockAvailableView' } }
|
||||
/**
|
||||
* Find the first StockAvailableView 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 {StockAvailableViewFindFirstArgs} args - Arguments to find a StockAvailableView
|
||||
* @example
|
||||
* // Get one StockAvailableView
|
||||
* const stockAvailableView = await prisma.stockAvailableView.findFirst({
|
||||
* where: {
|
||||
* // ... provide filter here
|
||||
* }
|
||||
* })
|
||||
*/
|
||||
findFirst<T extends StockAvailableViewFindFirstArgs, TakeDependenciesValidator extends "take" extends Prisma.Keys<T> ? {
|
||||
orderBy: {}
|
||||
} : {}, SkipDependenciesValidator extends "skip" extends Prisma.Keys<T> ? {
|
||||
orderBy: {}
|
||||
} : {}>(args?: Prisma.SelectSubset<T, StockAvailableViewFindFirstArgs<ExtArgs>> & TakeDependenciesValidator & SkipDependenciesValidator): Prisma.Prisma__StockAvailableViewClient<runtime.Types.Result.GetResult<Prisma.$StockAvailableViewPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
|
||||
|
||||
/**
|
||||
* Find the first StockAvailableView 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 {StockAvailableViewFindFirstOrThrowArgs} args - Arguments to find a StockAvailableView
|
||||
* @example
|
||||
* // Get one StockAvailableView
|
||||
* const stockAvailableView = await prisma.stockAvailableView.findFirstOrThrow({
|
||||
* where: {
|
||||
* // ... provide filter here
|
||||
* }
|
||||
* })
|
||||
*/
|
||||
findFirstOrThrow<T extends StockAvailableViewFindFirstOrThrowArgs, TakeDependenciesValidator extends "take" extends Prisma.Keys<T> ? {
|
||||
orderBy: {}
|
||||
} : {}, SkipDependenciesValidator extends "skip" extends Prisma.Keys<T> ? {
|
||||
orderBy: {}
|
||||
} : {}>(args?: Prisma.SelectSubset<T, StockAvailableViewFindFirstOrThrowArgs<ExtArgs>> & TakeDependenciesValidator & SkipDependenciesValidator): Prisma.Prisma__StockAvailableViewClient<runtime.Types.Result.GetResult<Prisma.$StockAvailableViewPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
|
||||
|
||||
/**
|
||||
* Find zero or more StockAvailableViews 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 {StockAvailableViewFindManyArgs} args - Arguments to filter and select certain fields only.
|
||||
* @example
|
||||
* // Get all StockAvailableViews
|
||||
* const stockAvailableViews = await prisma.stockAvailableView.findMany()
|
||||
*
|
||||
* // Get first 10 StockAvailableViews
|
||||
* const stockAvailableViews = await prisma.stockAvailableView.findMany({ take: 10 })
|
||||
*
|
||||
* // Only select the `productId`
|
||||
* const stockAvailableViewWithProductIdOnly = await prisma.stockAvailableView.findMany({ select: { productId: true } })
|
||||
*
|
||||
*/
|
||||
findMany<T extends StockAvailableViewFindManyArgs, TakeDependenciesValidator extends "take" extends Prisma.Keys<T> ? {
|
||||
orderBy: {}
|
||||
} : {}, SkipDependenciesValidator extends "skip" extends Prisma.Keys<T> ? {
|
||||
orderBy: {}
|
||||
} : {}>(args?: Prisma.SelectSubset<T, StockAvailableViewFindManyArgs<ExtArgs>> & TakeDependenciesValidator & SkipDependenciesValidator): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$StockAvailableViewPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>
|
||||
|
||||
|
||||
/**
|
||||
* Count the number of StockAvailableViews.
|
||||
* Note, that providing `undefined` is treated as the value not being there.
|
||||
* Read more here: https://pris.ly/d/null-undefined
|
||||
* @param {StockAvailableViewCountArgs} args - Arguments to filter StockAvailableViews to count.
|
||||
* @example
|
||||
* // Count the number of StockAvailableViews
|
||||
* const count = await prisma.stockAvailableView.count({
|
||||
* where: {
|
||||
* // ... the filter for the StockAvailableViews we want to count
|
||||
* }
|
||||
* })
|
||||
**/
|
||||
count<T extends StockAvailableViewCountArgs>(
|
||||
args?: Prisma.Subset<T, StockAvailableViewCountArgs>,
|
||||
): Prisma.PrismaPromise<
|
||||
T extends runtime.Types.Utils.Record<'select', any>
|
||||
? T['select'] extends true
|
||||
? number
|
||||
: Prisma.GetScalarType<T['select'], StockAvailableViewCountAggregateOutputType>
|
||||
: number
|
||||
>
|
||||
|
||||
/**
|
||||
* Allows you to perform aggregations operations on a StockAvailableView.
|
||||
* Note, that providing `undefined` is treated as the value not being there.
|
||||
* Read more here: https://pris.ly/d/null-undefined
|
||||
* @param {StockAvailableViewAggregateArgs} 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 StockAvailableViewAggregateArgs>(args: Prisma.Subset<T, StockAvailableViewAggregateArgs>): Prisma.PrismaPromise<GetStockAvailableViewAggregateType<T>>
|
||||
|
||||
/**
|
||||
* Group by StockAvailableView.
|
||||
* Note, that providing `undefined` is treated as the value not being there.
|
||||
* Read more here: https://pris.ly/d/null-undefined
|
||||
* @param {StockAvailableViewGroupByArgs} 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 StockAvailableViewGroupByArgs,
|
||||
HasSelectOrTake extends Prisma.Or<
|
||||
Prisma.Extends<'skip', Prisma.Keys<T>>,
|
||||
Prisma.Extends<'take', Prisma.Keys<T>>
|
||||
>,
|
||||
OrderByArg extends Prisma.True extends HasSelectOrTake
|
||||
? { orderBy: StockAvailableViewGroupByArgs['orderBy'] }
|
||||
: { orderBy?: StockAvailableViewGroupByArgs['orderBy'] },
|
||||
OrderFields extends Prisma.ExcludeUnderscoreKeys<Prisma.Keys<Prisma.MaybeTupleToUnion<T['orderBy']>>>,
|
||||
ByFields extends Prisma.MaybeTupleToUnion<T['by']>,
|
||||
ByValid extends Prisma.Has<ByFields, OrderFields>,
|
||||
HavingFields extends Prisma.GetHavingFields<T['having']>,
|
||||
HavingValid extends Prisma.Has<ByFields, HavingFields>,
|
||||
ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False,
|
||||
InputErrors extends ByEmpty extends Prisma.True
|
||||
? `Error: "by" must not be empty.`
|
||||
: HavingValid extends Prisma.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 Prisma.Keys<T>
|
||||
? 'orderBy' extends Prisma.Keys<T>
|
||||
? ByValid extends Prisma.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 Prisma.Keys<T>
|
||||
? 'orderBy' extends Prisma.Keys<T>
|
||||
? ByValid extends Prisma.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 Prisma.True
|
||||
? {}
|
||||
: {
|
||||
[P in OrderFields]: P extends ByFields
|
||||
? never
|
||||
: `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
|
||||
}[OrderFields]
|
||||
>(args: Prisma.SubsetIntersection<T, StockAvailableViewGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetStockAvailableViewGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
|
||||
/**
|
||||
* Fields of the StockAvailableView model
|
||||
*/
|
||||
readonly fields: StockAvailableViewFieldRefs;
|
||||
}
|
||||
|
||||
/**
|
||||
* The delegate class that acts as a "Promise-like" for StockAvailableView.
|
||||
* 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__StockAvailableViewClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
|
||||
readonly [Symbol.toStringTag]: "PrismaPromise"
|
||||
/**
|
||||
* Attaches callbacks for the resolution and/or rejection of the Promise.
|
||||
* @param onfulfilled The callback to execute when the Promise is resolved.
|
||||
* @param onrejected The callback to execute when the Promise is rejected.
|
||||
* @returns A Promise for the completion of which ever callback is executed.
|
||||
*/
|
||||
then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): runtime.Types.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): runtime.Types.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): runtime.Types.Utils.JsPromise<T>
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Fields of the StockAvailableView model
|
||||
*/
|
||||
export interface StockAvailableViewFieldRefs {
|
||||
readonly productId: Prisma.FieldRef<"StockAvailableView", 'Int'>
|
||||
readonly inventoryId: Prisma.FieldRef<"StockAvailableView", 'Int'>
|
||||
readonly physicalQuantity: Prisma.FieldRef<"StockAvailableView", 'Decimal'>
|
||||
readonly reservedQuantity: Prisma.FieldRef<"StockAvailableView", 'Decimal'>
|
||||
readonly availableQuantity: Prisma.FieldRef<"StockAvailableView", 'Decimal'>
|
||||
}
|
||||
|
||||
|
||||
// Custom InputTypes
|
||||
/**
|
||||
* StockAvailableView findFirst
|
||||
*/
|
||||
export type StockAvailableViewFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Select specific fields to fetch from the StockAvailableView
|
||||
*/
|
||||
select?: Prisma.StockAvailableViewSelect<ExtArgs> | null
|
||||
/**
|
||||
* Omit specific fields from the StockAvailableView
|
||||
*/
|
||||
omit?: Prisma.StockAvailableViewOmit<ExtArgs> | null
|
||||
/**
|
||||
* Filter, which StockAvailableView to fetch.
|
||||
*/
|
||||
where?: Prisma.StockAvailableViewWhereInput
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
||||
*
|
||||
* Determine the order of StockAvailableViews to fetch.
|
||||
*/
|
||||
orderBy?: Prisma.StockAvailableViewOrderByWithRelationInput | Prisma.StockAvailableViewOrderByWithRelationInput[]
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
||||
*
|
||||
* Take `±n` StockAvailableViews 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` StockAvailableViews.
|
||||
*/
|
||||
skip?: number
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
||||
*
|
||||
* Filter by unique combinations of StockAvailableViews.
|
||||
*/
|
||||
distinct?: Prisma.StockAvailableViewScalarFieldEnum | Prisma.StockAvailableViewScalarFieldEnum[]
|
||||
}
|
||||
|
||||
/**
|
||||
* StockAvailableView findFirstOrThrow
|
||||
*/
|
||||
export type StockAvailableViewFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Select specific fields to fetch from the StockAvailableView
|
||||
*/
|
||||
select?: Prisma.StockAvailableViewSelect<ExtArgs> | null
|
||||
/**
|
||||
* Omit specific fields from the StockAvailableView
|
||||
*/
|
||||
omit?: Prisma.StockAvailableViewOmit<ExtArgs> | null
|
||||
/**
|
||||
* Filter, which StockAvailableView to fetch.
|
||||
*/
|
||||
where?: Prisma.StockAvailableViewWhereInput
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
||||
*
|
||||
* Determine the order of StockAvailableViews to fetch.
|
||||
*/
|
||||
orderBy?: Prisma.StockAvailableViewOrderByWithRelationInput | Prisma.StockAvailableViewOrderByWithRelationInput[]
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
||||
*
|
||||
* Take `±n` StockAvailableViews 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` StockAvailableViews.
|
||||
*/
|
||||
skip?: number
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
|
||||
*
|
||||
* Filter by unique combinations of StockAvailableViews.
|
||||
*/
|
||||
distinct?: Prisma.StockAvailableViewScalarFieldEnum | Prisma.StockAvailableViewScalarFieldEnum[]
|
||||
}
|
||||
|
||||
/**
|
||||
* StockAvailableView findMany
|
||||
*/
|
||||
export type StockAvailableViewFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Select specific fields to fetch from the StockAvailableView
|
||||
*/
|
||||
select?: Prisma.StockAvailableViewSelect<ExtArgs> | null
|
||||
/**
|
||||
* Omit specific fields from the StockAvailableView
|
||||
*/
|
||||
omit?: Prisma.StockAvailableViewOmit<ExtArgs> | null
|
||||
/**
|
||||
* Filter, which StockAvailableViews to fetch.
|
||||
*/
|
||||
where?: Prisma.StockAvailableViewWhereInput
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
|
||||
*
|
||||
* Determine the order of StockAvailableViews to fetch.
|
||||
*/
|
||||
orderBy?: Prisma.StockAvailableViewOrderByWithRelationInput | Prisma.StockAvailableViewOrderByWithRelationInput[]
|
||||
/**
|
||||
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
|
||||
*
|
||||
* Take `±n` StockAvailableViews 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` StockAvailableViews.
|
||||
*/
|
||||
skip?: number
|
||||
distinct?: Prisma.StockAvailableViewScalarFieldEnum | Prisma.StockAvailableViewScalarFieldEnum[]
|
||||
}
|
||||
|
||||
/**
|
||||
* StockAvailableView without action
|
||||
*/
|
||||
export type StockAvailableViewDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
|
||||
/**
|
||||
* Select specific fields to fetch from the StockAvailableView
|
||||
*/
|
||||
select?: Prisma.StockAvailableViewSelect<ExtArgs> | null
|
||||
/**
|
||||
* Omit specific fields from the StockAvailableView
|
||||
*/
|
||||
omit?: Prisma.StockAvailableViewOmit<ExtArgs> | null
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -1,20 +0,0 @@
|
||||
import { ApiProperty } from '@nestjs/swagger'
|
||||
import { Type } from 'class-transformer'
|
||||
import { IsInt, IsNumber } from 'class-validator'
|
||||
|
||||
export class CreateInventoryTransferItemDto {
|
||||
@ApiProperty()
|
||||
@Type(() => Number)
|
||||
@IsNumber()
|
||||
count: number
|
||||
|
||||
@ApiProperty()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
productId: number
|
||||
|
||||
@ApiProperty()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
transferId: number
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
import { ApiPropertyOptional } from '@nestjs/swagger'
|
||||
import { Type } from 'class-transformer'
|
||||
import { IsInt, IsNumber, IsOptional } from 'class-validator'
|
||||
|
||||
export class UpdateInventoryTransferItemDto {
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsNumber()
|
||||
count?: number
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
productId?: number
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
transferId?: number
|
||||
}
|
||||
@@ -1,42 +0,0 @@
|
||||
import { Body, Controller, Delete, Get, Param, Patch, Post } from '@nestjs/common'
|
||||
import { CreateInventoryTransferItemDto } from './dto/create-inventory-transfer-item.dto'
|
||||
import { UpdateInventoryTransferItemDto } from './dto/update-inventory-transfer-item.dto'
|
||||
import { InventoryTransferItemsService } from './inventory-transfer-items.service'
|
||||
|
||||
@Controller('inventory-transfers/:transferId/items')
|
||||
export class InventoryTransferItemsController {
|
||||
constructor(private readonly service: InventoryTransferItemsService) {}
|
||||
|
||||
@Post()
|
||||
create(
|
||||
@Param('transferId') transferId: string,
|
||||
@Body() dto: CreateInventoryTransferItemDto,
|
||||
) {
|
||||
// ensure transferId from route is used
|
||||
return this.service.createForTransfer(Number(transferId), dto)
|
||||
}
|
||||
|
||||
@Get()
|
||||
findAll(@Param('transferId') transferId: string) {
|
||||
return this.service.findAllForTransfer(Number(transferId))
|
||||
}
|
||||
|
||||
@Get(':id')
|
||||
findOne(@Param('transferId') transferId: string, @Param('id') id: string) {
|
||||
return this.service.findOneForTransfer(Number(transferId), Number(id))
|
||||
}
|
||||
|
||||
@Patch(':id')
|
||||
update(
|
||||
@Param('transferId') transferId: string,
|
||||
@Param('id') id: string,
|
||||
@Body() dto: UpdateInventoryTransferItemDto,
|
||||
) {
|
||||
return this.service.updateForTransfer(Number(transferId), Number(id), dto)
|
||||
}
|
||||
|
||||
@Delete(':id')
|
||||
remove(@Param('transferId') transferId: string, @Param('id') id: string) {
|
||||
return this.service.removeForTransfer(Number(transferId), Number(id))
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../prisma/prisma.module'
|
||||
import { InventoryTransferItemsController } from './inventory-transfer-items.controller'
|
||||
import { InventoryTransferItemsService } from './inventory-transfer-items.service'
|
||||
|
||||
@Module({
|
||||
imports: [PrismaModule],
|
||||
controllers: [InventoryTransferItemsController],
|
||||
providers: [InventoryTransferItemsService],
|
||||
})
|
||||
export class InventoryTransferItemsModule {}
|
||||
@@ -1,101 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import { ResponseMapper } from '../common/response/response-mapper'
|
||||
import { PrismaService } from '../prisma/prisma.service'
|
||||
import { CreateInventoryTransferItemDto } from './dto/create-inventory-transfer-item.dto'
|
||||
|
||||
@Injectable()
|
||||
export class InventoryTransferItemsService {
|
||||
constructor(private prisma: PrismaService) {}
|
||||
|
||||
async create(dto: CreateInventoryTransferItemDto) {
|
||||
const payload: any = { ...dto }
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'productId')) {
|
||||
payload.product = { connect: { id: Number(payload.productId) } }
|
||||
delete payload.productId
|
||||
}
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'transferId')) {
|
||||
payload.transfer = { connect: { id: Number(payload.transferId) } }
|
||||
delete payload.transferId
|
||||
}
|
||||
|
||||
const item = await this.prisma.inventoryTransferItem.create({ data: payload })
|
||||
return ResponseMapper.create(item)
|
||||
}
|
||||
|
||||
async findAll(transferId?: number) {
|
||||
const where = transferId ? { transferId: Number(transferId) } : undefined
|
||||
const items = await this.prisma.inventoryTransferItem.findMany({
|
||||
where,
|
||||
include: { product: true },
|
||||
})
|
||||
return ResponseMapper.list(items)
|
||||
}
|
||||
|
||||
async findOne(id: number) {
|
||||
const item = await this.prisma.inventoryTransferItem.findUnique({
|
||||
where: { id },
|
||||
include: { product: true, transfer: true },
|
||||
})
|
||||
if (!item) return null
|
||||
return ResponseMapper.single(item)
|
||||
}
|
||||
|
||||
// scoped helpers for nested routes
|
||||
async createForTransfer(transferId: number, dto: CreateInventoryTransferItemDto) {
|
||||
const payload: any = { ...dto, transferId }
|
||||
return this.create(payload)
|
||||
}
|
||||
|
||||
async findAllForTransfer(transferId: number) {
|
||||
return this.findAll(transferId)
|
||||
}
|
||||
|
||||
async findOneForTransfer(transferId: number, id: number) {
|
||||
const item = await this.prisma.inventoryTransferItem.findFirst({
|
||||
where: { id, transferId },
|
||||
include: { product: true, transfer: true },
|
||||
})
|
||||
if (!item) return null
|
||||
return ResponseMapper.single(item)
|
||||
}
|
||||
|
||||
async update(id: number, data: any) {
|
||||
const payload: any = { ...data }
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'productId')) {
|
||||
payload.product = { connect: { id: Number(payload.productId) } }
|
||||
delete payload.productId
|
||||
}
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'transferId')) {
|
||||
payload.transfer = { connect: { id: Number(payload.transferId) } }
|
||||
delete payload.transferId
|
||||
}
|
||||
|
||||
const item = await this.prisma.inventoryTransferItem.update({
|
||||
where: { id },
|
||||
data: payload,
|
||||
})
|
||||
return ResponseMapper.update(item)
|
||||
}
|
||||
|
||||
async updateForTransfer(transferId: number, id: number, data: any) {
|
||||
// ensure the item belongs to the transfer
|
||||
const existing = await this.prisma.inventoryTransferItem.findFirst({
|
||||
where: { id, transferId },
|
||||
})
|
||||
if (!existing) return null
|
||||
return this.update(id, data)
|
||||
}
|
||||
|
||||
async remove(id: number) {
|
||||
const item = await this.prisma.inventoryTransferItem.delete({ where: { id } })
|
||||
return ResponseMapper.single(item)
|
||||
}
|
||||
|
||||
async removeForTransfer(transferId: number, id: number) {
|
||||
const existing = await this.prisma.inventoryTransferItem.findFirst({
|
||||
where: { id, transferId },
|
||||
})
|
||||
if (!existing) return null
|
||||
return this.remove(id)
|
||||
}
|
||||
}
|
||||
@@ -1,30 +0,0 @@
|
||||
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger'
|
||||
import { Type } from 'class-transformer'
|
||||
import { ArrayMinSize, IsInt, IsOptional, IsString } from 'class-validator'
|
||||
import { CreateInventoryTransferItemDto } from '../../inventory-transfer-items/dto/create-inventory-transfer-item.dto'
|
||||
|
||||
export class CreateInventoryTransferDto {
|
||||
@ApiProperty()
|
||||
@IsString()
|
||||
code: string
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
description?: string
|
||||
|
||||
@ApiProperty()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
fromInventoryId: number
|
||||
|
||||
@ApiProperty()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
toInventoryId: number
|
||||
|
||||
@ApiProperty({ type: [CreateInventoryTransferItemDto] })
|
||||
@Type(() => Array)
|
||||
@ArrayMinSize(1)
|
||||
items: Array<Omit<CreateInventoryTransferItemDto, 'transferId'>>
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
import { ApiPropertyOptional } from '@nestjs/swagger'
|
||||
import { Type } from 'class-transformer'
|
||||
import { IsInt, IsOptional, IsString } from 'class-validator'
|
||||
|
||||
export class UpdateInventoryTransferDto {
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
code?: string
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
description?: string
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
fromInventoryId?: number | null
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@Type(() => Number)
|
||||
@IsInt()
|
||||
toInventoryId?: number | null
|
||||
}
|
||||
@@ -1,34 +0,0 @@
|
||||
import { Body, Controller, Delete, Get, Param, Patch, Post } from '@nestjs/common'
|
||||
import { CreateInventoryTransferDto } from './dto/create-inventory-transfer.dto'
|
||||
import { UpdateInventoryTransferDto } from './dto/update-inventory-transfer.dto'
|
||||
import { InventoryTransfersService } from './inventory-transfers.service'
|
||||
|
||||
@Controller('inventories/transfers')
|
||||
export class InventoryTransfersController {
|
||||
constructor(private readonly service: InventoryTransfersService) {}
|
||||
|
||||
@Post()
|
||||
create(@Body() dto: CreateInventoryTransferDto) {
|
||||
return this.service.create(dto)
|
||||
}
|
||||
|
||||
@Get()
|
||||
findAll() {
|
||||
return this.service.findAll()
|
||||
}
|
||||
|
||||
@Get(':id')
|
||||
findOne(@Param('id') id: string) {
|
||||
return this.service.findOne(Number(id))
|
||||
}
|
||||
|
||||
@Patch(':id')
|
||||
update(@Param('id') id: string, @Body() dto: UpdateInventoryTransferDto) {
|
||||
return this.service.update(Number(id), dto)
|
||||
}
|
||||
|
||||
@Delete(':id')
|
||||
remove(@Param('id') id: string) {
|
||||
return this.service.remove(Number(id))
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../prisma/prisma.module'
|
||||
import { InventoryTransfersController } from './inventory-transfers.controller'
|
||||
import { InventoryTransfersService } from './inventory-transfers.service'
|
||||
|
||||
@Module({
|
||||
imports: [PrismaModule],
|
||||
controllers: [InventoryTransfersController],
|
||||
providers: [InventoryTransfersService],
|
||||
})
|
||||
export class InventoryTransfersModule {}
|
||||
@@ -1,74 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import { ResponseMapper } from '../common/response/response-mapper'
|
||||
import { PrismaService } from '../prisma/prisma.service'
|
||||
import { CreateInventoryTransferDto } from './dto/create-inventory-transfer.dto'
|
||||
|
||||
@Injectable()
|
||||
export class InventoryTransfersService {
|
||||
constructor(private prisma: PrismaService) {}
|
||||
|
||||
async create(dto: CreateInventoryTransferDto) {
|
||||
const payload: any = { ...dto }
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'fromInventoryId')) {
|
||||
payload.fromInventory = { connect: { id: Number(payload.fromInventoryId) } }
|
||||
delete payload.fromInventoryId
|
||||
}
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'toInventoryId')) {
|
||||
payload.toInventory = { connect: { id: Number(payload.toInventoryId) } }
|
||||
delete payload.toInventoryId
|
||||
}
|
||||
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'items')) {
|
||||
payload.items = {
|
||||
create: payload.items.map((item: any) => ({
|
||||
product: { connect: { id: Number(item.productId) } },
|
||||
count: item.count,
|
||||
})),
|
||||
}
|
||||
}
|
||||
|
||||
const item = await this.prisma.inventoryTransfer.create({ data: payload })
|
||||
return ResponseMapper.create(item)
|
||||
}
|
||||
|
||||
async findAll() {
|
||||
const items = await this.prisma.inventoryTransfer.findMany({
|
||||
include: { fromInventory: true, toInventory: true },
|
||||
})
|
||||
return ResponseMapper.list(items)
|
||||
}
|
||||
|
||||
async findOne(id: number) {
|
||||
const item = await this.prisma.inventoryTransfer.findUnique({
|
||||
where: { id },
|
||||
include: { items: true, fromInventory: true, toInventory: true },
|
||||
})
|
||||
if (!item) return null
|
||||
return ResponseMapper.single(item)
|
||||
}
|
||||
|
||||
async update(id: number, data: any) {
|
||||
const payload: any = { ...data }
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'fromInventoryId')) {
|
||||
if (payload.fromInventoryId === null) payload.fromInventory = { disconnect: true }
|
||||
else payload.fromInventory = { connect: { id: Number(payload.fromInventoryId) } }
|
||||
delete payload.fromInventoryId
|
||||
}
|
||||
if (Object.prototype.hasOwnProperty.call(payload, 'toInventoryId')) {
|
||||
if (payload.toInventoryId === null) payload.toInventory = { disconnect: true }
|
||||
else payload.toInventory = { connect: { id: Number(payload.toInventoryId) } }
|
||||
delete payload.toInventoryId
|
||||
}
|
||||
|
||||
const item = await this.prisma.inventoryTransfer.update({
|
||||
where: { id },
|
||||
data: payload,
|
||||
})
|
||||
return ResponseMapper.update(item)
|
||||
}
|
||||
|
||||
async remove(id: number) {
|
||||
const item = await this.prisma.inventoryTransfer.delete({ where: { id } })
|
||||
return ResponseMapper.single(item)
|
||||
}
|
||||
}
|
||||
@@ -1,39 +0,0 @@
|
||||
import { Body, Controller, Delete, Get, Param, Patch, Post } from '@nestjs/common'
|
||||
import { BankAccountsService } from './bank-accounts.service'
|
||||
import { CreateBankAccountDto } from './dto/create-bank-account.dto'
|
||||
import { UpdateBankAccountDto } from './dto/update-bank-account.dto'
|
||||
|
||||
@Controller('bank-accounts')
|
||||
export class BankAccountsController {
|
||||
constructor(private readonly bankAccountsService: BankAccountsService) {}
|
||||
|
||||
@Post()
|
||||
create(@Body() dto: CreateBankAccountDto) {
|
||||
return this.bankAccountsService.create(dto)
|
||||
}
|
||||
|
||||
@Get()
|
||||
findAll() {
|
||||
return this.bankAccountsService.findAll()
|
||||
}
|
||||
|
||||
@Get(':id')
|
||||
findOne(@Param('id') id: string) {
|
||||
return this.bankAccountsService.findOne(Number(id))
|
||||
}
|
||||
|
||||
@Patch(':id')
|
||||
update(@Param('id') id: string, @Body() dto: UpdateBankAccountDto) {
|
||||
return this.bankAccountsService.update(Number(id), dto)
|
||||
}
|
||||
|
||||
@Delete(':id')
|
||||
remove(@Param('id') id: string) {
|
||||
return this.bankAccountsService.remove(Number(id))
|
||||
}
|
||||
|
||||
@Get(':id/transactions')
|
||||
getTransactions(@Param('id') id: string) {
|
||||
return this.bankAccountsService.getTransactions(Number(id))
|
||||
}
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../../prisma/prisma.module'
|
||||
import { BankAccountsController } from './bank-accounts.controller'
|
||||
import { BankAccountsService } from './bank-accounts.service'
|
||||
import { BankAccountsWorkflow } from './bank-accounts.workflow'
|
||||
|
||||
@Module({
|
||||
imports: [PrismaModule],
|
||||
controllers: [BankAccountsController],
|
||||
providers: [BankAccountsService, BankAccountsWorkflow],
|
||||
exports: [BankAccountsWorkflow],
|
||||
})
|
||||
export class BankAccountsModule {}
|
||||
@@ -1,153 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import { ResponseMapper } from '../../common/response/response-mapper'
|
||||
import { BankTransactionRefType } from '../../generated/prisma/enums'
|
||||
import { PrismaService } from '../../prisma/prisma.service'
|
||||
|
||||
@Injectable()
|
||||
export class BankAccountsService {
|
||||
constructor(private prisma: PrismaService) {}
|
||||
|
||||
private readonly bankAccountQuery = {
|
||||
include: {
|
||||
branch: {
|
||||
select: {
|
||||
id: true,
|
||||
name: true,
|
||||
code: true,
|
||||
bank: {
|
||||
select: { id: true, name: true, shortName: true },
|
||||
},
|
||||
},
|
||||
},
|
||||
bankAccountTransactions: {
|
||||
take: 1,
|
||||
select: { id: true, createdAt: true, balanceAfter: true },
|
||||
orderBy: { createdAt: 'desc' as const },
|
||||
},
|
||||
},
|
||||
omit: {
|
||||
branchId: true,
|
||||
},
|
||||
}
|
||||
|
||||
async create(data: any) {
|
||||
const item = await this.prisma.bankAccount.create({ data })
|
||||
return ResponseMapper.create(item)
|
||||
}
|
||||
|
||||
async findAll() {
|
||||
const items = await this.prisma.bankAccount.findMany(this.bankAccountQuery)
|
||||
const mappedData = items.map(({ bankAccountTransactions, ...rest }) => ({
|
||||
...rest,
|
||||
currentBalance: Number(bankAccountTransactions[0]?.balanceAfter || 0),
|
||||
}))
|
||||
|
||||
return ResponseMapper.list(mappedData)
|
||||
}
|
||||
|
||||
async findOne(id: number) {
|
||||
const item = await this.prisma.bankAccount.findUniqueOrThrow({
|
||||
...this.bankAccountQuery,
|
||||
where: { id },
|
||||
})
|
||||
|
||||
const { bankAccountTransactions, ...rest } = item
|
||||
return ResponseMapper.single({
|
||||
...rest,
|
||||
currentBalance: Number(bankAccountTransactions[0]?.balanceAfter || 0),
|
||||
})
|
||||
}
|
||||
|
||||
async update(id: number, data: any) {
|
||||
const item = await this.prisma.bankAccount.update({ where: { id }, data })
|
||||
return ResponseMapper.update(item)
|
||||
}
|
||||
|
||||
async remove(id: number) {
|
||||
const item = await this.prisma.bankAccount.delete({ where: { id } })
|
||||
return ResponseMapper.single(item)
|
||||
}
|
||||
|
||||
async getTransactions(bankAccountId: number, page = 1, pageSize = 50) {
|
||||
const query = {
|
||||
where: { bankAccountId },
|
||||
orderBy: { createdAt: 'desc' as const },
|
||||
skip: (page - 1) * pageSize,
|
||||
take: pageSize,
|
||||
}
|
||||
|
||||
const [items, count] = await this.prisma.$transaction([
|
||||
this.prisma.bankAccountTransaction.findMany({
|
||||
...query,
|
||||
omit: { bankAccountId: true },
|
||||
}),
|
||||
this.prisma.bankAccountTransaction.count({ where: { bankAccountId } }),
|
||||
])
|
||||
|
||||
const PosReferenceIds = [] as number[]
|
||||
const purchaseReferenceIds = [] as number[]
|
||||
|
||||
items.forEach(({ referenceType, referenceId }) => {
|
||||
if (referenceId && referenceType) {
|
||||
if (
|
||||
referenceType === BankTransactionRefType.POS_SALE ||
|
||||
referenceType === BankTransactionRefType.POS_REFUND
|
||||
) {
|
||||
PosReferenceIds.push(referenceId)
|
||||
} else if (
|
||||
referenceType === BankTransactionRefType.PURCHASE_PAYMENT ||
|
||||
referenceType === BankTransactionRefType.PURCHASE_REFUND
|
||||
) {
|
||||
purchaseReferenceIds.push(referenceId)
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
const posRecords = await this.prisma.salesInvoice.findMany({
|
||||
where: { id: { in: PosReferenceIds } },
|
||||
select: {
|
||||
id: true,
|
||||
code: true,
|
||||
totalAmount: true,
|
||||
posAccount: {
|
||||
select: { id: true, name: true },
|
||||
},
|
||||
customer: {
|
||||
select: { id: true, firstName: true, lastName: true },
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
const purchaseRecords = await this.prisma.purchaseReceipt.findMany({
|
||||
where: { id: { in: purchaseReferenceIds } },
|
||||
select: {
|
||||
id: true,
|
||||
code: true,
|
||||
totalAmount: true,
|
||||
supplier: {
|
||||
select: { id: true, firstName: true, lastName: true },
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
const mappedItems = items.map(tx => {
|
||||
let reference = null as any
|
||||
if (tx.referenceId && tx.referenceType) {
|
||||
if (
|
||||
tx.referenceType === BankTransactionRefType.POS_SALE ||
|
||||
tx.referenceType === BankTransactionRefType.POS_REFUND
|
||||
) {
|
||||
reference = posRecords.find(r => r.id === tx.referenceId) || null
|
||||
} else if (
|
||||
tx.referenceType === BankTransactionRefType.PURCHASE_PAYMENT ||
|
||||
tx.referenceType === BankTransactionRefType.PURCHASE_REFUND
|
||||
) {
|
||||
reference = purchaseRecords.find(r => r.id === tx.referenceId) || null
|
||||
}
|
||||
}
|
||||
return { ...tx, reference }
|
||||
})
|
||||
|
||||
return ResponseMapper.paginate(mappedItems, count, page, pageSize)
|
||||
}
|
||||
}
|
||||
@@ -1,39 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import { Prisma } from '../../generated/prisma/client'
|
||||
import { AddTransactionToBankAccountDto } from './dto/add-transaction.dto'
|
||||
|
||||
@Injectable()
|
||||
export class BankAccountsWorkflow {
|
||||
async addTransaction(
|
||||
tx: Prisma.TransactionClient,
|
||||
payload: AddTransactionToBankAccountDto,
|
||||
) {
|
||||
const item = await tx.bankAccountTransaction.findFirst({
|
||||
where: {
|
||||
bankAccountId: payload.bankAccountId,
|
||||
},
|
||||
})
|
||||
|
||||
const balance = item ? Number(item?.balanceAfter) : 0
|
||||
|
||||
const newBalance = item
|
||||
? payload.type === 'DEPOSIT'
|
||||
? balance + payload.amount
|
||||
: balance - payload.amount
|
||||
: payload.type === 'DEPOSIT'
|
||||
? payload.amount
|
||||
: -payload.amount
|
||||
|
||||
await tx.bankAccountTransaction.create({
|
||||
data: {
|
||||
bankAccount: { connect: { id: payload.bankAccountId } },
|
||||
amount: payload.amount,
|
||||
type: payload.type,
|
||||
balanceAfter: newBalance,
|
||||
|
||||
referenceId: payload.referenceId,
|
||||
referenceType: payload.referenceType,
|
||||
},
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
import { IsEnum, IsInt } from 'class-validator'
|
||||
import {
|
||||
BankAccountTransactionType,
|
||||
BankTransactionRefType,
|
||||
} from '../../../generated/prisma/enums'
|
||||
|
||||
export class AddTransactionToBankAccountDto {
|
||||
@IsInt()
|
||||
bankAccountId: number
|
||||
|
||||
@IsInt()
|
||||
amount: number
|
||||
|
||||
@IsInt()
|
||||
referenceId: number
|
||||
|
||||
@IsEnum(BankTransactionRefType)
|
||||
referenceType: BankTransactionRefType
|
||||
|
||||
@IsEnum(BankAccountTransactionType)
|
||||
type: BankAccountTransactionType
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
import { IsInt, IsOptional, IsString } from 'class-validator'
|
||||
|
||||
export class CreateBankAccountDto {
|
||||
@IsString()
|
||||
accountNumber: string
|
||||
|
||||
@IsString()
|
||||
name: string
|
||||
|
||||
@IsString()
|
||||
iban: string
|
||||
|
||||
@IsInt()
|
||||
branchId: number
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
createdAt?: string
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
updatedAt?: string
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
deletedAt?: string
|
||||
}
|
||||
@@ -1,4 +0,0 @@
|
||||
import { PartialType } from '@nestjs/swagger'
|
||||
import { CreateBankAccountDto } from './create-bank-account.dto'
|
||||
|
||||
export class UpdateBankAccountDto extends PartialType(CreateBankAccountDto) {}
|
||||
@@ -1,34 +0,0 @@
|
||||
import { Body, Controller, Delete, Get, Param, Patch, Post } from '@nestjs/common'
|
||||
import { BankBranchesService } from './bank-branches.service'
|
||||
import { CreateBankBranchDto } from './dto/create-bank-branches.dto'
|
||||
import { UpdateBankBranchDto } from './dto/update-bank-branches.dto'
|
||||
|
||||
@Controller('bank-branches')
|
||||
export class BankBranchesController {
|
||||
constructor(private readonly bankBranchesService: BankBranchesService) {}
|
||||
|
||||
@Post()
|
||||
create(@Body() dto: CreateBankBranchDto) {
|
||||
return this.bankBranchesService.create(dto)
|
||||
}
|
||||
|
||||
@Get()
|
||||
findAll() {
|
||||
return this.bankBranchesService.findAll()
|
||||
}
|
||||
|
||||
@Get(':id')
|
||||
findOne(@Param('id') id: string) {
|
||||
return this.bankBranchesService.findOne(Number(id))
|
||||
}
|
||||
|
||||
@Patch(':id')
|
||||
update(@Param('id') id: string, @Body() dto: UpdateBankBranchDto) {
|
||||
return this.bankBranchesService.update(Number(id), dto)
|
||||
}
|
||||
|
||||
@Delete(':id')
|
||||
remove(@Param('id') id: string) {
|
||||
return this.bankBranchesService.remove(Number(id))
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../../prisma/prisma.module'
|
||||
import { BankBranchesController } from './bank-branches.controller'
|
||||
import { BankBranchesService } from './bank-branches.service'
|
||||
|
||||
@Module({
|
||||
imports: [PrismaModule],
|
||||
controllers: [BankBranchesController],
|
||||
providers: [BankBranchesService],
|
||||
})
|
||||
export class BankBranchesModule {}
|
||||
@@ -1,12 +0,0 @@
|
||||
import { IsInt, IsString } from 'class-validator'
|
||||
|
||||
export class CreateBankBranchDto {
|
||||
@IsString()
|
||||
name: string
|
||||
|
||||
@IsString()
|
||||
code: string
|
||||
|
||||
@IsInt()
|
||||
bankId: number
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
import { IsOptional, IsString } from 'class-validator'
|
||||
|
||||
export class UpdateBankBranchDto {
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
name?: string
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
description?: string
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
imageUrl?: string
|
||||
}
|
||||
@@ -1,12 +0,0 @@
|
||||
import { Controller, Get } from '@nestjs/common'
|
||||
import { BanksService } from './banks.service'
|
||||
|
||||
@Controller('banks')
|
||||
export class BanksController {
|
||||
constructor(private readonly banksService: BanksService) {}
|
||||
|
||||
@Get()
|
||||
findAll() {
|
||||
return this.banksService.findAll()
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../../prisma/prisma.module'
|
||||
import { BanksController } from './banks.controller'
|
||||
import { BanksService } from './banks.service'
|
||||
|
||||
@Module({
|
||||
imports: [PrismaModule],
|
||||
controllers: [BanksController],
|
||||
providers: [BanksService],
|
||||
})
|
||||
export class BanksModule {}
|
||||
@@ -1,15 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import { ResponseMapper } from '../../common/response/response-mapper'
|
||||
import { PrismaService } from '../../prisma/prisma.service'
|
||||
|
||||
@Injectable()
|
||||
export class BanksService {
|
||||
constructor(private prisma: PrismaService) {}
|
||||
|
||||
async findAll() {
|
||||
const items = await this.prisma.bank.findMany({
|
||||
select: { id: true, name: true, shortName: true },
|
||||
})
|
||||
return ResponseMapper.list(items)
|
||||
}
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
import { Controller, Get, Query } from '@nestjs/common'
|
||||
import { ApiQuery } from '@nestjs/swagger'
|
||||
import { CardexService } from './cardex.service'
|
||||
|
||||
@Controller('cardex')
|
||||
export class CardexController {
|
||||
constructor(private readonly service: CardexService) {}
|
||||
|
||||
@Get('')
|
||||
@ApiQuery({ name: 'startDate', required: true, type: Date })
|
||||
@ApiQuery({ name: 'endDate', required: false, type: Date })
|
||||
@ApiQuery({ name: 'inventoryId', required: false, type: Number })
|
||||
@ApiQuery({ name: 'productId', required: false, type: Number })
|
||||
async getStock(
|
||||
@Query('startDate') startDate: Date,
|
||||
@Query('endDate') endDate: Date,
|
||||
@Query('inventoryId') inventoryId: number,
|
||||
@Query('productId') productId: number,
|
||||
) {
|
||||
return this.service.getCardex({
|
||||
startDate,
|
||||
endDate,
|
||||
inventoryId,
|
||||
productId,
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../../prisma/prisma.module'
|
||||
import { CardexController } from './cardex.controller'
|
||||
import { CardexService } from './cardex.service'
|
||||
|
||||
@Module({
|
||||
imports: [PrismaModule],
|
||||
controllers: [CardexController],
|
||||
providers: [CardexService],
|
||||
})
|
||||
export class CardexModule {}
|
||||
@@ -1,54 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import dayjs from 'dayjs'
|
||||
import { ResponseMapper } from '../../common/response/response-mapper'
|
||||
import { Prisma } from '../../generated/prisma/client'
|
||||
import { PrismaService } from '../../prisma/prisma.service'
|
||||
import { ReadCardexDto } from './dto/read-cardex.dto'
|
||||
|
||||
@Injectable()
|
||||
export class CardexService {
|
||||
constructor(private prisma: PrismaService) {}
|
||||
|
||||
async getCardex({ startDate, endDate, inventoryId, productId }: ReadCardexDto) {
|
||||
if (!endDate) {
|
||||
endDate = dayjs(startDate).add(1, 'months').toDate()
|
||||
}
|
||||
const where: Prisma.StockMovementWhereInput = {}
|
||||
|
||||
if (inventoryId !== undefined) where.inventoryId = inventoryId
|
||||
if (productId !== undefined) where.productId = productId
|
||||
|
||||
if (startDate || endDate) {
|
||||
where.createdAt = {}
|
||||
if (startDate) where.createdAt.gte = new Date(startDate)
|
||||
if (endDate) where.createdAt.lte = new Date(endDate)
|
||||
}
|
||||
|
||||
const items = await this.prisma.stockMovement.findMany({
|
||||
where,
|
||||
include: {
|
||||
product: { select: { id: true, name: true, sku: true } },
|
||||
inventory: { select: { id: true, name: true } },
|
||||
counterInventory: {
|
||||
select: { id: true, name: true },
|
||||
},
|
||||
supplier: {
|
||||
select: { id: true, firstName: true, lastName: true },
|
||||
},
|
||||
customer: {
|
||||
select: { id: true, firstName: true, lastName: true },
|
||||
},
|
||||
},
|
||||
omit: {
|
||||
productId: true,
|
||||
inventoryId: true,
|
||||
counterInventoryId: true,
|
||||
supplierId: true,
|
||||
customerId: true,
|
||||
},
|
||||
orderBy: { createdAt: 'desc' },
|
||||
})
|
||||
|
||||
return ResponseMapper.list(items)
|
||||
}
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
import { ApiPropertyOptional } from '@nestjs/swagger'
|
||||
import { IsDateString, IsNumber, IsOptional } from 'class-validator'
|
||||
|
||||
export class ReadCardexDto {
|
||||
@ApiPropertyOptional()
|
||||
@IsDateString()
|
||||
startDate: Date
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsDateString()
|
||||
endDate?: Date
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsNumber()
|
||||
inventoryId?: number
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsNumber()
|
||||
productId?: number
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../prisma/prisma.module'
|
||||
import { PrismaModule } from '../../prisma/prisma.module'
|
||||
import { CustomersController } from './customers.controller'
|
||||
import { CustomersService } from './customers.service'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import { ResponseMapper } from '../common/response/response-mapper'
|
||||
import { PrismaService } from '../prisma/prisma.service'
|
||||
import { ResponseMapper } from '../../common/response/response-mapper'
|
||||
import { PrismaService } from '../../prisma/prisma.service'
|
||||
|
||||
@Injectable()
|
||||
export class CustomersService {
|
||||
@@ -1,6 +0,0 @@
|
||||
import { IsNumber } from 'class-validator'
|
||||
|
||||
export class UpdateInventoryBankAccountDto {
|
||||
@IsNumber()
|
||||
bankAccountId: number
|
||||
}
|
||||
@@ -1,38 +0,0 @@
|
||||
import { Body, Controller, Get, Param, Post } from '@nestjs/common'
|
||||
import { CreateBankAccountDto } from '../../bank-accounts/dto/create-bank-account.dto'
|
||||
import { UpdateInventoryBankAccountDto } from './dto/update-inventory-bank-account.dto'
|
||||
import { InventoryBankAccountsService } from './inventory-bank-accounts.service'
|
||||
|
||||
@Controller('inventories/:inventoryId/bank-accounts')
|
||||
export class InventoryBankAccountsController {
|
||||
constructor(private readonly bankAccountsService: InventoryBankAccountsService) {}
|
||||
|
||||
@Post()
|
||||
create(
|
||||
@Param('inventoryId') inventoryId: string,
|
||||
@Body() bankAccount: CreateBankAccountDto,
|
||||
) {
|
||||
return this.bankAccountsService.create(Number(inventoryId), bankAccount)
|
||||
}
|
||||
|
||||
@Get()
|
||||
findAll(@Param('inventoryId') inventoryId: string) {
|
||||
return this.bankAccountsService.findAll(Number(inventoryId))
|
||||
}
|
||||
|
||||
@Post('/assign')
|
||||
assign(
|
||||
@Param('inventoryId') inventoryId: string,
|
||||
@Body() dto: UpdateInventoryBankAccountDto,
|
||||
) {
|
||||
return this.bankAccountsService.assign(Number(inventoryId), dto.bankAccountId)
|
||||
}
|
||||
|
||||
@Post('/unassign')
|
||||
unassign(
|
||||
@Param('inventoryId') inventoryId: string,
|
||||
@Body() dto: UpdateInventoryBankAccountDto,
|
||||
) {
|
||||
return this.bankAccountsService.unassign(Number(inventoryId), dto.bankAccountId)
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../../../prisma/prisma.module'
|
||||
import { InventoryBankAccountsController } from './inventory-bank-accounts.controller'
|
||||
import { InventoryBankAccountsService } from './inventory-bank-accounts.service'
|
||||
|
||||
@Module({
|
||||
imports: [PrismaModule],
|
||||
controllers: [InventoryBankAccountsController],
|
||||
providers: [InventoryBankAccountsService],
|
||||
})
|
||||
export class InventoryBankAccountsModule {}
|
||||
@@ -1,76 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import { ResponseMapper } from '../../../common/response/response-mapper'
|
||||
import { PrismaService } from '../../../prisma/prisma.service'
|
||||
import { CreateBankAccountDto } from '../../bank-accounts/dto/create-bank-account.dto'
|
||||
|
||||
@Injectable()
|
||||
export class InventoryBankAccountsService {
|
||||
constructor(private prisma: PrismaService) {}
|
||||
|
||||
async create(inventoryId: number, bankAccount: CreateBankAccountDto) {
|
||||
return this.prisma.bankAccount
|
||||
.create({
|
||||
data: bankAccount,
|
||||
})
|
||||
.then(async res => {
|
||||
await this.prisma.inventoryBankAccount.create({
|
||||
data: {
|
||||
inventoryId,
|
||||
bankAccountId: res.id,
|
||||
},
|
||||
})
|
||||
return ResponseMapper.create(res)
|
||||
})
|
||||
}
|
||||
|
||||
async findAll(inventoryId: number) {
|
||||
const items = await this.prisma.inventoryBankAccount.findMany({
|
||||
where: {
|
||||
inventoryId,
|
||||
},
|
||||
include: {
|
||||
bankAccount: {
|
||||
include: {
|
||||
branch: {
|
||||
include: {
|
||||
bank: {
|
||||
select: { id: true, name: true, shortName: true },
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
posAccounts: {
|
||||
select: { id: true, name: true, code: true },
|
||||
},
|
||||
},
|
||||
omit: {
|
||||
bankAccountId: true,
|
||||
inventoryId: true,
|
||||
},
|
||||
})
|
||||
return ResponseMapper.list(
|
||||
items.map(item => ({ posAccounts: item.posAccounts, ...item.bankAccount })),
|
||||
)
|
||||
}
|
||||
|
||||
async assign(inventoryId: number, bankAccountId: number) {
|
||||
const item = await this.prisma.inventoryBankAccount.create({
|
||||
data: {
|
||||
inventoryId,
|
||||
bankAccountId,
|
||||
},
|
||||
})
|
||||
return ResponseMapper.create(item)
|
||||
}
|
||||
|
||||
async unassign(inventoryId: number, bankAccountId: number) {
|
||||
const item = await this.prisma.inventoryBankAccount.deleteMany({
|
||||
where: {
|
||||
inventoryId,
|
||||
bankAccountId,
|
||||
},
|
||||
})
|
||||
return ResponseMapper.single(item)
|
||||
}
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger'
|
||||
import { IsOptional, IsString } from 'class-validator'
|
||||
|
||||
export class CreateInventoryDto {
|
||||
@ApiProperty()
|
||||
@IsString()
|
||||
name: string
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
location?: string
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
import { ApiPropertyOptional } from '@nestjs/swagger'
|
||||
import { Type } from 'class-transformer'
|
||||
import { IsBoolean, IsOptional, IsString } from 'class-validator'
|
||||
|
||||
export class UpdateInventoryDto {
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
name?: string
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
location?: string
|
||||
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
@Type(() => Boolean)
|
||||
@IsBoolean()
|
||||
isActive?: boolean
|
||||
}
|
||||
@@ -1,59 +0,0 @@
|
||||
import { Body, Controller, Delete, Get, Param, Patch, Post, Query } from '@nestjs/common'
|
||||
import { ApiQuery } from '@nestjs/swagger'
|
||||
import { MovementType } from '../../../generated/prisma/enums'
|
||||
import { CreateInventoryDto } from './dto/create-inventory.dto'
|
||||
import { UpdateInventoryDto } from './dto/update-inventory.dto'
|
||||
import { InventoriesService } from './inventories.service'
|
||||
|
||||
@Controller('inventories')
|
||||
export class InventoriesController {
|
||||
constructor(private readonly inventoriesService: InventoriesService) {}
|
||||
|
||||
@Post()
|
||||
create(@Body() dto: CreateInventoryDto) {
|
||||
return this.inventoriesService.create(dto)
|
||||
}
|
||||
|
||||
@Get()
|
||||
@ApiQuery({ name: 'isPointOfSale', required: false, type: Boolean })
|
||||
findAll(@Query('isPointOfSale') isPointOfSale?: boolean) {
|
||||
return this.inventoriesService.findAll(isPointOfSale)
|
||||
}
|
||||
|
||||
@Get(':id')
|
||||
findOne(@Param('id') id: string) {
|
||||
return this.inventoriesService.findOne(Number(id))
|
||||
}
|
||||
|
||||
@Patch(':id')
|
||||
update(@Param('id') id: string, @Body() dto: UpdateInventoryDto) {
|
||||
return this.inventoriesService.update(Number(id), dto)
|
||||
}
|
||||
|
||||
@Delete(':id')
|
||||
remove(@Param('id') id: string) {
|
||||
return this.inventoriesService.remove(Number(id))
|
||||
}
|
||||
|
||||
@Get(':id/movements')
|
||||
@ApiQuery({ name: 'type', required: false, enum: MovementType })
|
||||
findInventoryMovements(@Param('id') id: string, @Query('type') type?: MovementType) {
|
||||
return this.inventoriesService.findInventoryMovements(Number(id), type ?? undefined)
|
||||
}
|
||||
|
||||
@Get(':id/stock')
|
||||
@ApiQuery({ name: 'isAvailable', required: false, type: Boolean })
|
||||
getStock(@Param('id') id: string, @Query('isAvailable') isAvailable?: boolean) {
|
||||
return this.inventoriesService.getStock(Number(id), isAvailable ?? undefined)
|
||||
}
|
||||
|
||||
@Get(':id/products/:productId/cardex')
|
||||
getProductCardex(@Param('id') id: string, @Param('productId') productId: string) {
|
||||
return this.inventoriesService.getProductCardex(Number(id), Number(productId))
|
||||
}
|
||||
|
||||
@Get(':id/cardex')
|
||||
getCardex(@Param('id') id: string) {
|
||||
return this.inventoriesService.getCardex(Number(id))
|
||||
}
|
||||
}
|
||||
@@ -1,211 +0,0 @@
|
||||
import { Injectable } from '@nestjs/common'
|
||||
import { ResponseMapper } from '../../../common/response/response-mapper'
|
||||
import { MovementType } from '../../../generated/prisma/enums'
|
||||
import { PrismaService } from '../../../prisma/prisma.service'
|
||||
|
||||
@Injectable()
|
||||
export class InventoriesService {
|
||||
constructor(private prisma: PrismaService) {}
|
||||
async create(data: any) {
|
||||
const item = await this.prisma.inventory.create({ data })
|
||||
return ResponseMapper.create(item)
|
||||
}
|
||||
|
||||
async findAll(isPointOfSale?: boolean) {
|
||||
const items = await this.prisma.inventory.findMany({
|
||||
where: isPointOfSale !== undefined ? { isPointOfSale } : undefined,
|
||||
})
|
||||
|
||||
return ResponseMapper.list(items)
|
||||
}
|
||||
|
||||
async findOne(id: number) {
|
||||
const item = await this.prisma.inventory.findUnique({
|
||||
where: { id },
|
||||
include: {
|
||||
stockBalances: {
|
||||
where: { quantity: { gt: 0 } },
|
||||
select: { quantity: true, totalCost: true },
|
||||
},
|
||||
},
|
||||
})
|
||||
if (!item) return null
|
||||
|
||||
const { stockBalances, ...rest } = item
|
||||
return ResponseMapper.single({
|
||||
...rest,
|
||||
availableProductTypes: stockBalances.length,
|
||||
availableProductCount: stockBalances.reduce(
|
||||
(acc, sb) => acc + Number(sb.quantity),
|
||||
0,
|
||||
),
|
||||
availableProductsCost: stockBalances.reduce(
|
||||
(acc, sb) => acc + Number(sb.totalCost),
|
||||
0,
|
||||
),
|
||||
})
|
||||
}
|
||||
|
||||
async update(id: number, data: any) {
|
||||
const item = await this.prisma.inventory.update({ where: { id }, data })
|
||||
return ResponseMapper.update(item)
|
||||
}
|
||||
|
||||
async remove(id: number) {
|
||||
const item = await this.prisma.inventory.delete({ where: { id } })
|
||||
return ResponseMapper.single(item)
|
||||
}
|
||||
|
||||
async findInventoryMovements(
|
||||
inventoryId: number,
|
||||
type?: MovementType,
|
||||
page = 1,
|
||||
pageSize = 10,
|
||||
) {
|
||||
const groups = await this.prisma.stockMovement.groupBy({
|
||||
by: ['referenceId', 'referenceType'],
|
||||
where: { inventoryId, type },
|
||||
_count: { id: true },
|
||||
orderBy: { referenceId: 'desc' },
|
||||
skip: (page - 1) * pageSize,
|
||||
take: pageSize,
|
||||
})
|
||||
|
||||
const result = await Promise.all(
|
||||
groups.map(async group => {
|
||||
const movements = await this.prisma.stockMovement.findMany({
|
||||
where: {
|
||||
inventoryId,
|
||||
AND: {
|
||||
referenceId: group.referenceId,
|
||||
AND: { referenceType: group.referenceType },
|
||||
},
|
||||
},
|
||||
include: {
|
||||
product: true,
|
||||
counterInventory: {
|
||||
select: { id: true, name: true },
|
||||
},
|
||||
},
|
||||
})
|
||||
let info = null as any
|
||||
|
||||
const mapped = movements.map(movement => {
|
||||
const { id, quantity, unitPrice, totalCost, avgCost, product } = movement
|
||||
if (info === null) {
|
||||
info = {
|
||||
date: movement.createdAt,
|
||||
type: movement.type,
|
||||
quantity: Number(movement.quantity),
|
||||
unitPrice: Number(movement.unitPrice),
|
||||
totalCost: Number(movement.totalCost),
|
||||
referenceType: movement.referenceType,
|
||||
referenceId: movement.referenceId,
|
||||
counterInventory: movement.counterInventory,
|
||||
createdAt: movement.createdAt,
|
||||
}
|
||||
} else {
|
||||
info.quantity += Number(movement.quantity)
|
||||
info.unitPrice += Number(movement.unitPrice)
|
||||
info.totalCost += Number(movement.totalCost)
|
||||
}
|
||||
return {
|
||||
id,
|
||||
quantity: Number(quantity),
|
||||
unitPrice: Number(unitPrice),
|
||||
totalCost: Number(totalCost),
|
||||
avgCost: Number(avgCost),
|
||||
product,
|
||||
}
|
||||
})
|
||||
return {
|
||||
receiptId: group.referenceId,
|
||||
count: group._count.id,
|
||||
info,
|
||||
movements: mapped,
|
||||
}
|
||||
}),
|
||||
)
|
||||
return ResponseMapper.list(result)
|
||||
}
|
||||
|
||||
async getStock(inventoryId: number, isAvailable?: boolean, page = 1, pageSize = 10) {
|
||||
const items = await this.prisma.stockBalance.findMany({
|
||||
where: {
|
||||
inventoryId,
|
||||
quantity:
|
||||
isAvailable === true
|
||||
? { gt: 0 }
|
||||
: isAvailable === false
|
||||
? { lte: 0 }
|
||||
: undefined,
|
||||
},
|
||||
include: {
|
||||
product: true,
|
||||
},
|
||||
orderBy: {
|
||||
updatedAt: 'desc',
|
||||
},
|
||||
skip: (page - 1) * pageSize,
|
||||
take: pageSize,
|
||||
})
|
||||
|
||||
const mapped = items.map(item => ({
|
||||
id: item.id,
|
||||
quantity: Number(item.quantity),
|
||||
avgCost: Number(item.avgCost),
|
||||
product: item.product,
|
||||
}))
|
||||
|
||||
return ResponseMapper.list(mapped)
|
||||
}
|
||||
|
||||
async getCardex(inventoryId: number) {
|
||||
const movements = await this.prisma.stockMovement.findMany({
|
||||
where: { inventoryId },
|
||||
orderBy: { createdAt: 'asc' },
|
||||
include: {
|
||||
customer: { select: { id: true, firstName: true, lastName: true } },
|
||||
supplier: { select: { id: true, firstName: true, lastName: true } },
|
||||
counterInventory: {
|
||||
select: { id: true, name: true },
|
||||
},
|
||||
product: {
|
||||
select: { id: true, name: true, sku: true },
|
||||
},
|
||||
},
|
||||
omit: {
|
||||
inventoryId: true,
|
||||
productId: true,
|
||||
customerId: true,
|
||||
supplierId: true,
|
||||
counterInventoryId: true,
|
||||
},
|
||||
})
|
||||
|
||||
return ResponseMapper.list(movements)
|
||||
}
|
||||
|
||||
async getProductCardex(inventoryId: number, productId: number) {
|
||||
const movements = await this.prisma.stockMovement.findMany({
|
||||
where: { productId, inventoryId },
|
||||
orderBy: { createdAt: 'asc' },
|
||||
include: {
|
||||
customer: { select: { id: true, firstName: true, lastName: true } },
|
||||
supplier: { select: { id: true, firstName: true, lastName: true } },
|
||||
counterInventory: {
|
||||
select: { id: true, name: true },
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
return ResponseMapper.list(movements)
|
||||
}
|
||||
|
||||
async getInventoryBankAccounts(inventoryId: number) {
|
||||
const items = await this.prisma.bankAccount.findMany({
|
||||
where: { inventoryBankAccounts: { some: { inventoryId } } },
|
||||
})
|
||||
return ResponseMapper.list(items)
|
||||
}
|
||||
}
|
||||
@@ -1,5 +0,0 @@
|
||||
export interface IInventoryResponse {
|
||||
name: string
|
||||
location?: string
|
||||
isActive: boolean
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
import { Module } from '@nestjs/common'
|
||||
import { PrismaModule } from '../../prisma/prisma.module'
|
||||
import { InventoryBankAccountsModule } from './bank-accounts/inventory-bank-accounts.module'
|
||||
import { InventoriesController } from './index/inventories.controller'
|
||||
import { InventoriesService } from './index/inventories.service'
|
||||
import { PosAccountsModule } from './pos-accounts/pos-accounts.module'
|
||||
|
||||
@Module({
|
||||
imports: [PrismaModule, InventoryBankAccountsModule, PosAccountsModule],
|
||||
controllers: [InventoriesController],
|
||||
providers: [InventoriesService],
|
||||
})
|
||||
export class InventoriesModule {}
|
||||
@@ -1,16 +0,0 @@
|
||||
import { IsInt, IsOptional, IsString } from 'class-validator'
|
||||
|
||||
export class CreatePosAccountDto {
|
||||
@IsString()
|
||||
name: string
|
||||
|
||||
@IsString()
|
||||
code: string
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
description?: string
|
||||
|
||||
@IsInt()
|
||||
bankAccountId: number
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
import { PartialType } from '@nestjs/swagger'
|
||||
import { IsInt } from 'class-validator'
|
||||
import { CreatePosAccountDto } from './create-pos-accounts.dto'
|
||||
|
||||
export class UpdatePosAccountDto extends PartialType(CreatePosAccountDto) {
|
||||
@IsInt()
|
||||
bankAccountId: number
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user