
/* !!! This is code generated by Prisma. Do not edit directly. !!! */
/* eslint-disable */
// biome-ignore-all lint: generated file
// @ts-nocheck 
/*
 * This file exports the `Transaction` 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"
import type * as Prisma from "../internal/prismaNamespace"

/**
 * Model Transaction
 * 
 */
export type TransactionModel = runtime.Types.Result.DefaultSelection<Prisma.$TransactionPayload>

export type AggregateTransaction = {
  _count: TransactionCountAggregateOutputType | null
  _avg: TransactionAvgAggregateOutputType | null
  _sum: TransactionSumAggregateOutputType | null
  _min: TransactionMinAggregateOutputType | null
  _max: TransactionMaxAggregateOutputType | null
}

export type TransactionAvgAggregateOutputType = {
  totalGrossWeight: runtime.Decimal | null
  totalNetWeight: runtime.Decimal | null
  totalAmount: runtime.Decimal | null
}

export type TransactionSumAggregateOutputType = {
  totalGrossWeight: runtime.Decimal | null
  totalNetWeight: runtime.Decimal | null
  totalAmount: runtime.Decimal | null
}

export type TransactionMinAggregateOutputType = {
  id: string | null
  trxCode: string | null
  branchId: string | null
  customerId: string | null
  status: $Enums.TransactionStatus | null
  totalGrossWeight: runtime.Decimal | null
  totalNetWeight: runtime.Decimal | null
  totalAmount: runtime.Decimal | null
  bankId: string | null
  bankAccountNo: string | null
  bankAccountName: string | null
  referralSource: string | null
  knowsFounder: boolean | null
  createdBy: string | null
  createdAt: Date | null
  modifiedBy: string | null
  modifiedAt: Date | null
  cancellationReason: string | null
  cancelledBy: string | null
  cancelledAt: Date | null
  completedBy: string | null
  completedAt: Date | null
  headStoreId: string | null
}

export type TransactionMaxAggregateOutputType = {
  id: string | null
  trxCode: string | null
  branchId: string | null
  customerId: string | null
  status: $Enums.TransactionStatus | null
  totalGrossWeight: runtime.Decimal | null
  totalNetWeight: runtime.Decimal | null
  totalAmount: runtime.Decimal | null
  bankId: string | null
  bankAccountNo: string | null
  bankAccountName: string | null
  referralSource: string | null
  knowsFounder: boolean | null
  createdBy: string | null
  createdAt: Date | null
  modifiedBy: string | null
  modifiedAt: Date | null
  cancellationReason: string | null
  cancelledBy: string | null
  cancelledAt: Date | null
  completedBy: string | null
  completedAt: Date | null
  headStoreId: string | null
}

export type TransactionCountAggregateOutputType = {
  id: number
  trxCode: number
  branchId: number
  customerId: number
  status: number
  totalGrossWeight: number
  totalNetWeight: number
  totalAmount: number
  bankId: number
  bankAccountNo: number
  bankAccountName: number
  referralSource: number
  knowsFounder: number
  createdBy: number
  createdAt: number
  modifiedBy: number
  modifiedAt: number
  cancellationReason: number
  cancelledBy: number
  cancelledAt: number
  completedBy: number
  completedAt: number
  headStoreId: number
  _all: number
}


export type TransactionAvgAggregateInputType = {
  totalGrossWeight?: true
  totalNetWeight?: true
  totalAmount?: true
}

export type TransactionSumAggregateInputType = {
  totalGrossWeight?: true
  totalNetWeight?: true
  totalAmount?: true
}

export type TransactionMinAggregateInputType = {
  id?: true
  trxCode?: true
  branchId?: true
  customerId?: true
  status?: true
  totalGrossWeight?: true
  totalNetWeight?: true
  totalAmount?: true
  bankId?: true
  bankAccountNo?: true
  bankAccountName?: true
  referralSource?: true
  knowsFounder?: true
  createdBy?: true
  createdAt?: true
  modifiedBy?: true
  modifiedAt?: true
  cancellationReason?: true
  cancelledBy?: true
  cancelledAt?: true
  completedBy?: true
  completedAt?: true
  headStoreId?: true
}

export type TransactionMaxAggregateInputType = {
  id?: true
  trxCode?: true
  branchId?: true
  customerId?: true
  status?: true
  totalGrossWeight?: true
  totalNetWeight?: true
  totalAmount?: true
  bankId?: true
  bankAccountNo?: true
  bankAccountName?: true
  referralSource?: true
  knowsFounder?: true
  createdBy?: true
  createdAt?: true
  modifiedBy?: true
  modifiedAt?: true
  cancellationReason?: true
  cancelledBy?: true
  cancelledAt?: true
  completedBy?: true
  completedAt?: true
  headStoreId?: true
}

export type TransactionCountAggregateInputType = {
  id?: true
  trxCode?: true
  branchId?: true
  customerId?: true
  status?: true
  totalGrossWeight?: true
  totalNetWeight?: true
  totalAmount?: true
  bankId?: true
  bankAccountNo?: true
  bankAccountName?: true
  referralSource?: true
  knowsFounder?: true
  createdBy?: true
  createdAt?: true
  modifiedBy?: true
  modifiedAt?: true
  cancellationReason?: true
  cancelledBy?: true
  cancelledAt?: true
  completedBy?: true
  completedAt?: true
  headStoreId?: true
  _all?: true
}

