
/* !!! This is code generated by Prisma. Do not edit directly. !!! */
/* eslint-disable */
// biome-ignore-all lint: generated file
// @ts-nocheck 
/*
 * This file exports the `bon_travail_item` 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 bon_travail_item
 * 
 */
export type bon_travail_itemModel = runtime.Types.Result.DefaultSelection<Prisma.$bon_travail_itemPayload>

export type AggregateBon_travail_item = {
  _count: Bon_travail_itemCountAggregateOutputType | null
  _avg: Bon_travail_itemAvgAggregateOutputType | null
  _sum: Bon_travail_itemSumAggregateOutputType | null
  _min: Bon_travail_itemMinAggregateOutputType | null
  _max: Bon_travail_itemMaxAggregateOutputType | null
}

export type Bon_travail_itemAvgAggregateOutputType = {
  id: number | null
  bon_id: number | null
  product_id: number | null
  qte: number | null
  price: runtime.Decimal | null
}

export type Bon_travail_itemSumAggregateOutputType = {
  id: number | null
  bon_id: number | null
  product_id: number | null
  qte: number | null
  price: runtime.Decimal | null
}

export type Bon_travail_itemMinAggregateOutputType = {
  id: number | null
  bon_id: number | null
  product_id: number | null
  qte: number | null
  price: runtime.Decimal | null
  desc: string | null
}

export type Bon_travail_itemMaxAggregateOutputType = {
  id: number | null
  bon_id: number | null
  product_id: number | null
  qte: number | null
  price: runtime.Decimal | null
  desc: string | null
}

export type Bon_travail_itemCountAggregateOutputType = {
  id: number
  bon_id: number
  product_id: number
  qte: number
  price: number
  desc: number
  _all: number
}


export type Bon_travail_itemAvgAggregateInputType = {
  id?: true
  bon_id?: true
  product_id?: true
  qte?: true
  price?: true
}

export type Bon_travail_itemSumAggregateInputType = {
  id?: true
  bon_id?: true
  product_id?: true
  qte?: true
  price?: true
}

export type Bon_travail_itemMinAggregateInputType = {
  id?: true
  bon_id?: true
  product_id?: true
  qte?: true
  price?: true
  desc?: true
}

export type Bon_travail_itemMaxAggregateInputType = {
  id?: true
  bon_id?: true
  product_id?: true
  qte?: true
  price?: true
  desc?: true
}

export type Bon_travail_itemCountAggregateInputType = {
  id?: true
  bon_id?: true
  product_id?: true
  qte?: true
  price?: true
  desc?: true
  _all?: true
}

export type Bon_travail_itemAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Filter which bon_travail_item to aggregate.
   */
  where?: Prisma.bon_travail_itemWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of bon_travail_items to fetch.
   */
  orderBy?: Prisma.bon_travail_itemOrderByWithRelationInput | Prisma.bon_travail_itemOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the start position
   */
  cursor?: Prisma.bon_travail_itemWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` bon_travail_items 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` bon_travail_items.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Count returned bon_travail_items
  **/
  _count?: true | Bon_travail_itemCountAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to average
  **/
  _avg?: Bon_travail_itemAvgAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to sum
  **/
  _sum?: Bon_travail_itemSumAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to find the minimum value
  **/
  _min?: Bon_travail_itemMinAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to find the maximum value
  **/
  _max?: Bon_travail_itemMaxAggregateInputType
}

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




export type bon_travail_itemGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.bon_travail_itemWhereInput
  orderBy?: Prisma.bon_travail_itemOrderByWithAggregationInput | Prisma.bon_travail_itemOrderByWithAggregationInput[]
  by: Prisma.Bon_travail_itemScalarFieldEnum[] | Prisma.Bon_travail_itemScalarFieldEnum
  having?: Prisma.bon_travail_itemScalarWhereWithAggregatesInput
  take?: number
  skip?: number
  _count?: Bon_travail_itemCountAggregateInputType | true
  _avg?: Bon_travail_itemAvgAggregateInputType
  _sum?: Bon_travail_itemSumAggregateInputType
  _min?: Bon_travail_itemMinAggregateInputType
  _max?: Bon_travail_itemMaxAggregateInputType
}

