iboard/generated/prisma/models/SowInventory.ts
cheney 4c7f600a6b
Some checks failed
Docker Build and Push / build-image (push) Failing after 6m27s
增加数据库
2026-04-09 22:07:23 +08:00

1091 lines
38 KiB
TypeScript

/* !!! This is code generated by Prisma. Do not edit directly. !!! */
/* eslint-disable */
// biome-ignore-all lint: generated file
// @ts-nocheck
/*
* This file exports the `SowInventory` 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.ts"
import type * as Prisma from "../internal/prismaNamespace.ts"
/**
* Model SowInventory
*
*/
export type SowInventoryModel = runtime.Types.Result.DefaultSelection<Prisma.$SowInventoryPayload>
export type AggregateSowInventory = {
_count: SowInventoryCountAggregateOutputType | null
_avg: SowInventoryAvgAggregateOutputType | null
_sum: SowInventorySumAggregateOutputType | null
_min: SowInventoryMinAggregateOutputType | null
_max: SowInventoryMaxAggregateOutputType | null
}
export type SowInventoryAvgAggregateOutputType = {
id: number | null
inventory: number | null
}
export type SowInventorySumAggregateOutputType = {
id: number | null
inventory: number | null
}
export type SowInventoryMinAggregateOutputType = {
id: number | null
month: string | null
inventory: number | null
createdAt: Date | null
updatedAt: Date | null
}
export type SowInventoryMaxAggregateOutputType = {
id: number | null
month: string | null
inventory: number | null
createdAt: Date | null
updatedAt: Date | null
}
export type SowInventoryCountAggregateOutputType = {
id: number
month: number
inventory: number
createdAt: number
updatedAt: number
_all: number
}
export type SowInventoryAvgAggregateInputType = {
id?: true
inventory?: true
}
export type SowInventorySumAggregateInputType = {
id?: true
inventory?: true
}
export type SowInventoryMinAggregateInputType = {
id?: true
month?: true
inventory?: true
createdAt?: true
updatedAt?: true
}
export type SowInventoryMaxAggregateInputType = {
id?: true
month?: true
inventory?: true
createdAt?: true
updatedAt?: true
}
export type SowInventoryCountAggregateInputType = {
id?: true
month?: true
inventory?: true
createdAt?: true
updatedAt?: true
_all?: true
}
export type SowInventoryAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Filter which SowInventory to aggregate.
*/
where?: Prisma.SowInventoryWhereInput
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
*
* Determine the order of SowInventories to fetch.
*/
orderBy?: Prisma.SowInventoryOrderByWithRelationInput | Prisma.SowInventoryOrderByWithRelationInput[]
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
*
* Sets the start position
*/
cursor?: Prisma.SowInventoryWhereUniqueInput
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
*
* Take `±n` SowInventories 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` SowInventories.
*/
skip?: number
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
*
* Count returned SowInventories
**/
_count?: true | SowInventoryCountAggregateInputType
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
*
* Select which fields to average
**/
_avg?: SowInventoryAvgAggregateInputType
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
*
* Select which fields to sum
**/
_sum?: SowInventorySumAggregateInputType
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
*
* Select which fields to find the minimum value
**/
_min?: SowInventoryMinAggregateInputType
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
*
* Select which fields to find the maximum value
**/
_max?: SowInventoryMaxAggregateInputType
}
export type GetSowInventoryAggregateType<T extends SowInventoryAggregateArgs> = {
[P in keyof T & keyof AggregateSowInventory]: P extends '_count' | 'count'
? T[P] extends true
? number
: Prisma.GetScalarType<T[P], AggregateSowInventory[P]>
: Prisma.GetScalarType<T[P], AggregateSowInventory[P]>
}
export type SowInventoryGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
where?: Prisma.SowInventoryWhereInput
orderBy?: Prisma.SowInventoryOrderByWithAggregationInput | Prisma.SowInventoryOrderByWithAggregationInput[]
by: Prisma.SowInventoryScalarFieldEnum[] | Prisma.SowInventoryScalarFieldEnum
having?: Prisma.SowInventoryScalarWhereWithAggregatesInput
take?: number
skip?: number
_count?: SowInventoryCountAggregateInputType | true
_avg?: SowInventoryAvgAggregateInputType
_sum?: SowInventorySumAggregateInputType
_min?: SowInventoryMinAggregateInputType
_max?: SowInventoryMaxAggregateInputType
}
export type SowInventoryGroupByOutputType = {
id: number
month: string
inventory: number
createdAt: Date
updatedAt: Date
_count: SowInventoryCountAggregateOutputType | null
_avg: SowInventoryAvgAggregateOutputType | null
_sum: SowInventorySumAggregateOutputType | null
_min: SowInventoryMinAggregateOutputType | null
_max: SowInventoryMaxAggregateOutputType | null
}
export type GetSowInventoryGroupByPayload<T extends SowInventoryGroupByArgs> = Prisma.PrismaPromise<
Array<
Prisma.PickEnumerable<SowInventoryGroupByOutputType, T['by']> &
{
[P in ((keyof T) & (keyof SowInventoryGroupByOutputType))]: P extends '_count'
? T[P] extends boolean
? number
: Prisma.GetScalarType<T[P], SowInventoryGroupByOutputType[P]>
: Prisma.GetScalarType<T[P], SowInventoryGroupByOutputType[P]>
}
>
>
export type SowInventoryWhereInput = {
AND?: Prisma.SowInventoryWhereInput | Prisma.SowInventoryWhereInput[]
OR?: Prisma.SowInventoryWhereInput[]
NOT?: Prisma.SowInventoryWhereInput | Prisma.SowInventoryWhereInput[]
id?: Prisma.IntFilter<"SowInventory"> | number
month?: Prisma.StringFilter<"SowInventory"> | string
inventory?: Prisma.IntFilter<"SowInventory"> | number
createdAt?: Prisma.DateTimeFilter<"SowInventory"> | Date | string
updatedAt?: Prisma.DateTimeFilter<"SowInventory"> | Date | string
}
export type SowInventoryOrderByWithRelationInput = {
id?: Prisma.SortOrder
month?: Prisma.SortOrder
inventory?: Prisma.SortOrder
createdAt?: Prisma.SortOrder
updatedAt?: Prisma.SortOrder
_relevance?: Prisma.SowInventoryOrderByRelevanceInput
}
export type SowInventoryWhereUniqueInput = Prisma.AtLeast<{
id?: number
month?: string
AND?: Prisma.SowInventoryWhereInput | Prisma.SowInventoryWhereInput[]
OR?: Prisma.SowInventoryWhereInput[]
NOT?: Prisma.SowInventoryWhereInput | Prisma.SowInventoryWhereInput[]
inventory?: Prisma.IntFilter<"SowInventory"> | number
createdAt?: Prisma.DateTimeFilter<"SowInventory"> | Date | string
updatedAt?: Prisma.DateTimeFilter<"SowInventory"> | Date | string
}, "id" | "month">
export type SowInventoryOrderByWithAggregationInput = {
id?: Prisma.SortOrder
month?: Prisma.SortOrder
inventory?: Prisma.SortOrder
createdAt?: Prisma.SortOrder
updatedAt?: Prisma.SortOrder
_count?: Prisma.SowInventoryCountOrderByAggregateInput
_avg?: Prisma.SowInventoryAvgOrderByAggregateInput
_max?: Prisma.SowInventoryMaxOrderByAggregateInput
_min?: Prisma.SowInventoryMinOrderByAggregateInput
_sum?: Prisma.SowInventorySumOrderByAggregateInput
}
export type SowInventoryScalarWhereWithAggregatesInput = {
AND?: Prisma.SowInventoryScalarWhereWithAggregatesInput | Prisma.SowInventoryScalarWhereWithAggregatesInput[]
OR?: Prisma.SowInventoryScalarWhereWithAggregatesInput[]
NOT?: Prisma.SowInventoryScalarWhereWithAggregatesInput | Prisma.SowInventoryScalarWhereWithAggregatesInput[]
id?: Prisma.IntWithAggregatesFilter<"SowInventory"> | number
month?: Prisma.StringWithAggregatesFilter<"SowInventory"> | string
inventory?: Prisma.IntWithAggregatesFilter<"SowInventory"> | number
createdAt?: Prisma.DateTimeWithAggregatesFilter<"SowInventory"> | Date | string
updatedAt?: Prisma.DateTimeWithAggregatesFilter<"SowInventory"> | Date | string
}
export type SowInventoryCreateInput = {
month: string
inventory: number
createdAt?: Date | string
updatedAt?: Date | string
}
export type SowInventoryUncheckedCreateInput = {
id?: number
month: string
inventory: number
createdAt?: Date | string
updatedAt?: Date | string
}
export type SowInventoryUpdateInput = {
month?: Prisma.StringFieldUpdateOperationsInput | string
inventory?: Prisma.IntFieldUpdateOperationsInput | number
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
}
export type SowInventoryUncheckedUpdateInput = {
id?: Prisma.IntFieldUpdateOperationsInput | number
month?: Prisma.StringFieldUpdateOperationsInput | string
inventory?: Prisma.IntFieldUpdateOperationsInput | number
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
}
export type SowInventoryCreateManyInput = {
id?: number
month: string
inventory: number
createdAt?: Date | string
updatedAt?: Date | string
}
export type SowInventoryUpdateManyMutationInput = {
month?: Prisma.StringFieldUpdateOperationsInput | string
inventory?: Prisma.IntFieldUpdateOperationsInput | number
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
}
export type SowInventoryUncheckedUpdateManyInput = {
id?: Prisma.IntFieldUpdateOperationsInput | number
month?: Prisma.StringFieldUpdateOperationsInput | string
inventory?: Prisma.IntFieldUpdateOperationsInput | number
createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
}
export type SowInventoryOrderByRelevanceInput = {
fields: Prisma.SowInventoryOrderByRelevanceFieldEnum | Prisma.SowInventoryOrderByRelevanceFieldEnum[]
sort: Prisma.SortOrder
search: string
}
export type SowInventoryCountOrderByAggregateInput = {
id?: Prisma.SortOrder
month?: Prisma.SortOrder
inventory?: Prisma.SortOrder
createdAt?: Prisma.SortOrder
updatedAt?: Prisma.SortOrder
}
export type SowInventoryAvgOrderByAggregateInput = {
id?: Prisma.SortOrder
inventory?: Prisma.SortOrder
}
export type SowInventoryMaxOrderByAggregateInput = {
id?: Prisma.SortOrder
month?: Prisma.SortOrder
inventory?: Prisma.SortOrder
createdAt?: Prisma.SortOrder
updatedAt?: Prisma.SortOrder
}
export type SowInventoryMinOrderByAggregateInput = {
id?: Prisma.SortOrder
month?: Prisma.SortOrder
inventory?: Prisma.SortOrder
createdAt?: Prisma.SortOrder
updatedAt?: Prisma.SortOrder
}
export type SowInventorySumOrderByAggregateInput = {
id?: Prisma.SortOrder
inventory?: Prisma.SortOrder
}
export type SowInventorySelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
id?: boolean
month?: boolean
inventory?: boolean
createdAt?: boolean
updatedAt?: boolean
}, ExtArgs["result"]["sowInventory"]>
export type SowInventorySelectScalar = {
id?: boolean
month?: boolean
inventory?: boolean
createdAt?: boolean
updatedAt?: boolean
}
export type SowInventoryOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "month" | "inventory" | "createdAt" | "updatedAt", ExtArgs["result"]["sowInventory"]>
export type $SowInventoryPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
name: "SowInventory"
objects: {}
scalars: runtime.Types.Extensions.GetPayloadResult<{
id: number
month: string
inventory: number
createdAt: Date
updatedAt: Date
}, ExtArgs["result"]["sowInventory"]>
composites: {}
}
export type SowInventoryGetPayload<S extends boolean | null | undefined | SowInventoryDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload, S>
export type SowInventoryCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> =
Omit<SowInventoryFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
select?: SowInventoryCountAggregateInputType | true
}
export interface SowInventoryDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
[K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['SowInventory'], meta: { name: 'SowInventory' } }
/**
* Find zero or one SowInventory that matches the filter.
* @param {SowInventoryFindUniqueArgs} args - Arguments to find a SowInventory
* @example
* // Get one SowInventory
* const sowInventory = await prisma.sowInventory.findUnique({
* where: {
* // ... provide filter here
* }
* })
*/
findUnique<T extends SowInventoryFindUniqueArgs>(args: Prisma.SelectSubset<T, SowInventoryFindUniqueArgs<ExtArgs>>): Prisma.Prisma__SowInventoryClient<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
/**
* Find one SowInventory that matches the filter or throw an error with `error.code='P2025'`
* if no matches were found.
* @param {SowInventoryFindUniqueOrThrowArgs} args - Arguments to find a SowInventory
* @example
* // Get one SowInventory
* const sowInventory = await prisma.sowInventory.findUniqueOrThrow({
* where: {
* // ... provide filter here
* }
* })
*/
findUniqueOrThrow<T extends SowInventoryFindUniqueOrThrowArgs>(args: Prisma.SelectSubset<T, SowInventoryFindUniqueOrThrowArgs<ExtArgs>>): Prisma.Prisma__SowInventoryClient<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
/**
* Find the first SowInventory 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 {SowInventoryFindFirstArgs} args - Arguments to find a SowInventory
* @example
* // Get one SowInventory
* const sowInventory = await prisma.sowInventory.findFirst({
* where: {
* // ... provide filter here
* }
* })
*/
findFirst<T extends SowInventoryFindFirstArgs>(args?: Prisma.SelectSubset<T, SowInventoryFindFirstArgs<ExtArgs>>): Prisma.Prisma__SowInventoryClient<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
/**
* Find the first SowInventory 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 {SowInventoryFindFirstOrThrowArgs} args - Arguments to find a SowInventory
* @example
* // Get one SowInventory
* const sowInventory = await prisma.sowInventory.findFirstOrThrow({
* where: {
* // ... provide filter here
* }
* })
*/
findFirstOrThrow<T extends SowInventoryFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, SowInventoryFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__SowInventoryClient<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
/**
* Find zero or more SowInventories 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 {SowInventoryFindManyArgs} args - Arguments to filter and select certain fields only.
* @example
* // Get all SowInventories
* const sowInventories = await prisma.sowInventory.findMany()
*
* // Get first 10 SowInventories
* const sowInventories = await prisma.sowInventory.findMany({ take: 10 })
*
* // Only select the `id`
* const sowInventoryWithIdOnly = await prisma.sowInventory.findMany({ select: { id: true } })
*
*/
findMany<T extends SowInventoryFindManyArgs>(args?: Prisma.SelectSubset<T, SowInventoryFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>
/**
* Create a SowInventory.
* @param {SowInventoryCreateArgs} args - Arguments to create a SowInventory.
* @example
* // Create one SowInventory
* const SowInventory = await prisma.sowInventory.create({
* data: {
* // ... data to create a SowInventory
* }
* })
*
*/
create<T extends SowInventoryCreateArgs>(args: Prisma.SelectSubset<T, SowInventoryCreateArgs<ExtArgs>>): Prisma.Prisma__SowInventoryClient<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
/**
* Create many SowInventories.
* @param {SowInventoryCreateManyArgs} args - Arguments to create many SowInventories.
* @example
* // Create many SowInventories
* const sowInventory = await prisma.sowInventory.createMany({
* data: [
* // ... provide data here
* ]
* })
*
*/
createMany<T extends SowInventoryCreateManyArgs>(args?: Prisma.SelectSubset<T, SowInventoryCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
/**
* Delete a SowInventory.
* @param {SowInventoryDeleteArgs} args - Arguments to delete one SowInventory.
* @example
* // Delete one SowInventory
* const SowInventory = await prisma.sowInventory.delete({
* where: {
* // ... filter to delete one SowInventory
* }
* })
*
*/
delete<T extends SowInventoryDeleteArgs>(args: Prisma.SelectSubset<T, SowInventoryDeleteArgs<ExtArgs>>): Prisma.Prisma__SowInventoryClient<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
/**
* Update one SowInventory.
* @param {SowInventoryUpdateArgs} args - Arguments to update one SowInventory.
* @example
* // Update one SowInventory
* const sowInventory = await prisma.sowInventory.update({
* where: {
* // ... provide filter here
* },
* data: {
* // ... provide data here
* }
* })
*
*/
update<T extends SowInventoryUpdateArgs>(args: Prisma.SelectSubset<T, SowInventoryUpdateArgs<ExtArgs>>): Prisma.Prisma__SowInventoryClient<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
/**
* Delete zero or more SowInventories.
* @param {SowInventoryDeleteManyArgs} args - Arguments to filter SowInventories to delete.
* @example
* // Delete a few SowInventories
* const { count } = await prisma.sowInventory.deleteMany({
* where: {
* // ... provide filter here
* }
* })
*
*/
deleteMany<T extends SowInventoryDeleteManyArgs>(args?: Prisma.SelectSubset<T, SowInventoryDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
/**
* Update zero or more SowInventories.
* Note, that providing `undefined` is treated as the value not being there.
* Read more here: https://pris.ly/d/null-undefined
* @param {SowInventoryUpdateManyArgs} args - Arguments to update one or more rows.
* @example
* // Update many SowInventories
* const sowInventory = await prisma.sowInventory.updateMany({
* where: {
* // ... provide filter here
* },
* data: {
* // ... provide data here
* }
* })
*
*/
updateMany<T extends SowInventoryUpdateManyArgs>(args: Prisma.SelectSubset<T, SowInventoryUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
/**
* Create or update one SowInventory.
* @param {SowInventoryUpsertArgs} args - Arguments to update or create a SowInventory.
* @example
* // Update or create a SowInventory
* const sowInventory = await prisma.sowInventory.upsert({
* create: {
* // ... data to create a SowInventory
* },
* update: {
* // ... in case it already exists, update
* },
* where: {
* // ... the filter for the SowInventory we want to update
* }
* })
*/
upsert<T extends SowInventoryUpsertArgs>(args: Prisma.SelectSubset<T, SowInventoryUpsertArgs<ExtArgs>>): Prisma.Prisma__SowInventoryClient<runtime.Types.Result.GetResult<Prisma.$SowInventoryPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
/**
* Count the number of SowInventories.
* Note, that providing `undefined` is treated as the value not being there.
* Read more here: https://pris.ly/d/null-undefined
* @param {SowInventoryCountArgs} args - Arguments to filter SowInventories to count.
* @example
* // Count the number of SowInventories
* const count = await prisma.sowInventory.count({
* where: {
* // ... the filter for the SowInventories we want to count
* }
* })
**/
count<T extends SowInventoryCountArgs>(
args?: Prisma.Subset<T, SowInventoryCountArgs>,
): Prisma.PrismaPromise<
T extends runtime.Types.Utils.Record<'select', any>
? T['select'] extends true
? number
: Prisma.GetScalarType<T['select'], SowInventoryCountAggregateOutputType>
: number
>
/**
* Allows you to perform aggregations operations on a SowInventory.
* Note, that providing `undefined` is treated as the value not being there.
* Read more here: https://pris.ly/d/null-undefined
* @param {SowInventoryAggregateArgs} 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 SowInventoryAggregateArgs>(args: Prisma.Subset<T, SowInventoryAggregateArgs>): Prisma.PrismaPromise<GetSowInventoryAggregateType<T>>
/**
* Group by SowInventory.
* Note, that providing `undefined` is treated as the value not being there.
* Read more here: https://pris.ly/d/null-undefined
* @param {SowInventoryGroupByArgs} 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 SowInventoryGroupByArgs,
HasSelectOrTake extends Prisma.Or<
Prisma.Extends<'skip', Prisma.Keys<T>>,
Prisma.Extends<'take', Prisma.Keys<T>>
>,
OrderByArg extends Prisma.True extends HasSelectOrTake
? { orderBy: SowInventoryGroupByArgs['orderBy'] }
: { orderBy?: SowInventoryGroupByArgs['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, SowInventoryGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetSowInventoryGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
* Fields of the SowInventory model
*/
readonly fields: SowInventoryFieldRefs;
}
/**
* The delegate class that acts as a "Promise-like" for SowInventory.
* 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__SowInventoryClient<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 SowInventory model
*/
export interface SowInventoryFieldRefs {
readonly id: Prisma.FieldRef<"SowInventory", 'Int'>
readonly month: Prisma.FieldRef<"SowInventory", 'String'>
readonly inventory: Prisma.FieldRef<"SowInventory", 'Int'>
readonly createdAt: Prisma.FieldRef<"SowInventory", 'DateTime'>
readonly updatedAt: Prisma.FieldRef<"SowInventory", 'DateTime'>
}
// Custom InputTypes
/**
* SowInventory findUnique
*/
export type SowInventoryFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* Filter, which SowInventory to fetch.
*/
where: Prisma.SowInventoryWhereUniqueInput
}
/**
* SowInventory findUniqueOrThrow
*/
export type SowInventoryFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* Filter, which SowInventory to fetch.
*/
where: Prisma.SowInventoryWhereUniqueInput
}
/**
* SowInventory findFirst
*/
export type SowInventoryFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* Filter, which SowInventory to fetch.
*/
where?: Prisma.SowInventoryWhereInput
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
*
* Determine the order of SowInventories to fetch.
*/
orderBy?: Prisma.SowInventoryOrderByWithRelationInput | Prisma.SowInventoryOrderByWithRelationInput[]
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
*
* Sets the position for searching for SowInventories.
*/
cursor?: Prisma.SowInventoryWhereUniqueInput
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
*
* Take `±n` SowInventories 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` SowInventories.
*/
skip?: number
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
*
* Filter by unique combinations of SowInventories.
*/
distinct?: Prisma.SowInventoryScalarFieldEnum | Prisma.SowInventoryScalarFieldEnum[]
}
/**
* SowInventory findFirstOrThrow
*/
export type SowInventoryFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* Filter, which SowInventory to fetch.
*/
where?: Prisma.SowInventoryWhereInput
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
*
* Determine the order of SowInventories to fetch.
*/
orderBy?: Prisma.SowInventoryOrderByWithRelationInput | Prisma.SowInventoryOrderByWithRelationInput[]
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
*
* Sets the position for searching for SowInventories.
*/
cursor?: Prisma.SowInventoryWhereUniqueInput
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
*
* Take `±n` SowInventories 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` SowInventories.
*/
skip?: number
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
*
* Filter by unique combinations of SowInventories.
*/
distinct?: Prisma.SowInventoryScalarFieldEnum | Prisma.SowInventoryScalarFieldEnum[]
}
/**
* SowInventory findMany
*/
export type SowInventoryFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* Filter, which SowInventories to fetch.
*/
where?: Prisma.SowInventoryWhereInput
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
*
* Determine the order of SowInventories to fetch.
*/
orderBy?: Prisma.SowInventoryOrderByWithRelationInput | Prisma.SowInventoryOrderByWithRelationInput[]
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
*
* Sets the position for listing SowInventories.
*/
cursor?: Prisma.SowInventoryWhereUniqueInput
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
*
* Take `±n` SowInventories 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` SowInventories.
*/
skip?: number
/**
* {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
*
* Filter by unique combinations of SowInventories.
*/
distinct?: Prisma.SowInventoryScalarFieldEnum | Prisma.SowInventoryScalarFieldEnum[]
}
/**
* SowInventory create
*/
export type SowInventoryCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* The data needed to create a SowInventory.
*/
data: Prisma.XOR<Prisma.SowInventoryCreateInput, Prisma.SowInventoryUncheckedCreateInput>
}
/**
* SowInventory createMany
*/
export type SowInventoryCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* The data used to create many SowInventories.
*/
data: Prisma.SowInventoryCreateManyInput | Prisma.SowInventoryCreateManyInput[]
skipDuplicates?: boolean
}
/**
* SowInventory update
*/
export type SowInventoryUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* The data needed to update a SowInventory.
*/
data: Prisma.XOR<Prisma.SowInventoryUpdateInput, Prisma.SowInventoryUncheckedUpdateInput>
/**
* Choose, which SowInventory to update.
*/
where: Prisma.SowInventoryWhereUniqueInput
}
/**
* SowInventory updateMany
*/
export type SowInventoryUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* The data used to update SowInventories.
*/
data: Prisma.XOR<Prisma.SowInventoryUpdateManyMutationInput, Prisma.SowInventoryUncheckedUpdateManyInput>
/**
* Filter which SowInventories to update
*/
where?: Prisma.SowInventoryWhereInput
/**
* Limit how many SowInventories to update.
*/
limit?: number
}
/**
* SowInventory upsert
*/
export type SowInventoryUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* The filter to search for the SowInventory to update in case it exists.
*/
where: Prisma.SowInventoryWhereUniqueInput
/**
* In case the SowInventory found by the `where` argument doesn't exist, create a new SowInventory with this data.
*/
create: Prisma.XOR<Prisma.SowInventoryCreateInput, Prisma.SowInventoryUncheckedCreateInput>
/**
* In case the SowInventory was found with the provided `where` argument, update it with this data.
*/
update: Prisma.XOR<Prisma.SowInventoryUpdateInput, Prisma.SowInventoryUncheckedUpdateInput>
}
/**
* SowInventory delete
*/
export type SowInventoryDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
/**
* Filter which SowInventory to delete.
*/
where: Prisma.SowInventoryWhereUniqueInput
}
/**
* SowInventory deleteMany
*/
export type SowInventoryDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Filter which SowInventories to delete
*/
where?: Prisma.SowInventoryWhereInput
/**
* Limit how many SowInventories to delete.
*/
limit?: number
}
/**
* SowInventory without action
*/
export type SowInventoryDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
/**
* Select specific fields to fetch from the SowInventory
*/
select?: Prisma.SowInventorySelect<ExtArgs> | null
/**
* Omit specific fields from the SowInventory
*/
omit?: Prisma.SowInventoryOmit<ExtArgs> | null
}