export type TransactionAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Filter which Transaction to aggregate.
   */
  where?: Prisma.TransactionWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of Transactions to fetch.
   */
  orderBy?: Prisma.TransactionOrderByWithRelationInput | Prisma.TransactionOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the start position
   */
  cursor?: Prisma.TransactionWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` Transactions from the position of the cursor.
   */
  take?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Skip the first `n` Transactions.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Count returned Transactions
  **/
  _count?: true | TransactionCountAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to average
  **/
  _avg?: TransactionAvgAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to sum
  **/
  _sum?: TransactionSumAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to find the minimum value
  **/
  _min?: TransactionMinAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to find the maximum value
  **/
  _max?: TransactionMaxAggregateInputType
}

export type GetTransactionAggregateType<T extends TransactionAggregateArgs> = {
      [P in keyof T & keyof AggregateTransaction]: P extends '_count' | 'count'
    ? T[P] extends true
      ? number
      : Prisma.GetScalarType<T[P], AggregateTransaction[P]>
    : Prisma.GetScalarType<T[P], AggregateTransaction[P]>
}




export type TransactionGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.TransactionWhereInput
  orderBy?: Prisma.TransactionOrderByWithAggregationInput | Prisma.TransactionOrderByWithAggregationInput[]
  by: Prisma.TransactionScalarFieldEnum[] | Prisma.TransactionScalarFieldEnum
  having?: Prisma.TransactionScalarWhereWithAggregatesInput
  take?: number
  skip?: number
  _count?: TransactionCountAggregateInputType | true
  _avg?: TransactionAvgAggregateInputType
  _sum?: TransactionSumAggregateInputType
  _min?: TransactionMinAggregateInputType
  _max?: TransactionMaxAggregateInputType
}

export type TransactionGroupByOutputType = {
  id: string
  trxCode: string
  branchId: string
  customerId: string
  status: $Enums.TransactionStatus
  totalGrossWeight: runtime.Decimal | null
  totalNetWeight: runtime.Decimal | null
  totalAmount: runtime.Decimal | null
  bankId: string | null
  bankAccountNo: string | null
  bankAccountName: string | null
  referralSource: string | null
  knowsFounder: boolean | null
  createdBy: string | null
  createdAt: Date
  modifiedBy: string | null
  modifiedAt: Date | null
  cancellationReason: string | null
  cancelledBy: string | null
  cancelledAt: Date | null
  completedBy: string | null
  completedAt: Date | null
  headStoreId: string | null
  _count: TransactionCountAggregateOutputType | null
  _avg: TransactionAvgAggregateOutputType | null
  _sum: TransactionSumAggregateOutputType | null
  _min: TransactionMinAggregateOutputType | null
  _max: TransactionMaxAggregateOutputType | null
}

type GetTransactionGroupByPayload<T extends TransactionGroupByArgs> = Prisma.PrismaPromise<
  Array<
    Prisma.PickEnumerable<TransactionGroupByOutputType, T['by']> &
      {
        [P in ((keyof T) & (keyof TransactionGroupByOutputType))]: P extends '_count'
          ? T[P] extends boolean
            ? number
            : Prisma.GetScalarType<T[P], TransactionGroupByOutputType[P]>
          : Prisma.GetScalarType<T[P], TransactionGroupByOutputType[P]>
      }
    >
  >



export type TransactionWhereInput = {
  AND?: Prisma.TransactionWhereInput | Prisma.TransactionWhereInput[]
  OR?: Prisma.TransactionWhereInput[]
  NOT?: Prisma.TransactionWhereInput | Prisma.TransactionWhereInput[]
  id?: Prisma.StringFilter<"Transaction"> | string
  trxCode?: Prisma.StringFilter<"Transaction"> | string
  branchId?: Prisma.StringFilter<"Transaction"> | string
  customerId?: Prisma.StringFilter<"Transaction"> | string
  status?: Prisma.EnumTransactionStatusFilter<"Transaction"> | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.UuidNullableFilter<"Transaction"> | string | null
  bankAccountNo?: Prisma.StringNullableFilter<"Transaction"> | string | null
  bankAccountName?: Prisma.StringNullableFilter<"Transaction"> | string | null
  referralSource?: Prisma.StringNullableFilter<"Transaction"> | string | null
  knowsFounder?: Prisma.BoolNullableFilter<"Transaction"> | boolean | null
  createdBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  createdAt?: Prisma.DateTimeFilter<"Transaction"> | Date | string
  modifiedBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  modifiedAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  cancellationReason?: Prisma.StringNullableFilter<"Transaction"> | string | null
  cancelledBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  cancelledAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  completedBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  completedAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  headStoreId?: Prisma.StringNullableFilter<"Transaction"> | string | null
  branch?: Prisma.XOR<Prisma.BranchScalarRelationFilter, Prisma.BranchWhereInput>
  customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput>
  bank?: Prisma.XOR<Prisma.BankNullableScalarRelationFilter, Prisma.BankWhereInput> | null
  docs?: Prisma.TransactionDocListRelationFilter
  createdByUser?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
  modifiedByUser?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
  items?: Prisma.TransactionItemListRelationFilter
  approvals?: Prisma.ApprovalListRelationFilter
  payments?: Prisma.PaymentListRelationFilter
  snapshots?: Prisma.TransactionSnapshotListRelationFilter
  completedByUser?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
  headStoreUser?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
}

export type TransactionOrderByWithRelationInput = {
  id?: Prisma.SortOrder
  trxCode?: Prisma.SortOrder
  branchId?: Prisma.SortOrder
  customerId?: Prisma.SortOrder
  status?: Prisma.SortOrder
  totalGrossWeight?: Prisma.SortOrderInput | Prisma.SortOrder
  totalNetWeight?: Prisma.SortOrderInput | Prisma.SortOrder
  totalAmount?: Prisma.SortOrderInput | Prisma.SortOrder
  bankId?: Prisma.SortOrderInput | Prisma.SortOrder
  bankAccountNo?: Prisma.SortOrderInput | Prisma.SortOrder
  bankAccountName?: Prisma.SortOrderInput | Prisma.SortOrder
  referralSource?: Prisma.SortOrderInput | Prisma.SortOrder
  knowsFounder?: Prisma.SortOrderInput | Prisma.SortOrder
  createdBy?: Prisma.SortOrderInput | Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  modifiedBy?: Prisma.SortOrderInput | Prisma.SortOrder
  modifiedAt?: Prisma.SortOrderInput | Prisma.SortOrder
  cancellationReason?: Prisma.SortOrderInput | Prisma.SortOrder
  cancelledBy?: Prisma.SortOrderInput | Prisma.SortOrder
  cancelledAt?: Prisma.SortOrderInput | Prisma.SortOrder
  completedBy?: Prisma.SortOrderInput | Prisma.SortOrder
  completedAt?: Prisma.SortOrderInput | Prisma.SortOrder
  headStoreId?: Prisma.SortOrderInput | Prisma.SortOrder
  branch?: Prisma.BranchOrderByWithRelationInput
  customer?: Prisma.CustomerOrderByWithRelationInput
  bank?: Prisma.BankOrderByWithRelationInput
  docs?: Prisma.TransactionDocOrderByRelationAggregateInput
  createdByUser?: Prisma.UserOrderByWithRelationInput
  modifiedByUser?: Prisma.UserOrderByWithRelationInput
  items?: Prisma.TransactionItemOrderByRelationAggregateInput
  approvals?: Prisma.ApprovalOrderByRelationAggregateInput
  payments?: Prisma.PaymentOrderByRelationAggregateInput
  snapshots?: Prisma.TransactionSnapshotOrderByRelationAggregateInput
  completedByUser?: Prisma.UserOrderByWithRelationInput
  headStoreUser?: Prisma.UserOrderByWithRelationInput
}

export type TransactionWhereUniqueInput = Prisma.AtLeast<{
  id?: string
  trxCode?: string
  AND?: Prisma.TransactionWhereInput | Prisma.TransactionWhereInput[]
  OR?: Prisma.TransactionWhereInput[]
  NOT?: Prisma.TransactionWhereInput | Prisma.TransactionWhereInput[]
  branchId?: Prisma.StringFilter<"Transaction"> | string
  customerId?: Prisma.StringFilter<"Transaction"> | string
  status?: Prisma.EnumTransactionStatusFilter<"Transaction"> | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.UuidNullableFilter<"Transaction"> | string | null
  bankAccountNo?: Prisma.StringNullableFilter<"Transaction"> | string | null
  bankAccountName?: Prisma.StringNullableFilter<"Transaction"> | string | null
  referralSource?: Prisma.StringNullableFilter<"Transaction"> | string | null
  knowsFounder?: Prisma.BoolNullableFilter<"Transaction"> | boolean | null
  createdBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  createdAt?: Prisma.DateTimeFilter<"Transaction"> | Date | string
  modifiedBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  modifiedAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  cancellationReason?: Prisma.StringNullableFilter<"Transaction"> | string | null
  cancelledBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  cancelledAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  completedBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  completedAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  headStoreId?: Prisma.StringNullableFilter<"Transaction"> | string | null
  branch?: Prisma.XOR<Prisma.BranchScalarRelationFilter, Prisma.BranchWhereInput>
  customer?: Prisma.XOR<Prisma.CustomerScalarRelationFilter, Prisma.CustomerWhereInput>
  bank?: Prisma.XOR<Prisma.BankNullableScalarRelationFilter, Prisma.BankWhereInput> | null
  docs?: Prisma.TransactionDocListRelationFilter
  createdByUser?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
  modifiedByUser?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
  items?: Prisma.TransactionItemListRelationFilter
  approvals?: Prisma.ApprovalListRelationFilter
  payments?: Prisma.PaymentListRelationFilter
  snapshots?: Prisma.TransactionSnapshotListRelationFilter
  completedByUser?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
  headStoreUser?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
}, "id" | "trxCode">

export type TransactionOrderByWithAggregationInput = {
  id?: Prisma.SortOrder
  trxCode?: Prisma.SortOrder
  branchId?: Prisma.SortOrder
  customerId?: Prisma.SortOrder
  status?: Prisma.SortOrder
  totalGrossWeight?: Prisma.SortOrderInput | Prisma.SortOrder
  totalNetWeight?: Prisma.SortOrderInput | Prisma.SortOrder
  totalAmount?: Prisma.SortOrderInput | Prisma.SortOrder
  bankId?: Prisma.SortOrderInput | Prisma.SortOrder
  bankAccountNo?: Prisma.SortOrderInput | Prisma.SortOrder
  bankAccountName?: Prisma.SortOrderInput | Prisma.SortOrder
  referralSource?: Prisma.SortOrderInput | Prisma.SortOrder
  knowsFounder?: Prisma.SortOrderInput | Prisma.SortOrder
  createdBy?: Prisma.SortOrderInput | Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  modifiedBy?: Prisma.SortOrderInput | Prisma.SortOrder
  modifiedAt?: Prisma.SortOrderInput | Prisma.SortOrder
  cancellationReason?: Prisma.SortOrderInput | Prisma.SortOrder
  cancelledBy?: Prisma.SortOrderInput | Prisma.SortOrder
  cancelledAt?: Prisma.SortOrderInput | Prisma.SortOrder
  completedBy?: Prisma.SortOrderInput | Prisma.SortOrder
  completedAt?: Prisma.SortOrderInput | Prisma.SortOrder
  headStoreId?: Prisma.SortOrderInput | Prisma.SortOrder
  _count?: Prisma.TransactionCountOrderByAggregateInput
  _avg?: Prisma.TransactionAvgOrderByAggregateInput
  _max?: Prisma.TransactionMaxOrderByAggregateInput
  _min?: Prisma.TransactionMinOrderByAggregateInput
  _sum?: Prisma.TransactionSumOrderByAggregateInput
}

export type TransactionScalarWhereWithAggregatesInput = {
  AND?: Prisma.TransactionScalarWhereWithAggregatesInput | Prisma.TransactionScalarWhereWithAggregatesInput[]
  OR?: Prisma.TransactionScalarWhereWithAggregatesInput[]
  NOT?: Prisma.TransactionScalarWhereWithAggregatesInput | Prisma.TransactionScalarWhereWithAggregatesInput[]
  id?: Prisma.StringWithAggregatesFilter<"Transaction"> | string
  trxCode?: Prisma.StringWithAggregatesFilter<"Transaction"> | string
  branchId?: Prisma.StringWithAggregatesFilter<"Transaction"> | string
  customerId?: Prisma.StringWithAggregatesFilter<"Transaction"> | string
  status?: Prisma.EnumTransactionStatusWithAggregatesFilter<"Transaction"> | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.DecimalNullableWithAggregatesFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.DecimalNullableWithAggregatesFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.DecimalNullableWithAggregatesFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.UuidNullableWithAggregatesFilter<"Transaction"> | string | null
  bankAccountNo?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
  bankAccountName?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
  referralSource?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
  knowsFounder?: Prisma.BoolNullableWithAggregatesFilter<"Transaction"> | boolean | null
  createdBy?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
  createdAt?: Prisma.DateTimeWithAggregatesFilter<"Transaction"> | Date | string
  modifiedBy?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
  modifiedAt?: Prisma.DateTimeNullableWithAggregatesFilter<"Transaction"> | Date | string | null
  cancellationReason?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
  cancelledBy?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
  cancelledAt?: Prisma.DateTimeNullableWithAggregatesFilter<"Transaction"> | Date | string | null
  completedBy?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
  completedAt?: Prisma.DateTimeNullableWithAggregatesFilter<"Transaction"> | Date | string | null
  headStoreId?: Prisma.StringNullableWithAggregatesFilter<"Transaction"> | string | null
}

export type TransactionCreateInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionUpdateInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionCreateManyInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
}

export type TransactionUpdateManyMutationInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
}

export type TransactionUncheckedUpdateManyInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}

export type TransactionListRelationFilter = {
  every?: Prisma.TransactionWhereInput
  some?: Prisma.TransactionWhereInput
  none?: Prisma.TransactionWhereInput
}

export type TransactionOrderByRelationAggregateInput = {
  _count?: Prisma.SortOrder
}

export type TransactionCountOrderByAggregateInput = {
  id?: Prisma.SortOrder
  trxCode?: Prisma.SortOrder
  branchId?: Prisma.SortOrder
  customerId?: Prisma.SortOrder
  status?: Prisma.SortOrder
  totalGrossWeight?: Prisma.SortOrder
  totalNetWeight?: Prisma.SortOrder
  totalAmount?: Prisma.SortOrder
  bankId?: Prisma.SortOrder
  bankAccountNo?: Prisma.SortOrder
  bankAccountName?: Prisma.SortOrder
  referralSource?: Prisma.SortOrder
  knowsFounder?: Prisma.SortOrder
  createdBy?: Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  modifiedBy?: Prisma.SortOrder
  modifiedAt?: Prisma.SortOrder
  cancellationReason?: Prisma.SortOrder
  cancelledBy?: Prisma.SortOrder
  cancelledAt?: Prisma.SortOrder
  completedBy?: Prisma.SortOrder
  completedAt?: Prisma.SortOrder
  headStoreId?: Prisma.SortOrder
}

export type TransactionAvgOrderByAggregateInput = {
  totalGrossWeight?: Prisma.SortOrder
  totalNetWeight?: Prisma.SortOrder
  totalAmount?: Prisma.SortOrder
}

export type TransactionMaxOrderByAggregateInput = {
  id?: Prisma.SortOrder
  trxCode?: Prisma.SortOrder
  branchId?: Prisma.SortOrder
  customerId?: Prisma.SortOrder
  status?: Prisma.SortOrder
  totalGrossWeight?: Prisma.SortOrder
  totalNetWeight?: Prisma.SortOrder
  totalAmount?: Prisma.SortOrder
  bankId?: Prisma.SortOrder
  bankAccountNo?: Prisma.SortOrder
  bankAccountName?: Prisma.SortOrder
  referralSource?: Prisma.SortOrder
  knowsFounder?: Prisma.SortOrder
  createdBy?: Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  modifiedBy?: Prisma.SortOrder
  modifiedAt?: Prisma.SortOrder
  cancellationReason?: Prisma.SortOrder
  cancelledBy?: Prisma.SortOrder
  cancelledAt?: Prisma.SortOrder
  completedBy?: Prisma.SortOrder
  completedAt?: Prisma.SortOrder
  headStoreId?: Prisma.SortOrder
}

export type TransactionMinOrderByAggregateInput = {
  id?: Prisma.SortOrder
  trxCode?: Prisma.SortOrder
  branchId?: Prisma.SortOrder
  customerId?: Prisma.SortOrder
  status?: Prisma.SortOrder
  totalGrossWeight?: Prisma.SortOrder
  totalNetWeight?: Prisma.SortOrder
  totalAmount?: Prisma.SortOrder
  bankId?: Prisma.SortOrder
  bankAccountNo?: Prisma.SortOrder
  bankAccountName?: Prisma.SortOrder
  referralSource?: Prisma.SortOrder
  knowsFounder?: Prisma.SortOrder
  createdBy?: Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  modifiedBy?: Prisma.SortOrder
  modifiedAt?: Prisma.SortOrder
  cancellationReason?: Prisma.SortOrder
  cancelledBy?: Prisma.SortOrder
  cancelledAt?: Prisma.SortOrder
  completedBy?: Prisma.SortOrder
  completedAt?: Prisma.SortOrder
  headStoreId?: Prisma.SortOrder
}

export type TransactionSumOrderByAggregateInput = {
  totalGrossWeight?: Prisma.SortOrder
  totalNetWeight?: Prisma.SortOrder
  totalAmount?: Prisma.SortOrder
}

export type TransactionScalarRelationFilter = {
  is?: Prisma.TransactionWhereInput
  isNot?: Prisma.TransactionWhereInput
}

export type TransactionCreateNestedManyWithoutHeadStoreUserInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutHeadStoreUserInput, Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput> | Prisma.TransactionCreateWithoutHeadStoreUserInput[] | Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutHeadStoreUserInput | Prisma.TransactionCreateOrConnectWithoutHeadStoreUserInput[]
  createMany?: Prisma.TransactionCreateManyHeadStoreUserInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionCreateNestedManyWithoutCompletedByUserInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCompletedByUserInput, Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput> | Prisma.TransactionCreateWithoutCompletedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCompletedByUserInput | Prisma.TransactionCreateOrConnectWithoutCompletedByUserInput[]
  createMany?: Prisma.TransactionCreateManyCompletedByUserInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionCreateNestedManyWithoutCreatedByUserInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCreatedByUserInput, Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput> | Prisma.TransactionCreateWithoutCreatedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCreatedByUserInput | Prisma.TransactionCreateOrConnectWithoutCreatedByUserInput[]
  createMany?: Prisma.TransactionCreateManyCreatedByUserInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionCreateNestedManyWithoutModifiedByUserInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutModifiedByUserInput, Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput> | Prisma.TransactionCreateWithoutModifiedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutModifiedByUserInput | Prisma.TransactionCreateOrConnectWithoutModifiedByUserInput[]
  createMany?: Prisma.TransactionCreateManyModifiedByUserInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUncheckedCreateNestedManyWithoutHeadStoreUserInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutHeadStoreUserInput, Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput> | Prisma.TransactionCreateWithoutHeadStoreUserInput[] | Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutHeadStoreUserInput | Prisma.TransactionCreateOrConnectWithoutHeadStoreUserInput[]
  createMany?: Prisma.TransactionCreateManyHeadStoreUserInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUncheckedCreateNestedManyWithoutCompletedByUserInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCompletedByUserInput, Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput> | Prisma.TransactionCreateWithoutCompletedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCompletedByUserInput | Prisma.TransactionCreateOrConnectWithoutCompletedByUserInput[]
  createMany?: Prisma.TransactionCreateManyCompletedByUserInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUncheckedCreateNestedManyWithoutCreatedByUserInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCreatedByUserInput, Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput> | Prisma.TransactionCreateWithoutCreatedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCreatedByUserInput | Prisma.TransactionCreateOrConnectWithoutCreatedByUserInput[]
  createMany?: Prisma.TransactionCreateManyCreatedByUserInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUncheckedCreateNestedManyWithoutModifiedByUserInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutModifiedByUserInput, Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput> | Prisma.TransactionCreateWithoutModifiedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutModifiedByUserInput | Prisma.TransactionCreateOrConnectWithoutModifiedByUserInput[]
  createMany?: Prisma.TransactionCreateManyModifiedByUserInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUpdateManyWithoutHeadStoreUserNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutHeadStoreUserInput, Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput> | Prisma.TransactionCreateWithoutHeadStoreUserInput[] | Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutHeadStoreUserInput | Prisma.TransactionCreateOrConnectWithoutHeadStoreUserInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutHeadStoreUserInput | Prisma.TransactionUpsertWithWhereUniqueWithoutHeadStoreUserInput[]
  createMany?: Prisma.TransactionCreateManyHeadStoreUserInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutHeadStoreUserInput | Prisma.TransactionUpdateWithWhereUniqueWithoutHeadStoreUserInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutHeadStoreUserInput | Prisma.TransactionUpdateManyWithWhereWithoutHeadStoreUserInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUpdateManyWithoutCompletedByUserNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCompletedByUserInput, Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput> | Prisma.TransactionCreateWithoutCompletedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCompletedByUserInput | Prisma.TransactionCreateOrConnectWithoutCompletedByUserInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutCompletedByUserInput | Prisma.TransactionUpsertWithWhereUniqueWithoutCompletedByUserInput[]
  createMany?: Prisma.TransactionCreateManyCompletedByUserInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutCompletedByUserInput | Prisma.TransactionUpdateWithWhereUniqueWithoutCompletedByUserInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutCompletedByUserInput | Prisma.TransactionUpdateManyWithWhereWithoutCompletedByUserInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUpdateManyWithoutCreatedByUserNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCreatedByUserInput, Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput> | Prisma.TransactionCreateWithoutCreatedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCreatedByUserInput | Prisma.TransactionCreateOrConnectWithoutCreatedByUserInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutCreatedByUserInput | Prisma.TransactionUpsertWithWhereUniqueWithoutCreatedByUserInput[]
  createMany?: Prisma.TransactionCreateManyCreatedByUserInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutCreatedByUserInput | Prisma.TransactionUpdateWithWhereUniqueWithoutCreatedByUserInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutCreatedByUserInput | Prisma.TransactionUpdateManyWithWhereWithoutCreatedByUserInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUpdateManyWithoutModifiedByUserNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutModifiedByUserInput, Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput> | Prisma.TransactionCreateWithoutModifiedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutModifiedByUserInput | Prisma.TransactionCreateOrConnectWithoutModifiedByUserInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutModifiedByUserInput | Prisma.TransactionUpsertWithWhereUniqueWithoutModifiedByUserInput[]
  createMany?: Prisma.TransactionCreateManyModifiedByUserInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutModifiedByUserInput | Prisma.TransactionUpdateWithWhereUniqueWithoutModifiedByUserInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutModifiedByUserInput | Prisma.TransactionUpdateManyWithWhereWithoutModifiedByUserInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUncheckedUpdateManyWithoutHeadStoreUserNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutHeadStoreUserInput, Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput> | Prisma.TransactionCreateWithoutHeadStoreUserInput[] | Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutHeadStoreUserInput | Prisma.TransactionCreateOrConnectWithoutHeadStoreUserInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutHeadStoreUserInput | Prisma.TransactionUpsertWithWhereUniqueWithoutHeadStoreUserInput[]
  createMany?: Prisma.TransactionCreateManyHeadStoreUserInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutHeadStoreUserInput | Prisma.TransactionUpdateWithWhereUniqueWithoutHeadStoreUserInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutHeadStoreUserInput | Prisma.TransactionUpdateManyWithWhereWithoutHeadStoreUserInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUncheckedUpdateManyWithoutCompletedByUserNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCompletedByUserInput, Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput> | Prisma.TransactionCreateWithoutCompletedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCompletedByUserInput | Prisma.TransactionCreateOrConnectWithoutCompletedByUserInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutCompletedByUserInput | Prisma.TransactionUpsertWithWhereUniqueWithoutCompletedByUserInput[]
  createMany?: Prisma.TransactionCreateManyCompletedByUserInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutCompletedByUserInput | Prisma.TransactionUpdateWithWhereUniqueWithoutCompletedByUserInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutCompletedByUserInput | Prisma.TransactionUpdateManyWithWhereWithoutCompletedByUserInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUncheckedUpdateManyWithoutCreatedByUserNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCreatedByUserInput, Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput> | Prisma.TransactionCreateWithoutCreatedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCreatedByUserInput | Prisma.TransactionCreateOrConnectWithoutCreatedByUserInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutCreatedByUserInput | Prisma.TransactionUpsertWithWhereUniqueWithoutCreatedByUserInput[]
  createMany?: Prisma.TransactionCreateManyCreatedByUserInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutCreatedByUserInput | Prisma.TransactionUpdateWithWhereUniqueWithoutCreatedByUserInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutCreatedByUserInput | Prisma.TransactionUpdateManyWithWhereWithoutCreatedByUserInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUncheckedUpdateManyWithoutModifiedByUserNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutModifiedByUserInput, Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput> | Prisma.TransactionCreateWithoutModifiedByUserInput[] | Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutModifiedByUserInput | Prisma.TransactionCreateOrConnectWithoutModifiedByUserInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutModifiedByUserInput | Prisma.TransactionUpsertWithWhereUniqueWithoutModifiedByUserInput[]
  createMany?: Prisma.TransactionCreateManyModifiedByUserInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutModifiedByUserInput | Prisma.TransactionUpdateWithWhereUniqueWithoutModifiedByUserInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutModifiedByUserInput | Prisma.TransactionUpdateManyWithWhereWithoutModifiedByUserInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionCreateNestedManyWithoutBranchInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutBranchInput, Prisma.TransactionUncheckedCreateWithoutBranchInput> | Prisma.TransactionCreateWithoutBranchInput[] | Prisma.TransactionUncheckedCreateWithoutBranchInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutBranchInput | Prisma.TransactionCreateOrConnectWithoutBranchInput[]
  createMany?: Prisma.TransactionCreateManyBranchInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUncheckedCreateNestedManyWithoutBranchInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutBranchInput, Prisma.TransactionUncheckedCreateWithoutBranchInput> | Prisma.TransactionCreateWithoutBranchInput[] | Prisma.TransactionUncheckedCreateWithoutBranchInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutBranchInput | Prisma.TransactionCreateOrConnectWithoutBranchInput[]
  createMany?: Prisma.TransactionCreateManyBranchInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUpdateManyWithoutBranchNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutBranchInput, Prisma.TransactionUncheckedCreateWithoutBranchInput> | Prisma.TransactionCreateWithoutBranchInput[] | Prisma.TransactionUncheckedCreateWithoutBranchInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutBranchInput | Prisma.TransactionCreateOrConnectWithoutBranchInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutBranchInput | Prisma.TransactionUpsertWithWhereUniqueWithoutBranchInput[]
  createMany?: Prisma.TransactionCreateManyBranchInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutBranchInput | Prisma.TransactionUpdateWithWhereUniqueWithoutBranchInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutBranchInput | Prisma.TransactionUpdateManyWithWhereWithoutBranchInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUncheckedUpdateManyWithoutBranchNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutBranchInput, Prisma.TransactionUncheckedCreateWithoutBranchInput> | Prisma.TransactionCreateWithoutBranchInput[] | Prisma.TransactionUncheckedCreateWithoutBranchInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutBranchInput | Prisma.TransactionCreateOrConnectWithoutBranchInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutBranchInput | Prisma.TransactionUpsertWithWhereUniqueWithoutBranchInput[]
  createMany?: Prisma.TransactionCreateManyBranchInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutBranchInput | Prisma.TransactionUpdateWithWhereUniqueWithoutBranchInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutBranchInput | Prisma.TransactionUpdateManyWithWhereWithoutBranchInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionCreateNestedManyWithoutBankInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutBankInput, Prisma.TransactionUncheckedCreateWithoutBankInput> | Prisma.TransactionCreateWithoutBankInput[] | Prisma.TransactionUncheckedCreateWithoutBankInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutBankInput | Prisma.TransactionCreateOrConnectWithoutBankInput[]
  createMany?: Prisma.TransactionCreateManyBankInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUncheckedCreateNestedManyWithoutBankInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutBankInput, Prisma.TransactionUncheckedCreateWithoutBankInput> | Prisma.TransactionCreateWithoutBankInput[] | Prisma.TransactionUncheckedCreateWithoutBankInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutBankInput | Prisma.TransactionCreateOrConnectWithoutBankInput[]
  createMany?: Prisma.TransactionCreateManyBankInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUpdateManyWithoutBankNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutBankInput, Prisma.TransactionUncheckedCreateWithoutBankInput> | Prisma.TransactionCreateWithoutBankInput[] | Prisma.TransactionUncheckedCreateWithoutBankInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutBankInput | Prisma.TransactionCreateOrConnectWithoutBankInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutBankInput | Prisma.TransactionUpsertWithWhereUniqueWithoutBankInput[]
  createMany?: Prisma.TransactionCreateManyBankInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutBankInput | Prisma.TransactionUpdateWithWhereUniqueWithoutBankInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutBankInput | Prisma.TransactionUpdateManyWithWhereWithoutBankInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUncheckedUpdateManyWithoutBankNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutBankInput, Prisma.TransactionUncheckedCreateWithoutBankInput> | Prisma.TransactionCreateWithoutBankInput[] | Prisma.TransactionUncheckedCreateWithoutBankInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutBankInput | Prisma.TransactionCreateOrConnectWithoutBankInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutBankInput | Prisma.TransactionUpsertWithWhereUniqueWithoutBankInput[]
  createMany?: Prisma.TransactionCreateManyBankInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutBankInput | Prisma.TransactionUpdateWithWhereUniqueWithoutBankInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutBankInput | Prisma.TransactionUpdateManyWithWhereWithoutBankInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionCreateNestedManyWithoutCustomerInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCustomerInput, Prisma.TransactionUncheckedCreateWithoutCustomerInput> | Prisma.TransactionCreateWithoutCustomerInput[] | Prisma.TransactionUncheckedCreateWithoutCustomerInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCustomerInput | Prisma.TransactionCreateOrConnectWithoutCustomerInput[]
  createMany?: Prisma.TransactionCreateManyCustomerInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUncheckedCreateNestedManyWithoutCustomerInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCustomerInput, Prisma.TransactionUncheckedCreateWithoutCustomerInput> | Prisma.TransactionCreateWithoutCustomerInput[] | Prisma.TransactionUncheckedCreateWithoutCustomerInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCustomerInput | Prisma.TransactionCreateOrConnectWithoutCustomerInput[]
  createMany?: Prisma.TransactionCreateManyCustomerInputEnvelope
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
}

export type TransactionUpdateManyWithoutCustomerNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCustomerInput, Prisma.TransactionUncheckedCreateWithoutCustomerInput> | Prisma.TransactionCreateWithoutCustomerInput[] | Prisma.TransactionUncheckedCreateWithoutCustomerInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCustomerInput | Prisma.TransactionCreateOrConnectWithoutCustomerInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutCustomerInput | Prisma.TransactionUpsertWithWhereUniqueWithoutCustomerInput[]
  createMany?: Prisma.TransactionCreateManyCustomerInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutCustomerInput | Prisma.TransactionUpdateWithWhereUniqueWithoutCustomerInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutCustomerInput | Prisma.TransactionUpdateManyWithWhereWithoutCustomerInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type TransactionUncheckedUpdateManyWithoutCustomerNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutCustomerInput, Prisma.TransactionUncheckedCreateWithoutCustomerInput> | Prisma.TransactionCreateWithoutCustomerInput[] | Prisma.TransactionUncheckedCreateWithoutCustomerInput[]
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutCustomerInput | Prisma.TransactionCreateOrConnectWithoutCustomerInput[]
  upsert?: Prisma.TransactionUpsertWithWhereUniqueWithoutCustomerInput | Prisma.TransactionUpsertWithWhereUniqueWithoutCustomerInput[]
  createMany?: Prisma.TransactionCreateManyCustomerInputEnvelope
  set?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  disconnect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  delete?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  connect?: Prisma.TransactionWhereUniqueInput | Prisma.TransactionWhereUniqueInput[]
  update?: Prisma.TransactionUpdateWithWhereUniqueWithoutCustomerInput | Prisma.TransactionUpdateWithWhereUniqueWithoutCustomerInput[]
  updateMany?: Prisma.TransactionUpdateManyWithWhereWithoutCustomerInput | Prisma.TransactionUpdateManyWithWhereWithoutCustomerInput[]
  deleteMany?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
}

export type EnumTransactionStatusFieldUpdateOperationsInput = {
  set?: $Enums.TransactionStatus
}

export type NullableDecimalFieldUpdateOperationsInput = {
  set?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  increment?: runtime.Decimal | runtime.DecimalJsLike | number | string
  decrement?: runtime.Decimal | runtime.DecimalJsLike | number | string
  multiply?: runtime.Decimal | runtime.DecimalJsLike | number | string
  divide?: runtime.Decimal | runtime.DecimalJsLike | number | string
}

export type NullableBoolFieldUpdateOperationsInput = {
  set?: boolean | null
}

export type TransactionCreateNestedOneWithoutItemsInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutItemsInput, Prisma.TransactionUncheckedCreateWithoutItemsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutItemsInput
  connect?: Prisma.TransactionWhereUniqueInput
}

export type TransactionUpdateOneRequiredWithoutItemsNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutItemsInput, Prisma.TransactionUncheckedCreateWithoutItemsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutItemsInput
  upsert?: Prisma.TransactionUpsertWithoutItemsInput
  connect?: Prisma.TransactionWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.TransactionUpdateToOneWithWhereWithoutItemsInput, Prisma.TransactionUpdateWithoutItemsInput>, Prisma.TransactionUncheckedUpdateWithoutItemsInput>
}

export type TransactionCreateNestedOneWithoutDocsInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutDocsInput, Prisma.TransactionUncheckedCreateWithoutDocsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutDocsInput
  connect?: Prisma.TransactionWhereUniqueInput
}

export type TransactionUpdateOneRequiredWithoutDocsNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutDocsInput, Prisma.TransactionUncheckedCreateWithoutDocsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutDocsInput
  upsert?: Prisma.TransactionUpsertWithoutDocsInput
  connect?: Prisma.TransactionWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.TransactionUpdateToOneWithWhereWithoutDocsInput, Prisma.TransactionUpdateWithoutDocsInput>, Prisma.TransactionUncheckedUpdateWithoutDocsInput>
}

export type TransactionCreateNestedOneWithoutApprovalsInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutApprovalsInput, Prisma.TransactionUncheckedCreateWithoutApprovalsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutApprovalsInput
  connect?: Prisma.TransactionWhereUniqueInput
}

export type TransactionUpdateOneRequiredWithoutApprovalsNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutApprovalsInput, Prisma.TransactionUncheckedCreateWithoutApprovalsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutApprovalsInput
  upsert?: Prisma.TransactionUpsertWithoutApprovalsInput
  connect?: Prisma.TransactionWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.TransactionUpdateToOneWithWhereWithoutApprovalsInput, Prisma.TransactionUpdateWithoutApprovalsInput>, Prisma.TransactionUncheckedUpdateWithoutApprovalsInput>
}

export type TransactionCreateNestedOneWithoutPaymentsInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutPaymentsInput, Prisma.TransactionUncheckedCreateWithoutPaymentsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutPaymentsInput
  connect?: Prisma.TransactionWhereUniqueInput
}

export type TransactionUpdateOneRequiredWithoutPaymentsNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutPaymentsInput, Prisma.TransactionUncheckedCreateWithoutPaymentsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutPaymentsInput
  upsert?: Prisma.TransactionUpsertWithoutPaymentsInput
  connect?: Prisma.TransactionWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.TransactionUpdateToOneWithWhereWithoutPaymentsInput, Prisma.TransactionUpdateWithoutPaymentsInput>, Prisma.TransactionUncheckedUpdateWithoutPaymentsInput>
}

export type TransactionCreateNestedOneWithoutSnapshotsInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutSnapshotsInput, Prisma.TransactionUncheckedCreateWithoutSnapshotsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutSnapshotsInput
  connect?: Prisma.TransactionWhereUniqueInput
}

export type TransactionUpdateOneRequiredWithoutSnapshotsNestedInput = {
  create?: Prisma.XOR<Prisma.TransactionCreateWithoutSnapshotsInput, Prisma.TransactionUncheckedCreateWithoutSnapshotsInput>
  connectOrCreate?: Prisma.TransactionCreateOrConnectWithoutSnapshotsInput
  upsert?: Prisma.TransactionUpsertWithoutSnapshotsInput
  connect?: Prisma.TransactionWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.TransactionUpdateToOneWithWhereWithoutSnapshotsInput, Prisma.TransactionUpdateWithoutSnapshotsInput>, Prisma.TransactionUncheckedUpdateWithoutSnapshotsInput>
}

export type TransactionCreateWithoutHeadStoreUserInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
}

export type TransactionUncheckedCreateWithoutHeadStoreUserInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutHeadStoreUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutHeadStoreUserInput, Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput>
}

export type TransactionCreateManyHeadStoreUserInputEnvelope = {
  data: Prisma.TransactionCreateManyHeadStoreUserInput | Prisma.TransactionCreateManyHeadStoreUserInput[]
  skipDuplicates?: boolean
}

export type TransactionCreateWithoutCompletedByUserInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutCompletedByUserInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutCompletedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutCompletedByUserInput, Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput>
}

export type TransactionCreateManyCompletedByUserInputEnvelope = {
  data: Prisma.TransactionCreateManyCompletedByUserInput | Prisma.TransactionCreateManyCompletedByUserInput[]
  skipDuplicates?: boolean
}

export type TransactionCreateWithoutCreatedByUserInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutCreatedByUserInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutCreatedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutCreatedByUserInput, Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput>
}

export type TransactionCreateManyCreatedByUserInputEnvelope = {
  data: Prisma.TransactionCreateManyCreatedByUserInput | Prisma.TransactionCreateManyCreatedByUserInput[]
  skipDuplicates?: boolean
}

export type TransactionCreateWithoutModifiedByUserInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutModifiedByUserInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutModifiedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutModifiedByUserInput, Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput>
}

export type TransactionCreateManyModifiedByUserInputEnvelope = {
  data: Prisma.TransactionCreateManyModifiedByUserInput | Prisma.TransactionCreateManyModifiedByUserInput[]
  skipDuplicates?: boolean
}

export type TransactionUpsertWithWhereUniqueWithoutHeadStoreUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutHeadStoreUserInput, Prisma.TransactionUncheckedUpdateWithoutHeadStoreUserInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutHeadStoreUserInput, Prisma.TransactionUncheckedCreateWithoutHeadStoreUserInput>
}

export type TransactionUpdateWithWhereUniqueWithoutHeadStoreUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutHeadStoreUserInput, Prisma.TransactionUncheckedUpdateWithoutHeadStoreUserInput>
}

export type TransactionUpdateManyWithWhereWithoutHeadStoreUserInput = {
  where: Prisma.TransactionScalarWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyWithoutHeadStoreUserInput>
}

export type TransactionScalarWhereInput = {
  AND?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
  OR?: Prisma.TransactionScalarWhereInput[]
  NOT?: Prisma.TransactionScalarWhereInput | Prisma.TransactionScalarWhereInput[]
  id?: Prisma.StringFilter<"Transaction"> | string
  trxCode?: Prisma.StringFilter<"Transaction"> | string
  branchId?: Prisma.StringFilter<"Transaction"> | string
  customerId?: Prisma.StringFilter<"Transaction"> | string
  status?: Prisma.EnumTransactionStatusFilter<"Transaction"> | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.DecimalNullableFilter<"Transaction"> | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.UuidNullableFilter<"Transaction"> | string | null
  bankAccountNo?: Prisma.StringNullableFilter<"Transaction"> | string | null
  bankAccountName?: Prisma.StringNullableFilter<"Transaction"> | string | null
  referralSource?: Prisma.StringNullableFilter<"Transaction"> | string | null
  knowsFounder?: Prisma.BoolNullableFilter<"Transaction"> | boolean | null
  createdBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  createdAt?: Prisma.DateTimeFilter<"Transaction"> | Date | string
  modifiedBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  modifiedAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  cancellationReason?: Prisma.StringNullableFilter<"Transaction"> | string | null
  cancelledBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  cancelledAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  completedBy?: Prisma.StringNullableFilter<"Transaction"> | string | null
  completedAt?: Prisma.DateTimeNullableFilter<"Transaction"> | Date | string | null
  headStoreId?: Prisma.StringNullableFilter<"Transaction"> | string | null
}

export type TransactionUpsertWithWhereUniqueWithoutCompletedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutCompletedByUserInput, Prisma.TransactionUncheckedUpdateWithoutCompletedByUserInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutCompletedByUserInput, Prisma.TransactionUncheckedCreateWithoutCompletedByUserInput>
}

export type TransactionUpdateWithWhereUniqueWithoutCompletedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutCompletedByUserInput, Prisma.TransactionUncheckedUpdateWithoutCompletedByUserInput>
}

export type TransactionUpdateManyWithWhereWithoutCompletedByUserInput = {
  where: Prisma.TransactionScalarWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyWithoutCompletedByUserInput>
}

export type TransactionUpsertWithWhereUniqueWithoutCreatedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutCreatedByUserInput, Prisma.TransactionUncheckedUpdateWithoutCreatedByUserInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutCreatedByUserInput, Prisma.TransactionUncheckedCreateWithoutCreatedByUserInput>
}

export type TransactionUpdateWithWhereUniqueWithoutCreatedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutCreatedByUserInput, Prisma.TransactionUncheckedUpdateWithoutCreatedByUserInput>
}

export type TransactionUpdateManyWithWhereWithoutCreatedByUserInput = {
  where: Prisma.TransactionScalarWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyWithoutCreatedByUserInput>
}

export type TransactionUpsertWithWhereUniqueWithoutModifiedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutModifiedByUserInput, Prisma.TransactionUncheckedUpdateWithoutModifiedByUserInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutModifiedByUserInput, Prisma.TransactionUncheckedCreateWithoutModifiedByUserInput>
}

export type TransactionUpdateWithWhereUniqueWithoutModifiedByUserInput = {
  where: Prisma.TransactionWhereUniqueInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutModifiedByUserInput, Prisma.TransactionUncheckedUpdateWithoutModifiedByUserInput>
}

export type TransactionUpdateManyWithWhereWithoutModifiedByUserInput = {
  where: Prisma.TransactionScalarWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyWithoutModifiedByUserInput>
}

export type TransactionCreateWithoutBranchInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutBranchInput = {
  id?: string
  trxCode: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutBranchInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutBranchInput, Prisma.TransactionUncheckedCreateWithoutBranchInput>
}

export type TransactionCreateManyBranchInputEnvelope = {
  data: Prisma.TransactionCreateManyBranchInput | Prisma.TransactionCreateManyBranchInput[]
  skipDuplicates?: boolean
}

export type TransactionUpsertWithWhereUniqueWithoutBranchInput = {
  where: Prisma.TransactionWhereUniqueInput
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutBranchInput, Prisma.TransactionUncheckedUpdateWithoutBranchInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutBranchInput, Prisma.TransactionUncheckedCreateWithoutBranchInput>
}

export type TransactionUpdateWithWhereUniqueWithoutBranchInput = {
  where: Prisma.TransactionWhereUniqueInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutBranchInput, Prisma.TransactionUncheckedUpdateWithoutBranchInput>
}

export type TransactionUpdateManyWithWhereWithoutBranchInput = {
  where: Prisma.TransactionScalarWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyWithoutBranchInput>
}

export type TransactionCreateWithoutBankInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutBankInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutBankInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutBankInput, Prisma.TransactionUncheckedCreateWithoutBankInput>
}

export type TransactionCreateManyBankInputEnvelope = {
  data: Prisma.TransactionCreateManyBankInput | Prisma.TransactionCreateManyBankInput[]
  skipDuplicates?: boolean
}

export type TransactionUpsertWithWhereUniqueWithoutBankInput = {
  where: Prisma.TransactionWhereUniqueInput
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutBankInput, Prisma.TransactionUncheckedUpdateWithoutBankInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutBankInput, Prisma.TransactionUncheckedCreateWithoutBankInput>
}

export type TransactionUpdateWithWhereUniqueWithoutBankInput = {
  where: Prisma.TransactionWhereUniqueInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutBankInput, Prisma.TransactionUncheckedUpdateWithoutBankInput>
}

export type TransactionUpdateManyWithWhereWithoutBankInput = {
  where: Prisma.TransactionScalarWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyWithoutBankInput>
}

export type TransactionCreateWithoutCustomerInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutCustomerInput = {
  id?: string
  trxCode: string
  branchId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutCustomerInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutCustomerInput, Prisma.TransactionUncheckedCreateWithoutCustomerInput>
}

export type TransactionCreateManyCustomerInputEnvelope = {
  data: Prisma.TransactionCreateManyCustomerInput | Prisma.TransactionCreateManyCustomerInput[]
  skipDuplicates?: boolean
}

export type TransactionUpsertWithWhereUniqueWithoutCustomerInput = {
  where: Prisma.TransactionWhereUniqueInput
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutCustomerInput, Prisma.TransactionUncheckedUpdateWithoutCustomerInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutCustomerInput, Prisma.TransactionUncheckedCreateWithoutCustomerInput>
}

export type TransactionUpdateWithWhereUniqueWithoutCustomerInput = {
  where: Prisma.TransactionWhereUniqueInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutCustomerInput, Prisma.TransactionUncheckedUpdateWithoutCustomerInput>
}

export type TransactionUpdateManyWithWhereWithoutCustomerInput = {
  where: Prisma.TransactionScalarWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyWithoutCustomerInput>
}

export type TransactionCreateWithoutItemsInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutItemsInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutItemsInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutItemsInput, Prisma.TransactionUncheckedCreateWithoutItemsInput>
}

export type TransactionUpsertWithoutItemsInput = {
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutItemsInput, Prisma.TransactionUncheckedUpdateWithoutItemsInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutItemsInput, Prisma.TransactionUncheckedCreateWithoutItemsInput>
  where?: Prisma.TransactionWhereInput
}

export type TransactionUpdateToOneWithWhereWithoutItemsInput = {
  where?: Prisma.TransactionWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutItemsInput, Prisma.TransactionUncheckedUpdateWithoutItemsInput>
}

export type TransactionUpdateWithoutItemsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutItemsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionCreateWithoutDocsInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutDocsInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutDocsInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutDocsInput, Prisma.TransactionUncheckedCreateWithoutDocsInput>
}

export type TransactionUpsertWithoutDocsInput = {
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutDocsInput, Prisma.TransactionUncheckedUpdateWithoutDocsInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutDocsInput, Prisma.TransactionUncheckedCreateWithoutDocsInput>
  where?: Prisma.TransactionWhereInput
}

export type TransactionUpdateToOneWithWhereWithoutDocsInput = {
  where?: Prisma.TransactionWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutDocsInput, Prisma.TransactionUncheckedUpdateWithoutDocsInput>
}

export type TransactionUpdateWithoutDocsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutDocsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionCreateWithoutApprovalsInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutApprovalsInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutApprovalsInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutApprovalsInput, Prisma.TransactionUncheckedCreateWithoutApprovalsInput>
}

export type TransactionUpsertWithoutApprovalsInput = {
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutApprovalsInput, Prisma.TransactionUncheckedUpdateWithoutApprovalsInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutApprovalsInput, Prisma.TransactionUncheckedCreateWithoutApprovalsInput>
  where?: Prisma.TransactionWhereInput
}

export type TransactionUpdateToOneWithWhereWithoutApprovalsInput = {
  where?: Prisma.TransactionWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutApprovalsInput, Prisma.TransactionUncheckedUpdateWithoutApprovalsInput>
}

export type TransactionUpdateWithoutApprovalsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutApprovalsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionCreateWithoutPaymentsInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutPaymentsInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  snapshots?: Prisma.TransactionSnapshotUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutPaymentsInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutPaymentsInput, Prisma.TransactionUncheckedCreateWithoutPaymentsInput>
}

export type TransactionUpsertWithoutPaymentsInput = {
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutPaymentsInput, Prisma.TransactionUncheckedUpdateWithoutPaymentsInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutPaymentsInput, Prisma.TransactionUncheckedCreateWithoutPaymentsInput>
  where?: Prisma.TransactionWhereInput
}

export type TransactionUpdateToOneWithWhereWithoutPaymentsInput = {
  where?: Prisma.TransactionWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutPaymentsInput, Prisma.TransactionUncheckedUpdateWithoutPaymentsInput>
}

export type TransactionUpdateWithoutPaymentsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutPaymentsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionCreateWithoutSnapshotsInput = {
  id?: string
  trxCode: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  branch: Prisma.BranchCreateNestedOneWithoutTransactionsInput
  customer: Prisma.CustomerCreateNestedOneWithoutTransactionsInput
  bank?: Prisma.BankCreateNestedOneWithoutTransactionsInput
  docs?: Prisma.TransactionDocCreateNestedManyWithoutTransactionInput
  createdByUser?: Prisma.UserCreateNestedOneWithoutCreatedTransactionsInput
  modifiedByUser?: Prisma.UserCreateNestedOneWithoutModifiedTransactionsInput
  items?: Prisma.TransactionItemCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentCreateNestedManyWithoutTransactionInput
  completedByUser?: Prisma.UserCreateNestedOneWithoutCompletedTransactionsInput
  headStoreUser?: Prisma.UserCreateNestedOneWithoutTransactionsInput
}

export type TransactionUncheckedCreateWithoutSnapshotsInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
  docs?: Prisma.TransactionDocUncheckedCreateNestedManyWithoutTransactionInput
  items?: Prisma.TransactionItemUncheckedCreateNestedManyWithoutTransactionInput
  approvals?: Prisma.ApprovalUncheckedCreateNestedManyWithoutTransactionInput
  payments?: Prisma.PaymentUncheckedCreateNestedManyWithoutTransactionInput
}

export type TransactionCreateOrConnectWithoutSnapshotsInput = {
  where: Prisma.TransactionWhereUniqueInput
  create: Prisma.XOR<Prisma.TransactionCreateWithoutSnapshotsInput, Prisma.TransactionUncheckedCreateWithoutSnapshotsInput>
}

export type TransactionUpsertWithoutSnapshotsInput = {
  update: Prisma.XOR<Prisma.TransactionUpdateWithoutSnapshotsInput, Prisma.TransactionUncheckedUpdateWithoutSnapshotsInput>
  create: Prisma.XOR<Prisma.TransactionCreateWithoutSnapshotsInput, Prisma.TransactionUncheckedCreateWithoutSnapshotsInput>
  where?: Prisma.TransactionWhereInput
}

export type TransactionUpdateToOneWithWhereWithoutSnapshotsInput = {
  where?: Prisma.TransactionWhereInput
  data: Prisma.XOR<Prisma.TransactionUpdateWithoutSnapshotsInput, Prisma.TransactionUncheckedUpdateWithoutSnapshotsInput>
}

export type TransactionUpdateWithoutSnapshotsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutSnapshotsInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionCreateManyHeadStoreUserInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
}

export type TransactionCreateManyCompletedByUserInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
}

export type TransactionCreateManyCreatedByUserInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
}

export type TransactionCreateManyModifiedByUserInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
}

export type TransactionUpdateWithoutHeadStoreUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutHeadStoreUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionUncheckedUpdateManyWithoutHeadStoreUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
}

export type TransactionUpdateWithoutCompletedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutCompletedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionUncheckedUpdateManyWithoutCompletedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}

export type TransactionUpdateWithoutCreatedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutCreatedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionUncheckedUpdateManyWithoutCreatedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}

export type TransactionUpdateWithoutModifiedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutModifiedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionUncheckedUpdateManyWithoutModifiedByUserInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}

export type TransactionCreateManyBranchInput = {
  id?: string
  trxCode: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
}

export type TransactionUpdateWithoutBranchInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutBranchInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionUncheckedUpdateManyWithoutBranchInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}

export type TransactionCreateManyBankInput = {
  id?: string
  trxCode: string
  branchId: string
  customerId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
}

export type TransactionUpdateWithoutBankInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  customer?: Prisma.CustomerUpdateOneRequiredWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutBankInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionUncheckedUpdateManyWithoutBankInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  customerId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}

export type TransactionCreateManyCustomerInput = {
  id?: string
  trxCode: string
  branchId: string
  status?: $Enums.TransactionStatus
  totalGrossWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: string | null
  bankAccountNo?: string | null
  bankAccountName?: string | null
  referralSource?: string | null
  knowsFounder?: boolean | null
  createdBy?: string | null
  createdAt?: Date | string
  modifiedBy?: string | null
  modifiedAt?: Date | string | null
  cancellationReason?: string | null
  cancelledBy?: string | null
  cancelledAt?: Date | string | null
  completedBy?: string | null
  completedAt?: Date | string | null
  headStoreId?: string | null
}

export type TransactionUpdateWithoutCustomerInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  branch?: Prisma.BranchUpdateOneRequiredWithoutTransactionsNestedInput
  bank?: Prisma.BankUpdateOneWithoutTransactionsNestedInput
  docs?: Prisma.TransactionDocUpdateManyWithoutTransactionNestedInput
  createdByUser?: Prisma.UserUpdateOneWithoutCreatedTransactionsNestedInput
  modifiedByUser?: Prisma.UserUpdateOneWithoutModifiedTransactionsNestedInput
  items?: Prisma.TransactionItemUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUpdateManyWithoutTransactionNestedInput
  completedByUser?: Prisma.UserUpdateOneWithoutCompletedTransactionsNestedInput
  headStoreUser?: Prisma.UserUpdateOneWithoutTransactionsNestedInput
}

export type TransactionUncheckedUpdateWithoutCustomerInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  docs?: Prisma.TransactionDocUncheckedUpdateManyWithoutTransactionNestedInput
  items?: Prisma.TransactionItemUncheckedUpdateManyWithoutTransactionNestedInput
  approvals?: Prisma.ApprovalUncheckedUpdateManyWithoutTransactionNestedInput
  payments?: Prisma.PaymentUncheckedUpdateManyWithoutTransactionNestedInput
  snapshots?: Prisma.TransactionSnapshotUncheckedUpdateManyWithoutTransactionNestedInput
}

export type TransactionUncheckedUpdateManyWithoutCustomerInput = {
  id?: Prisma.StringFieldUpdateOperationsInput | string
  trxCode?: Prisma.StringFieldUpdateOperationsInput | string
  branchId?: Prisma.StringFieldUpdateOperationsInput | string
  status?: Prisma.EnumTransactionStatusFieldUpdateOperationsInput | $Enums.TransactionStatus
  totalGrossWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalNetWeight?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  totalAmount?: Prisma.NullableDecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string | null
  bankId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountNo?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  bankAccountName?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  referralSource?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  knowsFounder?: Prisma.NullableBoolFieldUpdateOperationsInput | boolean | null
  createdBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  modifiedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  modifiedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  cancellationReason?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  cancelledAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  completedBy?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  completedAt?: Prisma.NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  headStoreId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
}


/**
 * Count Type TransactionCountOutputType
 */

export type TransactionCountOutputType = {
  docs: number
  items: number
  approvals: number
  payments: number
  snapshots: number
}

export type TransactionCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  docs?: boolean | TransactionCountOutputTypeCountDocsArgs
  items?: boolean | TransactionCountOutputTypeCountItemsArgs
  approvals?: boolean | TransactionCountOutputTypeCountApprovalsArgs
  payments?: boolean | TransactionCountOutputTypeCountPaymentsArgs
  snapshots?: boolean | TransactionCountOutputTypeCountSnapshotsArgs
}

/**
 * TransactionCountOutputType without action
 */
export type TransactionCountOutputTypeDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the TransactionCountOutputType
   */
  select?: Prisma.TransactionCountOutputTypeSelect<ExtArgs> | null
}

/**
 * TransactionCountOutputType without action
 */
export type TransactionCountOutputTypeCountDocsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.TransactionDocWhereInput
}

/**
 * TransactionCountOutputType without action
 */
export type TransactionCountOutputTypeCountItemsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.TransactionItemWhereInput
}

/**
 * TransactionCountOutputType without action
 */
export type TransactionCountOutputTypeCountApprovalsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.ApprovalWhereInput
}

/**
 * TransactionCountOutputType without action
 */
export type TransactionCountOutputTypeCountPaymentsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.PaymentWhereInput
}

/**
 * TransactionCountOutputType without action
 */
export type TransactionCountOutputTypeCountSnapshotsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.TransactionSnapshotWhereInput
}


export type TransactionSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
  id?: boolean
  trxCode?: boolean
  branchId?: boolean
  customerId?: boolean
  status?: boolean
  totalGrossWeight?: boolean
  totalNetWeight?: boolean
  totalAmount?: boolean
  bankId?: boolean
  bankAccountNo?: boolean
  bankAccountName?: boolean
  referralSource?: boolean
  knowsFounder?: boolean
  createdBy?: boolean
  createdAt?: boolean
  modifiedBy?: boolean
  modifiedAt?: boolean
  cancellationReason?: boolean
  cancelledBy?: boolean
  cancelledAt?: boolean
  completedBy?: boolean
  completedAt?: boolean
  headStoreId?: boolean
  branch?: boolean | Prisma.BranchDefaultArgs<ExtArgs>
  customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
  bank?: boolean | Prisma.Transaction$bankArgs<ExtArgs>
  docs?: boolean | Prisma.Transaction$docsArgs<ExtArgs>
  createdByUser?: boolean | Prisma.Transaction$createdByUserArgs<ExtArgs>
  modifiedByUser?: boolean | Prisma.Transaction$modifiedByUserArgs<ExtArgs>
  items?: boolean | Prisma.Transaction$itemsArgs<ExtArgs>
  approvals?: boolean | Prisma.Transaction$approvalsArgs<ExtArgs>
  payments?: boolean | Prisma.Transaction$paymentsArgs<ExtArgs>
  snapshots?: boolean | Prisma.Transaction$snapshotsArgs<ExtArgs>
  completedByUser?: boolean | Prisma.Transaction$completedByUserArgs<ExtArgs>
  headStoreUser?: boolean | Prisma.Transaction$headStoreUserArgs<ExtArgs>
  _count?: boolean | Prisma.TransactionCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["transaction"]>

export type TransactionSelectCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
  id?: boolean
  trxCode?: boolean
  branchId?: boolean
  customerId?: boolean
  status?: boolean
  totalGrossWeight?: boolean
  totalNetWeight?: boolean
  totalAmount?: boolean
  bankId?: boolean
  bankAccountNo?: boolean
  bankAccountName?: boolean
  referralSource?: boolean
  knowsFounder?: boolean
  createdBy?: boolean
  createdAt?: boolean
  modifiedBy?: boolean
  modifiedAt?: boolean
  cancellationReason?: boolean
  cancelledBy?: boolean
  cancelledAt?: boolean
  completedBy?: boolean
  completedAt?: boolean
  headStoreId?: boolean
  branch?: boolean | Prisma.BranchDefaultArgs<ExtArgs>
  customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
  bank?: boolean | Prisma.Transaction$bankArgs<ExtArgs>
  createdByUser?: boolean | Prisma.Transaction$createdByUserArgs<ExtArgs>
  modifiedByUser?: boolean | Prisma.Transaction$modifiedByUserArgs<ExtArgs>
  completedByUser?: boolean | Prisma.Transaction$completedByUserArgs<ExtArgs>
  headStoreUser?: boolean | Prisma.Transaction$headStoreUserArgs<ExtArgs>
}, ExtArgs["result"]["transaction"]>

export type TransactionSelectUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
  id?: boolean
  trxCode?: boolean
  branchId?: boolean
  customerId?: boolean
  status?: boolean
  totalGrossWeight?: boolean
  totalNetWeight?: boolean
  totalAmount?: boolean
  bankId?: boolean
  bankAccountNo?: boolean
  bankAccountName?: boolean
  referralSource?: boolean
  knowsFounder?: boolean
  createdBy?: boolean
  createdAt?: boolean
  modifiedBy?: boolean
  modifiedAt?: boolean
  cancellationReason?: boolean
  cancelledBy?: boolean
  cancelledAt?: boolean
  completedBy?: boolean
  completedAt?: boolean
  headStoreId?: boolean
  branch?: boolean | Prisma.BranchDefaultArgs<ExtArgs>
  customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
  bank?: boolean | Prisma.Transaction$bankArgs<ExtArgs>
  createdByUser?: boolean | Prisma.Transaction$createdByUserArgs<ExtArgs>
  modifiedByUser?: boolean | Prisma.Transaction$modifiedByUserArgs<ExtArgs>
  completedByUser?: boolean | Prisma.Transaction$completedByUserArgs<ExtArgs>
  headStoreUser?: boolean | Prisma.Transaction$headStoreUserArgs<ExtArgs>
}, ExtArgs["result"]["transaction"]>

export type TransactionSelectScalar = {
  id?: boolean
  trxCode?: boolean
  branchId?: boolean
  customerId?: boolean
  status?: boolean
  totalGrossWeight?: boolean
  totalNetWeight?: boolean
  totalAmount?: boolean
  bankId?: boolean
  bankAccountNo?: boolean
  bankAccountName?: boolean
  referralSource?: boolean
  knowsFounder?: boolean
  createdBy?: boolean
  createdAt?: boolean
  modifiedBy?: boolean
  modifiedAt?: boolean
  cancellationReason?: boolean
  cancelledBy?: boolean
  cancelledAt?: boolean
  completedBy?: boolean
  completedAt?: boolean
  headStoreId?: boolean
}

export type TransactionOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "trxCode" | "branchId" | "customerId" | "status" | "totalGrossWeight" | "totalNetWeight" | "totalAmount" | "bankId" | "bankAccountNo" | "bankAccountName" | "referralSource" | "knowsFounder" | "createdBy" | "createdAt" | "modifiedBy" | "modifiedAt" | "cancellationReason" | "cancelledBy" | "cancelledAt" | "completedBy" | "completedAt" | "headStoreId", ExtArgs["result"]["transaction"]>
export type TransactionInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  branch?: boolean | Prisma.BranchDefaultArgs<ExtArgs>
  customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
  bank?: boolean | Prisma.Transaction$bankArgs<ExtArgs>
  docs?: boolean | Prisma.Transaction$docsArgs<ExtArgs>
  createdByUser?: boolean | Prisma.Transaction$createdByUserArgs<ExtArgs>
  modifiedByUser?: boolean | Prisma.Transaction$modifiedByUserArgs<ExtArgs>
  items?: boolean | Prisma.Transaction$itemsArgs<ExtArgs>
  approvals?: boolean | Prisma.Transaction$approvalsArgs<ExtArgs>
  payments?: boolean | Prisma.Transaction$paymentsArgs<ExtArgs>
  snapshots?: boolean | Prisma.Transaction$snapshotsArgs<ExtArgs>
  completedByUser?: boolean | Prisma.Transaction$completedByUserArgs<ExtArgs>
  headStoreUser?: boolean | Prisma.Transaction$headStoreUserArgs<ExtArgs>
  _count?: boolean | Prisma.TransactionCountOutputTypeDefaultArgs<ExtArgs>
}
export type TransactionIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  branch?: boolean | Prisma.BranchDefaultArgs<ExtArgs>
  customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
  bank?: boolean | Prisma.Transaction$bankArgs<ExtArgs>
  createdByUser?: boolean | Prisma.Transaction$createdByUserArgs<ExtArgs>
  modifiedByUser?: boolean | Prisma.Transaction$modifiedByUserArgs<ExtArgs>
  completedByUser?: boolean | Prisma.Transaction$completedByUserArgs<ExtArgs>
  headStoreUser?: boolean | Prisma.Transaction$headStoreUserArgs<ExtArgs>
}
export type TransactionIncludeUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  branch?: boolean | Prisma.BranchDefaultArgs<ExtArgs>
  customer?: boolean | Prisma.CustomerDefaultArgs<ExtArgs>
  bank?: boolean | Prisma.Transaction$bankArgs<ExtArgs>
  createdByUser?: boolean | Prisma.Transaction$createdByUserArgs<ExtArgs>
  modifiedByUser?: boolean | Prisma.Transaction$modifiedByUserArgs<ExtArgs>
  completedByUser?: boolean | Prisma.Transaction$completedByUserArgs<ExtArgs>
  headStoreUser?: boolean | Prisma.Transaction$headStoreUserArgs<ExtArgs>
}

export type $TransactionPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  name: "Transaction"
  objects: {
    branch: Prisma.$BranchPayload<ExtArgs>
    customer: Prisma.$CustomerPayload<ExtArgs>
    bank: Prisma.$BankPayload<ExtArgs> | null
    docs: Prisma.$TransactionDocPayload<ExtArgs>[]
    createdByUser: Prisma.$UserPayload<ExtArgs> | null
    modifiedByUser: Prisma.$UserPayload<ExtArgs> | null
    items: Prisma.$TransactionItemPayload<ExtArgs>[]
    approvals: Prisma.$ApprovalPayload<ExtArgs>[]
    payments: Prisma.$PaymentPayload<ExtArgs>[]
    snapshots: Prisma.$TransactionSnapshotPayload<ExtArgs>[]
    completedByUser: Prisma.$UserPayload<ExtArgs> | null
    headStoreUser: Prisma.$UserPayload<ExtArgs> | null
  }
  scalars: runtime.Types.Extensions.GetPayloadResult<{
    id: string
    trxCode: string
    branchId: string
    customerId: string
    status: $Enums.TransactionStatus
    totalGrossWeight: runtime.Decimal | null
    totalNetWeight: runtime.Decimal | null
    totalAmount: runtime.Decimal | null
    bankId: string | null
    bankAccountNo: string | null
    bankAccountName: string | null
    referralSource: string | null
    knowsFounder: boolean | null
    createdBy: string | null
    createdAt: Date
    modifiedBy: string | null
    modifiedAt: Date | null
    cancellationReason: string | null
    cancelledBy: string | null
    cancelledAt: Date | null
    completedBy: string | null
    completedAt: Date | null
    headStoreId: string | null
  }, ExtArgs["result"]["transaction"]>
  composites: {}
}

export type TransactionGetPayload<S extends boolean | null | undefined | TransactionDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$TransactionPayload, S>

export type TransactionCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> =
  Omit<TransactionFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
    select?: TransactionCountAggregateInputType | true
  }

export interface TransactionDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
  [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Transaction'], meta: { name: 'Transaction' } }
  /**
   * Find zero or one Transaction that matches the filter.
   * @param {TransactionFindUniqueArgs} args - Arguments to find a Transaction
   * @example
   * // Get one Transaction
   * const transaction = await prisma.transaction.findUnique({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   */
  findUnique<T extends TransactionFindUniqueArgs>(args: Prisma.SelectSubset<T, TransactionFindUniqueArgs<ExtArgs>>): Prisma.Prisma__TransactionClient<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

  /**
   * Find one Transaction that matches the filter or throw an error with `error.code='P2025'`
   * if no matches were found.
   * @param {TransactionFindUniqueOrThrowArgs} args - Arguments to find a Transaction
   * @example
   * // Get one Transaction
   * const transaction = await prisma.transaction.findUniqueOrThrow({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   */
  findUniqueOrThrow<T extends TransactionFindUniqueOrThrowArgs>(args: Prisma.SelectSubset<T, TransactionFindUniqueOrThrowArgs<ExtArgs>>): Prisma.Prisma__TransactionClient<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

  /**
   * Find the first Transaction that matches the filter.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {TransactionFindFirstArgs} args - Arguments to find a Transaction
   * @example
   * // Get one Transaction
   * const transaction = await prisma.transaction.findFirst({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   */
  findFirst<T extends TransactionFindFirstArgs>(args?: Prisma.SelectSubset<T, TransactionFindFirstArgs<ExtArgs>>): Prisma.Prisma__TransactionClient<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

  /**
   * Find the first Transaction that matches the filter or
   * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {TransactionFindFirstOrThrowArgs} args - Arguments to find a Transaction
   * @example
   * // Get one Transaction
   * const transaction = await prisma.transaction.findFirstOrThrow({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   */
  findFirstOrThrow<T extends TransactionFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, TransactionFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__TransactionClient<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

  /**
   * Find zero or more Transactions that matches the filter.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {TransactionFindManyArgs} args - Arguments to filter and select certain fields only.
   * @example
   * // Get all Transactions
   * const transactions = await prisma.transaction.findMany()
   * 
   * // Get first 10 Transactions
   * const transactions = await prisma.transaction.findMany({ take: 10 })
   * 
   * // Only select the `id`
   * const transactionWithIdOnly = await prisma.transaction.findMany({ select: { id: true } })
   * 
   */
  findMany<T extends TransactionFindManyArgs>(args?: Prisma.SelectSubset<T, TransactionFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

  /**
   * Create a Transaction.
   * @param {TransactionCreateArgs} args - Arguments to create a Transaction.
   * @example
   * // Create one Transaction
   * const Transaction = await prisma.transaction.create({
   *   data: {
   *     // ... data to create a Transaction
   *   }
   * })
   * 
   */
  create<T extends TransactionCreateArgs>(args: Prisma.SelectSubset<T, TransactionCreateArgs<ExtArgs>>): Prisma.Prisma__TransactionClient<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

  /**
   * Create many Transactions.
   * @param {TransactionCreateManyArgs} args - Arguments to create many Transactions.
   * @example
   * // Create many Transactions
   * const transaction = await prisma.transaction.createMany({
   *   data: [
   *     // ... provide data here
   *   ]
   * })
   *     
   */
  createMany<T extends TransactionCreateManyArgs>(args?: Prisma.SelectSubset<T, TransactionCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>

  /**
   * Create many Transactions and returns the data saved in the database.
   * @param {TransactionCreateManyAndReturnArgs} args - Arguments to create many Transactions.
   * @example
   * // Create many Transactions
   * const transaction = await prisma.transaction.createManyAndReturn({
   *   data: [
   *     // ... provide data here
   *   ]
   * })
   * 
   * // Create many Transactions and only return the `id`
   * const transactionWithIdOnly = await prisma.transaction.createManyAndReturn({
   *   select: { id: true },
   *   data: [
   *     // ... provide data here
   *   ]
   * })
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * 
   */
  createManyAndReturn<T extends TransactionCreateManyAndReturnArgs>(args?: Prisma.SelectSubset<T, TransactionCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

  /**
   * Delete a Transaction.
   * @param {TransactionDeleteArgs} args - Arguments to delete one Transaction.
   * @example
   * // Delete one Transaction
   * const Transaction = await prisma.transaction.delete({
   *   where: {
   *     // ... filter to delete one Transaction
   *   }
   * })
   * 
   */
  delete<T extends TransactionDeleteArgs>(args: Prisma.SelectSubset<T, TransactionDeleteArgs<ExtArgs>>): Prisma.Prisma__TransactionClient<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

  /**
   * Update one Transaction.
   * @param {TransactionUpdateArgs} args - Arguments to update one Transaction.
   * @example
   * // Update one Transaction
   * const transaction = await prisma.transaction.update({
   *   where: {
   *     // ... provide filter here
   *   },
   *   data: {
   *     // ... provide data here
   *   }
   * })
   * 
   */
  update<T extends TransactionUpdateArgs>(args: Prisma.SelectSubset<T, TransactionUpdateArgs<ExtArgs>>): Prisma.Prisma__TransactionClient<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

  /**
   * Delete zero or more Transactions.
   * @param {TransactionDeleteManyArgs} args - Arguments to filter Transactions to delete.
   * @example
   * // Delete a few Transactions
   * const { count } = await prisma.transaction.deleteMany({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   * 
   */
  deleteMany<T extends TransactionDeleteManyArgs>(args?: Prisma.SelectSubset<T, TransactionDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>

  /**
   * Update zero or more Transactions.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {TransactionUpdateManyArgs} args - Arguments to update one or more rows.
   * @example
   * // Update many Transactions
   * const transaction = await prisma.transaction.updateMany({
   *   where: {
   *     // ... provide filter here
   *   },
   *   data: {
   *     // ... provide data here
   *   }
   * })
   * 
   */
  updateMany<T extends TransactionUpdateManyArgs>(args: Prisma.SelectSubset<T, TransactionUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>

  /**
   * Update zero or more Transactions and returns the data updated in the database.
   * @param {TransactionUpdateManyAndReturnArgs} args - Arguments to update many Transactions.
   * @example
   * // Update many Transactions
   * const transaction = await prisma.transaction.updateManyAndReturn({
   *   where: {
   *     // ... provide filter here
   *   },
   *   data: [
   *     // ... provide data here
   *   ]
   * })
   * 
   * // Update zero or more Transactions and only return the `id`
   * const transactionWithIdOnly = await prisma.transaction.updateManyAndReturn({
   *   select: { id: true },
   *   where: {
   *     // ... provide filter here
   *   },
   *   data: [
   *     // ... provide data here
   *   ]
   * })
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * 
   */
  updateManyAndReturn<T extends TransactionUpdateManyAndReturnArgs>(args: Prisma.SelectSubset<T, TransactionUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

  /**
   * Create or update one Transaction.
   * @param {TransactionUpsertArgs} args - Arguments to update or create a Transaction.
   * @example
   * // Update or create a Transaction
   * const transaction = await prisma.transaction.upsert({
   *   create: {
   *     // ... data to create a Transaction
   *   },
   *   update: {
   *     // ... in case it already exists, update
   *   },
   *   where: {
   *     // ... the filter for the Transaction we want to update
   *   }
   * })
   */
  upsert<T extends TransactionUpsertArgs>(args: Prisma.SelectSubset<T, TransactionUpsertArgs<ExtArgs>>): Prisma.Prisma__TransactionClient<runtime.Types.Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


  /**
   * Count the number of Transactions.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {TransactionCountArgs} args - Arguments to filter Transactions to count.
   * @example
   * // Count the number of Transactions
   * const count = await prisma.transaction.count({
   *   where: {
   *     // ... the filter for the Transactions we want to count
   *   }
   * })
  **/
  count<T extends TransactionCountArgs>(
    args?: Prisma.Subset<T, TransactionCountArgs>,
  ): Prisma.PrismaPromise<
    T extends runtime.Types.Utils.Record<'select', any>
      ? T['select'] extends true
        ? number
        : Prisma.GetScalarType<T['select'], TransactionCountAggregateOutputType>
      : number
  >

  /**
   * Allows you to perform aggregations operations on a Transaction.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {TransactionAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
   * @example
   * // Ordered by age ascending
   * // Where email contains prisma.io
   * // Limited to the 10 users
   * const aggregations = await prisma.user.aggregate({
   *   _avg: {
   *     age: true,
   *   },
   *   where: {
   *     email: {
   *       contains: "prisma.io",
   *     },
   *   },
   *   orderBy: {
   *     age: "asc",
   *   },
   *   take: 10,
   * })
  **/
  aggregate<T extends TransactionAggregateArgs>(args: Prisma.Subset<T, TransactionAggregateArgs>): Prisma.PrismaPromise<GetTransactionAggregateType<T>>

  /**
   * Group by Transaction.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {TransactionGroupByArgs} args - Group by arguments.
   * @example
   * // Group by city, order by createdAt, get count
   * const result = await prisma.user.groupBy({
   *   by: ['city', 'createdAt'],
   *   orderBy: {
   *     createdAt: true
   *   },
   *   _count: {
   *     _all: true
   *   },
   * })
   * 
  **/
  groupBy<
    T extends TransactionGroupByArgs,
    HasSelectOrTake extends Prisma.Or<
      Prisma.Extends<'skip', Prisma.Keys<T>>,
      Prisma.Extends<'take', Prisma.Keys<T>>
    >,
    OrderByArg extends Prisma.True extends HasSelectOrTake
      ? { orderBy: TransactionGroupByArgs['orderBy'] }
      : { orderBy?: TransactionGroupByArgs['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, TransactionGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetTransactionGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
 * Fields of the Transaction model
 */
readonly fields: TransactionFieldRefs;
}

/**
 * The delegate class that acts as a "Promise-like" for Transaction.
 * Why is this prefixed with `Prisma__`?
 * Because we want to prevent naming conflicts as mentioned in
 * https://github.com/prisma/prisma-client-js/issues/707
 */
export interface Prisma__TransactionClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
  readonly [Symbol.toStringTag]: "PrismaPromise"
  branch<T extends Prisma.BranchDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.BranchDefaultArgs<ExtArgs>>): Prisma.Prisma__BranchClient<runtime.Types.Result.GetResult<Prisma.$BranchPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
  customer<T extends Prisma.CustomerDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.CustomerDefaultArgs<ExtArgs>>): Prisma.Prisma__CustomerClient<runtime.Types.Result.GetResult<Prisma.$CustomerPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
  bank<T extends Prisma.Transaction$bankArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$bankArgs<ExtArgs>>): Prisma.Prisma__BankClient<runtime.Types.Result.GetResult<Prisma.$BankPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
  docs<T extends Prisma.Transaction$docsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$docsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TransactionDocPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  createdByUser<T extends Prisma.Transaction$createdByUserArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$createdByUserArgs<ExtArgs>>): Prisma.Prisma__UserClient<runtime.Types.Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
  modifiedByUser<T extends Prisma.Transaction$modifiedByUserArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$modifiedByUserArgs<ExtArgs>>): Prisma.Prisma__UserClient<runtime.Types.Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
  items<T extends Prisma.Transaction$itemsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$itemsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TransactionItemPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  approvals<T extends Prisma.Transaction$approvalsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$approvalsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$ApprovalPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  payments<T extends Prisma.Transaction$paymentsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$paymentsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PaymentPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  snapshots<T extends Prisma.Transaction$snapshotsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$snapshotsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TransactionSnapshotPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  completedByUser<T extends Prisma.Transaction$completedByUserArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$completedByUserArgs<ExtArgs>>): Prisma.Prisma__UserClient<runtime.Types.Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
  headStoreUser<T extends Prisma.Transaction$headStoreUserArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Transaction$headStoreUserArgs<ExtArgs>>): Prisma.Prisma__UserClient<runtime.Types.Result.GetResult<Prisma.$UserPayload<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.
   * @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 Transaction model
 */
export interface TransactionFieldRefs {
  readonly id: Prisma.FieldRef<"Transaction", 'String'>
  readonly trxCode: Prisma.FieldRef<"Transaction", 'String'>
  readonly branchId: Prisma.FieldRef<"Transaction", 'String'>
  readonly customerId: Prisma.FieldRef<"Transaction", 'String'>
  readonly status: Prisma.FieldRef<"Transaction", 'TransactionStatus'>
  readonly totalGrossWeight: Prisma.FieldRef<"Transaction", 'Decimal'>
  readonly totalNetWeight: Prisma.FieldRef<"Transaction", 'Decimal'>
  readonly totalAmount: Prisma.FieldRef<"Transaction", 'Decimal'>
  readonly bankId: Prisma.FieldRef<"Transaction", 'String'>
  readonly bankAccountNo: Prisma.FieldRef<"Transaction", 'String'>
  readonly bankAccountName: Prisma.FieldRef<"Transaction", 'String'>
  readonly referralSource: Prisma.FieldRef<"Transaction", 'String'>
  readonly knowsFounder: Prisma.FieldRef<"Transaction", 'Boolean'>
  readonly createdBy: Prisma.FieldRef<"Transaction", 'String'>
  readonly createdAt: Prisma.FieldRef<"Transaction", 'DateTime'>
  readonly modifiedBy: Prisma.FieldRef<"Transaction", 'String'>
  readonly modifiedAt: Prisma.FieldRef<"Transaction", 'DateTime'>
  readonly cancellationReason: Prisma.FieldRef<"Transaction", 'String'>
  readonly cancelledBy: Prisma.FieldRef<"Transaction", 'String'>
  readonly cancelledAt: Prisma.FieldRef<"Transaction", 'DateTime'>
  readonly completedBy: Prisma.FieldRef<"Transaction", 'String'>
  readonly completedAt: Prisma.FieldRef<"Transaction", 'DateTime'>
  readonly headStoreId: Prisma.FieldRef<"Transaction", 'String'>
}
    

// Custom InputTypes
/**
 * Transaction findUnique
 */
export type TransactionFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * Filter, which Transaction to fetch.
   */
  where: Prisma.TransactionWhereUniqueInput
}

/**
 * Transaction findUniqueOrThrow
 */
export type TransactionFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * Filter, which Transaction to fetch.
   */
  where: Prisma.TransactionWhereUniqueInput
}

/**
 * Transaction findFirst
 */
export type TransactionFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * Filter, which Transaction to fetch.
   */
  where?: Prisma.TransactionWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of Transactions to fetch.
   */
  orderBy?: Prisma.TransactionOrderByWithRelationInput | Prisma.TransactionOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for searching for Transactions.
   */
  cursor?: Prisma.TransactionWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` Transactions from the position of the cursor.
   */
  take?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Skip the first `n` Transactions.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
   * 
   * Filter by unique combinations of Transactions.
   */
  distinct?: Prisma.TransactionScalarFieldEnum | Prisma.TransactionScalarFieldEnum[]
}