export type Bon_travail_itemGroupByOutputType = {
  id: number
  bon_id: number
  product_id: number
  qte: number
  price: runtime.Decimal
  desc: string
  _count: Bon_travail_itemCountAggregateOutputType | null
  _avg: Bon_travail_itemAvgAggregateOutputType | null
  _sum: Bon_travail_itemSumAggregateOutputType | null
  _min: Bon_travail_itemMinAggregateOutputType | null
  _max: Bon_travail_itemMaxAggregateOutputType | null
}

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



export type bon_travail_itemWhereInput = {
  AND?: Prisma.bon_travail_itemWhereInput | Prisma.bon_travail_itemWhereInput[]
  OR?: Prisma.bon_travail_itemWhereInput[]
  NOT?: Prisma.bon_travail_itemWhereInput | Prisma.bon_travail_itemWhereInput[]
  id?: Prisma.IntFilter<"bon_travail_item"> | number
  bon_id?: Prisma.IntFilter<"bon_travail_item"> | number
  product_id?: Prisma.IntFilter<"bon_travail_item"> | number
  qte?: Prisma.IntFilter<"bon_travail_item"> | number
  price?: Prisma.DecimalFilter<"bon_travail_item"> | runtime.Decimal | runtime.DecimalJsLike | number | string
  desc?: Prisma.StringFilter<"bon_travail_item"> | string
}

export type bon_travail_itemOrderByWithRelationInput = {
  id?: Prisma.SortOrder
  bon_id?: Prisma.SortOrder
  product_id?: Prisma.SortOrder
  qte?: Prisma.SortOrder
  price?: Prisma.SortOrder
  desc?: Prisma.SortOrder
  _relevance?: Prisma.bon_travail_itemOrderByRelevanceInput
}

export type bon_travail_itemWhereUniqueInput = Prisma.AtLeast<{
  id?: number
  AND?: Prisma.bon_travail_itemWhereInput | Prisma.bon_travail_itemWhereInput[]
  OR?: Prisma.bon_travail_itemWhereInput[]
  NOT?: Prisma.bon_travail_itemWhereInput | Prisma.bon_travail_itemWhereInput[]
  bon_id?: Prisma.IntFilter<"bon_travail_item"> | number
  product_id?: Prisma.IntFilter<"bon_travail_item"> | number
  qte?: Prisma.IntFilter<"bon_travail_item"> | number
  price?: Prisma.DecimalFilter<"bon_travail_item"> | runtime.Decimal | runtime.DecimalJsLike | number | string
  desc?: Prisma.StringFilter<"bon_travail_item"> | string
}, "id">

export type bon_travail_itemOrderByWithAggregationInput = {
  id?: Prisma.SortOrder
  bon_id?: Prisma.SortOrder
  product_id?: Prisma.SortOrder
  qte?: Prisma.SortOrder
  price?: Prisma.SortOrder
  desc?: Prisma.SortOrder
  _count?: Prisma.bon_travail_itemCountOrderByAggregateInput
  _avg?: Prisma.bon_travail_itemAvgOrderByAggregateInput
  _max?: Prisma.bon_travail_itemMaxOrderByAggregateInput
  _min?: Prisma.bon_travail_itemMinOrderByAggregateInput
  _sum?: Prisma.bon_travail_itemSumOrderByAggregateInput
}

