add booking and payment schema
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -391,7 +391,9 @@ export const ModelName = {
|
||||
Trip: 'Trip',
|
||||
TripReview: 'TripReview',
|
||||
TripImage: 'TripImage',
|
||||
TripParticipant: 'TripParticipant'
|
||||
TripParticipant: 'TripParticipant',
|
||||
Booking: 'Booking',
|
||||
Payment: 'Payment'
|
||||
} as const
|
||||
|
||||
export type ModelName = (typeof ModelName)[keyof typeof ModelName]
|
||||
@@ -407,7 +409,7 @@ export type TypeMap<ExtArgs extends runtime.Types.Extensions.InternalArgs = runt
|
||||
omit: GlobalOmitOptions
|
||||
}
|
||||
meta: {
|
||||
modelProps: "user" | "userProfile" | "account" | "organizerVerification" | "trip" | "tripReview" | "tripImage" | "tripParticipant"
|
||||
modelProps: "user" | "userProfile" | "account" | "organizerVerification" | "trip" | "tripReview" | "tripImage" | "tripParticipant" | "booking" | "payment"
|
||||
txIsolationLevel: TransactionIsolationLevel
|
||||
}
|
||||
model: {
|
||||
@@ -1003,6 +1005,154 @@ export type TypeMap<ExtArgs extends runtime.Types.Extensions.InternalArgs = runt
|
||||
}
|
||||
}
|
||||
}
|
||||
Booking: {
|
||||
payload: Prisma.$BookingPayload<ExtArgs>
|
||||
fields: Prisma.BookingFieldRefs
|
||||
operations: {
|
||||
findUnique: {
|
||||
args: Prisma.BookingFindUniqueArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload> | null
|
||||
}
|
||||
findUniqueOrThrow: {
|
||||
args: Prisma.BookingFindUniqueOrThrowArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>
|
||||
}
|
||||
findFirst: {
|
||||
args: Prisma.BookingFindFirstArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload> | null
|
||||
}
|
||||
findFirstOrThrow: {
|
||||
args: Prisma.BookingFindFirstOrThrowArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>
|
||||
}
|
||||
findMany: {
|
||||
args: Prisma.BookingFindManyArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>[]
|
||||
}
|
||||
create: {
|
||||
args: Prisma.BookingCreateArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>
|
||||
}
|
||||
createMany: {
|
||||
args: Prisma.BookingCreateManyArgs<ExtArgs>
|
||||
result: BatchPayload
|
||||
}
|
||||
createManyAndReturn: {
|
||||
args: Prisma.BookingCreateManyAndReturnArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>[]
|
||||
}
|
||||
delete: {
|
||||
args: Prisma.BookingDeleteArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>
|
||||
}
|
||||
update: {
|
||||
args: Prisma.BookingUpdateArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>
|
||||
}
|
||||
deleteMany: {
|
||||
args: Prisma.BookingDeleteManyArgs<ExtArgs>
|
||||
result: BatchPayload
|
||||
}
|
||||
updateMany: {
|
||||
args: Prisma.BookingUpdateManyArgs<ExtArgs>
|
||||
result: BatchPayload
|
||||
}
|
||||
updateManyAndReturn: {
|
||||
args: Prisma.BookingUpdateManyAndReturnArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>[]
|
||||
}
|
||||
upsert: {
|
||||
args: Prisma.BookingUpsertArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$BookingPayload>
|
||||
}
|
||||
aggregate: {
|
||||
args: Prisma.BookingAggregateArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.Optional<Prisma.AggregateBooking>
|
||||
}
|
||||
groupBy: {
|
||||
args: Prisma.BookingGroupByArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.Optional<Prisma.BookingGroupByOutputType>[]
|
||||
}
|
||||
count: {
|
||||
args: Prisma.BookingCountArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.Optional<Prisma.BookingCountAggregateOutputType> | number
|
||||
}
|
||||
}
|
||||
}
|
||||
Payment: {
|
||||
payload: Prisma.$PaymentPayload<ExtArgs>
|
||||
fields: Prisma.PaymentFieldRefs
|
||||
operations: {
|
||||
findUnique: {
|
||||
args: Prisma.PaymentFindUniqueArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload> | null
|
||||
}
|
||||
findUniqueOrThrow: {
|
||||
args: Prisma.PaymentFindUniqueOrThrowArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>
|
||||
}
|
||||
findFirst: {
|
||||
args: Prisma.PaymentFindFirstArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload> | null
|
||||
}
|
||||
findFirstOrThrow: {
|
||||
args: Prisma.PaymentFindFirstOrThrowArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>
|
||||
}
|
||||
findMany: {
|
||||
args: Prisma.PaymentFindManyArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>[]
|
||||
}
|
||||
create: {
|
||||
args: Prisma.PaymentCreateArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>
|
||||
}
|
||||
createMany: {
|
||||
args: Prisma.PaymentCreateManyArgs<ExtArgs>
|
||||
result: BatchPayload
|
||||
}
|
||||
createManyAndReturn: {
|
||||
args: Prisma.PaymentCreateManyAndReturnArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>[]
|
||||
}
|
||||
delete: {
|
||||
args: Prisma.PaymentDeleteArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>
|
||||
}
|
||||
update: {
|
||||
args: Prisma.PaymentUpdateArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>
|
||||
}
|
||||
deleteMany: {
|
||||
args: Prisma.PaymentDeleteManyArgs<ExtArgs>
|
||||
result: BatchPayload
|
||||
}
|
||||
updateMany: {
|
||||
args: Prisma.PaymentUpdateManyArgs<ExtArgs>
|
||||
result: BatchPayload
|
||||
}
|
||||
updateManyAndReturn: {
|
||||
args: Prisma.PaymentUpdateManyAndReturnArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>[]
|
||||
}
|
||||
upsert: {
|
||||
args: Prisma.PaymentUpsertArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.PayloadToResult<Prisma.$PaymentPayload>
|
||||
}
|
||||
aggregate: {
|
||||
args: Prisma.PaymentAggregateArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.Optional<Prisma.AggregatePayment>
|
||||
}
|
||||
groupBy: {
|
||||
args: Prisma.PaymentGroupByArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.Optional<Prisma.PaymentGroupByOutputType>[]
|
||||
}
|
||||
count: {
|
||||
args: Prisma.PaymentCountArgs<ExtArgs>
|
||||
result: runtime.Types.Utils.Optional<Prisma.PaymentCountAggregateOutputType> | number
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} & {
|
||||
other: {
|
||||
@@ -1178,6 +1328,43 @@ export const TripParticipantScalarFieldEnum = {
|
||||
export type TripParticipantScalarFieldEnum = (typeof TripParticipantScalarFieldEnum)[keyof typeof TripParticipantScalarFieldEnum]
|
||||
|
||||
|
||||
export const BookingScalarFieldEnum = {
|
||||
id: 'id',
|
||||
tripId: 'tripId',
|
||||
userId: 'userId',
|
||||
participantId: 'participantId',
|
||||
amount: 'amount',
|
||||
currency: 'currency',
|
||||
status: 'status',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt'
|
||||
} as const
|
||||
|
||||
export type BookingScalarFieldEnum = (typeof BookingScalarFieldEnum)[keyof typeof BookingScalarFieldEnum]
|
||||
|
||||
|
||||
export const PaymentScalarFieldEnum = {
|
||||
id: 'id',
|
||||
bookingId: 'bookingId',
|
||||
provider: 'provider',
|
||||
externalOrderId: 'externalOrderId',
|
||||
externalTxId: 'externalTxId',
|
||||
method: 'method',
|
||||
amount: 'amount',
|
||||
status: 'status',
|
||||
rawCallback: 'rawCallback',
|
||||
snapToken: 'snapToken',
|
||||
expiresAt: 'expiresAt',
|
||||
paidAt: 'paidAt',
|
||||
failedAt: 'failedAt',
|
||||
rejectionReason: 'rejectionReason',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt'
|
||||
} as const
|
||||
|
||||
export type PaymentScalarFieldEnum = (typeof PaymentScalarFieldEnum)[keyof typeof PaymentScalarFieldEnum]
|
||||
|
||||
|
||||
export const SortOrder = {
|
||||
asc: 'asc',
|
||||
desc: 'desc'
|
||||
@@ -1186,6 +1373,14 @@ export const SortOrder = {
|
||||
export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder]
|
||||
|
||||
|
||||
export const NullableJsonNullValueInput = {
|
||||
DbNull: DbNull,
|
||||
JsonNull: JsonNull
|
||||
} as const
|
||||
|
||||
export type NullableJsonNullValueInput = (typeof NullableJsonNullValueInput)[keyof typeof NullableJsonNullValueInput]
|
||||
|
||||
|
||||
export const QueryMode = {
|
||||
default: 'default',
|
||||
insensitive: 'insensitive'
|
||||
@@ -1202,6 +1397,15 @@ export const NullsOrder = {
|
||||
export type NullsOrder = (typeof NullsOrder)[keyof typeof NullsOrder]
|
||||
|
||||
|
||||
export const JsonNullValueFilter = {
|
||||
DbNull: DbNull,
|
||||
JsonNull: JsonNull,
|
||||
AnyNull: AnyNull
|
||||
} as const
|
||||
|
||||
export type JsonNullValueFilter = (typeof JsonNullValueFilter)[keyof typeof JsonNullValueFilter]
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Field references
|
||||
@@ -1327,6 +1531,62 @@ export type ListEnumParticipantStatusFieldRefInput<$PrismaModel> = FieldRefInput
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'BookingStatus'
|
||||
*/
|
||||
export type EnumBookingStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'BookingStatus'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'BookingStatus[]'
|
||||
*/
|
||||
export type ListEnumBookingStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'BookingStatus[]'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'PaymentProvider'
|
||||
*/
|
||||
export type EnumPaymentProviderFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'PaymentProvider'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'PaymentProvider[]'
|
||||
*/
|
||||
export type ListEnumPaymentProviderFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'PaymentProvider[]'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'PaymentStatus'
|
||||
*/
|
||||
export type EnumPaymentStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'PaymentStatus'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'PaymentStatus[]'
|
||||
*/
|
||||
export type ListEnumPaymentStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'PaymentStatus[]'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'Json'
|
||||
*/
|
||||
export type JsonFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Json'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'QueryMode'
|
||||
*/
|
||||
export type EnumQueryModeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'QueryMode'>
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Reference to a field of type 'Float'
|
||||
*/
|
||||
@@ -1458,6 +1718,8 @@ export type GlobalOmitConfig = {
|
||||
tripReview?: Prisma.TripReviewOmit
|
||||
tripImage?: Prisma.TripImageOmit
|
||||
tripParticipant?: Prisma.TripParticipantOmit
|
||||
booking?: Prisma.BookingOmit
|
||||
payment?: Prisma.PaymentOmit
|
||||
}
|
||||
|
||||
/* Types for Logging */
|
||||
|
||||
@@ -58,7 +58,9 @@ export const ModelName = {
|
||||
Trip: 'Trip',
|
||||
TripReview: 'TripReview',
|
||||
TripImage: 'TripImage',
|
||||
TripParticipant: 'TripParticipant'
|
||||
TripParticipant: 'TripParticipant',
|
||||
Booking: 'Booking',
|
||||
Payment: 'Payment'
|
||||
} as const
|
||||
|
||||
export type ModelName = (typeof ModelName)[keyof typeof ModelName]
|
||||
@@ -213,6 +215,43 @@ export const TripParticipantScalarFieldEnum = {
|
||||
export type TripParticipantScalarFieldEnum = (typeof TripParticipantScalarFieldEnum)[keyof typeof TripParticipantScalarFieldEnum]
|
||||
|
||||
|
||||
export const BookingScalarFieldEnum = {
|
||||
id: 'id',
|
||||
tripId: 'tripId',
|
||||
userId: 'userId',
|
||||
participantId: 'participantId',
|
||||
amount: 'amount',
|
||||
currency: 'currency',
|
||||
status: 'status',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt'
|
||||
} as const
|
||||
|
||||
export type BookingScalarFieldEnum = (typeof BookingScalarFieldEnum)[keyof typeof BookingScalarFieldEnum]
|
||||
|
||||
|
||||
export const PaymentScalarFieldEnum = {
|
||||
id: 'id',
|
||||
bookingId: 'bookingId',
|
||||
provider: 'provider',
|
||||
externalOrderId: 'externalOrderId',
|
||||
externalTxId: 'externalTxId',
|
||||
method: 'method',
|
||||
amount: 'amount',
|
||||
status: 'status',
|
||||
rawCallback: 'rawCallback',
|
||||
snapToken: 'snapToken',
|
||||
expiresAt: 'expiresAt',
|
||||
paidAt: 'paidAt',
|
||||
failedAt: 'failedAt',
|
||||
rejectionReason: 'rejectionReason',
|
||||
createdAt: 'createdAt',
|
||||
updatedAt: 'updatedAt'
|
||||
} as const
|
||||
|
||||
export type PaymentScalarFieldEnum = (typeof PaymentScalarFieldEnum)[keyof typeof PaymentScalarFieldEnum]
|
||||
|
||||
|
||||
export const SortOrder = {
|
||||
asc: 'asc',
|
||||
desc: 'desc'
|
||||
@@ -221,6 +260,14 @@ export const SortOrder = {
|
||||
export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder]
|
||||
|
||||
|
||||
export const NullableJsonNullValueInput = {
|
||||
DbNull: DbNull,
|
||||
JsonNull: JsonNull
|
||||
} as const
|
||||
|
||||
export type NullableJsonNullValueInput = (typeof NullableJsonNullValueInput)[keyof typeof NullableJsonNullValueInput]
|
||||
|
||||
|
||||
export const QueryMode = {
|
||||
default: 'default',
|
||||
insensitive: 'insensitive'
|
||||
@@ -236,3 +283,12 @@ export const NullsOrder = {
|
||||
|
||||
export type NullsOrder = (typeof NullsOrder)[keyof typeof NullsOrder]
|
||||
|
||||
|
||||
export const JsonNullValueFilter = {
|
||||
DbNull: DbNull,
|
||||
JsonNull: JsonNull,
|
||||
AnyNull: AnyNull
|
||||
} as const
|
||||
|
||||
export type JsonNullValueFilter = (typeof JsonNullValueFilter)[keyof typeof JsonNullValueFilter]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user