/**
 * Transaction findFirstOrThrow
 */
export type TransactionFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * Filter, which Transaction to fetch.
   */
  where?: Prisma.TransactionWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of Transactions to fetch.
   */
  orderBy?: Prisma.TransactionOrderByWithRelationInput | Prisma.TransactionOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for searching for Transactions.
   */
  cursor?: Prisma.TransactionWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` Transactions from the position of the cursor.
   */
  take?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Skip the first `n` Transactions.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
   * 
   * Filter by unique combinations of Transactions.
   */
  distinct?: Prisma.TransactionScalarFieldEnum | Prisma.TransactionScalarFieldEnum[]
}

/**
 * Transaction findMany
 */
export type TransactionFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * Filter, which Transactions to fetch.
   */
  where?: Prisma.TransactionWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of Transactions to fetch.
   */
  orderBy?: Prisma.TransactionOrderByWithRelationInput | Prisma.TransactionOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for listing Transactions.
   */
  cursor?: Prisma.TransactionWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` Transactions from the position of the cursor.
   */
  take?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Skip the first `n` Transactions.
   */
  skip?: number
  distinct?: Prisma.TransactionScalarFieldEnum | Prisma.TransactionScalarFieldEnum[]
}

/**
 * Transaction create
 */
export type TransactionCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * The data needed to create a Transaction.
   */
  data: Prisma.XOR<Prisma.TransactionCreateInput, Prisma.TransactionUncheckedCreateInput>
}