export type bon_travail_itemScalarWhereWithAggregatesInput = {
  AND?: Prisma.bon_travail_itemScalarWhereWithAggregatesInput | Prisma.bon_travail_itemScalarWhereWithAggregatesInput[]
  OR?: Prisma.bon_travail_itemScalarWhereWithAggregatesInput[]
  NOT?: Prisma.bon_travail_itemScalarWhereWithAggregatesInput | Prisma.bon_travail_itemScalarWhereWithAggregatesInput[]
  id?: Prisma.IntWithAggregatesFilter<"bon_travail_item"> | number
  bon_id?: Prisma.IntWithAggregatesFilter<"bon_travail_item"> | number
  product_id?: Prisma.IntWithAggregatesFilter<"bon_travail_item"> | number
  qte?: Prisma.IntWithAggregatesFilter<"bon_travail_item"> | number
  price?: Prisma.DecimalWithAggregatesFilter<"bon_travail_item"> | runtime.Decimal | runtime.DecimalJsLike | number | string
  desc?: Prisma.StringWithAggregatesFilter<"bon_travail_item"> | string
}

export type bon_travail_itemCreateInput = {
  bon_id: number
  product_id: number
  qte: number
  price: runtime.Decimal | runtime.DecimalJsLike | number | string
  desc: string
}

export type bon_travail_itemUncheckedCreateInput = {
  id?: number
  bon_id: number
  product_id: number
  qte: number
  price: runtime.Decimal | runtime.DecimalJsLike | number | string
  desc: string
}

export type bon_travail_itemUpdateInput = {
  bon_id?: Prisma.IntFieldUpdateOperationsInput | number
  product_id?: Prisma.IntFieldUpdateOperationsInput | number
  qte?: Prisma.IntFieldUpdateOperationsInput | number
  price?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
  desc?: Prisma.StringFieldUpdateOperationsInput | string
}

export type bon_travail_itemUncheckedUpdateInput = {
  id?: Prisma.IntFieldUpdateOperationsInput | number
  bon_id?: Prisma.IntFieldUpdateOperationsInput | number
  product_id?: Prisma.IntFieldUpdateOperationsInput | number
  qte?: Prisma.IntFieldUpdateOperationsInput | number
  price?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
  desc?: Prisma.StringFieldUpdateOperationsInput | string
}

export type bon_travail_itemCreateManyInput = {
  id?: number
  bon_id: number
  product_id: number
  qte: number
  price: runtime.Decimal | runtime.DecimalJsLike | number | string
  desc: string
}

export type bon_travail_itemUpdateManyMutationInput = {
  bon_id?: Prisma.IntFieldUpdateOperationsInput | number
  product_id?: Prisma.IntFieldUpdateOperationsInput | number
  qte?: Prisma.IntFieldUpdateOperationsInput | number
  price?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
  desc?: Prisma.StringFieldUpdateOperationsInput | string
}

export type bon_travail_itemUncheckedUpdateManyInput = {
  id?: Prisma.IntFieldUpdateOperationsInput | number
  bon_id?: Prisma.IntFieldUpdateOperationsInput | number
  product_id?: Prisma.IntFieldUpdateOperationsInput | number
  qte?: Prisma.IntFieldUpdateOperationsInput | number
  price?: Prisma.DecimalFieldUpdateOperationsInput | runtime.Decimal | runtime.DecimalJsLike | number | string
  desc?: Prisma.StringFieldUpdateOperationsInput | string
}

export type bon_travail_itemOrderByRelevanceInput = {
  fields: Prisma.bon_travail_itemOrderByRelevanceFieldEnum | Prisma.bon_travail_itemOrderByRelevanceFieldEnum[]
  sort: Prisma.SortOrder
  search: string
}

export type bon_travail_itemCountOrderByAggregateInput = {
  id?: Prisma.SortOrder
  bon_id?: Prisma.SortOrder
  product_id?: Prisma.SortOrder
  qte?: Prisma.SortOrder
  price?: Prisma.SortOrder
  desc?: Prisma.SortOrder
}

export type bon_travail_itemAvgOrderByAggregateInput = {
  id?: Prisma.SortOrder
  bon_id?: Prisma.SortOrder
  product_id?: Prisma.SortOrder
  qte?: Prisma.SortOrder
  price?: Prisma.SortOrder
}