/**
 * Transaction createMany
 */
export type TransactionCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * The data used to create many Transactions.
   */
  data: Prisma.TransactionCreateManyInput | Prisma.TransactionCreateManyInput[]
  skipDuplicates?: boolean
}

/**
 * Transaction createManyAndReturn
 */
export type TransactionCreateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelectCreateManyAndReturn<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * The data used to create many Transactions.
   */
  data: Prisma.TransactionCreateManyInput | Prisma.TransactionCreateManyInput[]
  skipDuplicates?: boolean
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionIncludeCreateManyAndReturn<ExtArgs> | null
}

/**
 * Transaction update
 */
export type TransactionUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * The data needed to update a Transaction.
   */
  data: Prisma.XOR<Prisma.TransactionUpdateInput, Prisma.TransactionUncheckedUpdateInput>
  /**
   * Choose, which Transaction to update.
   */
  where: Prisma.TransactionWhereUniqueInput
}

/**
 * Transaction updateMany
 */
export type TransactionUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * The data used to update Transactions.
   */
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyInput>
  /**
   * Filter which Transactions to update
   */
  where?: Prisma.TransactionWhereInput
  /**
   * Limit how many Transactions to update.
   */
  limit?: number
}

/**
 * Transaction updateManyAndReturn
 */
export type TransactionUpdateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelectUpdateManyAndReturn<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * The data used to update Transactions.
   */
  data: Prisma.XOR<Prisma.TransactionUpdateManyMutationInput, Prisma.TransactionUncheckedUpdateManyInput>
  /**
   * Filter which Transactions to update
   */
  where?: Prisma.TransactionWhereInput
  /**
   * Limit how many Transactions to update.
   */
  limit?: number
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionIncludeUpdateManyAndReturn<ExtArgs> | null
}

/**
 * Transaction upsert
 */
export type TransactionUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * The filter to search for the Transaction to update in case it exists.
   */
  where: Prisma.TransactionWhereUniqueInput
  /**
   * In case the Transaction found by the `where` argument doesn't exist, create a new Transaction with this data.
   */
  create: Prisma.XOR<Prisma.TransactionCreateInput, Prisma.TransactionUncheckedCreateInput>
  /**
   * In case the Transaction was found with the provided `where` argument, update it with this data.
   */
  update: Prisma.XOR<Prisma.TransactionUpdateInput, Prisma.TransactionUncheckedUpdateInput>
}

/**
 * Transaction delete
 */
export type TransactionDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
  /**
   * Filter which Transaction to delete.
   */
  where: Prisma.TransactionWhereUniqueInput
}

/**
 * Transaction deleteMany
 */
export type TransactionDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Filter which Transactions to delete
   */
  where?: Prisma.TransactionWhereInput
  /**
   * Limit how many Transactions to delete.
   */
  limit?: number
}

/**
 * Transaction.bank
 */
export type Transaction$bankArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Bank
   */
  select?: Prisma.BankSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Bank
   */
  omit?: Prisma.BankOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.BankInclude<ExtArgs> | null
  where?: Prisma.BankWhereInput
}