export type bon_travail_itemMaxOrderByAggregateInput = {
  id?: Prisma.SortOrder
  bon_id?: Prisma.SortOrder
  product_id?: Prisma.SortOrder
  qte?: Prisma.SortOrder
  price?: Prisma.SortOrder
  desc?: Prisma.SortOrder
}

export type bon_travail_itemMinOrderByAggregateInput = {
  id?: Prisma.SortOrder
  bon_id?: Prisma.SortOrder
  product_id?: Prisma.SortOrder
  qte?: Prisma.SortOrder
  price?: Prisma.SortOrder
  desc?: Prisma.SortOrder
}

export type bon_travail_itemSumOrderByAggregateInput = {
  id?: Prisma.SortOrder
  bon_id?: Prisma.SortOrder
  product_id?: Prisma.SortOrder
  qte?: Prisma.SortOrder
  price?: Prisma.SortOrder
}



export type bon_travail_itemSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
  id?: boolean
  bon_id?: boolean
  product_id?: boolean
  qte?: boolean
  price?: boolean
  desc?: boolean
}, ExtArgs["result"]["bon_travail_item"]>



export type bon_travail_itemSelectScalar = {
  id?: boolean
  bon_id?: boolean
  product_id?: boolean
  qte?: boolean
  price?: boolean
  desc?: boolean
}

export type bon_travail_itemOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "bon_id" | "product_id" | "qte" | "price" | "desc", ExtArgs["result"]["bon_travail_item"]>

export type $bon_travail_itemPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  name: "bon_travail_item"
  objects: {}
  scalars: runtime.Types.Extensions.GetPayloadResult<{
    id: number
    bon_id: number
    product_id: number
    qte: number
    price: runtime.Decimal
    desc: string
  }, ExtArgs["result"]["bon_travail_item"]>
  composites: {}
}

export type bon_travail_itemGetPayload<S extends boolean | null | undefined | bon_travail_itemDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$bon_travail_itemPayload, S>

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

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

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

  /**
   * Find the first Bon_travail_item 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 {bon_travail_itemFindFirstArgs} args - Arguments to find a Bon_travail_item
   * @example
   * // Get one Bon_travail_item
   * const bon_travail_item = await prisma.bon_travail_item.findFirst({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   */
  findFirst<T extends bon_travail_itemFindFirstArgs>(args?: Prisma.SelectSubset<T, bon_travail_itemFindFirstArgs<ExtArgs>>): Prisma.Prisma__bon_travail_itemClient<runtime.Types.Result.GetResult<Prisma.$bon_travail_itemPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

  /**
   * Find the first Bon_travail_item 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 {bon_travail_itemFindFirstOrThrowArgs} args - Arguments to find a Bon_travail_item
   * @example
   * // Get one Bon_travail_item
   * const bon_travail_item = await prisma.bon_travail_item.findFirstOrThrow({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   */
  findFirstOrThrow<T extends bon_travail_itemFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, bon_travail_itemFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__bon_travail_itemClient<runtime.Types.Result.GetResult<Prisma.$bon_travail_itemPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

  /**
   * Find zero or more Bon_travail_items 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 {bon_travail_itemFindManyArgs} args - Arguments to filter and select certain fields only.
   * @example
   * // Get all Bon_travail_items
   * const bon_travail_items = await prisma.bon_travail_item.findMany()
   * 
   * // Get first 10 Bon_travail_items
   * const bon_travail_items = await prisma.bon_travail_item.findMany({ take: 10 })
   * 
   * // Only select the `id`
   * const bon_travail_itemWithIdOnly = await prisma.bon_travail_item.findMany({ select: { id: true } })
   * 
   */
  findMany<T extends bon_travail_itemFindManyArgs>(args?: Prisma.SelectSubset<T, bon_travail_itemFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$bon_travail_itemPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

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

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

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

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

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

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

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


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

  /**
   * Allows you to perform aggregations operations on a Bon_travail_item.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {Bon_travail_itemAggregateArgs} 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 Bon_travail_itemAggregateArgs>(args: Prisma.Subset<T, Bon_travail_itemAggregateArgs>): Prisma.PrismaPromise<GetBon_travail_itemAggregateType<T>>

  /**
   * Group by Bon_travail_item.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {bon_travail_itemGroupByArgs} 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 bon_travail_itemGroupByArgs,
    HasSelectOrTake extends Prisma.Or<
      Prisma.Extends<'skip', Prisma.Keys<T>>,
      Prisma.Extends<'take', Prisma.Keys<T>>
    >,
    OrderByArg extends Prisma.True extends HasSelectOrTake
      ? { orderBy: bon_travail_itemGroupByArgs['orderBy'] }
      : { orderBy?: bon_travail_itemGroupByArgs['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, bon_travail_itemGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetBon_travail_itemGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
 * Fields of the bon_travail_item model
 */
readonly fields: bon_travail_itemFieldRefs;
}

/**
 * The delegate class that acts as a "Promise-like" for bon_travail_item.
 * 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__bon_travail_itemClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
  readonly [Symbol.toStringTag]: "PrismaPromise"
  /**
   * Attaches callbacks for the resolution and/or rejection of the Promise.
   * @param onfulfilled The callback to execute when the Promise is resolved.
   * @param onrejected The callback to execute when the Promise is rejected.
   * @returns A Promise for the completion of which ever callback is executed.
   */
  then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): runtime.Types.Utils.JsPromise<TResult1 | TResult2>
  /**
   * Attaches a callback for only the rejection of the Promise.
   * @param onrejected The callback to execute when the Promise is rejected.
   * @returns A Promise for the completion of the callback.
   */
  catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): runtime.Types.Utils.JsPromise<T | TResult>
  /**
   * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
   * resolved value cannot be modified from the callback.
   * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
   * @returns A Promise for the completion of the callback.
   */
  finally(onfinally?: (() => void) | undefined | null): runtime.Types.Utils.JsPromise<T>
}




/**
 * Fields of the bon_travail_item model
 */
export interface bon_travail_itemFieldRefs {
  readonly id: Prisma.FieldRef<"bon_travail_item", 'Int'>
  readonly bon_id: Prisma.FieldRef<"bon_travail_item", 'Int'>
  readonly product_id: Prisma.FieldRef<"bon_travail_item", 'Int'>
  readonly qte: Prisma.FieldRef<"bon_travail_item", 'Int'>
  readonly price: Prisma.FieldRef<"bon_travail_item", 'Decimal'>
  readonly desc: Prisma.FieldRef<"bon_travail_item", 'String'>
}
    

// Custom InputTypes
/**
 * bon_travail_item findUnique
 */
export type bon_travail_itemFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * Filter, which bon_travail_item to fetch.
   */
  where: Prisma.bon_travail_itemWhereUniqueInput
}

/**
 * bon_travail_item findUniqueOrThrow
 */
export type bon_travail_itemFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * Filter, which bon_travail_item to fetch.
   */
  where: Prisma.bon_travail_itemWhereUniqueInput
}

/**
 * bon_travail_item findFirst
 */
export type bon_travail_itemFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * Filter, which bon_travail_item to fetch.
   */
  where?: Prisma.bon_travail_itemWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of bon_travail_items to fetch.
   */
  orderBy?: Prisma.bon_travail_itemOrderByWithRelationInput | Prisma.bon_travail_itemOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for searching for bon_travail_items.
   */
  cursor?: Prisma.bon_travail_itemWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` bon_travail_items 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` bon_travail_items.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
   * 
   * Filter by unique combinations of bon_travail_items.
   */
  distinct?: Prisma.Bon_travail_itemScalarFieldEnum | Prisma.Bon_travail_itemScalarFieldEnum[]
}

/**
 * bon_travail_item findFirstOrThrow
 */