/**
 * Transaction.docs
 */
export type Transaction$docsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the TransactionDoc
   */
  select?: Prisma.TransactionDocSelect<ExtArgs> | null
  /**
   * Omit specific fields from the TransactionDoc
   */
  omit?: Prisma.TransactionDocOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionDocInclude<ExtArgs> | null
  where?: Prisma.TransactionDocWhereInput
  orderBy?: Prisma.TransactionDocOrderByWithRelationInput | Prisma.TransactionDocOrderByWithRelationInput[]
  cursor?: Prisma.TransactionDocWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.TransactionDocScalarFieldEnum | Prisma.TransactionDocScalarFieldEnum[]
}

/**
 * Transaction.createdByUser
 */
export type Transaction$createdByUserArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the User
   */
  select?: Prisma.UserSelect<ExtArgs> | null
  /**
   * Omit specific fields from the User
   */
  omit?: Prisma.UserOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.UserInclude<ExtArgs> | null
  where?: Prisma.UserWhereInput
}

/**
 * Transaction.modifiedByUser
 */
export type Transaction$modifiedByUserArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the User
   */
  select?: Prisma.UserSelect<ExtArgs> | null
  /**
   * Omit specific fields from the User
   */
  omit?: Prisma.UserOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.UserInclude<ExtArgs> | null
  where?: Prisma.UserWhereInput
}

/**
 * Transaction.items
 */
export type Transaction$itemsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the TransactionItem
   */
  select?: Prisma.TransactionItemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the TransactionItem
   */
  omit?: Prisma.TransactionItemOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionItemInclude<ExtArgs> | null
  where?: Prisma.TransactionItemWhereInput
  orderBy?: Prisma.TransactionItemOrderByWithRelationInput | Prisma.TransactionItemOrderByWithRelationInput[]
  cursor?: Prisma.TransactionItemWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.TransactionItemScalarFieldEnum | Prisma.TransactionItemScalarFieldEnum[]
}

/**
 * Transaction.approvals
 */
export type Transaction$approvalsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Approval
   */
  select?: Prisma.ApprovalSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Approval
   */
  omit?: Prisma.ApprovalOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.ApprovalInclude<ExtArgs> | null
  where?: Prisma.ApprovalWhereInput
  orderBy?: Prisma.ApprovalOrderByWithRelationInput | Prisma.ApprovalOrderByWithRelationInput[]
  cursor?: Prisma.ApprovalWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.ApprovalScalarFieldEnum | Prisma.ApprovalScalarFieldEnum[]
}

/**
 * Transaction.payments
 */
export type Transaction$paymentsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Payment
   */
  select?: Prisma.PaymentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Payment
   */
  omit?: Prisma.PaymentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.PaymentInclude<ExtArgs> | null
  where?: Prisma.PaymentWhereInput
  orderBy?: Prisma.PaymentOrderByWithRelationInput | Prisma.PaymentOrderByWithRelationInput[]
  cursor?: Prisma.PaymentWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.PaymentScalarFieldEnum | Prisma.PaymentScalarFieldEnum[]
}