export type bon_travail_itemFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * Filter, which bon_travail_item to fetch.
   */
  where?: Prisma.bon_travail_itemWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of bon_travail_items to fetch.
   */
  orderBy?: Prisma.bon_travail_itemOrderByWithRelationInput | Prisma.bon_travail_itemOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for searching for bon_travail_items.
   */
  cursor?: Prisma.bon_travail_itemWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` bon_travail_items 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` bon_travail_items.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
   * 
   * Filter by unique combinations of bon_travail_items.
   */
  distinct?: Prisma.Bon_travail_itemScalarFieldEnum | Prisma.Bon_travail_itemScalarFieldEnum[]
}

/**
 * bon_travail_item findMany
 */
export type bon_travail_itemFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * Filter, which bon_travail_items to fetch.
   */
  where?: Prisma.bon_travail_itemWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of bon_travail_items to fetch.
   */
  orderBy?: Prisma.bon_travail_itemOrderByWithRelationInput | Prisma.bon_travail_itemOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for listing bon_travail_items.
   */
  cursor?: Prisma.bon_travail_itemWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` bon_travail_items 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` bon_travail_items.
   */
  skip?: number
  distinct?: Prisma.Bon_travail_itemScalarFieldEnum | Prisma.Bon_travail_itemScalarFieldEnum[]
}

/**
 * bon_travail_item create
 */
export type bon_travail_itemCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * The data needed to create a bon_travail_item.
   */
  data: Prisma.XOR<Prisma.bon_travail_itemCreateInput, Prisma.bon_travail_itemUncheckedCreateInput>
}

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

/**
 * bon_travail_item update
 */
export type bon_travail_itemUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * The data needed to update a bon_travail_item.
   */
  data: Prisma.XOR<Prisma.bon_travail_itemUpdateInput, Prisma.bon_travail_itemUncheckedUpdateInput>
  /**
   * Choose, which bon_travail_item to update.
   */
  where: Prisma.bon_travail_itemWhereUniqueInput
}

/**
 * bon_travail_item updateMany
 */
export type bon_travail_itemUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * The data used to update bon_travail_items.
   */
  data: Prisma.XOR<Prisma.bon_travail_itemUpdateManyMutationInput, Prisma.bon_travail_itemUncheckedUpdateManyInput>
  /**
   * Filter which bon_travail_items to update
   */
  where?: Prisma.bon_travail_itemWhereInput
  /**
   * Limit how many bon_travail_items to update.
   */
  limit?: number
}

/**
 * bon_travail_item upsert
 */
export type bon_travail_itemUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * The filter to search for the bon_travail_item to update in case it exists.
   */
  where: Prisma.bon_travail_itemWhereUniqueInput
  /**
   * In case the bon_travail_item found by the `where` argument doesn't exist, create a new bon_travail_item with this data.
   */
  create: Prisma.XOR<Prisma.bon_travail_itemCreateInput, Prisma.bon_travail_itemUncheckedCreateInput>
  /**
   * In case the bon_travail_item was found with the provided `where` argument, update it with this data.
   */
  update: Prisma.XOR<Prisma.bon_travail_itemUpdateInput, Prisma.bon_travail_itemUncheckedUpdateInput>
}

/**
 * bon_travail_item delete
 */
export type bon_travail_itemDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
  /**
   * Filter which bon_travail_item to delete.
   */
  where: Prisma.bon_travail_itemWhereUniqueInput
}

/**
 * bon_travail_item deleteMany
 */
export type bon_travail_itemDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Filter which bon_travail_items to delete
   */
  where?: Prisma.bon_travail_itemWhereInput
  /**
   * Limit how many bon_travail_items to delete.
   */
  limit?: number
}

/**
 * bon_travail_item without action
 */
export type bon_travail_itemDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the bon_travail_item
   */
  select?: Prisma.bon_travail_itemSelect<ExtArgs> | null
  /**
   * Omit specific fields from the bon_travail_item
   */
  omit?: Prisma.bon_travail_itemOmit<ExtArgs> | null
}