/**
 * Transaction.snapshots
 */
export type Transaction$snapshotsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the TransactionSnapshot
   */
  select?: Prisma.TransactionSnapshotSelect<ExtArgs> | null
  /**
   * Omit specific fields from the TransactionSnapshot
   */
  omit?: Prisma.TransactionSnapshotOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionSnapshotInclude<ExtArgs> | null
  where?: Prisma.TransactionSnapshotWhereInput
  orderBy?: Prisma.TransactionSnapshotOrderByWithRelationInput | Prisma.TransactionSnapshotOrderByWithRelationInput[]
  cursor?: Prisma.TransactionSnapshotWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.TransactionSnapshotScalarFieldEnum | Prisma.TransactionSnapshotScalarFieldEnum[]
}

/**
 * Transaction.completedByUser
 */
export type Transaction$completedByUserArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the User
   */
  select?: Prisma.UserSelect<ExtArgs> | null
  /**
   * Omit specific fields from the User
   */
  omit?: Prisma.UserOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.UserInclude<ExtArgs> | null
  where?: Prisma.UserWhereInput
}

/**
 * Transaction.headStoreUser
 */
export type Transaction$headStoreUserArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the User
   */
  select?: Prisma.UserSelect<ExtArgs> | null
  /**
   * Omit specific fields from the User
   */
  omit?: Prisma.UserOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.UserInclude<ExtArgs> | null
  where?: Prisma.UserWhereInput
}

/**
 * Transaction without action
 */
export type TransactionDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Transaction
   */
  select?: Prisma.TransactionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Transaction
   */
  omit?: Prisma.TransactionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.TransactionInclude<ExtArgs> | null
}
