@jest-games-org/backend-package-graphql-to-prisma-helpers 1.0.1 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +314 -314
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +337 -337
- package/dist/index.js.map +1 -1
- package/dist/modules/filter/helpers/graphQLBooleanFilterInputToPrismaBooleanFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLBooleanNullableFilterInputToPrismaBooleanNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLDateTimeFilterInputToPrismaDateTimeFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLDateTimeNullableFilterInputToPrismaDateTimeNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLFloatFilterInputToPrismaFloatFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLFloatNullableFilterInputToPrismaFloatNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLIdFilterInputToPrismaStringFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLIdNullableFilterInputToPrismaStringNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLIntFilterInputToPrismaIntFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLIntNullableFilterInputToPrismaIntNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedDateTimeFilterInputToPrismaNestedDateTimeFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedDateTimeNullableFilterInputToPrismaNestedDateTimeNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedFloatFilterInputToPrismaNestedFloatFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedFloatNullableFilterInputToPrismaNestedFloatNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedIdFilterInputToPrismaNestedStringFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedIdNullableFilterInputToPrismaNestedStringNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedIntFilterInputToPrismaNestedIntFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedIntNullableFilterInputToPrismaNestedIntNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedStringFilterInputToPrismaNestedStringFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLNestedStringNullableFilterInputToPrismaNestedStringNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLStringFilterInputToPrismaStringFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/graphQLStringNullableFilterInputToPrismaStringNullableFilter.d.ts +8 -0
- package/dist/modules/filter/helpers/index.d.ts +22 -22
- package/dist/modules/index.d.ts +1 -1
- package/dist/modules/order/helpers/graphQLOrderInputToPrismaOrderInput.d.ts +9 -0
- package/dist/modules/order/helpers/graphQLOrderInputsToPrismaOrderInputs.d.ts +9 -0
- package/dist/modules/order/helpers/index.d.ts +3 -0
- package/package.json +3 -3
- package/dist/modules/filter/helpers/graphQLBooleanFilterToPrismaBooleanFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLBooleanNullableFilterToPrismaBooleanNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLDateTimeFilterToPrismaDateTimeFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLDateTimeNullableFilterToPrismaDateTimeNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLFloatFilterToPrismaFloatFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLFloatNullableFilterToPrismaFloatNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLIdFilterToPrismaStringFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLIdNullableFilterToPrismaStringNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLIntFilterToPrismaIntFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLIntNullableFilterToPrismaIntNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedDateTimeFilterToPrismaNestedDateTimeFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedDateTimeNullableFilterToPrismaNestedDateTimeNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedFloatFilterToPrismaNestedFloatFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedFloatNullableFilterToPrismaNestedFloatNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedIdFilterToPrismaNestedStringFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedIdNullableFilterToPrismaNestedStringNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedIntFilterToPrismaNestedIntFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedIntNullableFilterToPrismaNestedIntNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedStringFilterToPrismaNestedStringFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLNestedStringNullableFilterToPrismaNestedStringNullableFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLStringFilterToPrismaStringFilter.d.ts +0 -8
- package/dist/modules/filter/helpers/graphQLStringNullableFilterToPrismaStringNullableFilter.d.ts +0 -8
- package/dist/modules/order-by/helpers/graphQLOrderByInputToPrismaOrderByInput.d.ts +0 -9
- package/dist/modules/order-by/helpers/graphQLOrderByInputsToPrismaOrderByInputs.d.ts +0 -9
- package/dist/modules/order-by/helpers/index.d.ts +0 -3
- /package/dist/modules/{order-by → order}/helpers/graphQLSortOrderToPrismaSortOrder.d.ts +0 -0
- /package/dist/modules/{order-by → order}/index.d.ts +0 -0
package/dist/index.js
CHANGED
|
@@ -94,244 +94,244 @@ const graphQLCursorToPrismaWhereInput = (cursor) => {
|
|
|
94
94
|
};
|
|
95
95
|
|
|
96
96
|
/**
|
|
97
|
-
* Maps the GraphQL boolean filter to a Prisma boolean filter.
|
|
98
|
-
* @param
|
|
97
|
+
* Maps the GraphQL boolean filter input to a Prisma boolean filter.
|
|
98
|
+
* @param input The GraphQL filter input.
|
|
99
99
|
* @returns The Prisma filter.
|
|
100
100
|
*/
|
|
101
|
-
const
|
|
102
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
103
|
-
if (
|
|
101
|
+
const graphQLBooleanFilterInputToPrismaBooleanFilter = (input) => {
|
|
102
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
103
|
+
if (input === null || input === undefined) {
|
|
104
104
|
return undefined;
|
|
105
105
|
}
|
|
106
106
|
// Return the Prisma filter.
|
|
107
107
|
return {
|
|
108
|
-
equals:
|
|
108
|
+
equals: input.equals ?? undefined,
|
|
109
109
|
};
|
|
110
110
|
};
|
|
111
111
|
|
|
112
112
|
/**
|
|
113
|
-
* Maps the GraphQL boolean nullable filter to a Prisma boolean nullable filter.
|
|
114
|
-
* @param
|
|
113
|
+
* Maps the GraphQL boolean nullable filter input to a Prisma boolean nullable filter.
|
|
114
|
+
* @param input The GraphQL filter input.
|
|
115
115
|
* @returns The Prisma filter.
|
|
116
116
|
*/
|
|
117
|
-
const
|
|
118
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
119
|
-
if (
|
|
117
|
+
const graphQLBooleanNullableFilterInputToPrismaBooleanNullableFilter = (input) => {
|
|
118
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
119
|
+
if (input === null || input === undefined) {
|
|
120
120
|
return undefined;
|
|
121
121
|
}
|
|
122
122
|
// Return the Prisma filter.
|
|
123
123
|
return {
|
|
124
|
-
equals:
|
|
124
|
+
equals: input.equals,
|
|
125
125
|
};
|
|
126
126
|
};
|
|
127
127
|
|
|
128
128
|
/**
|
|
129
|
-
* Maps the GraphQL nested date time filter to a Prisma neseted date time filter.
|
|
130
|
-
* @param
|
|
129
|
+
* Maps the GraphQL nested date time filter input to a Prisma neseted date time filter.
|
|
130
|
+
* @param input The GraphQL filter input.
|
|
131
131
|
* @returns The Prisma filter.
|
|
132
132
|
*/
|
|
133
|
-
const
|
|
134
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
135
|
-
if (
|
|
133
|
+
const graphQLNestedDateTimeFilterInputToPrismaNestedDateTimeFilter = (input) => {
|
|
134
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
135
|
+
if (input === null || input === undefined) {
|
|
136
136
|
return undefined;
|
|
137
137
|
}
|
|
138
138
|
// Return the Prisma filter.
|
|
139
139
|
return {
|
|
140
|
-
equals:
|
|
141
|
-
in:
|
|
142
|
-
notIn:
|
|
143
|
-
lt:
|
|
144
|
-
lte:
|
|
145
|
-
gt:
|
|
146
|
-
gte:
|
|
147
|
-
not:
|
|
140
|
+
equals: input.equals ?? undefined,
|
|
141
|
+
in: input.in?.filter((o) => !!o),
|
|
142
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
143
|
+
lt: input.lt ?? undefined,
|
|
144
|
+
lte: input.lte ?? undefined,
|
|
145
|
+
gt: input.gt ?? undefined,
|
|
146
|
+
gte: input.gte ?? undefined,
|
|
147
|
+
not: graphQLNestedDateTimeFilterInputToPrismaNestedDateTimeFilter(input.not),
|
|
148
148
|
};
|
|
149
149
|
};
|
|
150
150
|
|
|
151
151
|
/**
|
|
152
|
-
* Maps the GraphQL date time filter to a Prisma date time filter.
|
|
153
|
-
* @param
|
|
152
|
+
* Maps the GraphQL date time filter input to a Prisma date time filter.
|
|
153
|
+
* @param input The GraphQL filter input.
|
|
154
154
|
* @returns The Prisma filter.
|
|
155
155
|
*/
|
|
156
|
-
const
|
|
157
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
158
|
-
if (
|
|
156
|
+
const graphQLDateTimeFilterInputToPrismaDateTimeFilter = (input) => {
|
|
157
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
158
|
+
if (input === null || input === undefined) {
|
|
159
159
|
return undefined;
|
|
160
160
|
}
|
|
161
161
|
// Return the Prisma filter.
|
|
162
162
|
return {
|
|
163
|
-
equals:
|
|
164
|
-
in:
|
|
165
|
-
notIn:
|
|
166
|
-
lt:
|
|
167
|
-
lte:
|
|
168
|
-
gt:
|
|
169
|
-
gte:
|
|
170
|
-
not:
|
|
163
|
+
equals: input.equals ?? undefined,
|
|
164
|
+
in: input.in?.filter((o) => !!o),
|
|
165
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
166
|
+
lt: input.lt ?? undefined,
|
|
167
|
+
lte: input.lte ?? undefined,
|
|
168
|
+
gt: input.gt ?? undefined,
|
|
169
|
+
gte: input.gte ?? undefined,
|
|
170
|
+
not: graphQLNestedDateTimeFilterInputToPrismaNestedDateTimeFilter(input.not),
|
|
171
171
|
};
|
|
172
172
|
};
|
|
173
173
|
|
|
174
174
|
/**
|
|
175
|
-
* Maps the GraphQL nested date time nullable filter to a Prisma nested date time nullable filter.
|
|
176
|
-
* @param
|
|
175
|
+
* Maps the GraphQL nested date time nullable filter input to a Prisma nested date time nullable filter.
|
|
176
|
+
* @param input The GraphQL filter input.
|
|
177
177
|
* @returns The Prisma filter.
|
|
178
178
|
*/
|
|
179
|
-
const
|
|
180
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
181
|
-
if (
|
|
179
|
+
const graphQLNestedDateTimeNullableFilterInputToPrismaNestedDateTimeNullableFilter = (input) => {
|
|
180
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
181
|
+
if (input === null || input === undefined) {
|
|
182
182
|
return undefined;
|
|
183
183
|
}
|
|
184
184
|
// Return the Prisma filter.
|
|
185
185
|
return {
|
|
186
|
-
equals:
|
|
187
|
-
in:
|
|
188
|
-
notIn:
|
|
189
|
-
lt:
|
|
190
|
-
lte:
|
|
191
|
-
gt:
|
|
192
|
-
gte:
|
|
193
|
-
not:
|
|
186
|
+
equals: input.equals,
|
|
187
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
188
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
189
|
+
lt: input.lt ?? undefined,
|
|
190
|
+
lte: input.lte ?? undefined,
|
|
191
|
+
gt: input.gt ?? undefined,
|
|
192
|
+
gte: input.gte ?? undefined,
|
|
193
|
+
not: input.not ? graphQLNestedDateTimeNullableFilterInputToPrismaNestedDateTimeNullableFilter(input.not) : input.not,
|
|
194
194
|
};
|
|
195
195
|
};
|
|
196
196
|
|
|
197
197
|
/**
|
|
198
|
-
* Maps the GraphQL date time nullable filter to the Prisma date time nullable filter.
|
|
199
|
-
* @param
|
|
198
|
+
* Maps the GraphQL date time nullable filter input to the Prisma date time nullable filter.
|
|
199
|
+
* @param input The GraphQL filter input.
|
|
200
200
|
* @returns The Prisma filter.
|
|
201
201
|
*/
|
|
202
|
-
const
|
|
203
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
204
|
-
if (
|
|
202
|
+
const graphQLDateTimeNullableFilterInputToPrismaDateTimeNullableFilter = (input) => {
|
|
203
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
204
|
+
if (input === null || input === undefined) {
|
|
205
205
|
return undefined;
|
|
206
206
|
}
|
|
207
207
|
// Return the Prisma filter.
|
|
208
208
|
return {
|
|
209
|
-
equals:
|
|
210
|
-
in:
|
|
211
|
-
notIn:
|
|
212
|
-
lt:
|
|
213
|
-
lte:
|
|
214
|
-
gt:
|
|
215
|
-
gte:
|
|
216
|
-
not:
|
|
209
|
+
equals: input.equals,
|
|
210
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
211
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
212
|
+
lt: input.lt ?? undefined,
|
|
213
|
+
lte: input.lte ?? undefined,
|
|
214
|
+
gt: input.gt ?? undefined,
|
|
215
|
+
gte: input.gte ?? undefined,
|
|
216
|
+
not: input.not ? graphQLNestedDateTimeNullableFilterInputToPrismaNestedDateTimeNullableFilter(input.not) : input.not,
|
|
217
217
|
};
|
|
218
218
|
};
|
|
219
219
|
|
|
220
220
|
/**
|
|
221
|
-
* Maps the GraphQL nested float filter to a Prisma nested float filter.
|
|
222
|
-
* @param
|
|
221
|
+
* Maps the GraphQL nested float filter input to a Prisma nested float filter.
|
|
222
|
+
* @param input The GraphQL filter input.
|
|
223
223
|
* @returns The Prisma filter.
|
|
224
224
|
*/
|
|
225
|
-
const
|
|
226
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
227
|
-
if (
|
|
225
|
+
const graphQLNestedFloatFilterInputToPrismaNestedFloatFilter = (input) => {
|
|
226
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
227
|
+
if (input === null || input === undefined) {
|
|
228
228
|
return undefined;
|
|
229
229
|
}
|
|
230
230
|
// Return the Prisma filter.
|
|
231
231
|
return {
|
|
232
|
-
equals:
|
|
233
|
-
in:
|
|
234
|
-
notIn:
|
|
235
|
-
lt:
|
|
236
|
-
lte:
|
|
237
|
-
gt:
|
|
238
|
-
gte:
|
|
239
|
-
not:
|
|
232
|
+
equals: input.equals ?? undefined,
|
|
233
|
+
in: input.in?.filter((o) => !!o),
|
|
234
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
235
|
+
lt: input.lt ?? undefined,
|
|
236
|
+
lte: input.lte ?? undefined,
|
|
237
|
+
gt: input.gt ?? undefined,
|
|
238
|
+
gte: input.gte ?? undefined,
|
|
239
|
+
not: graphQLNestedFloatFilterInputToPrismaNestedFloatFilter(input.not),
|
|
240
240
|
};
|
|
241
241
|
};
|
|
242
242
|
|
|
243
243
|
/**
|
|
244
|
-
* Maps the GraphQL float filter to a Prisma float filter.
|
|
245
|
-
* @param
|
|
244
|
+
* Maps the GraphQL float filter input to a Prisma float filter.
|
|
245
|
+
* @param input The GraphQL filter input.
|
|
246
246
|
* @returns The Prisma filter.
|
|
247
247
|
*/
|
|
248
|
-
const
|
|
249
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
250
|
-
if (
|
|
248
|
+
const graphQLFloatFilterInputToPrismaFloatFilter = (input) => {
|
|
249
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
250
|
+
if (input === null || input === undefined) {
|
|
251
251
|
return undefined;
|
|
252
252
|
}
|
|
253
253
|
// Return the Prisma filter.
|
|
254
254
|
return {
|
|
255
|
-
equals:
|
|
256
|
-
in:
|
|
257
|
-
notIn:
|
|
258
|
-
lt:
|
|
259
|
-
lte:
|
|
260
|
-
gt:
|
|
261
|
-
gte:
|
|
262
|
-
not:
|
|
255
|
+
equals: input.equals ?? undefined,
|
|
256
|
+
in: input.in?.filter((o) => !!o),
|
|
257
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
258
|
+
lt: input.lt ?? undefined,
|
|
259
|
+
lte: input.lte ?? undefined,
|
|
260
|
+
gt: input.gt ?? undefined,
|
|
261
|
+
gte: input.gte ?? undefined,
|
|
262
|
+
not: graphQLNestedFloatFilterInputToPrismaNestedFloatFilter(input.not),
|
|
263
263
|
};
|
|
264
264
|
};
|
|
265
265
|
|
|
266
266
|
/**
|
|
267
|
-
* Maps the GraphQL nested float nullable filter to a Prisma nested float nullable filter.
|
|
268
|
-
* @param
|
|
267
|
+
* Maps the GraphQL nested float nullable filter input to a Prisma nested float nullable filter.
|
|
268
|
+
* @param input The GraphQL filter.
|
|
269
269
|
* @returns The Prisma filter.
|
|
270
270
|
*/
|
|
271
|
-
const
|
|
272
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
273
|
-
if (
|
|
271
|
+
const graphQLNestedFloatNullableFilterInputToPrismaNestedFloatNullableFilter = (input) => {
|
|
272
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
273
|
+
if (input === null || input === undefined) {
|
|
274
274
|
return undefined;
|
|
275
275
|
}
|
|
276
276
|
// Return the Prisma filter.
|
|
277
277
|
return {
|
|
278
|
-
equals:
|
|
279
|
-
in:
|
|
280
|
-
notIn:
|
|
281
|
-
lt:
|
|
282
|
-
lte:
|
|
283
|
-
gt:
|
|
284
|
-
gte:
|
|
285
|
-
not:
|
|
278
|
+
equals: input.equals,
|
|
279
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
280
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
281
|
+
lt: input.lt ?? undefined,
|
|
282
|
+
lte: input.lte ?? undefined,
|
|
283
|
+
gt: input.gt ?? undefined,
|
|
284
|
+
gte: input.gte ?? undefined,
|
|
285
|
+
not: input.not ? graphQLNestedFloatNullableFilterInputToPrismaNestedFloatNullableFilter(input.not) : input.not,
|
|
286
286
|
};
|
|
287
287
|
};
|
|
288
288
|
|
|
289
289
|
/**
|
|
290
|
-
* Maps the GraphQL float nullable filter to a Prisma float nullable filter.
|
|
291
|
-
* @param
|
|
290
|
+
* Maps the GraphQL float nullable filter input to a Prisma float nullable filter.
|
|
291
|
+
* @param input The GraphQL filter input.
|
|
292
292
|
* @returns The Prisma filter.
|
|
293
293
|
*/
|
|
294
|
-
const
|
|
295
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
296
|
-
if (
|
|
294
|
+
const graphQLFloatNullableFilterInputToPrismaFloatNullableFilter = (input) => {
|
|
295
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
296
|
+
if (input === null || input === undefined) {
|
|
297
297
|
return undefined;
|
|
298
298
|
}
|
|
299
299
|
// Return the Prisma filter.
|
|
300
300
|
return {
|
|
301
|
-
equals:
|
|
302
|
-
in:
|
|
303
|
-
notIn:
|
|
304
|
-
lt:
|
|
305
|
-
lte:
|
|
306
|
-
gt:
|
|
307
|
-
gte:
|
|
308
|
-
not:
|
|
301
|
+
equals: input.equals,
|
|
302
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
303
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
304
|
+
lt: input.lt ?? undefined,
|
|
305
|
+
lte: input.lte ?? undefined,
|
|
306
|
+
gt: input.gt ?? undefined,
|
|
307
|
+
gte: input.gte ?? undefined,
|
|
308
|
+
not: input.not ? graphQLNestedFloatNullableFilterInputToPrismaNestedFloatNullableFilter(input.not) : input.not,
|
|
309
309
|
};
|
|
310
310
|
};
|
|
311
311
|
|
|
312
312
|
/**
|
|
313
|
-
* Maps the GraphQL nested id filter to the Prisma nested string filter.
|
|
314
|
-
* @param
|
|
313
|
+
* Maps the GraphQL nested id filter input to the Prisma nested string filter.
|
|
314
|
+
* @param input The GraphQL filter input.
|
|
315
315
|
* @returns The Prisma filter.
|
|
316
316
|
*/
|
|
317
|
-
const
|
|
318
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
319
|
-
if (
|
|
317
|
+
const graphQLNestedIdFilterInputToPrismaNestedStringFilter = (input) => {
|
|
318
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
319
|
+
if (input === null || input === undefined) {
|
|
320
320
|
return undefined;
|
|
321
321
|
}
|
|
322
322
|
// Return the Prisma filter.
|
|
323
323
|
return {
|
|
324
|
-
contains:
|
|
325
|
-
endsWith:
|
|
326
|
-
equals:
|
|
327
|
-
gt:
|
|
328
|
-
gte:
|
|
329
|
-
in:
|
|
330
|
-
lt:
|
|
331
|
-
lte:
|
|
332
|
-
not:
|
|
333
|
-
notIn:
|
|
334
|
-
startsWith:
|
|
324
|
+
contains: input.contains ?? undefined,
|
|
325
|
+
endsWith: input.endsWith ?? undefined,
|
|
326
|
+
equals: input.equals ?? undefined,
|
|
327
|
+
gt: input.gt ?? undefined,
|
|
328
|
+
gte: input.gte ?? undefined,
|
|
329
|
+
in: input.in?.filter((o) => !!o),
|
|
330
|
+
lt: input.lt ?? undefined,
|
|
331
|
+
lte: input.lte ?? undefined,
|
|
332
|
+
not: graphQLNestedIdFilterInputToPrismaNestedStringFilter(input.not),
|
|
333
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
334
|
+
startsWith: input.startsWith ?? undefined,
|
|
335
335
|
};
|
|
336
336
|
};
|
|
337
337
|
|
|
@@ -362,280 +362,280 @@ const graphQLQueryModeToPrismaQueryMode = (queryMode) => {
|
|
|
362
362
|
};
|
|
363
363
|
|
|
364
364
|
/**
|
|
365
|
-
* Maps the GraphQL id filter to the Prisma string filter.
|
|
366
|
-
* @param
|
|
365
|
+
* Maps the GraphQL id filter input to the Prisma string filter.
|
|
366
|
+
* @param input The GraphQL filter input.
|
|
367
367
|
* @returns The Prisma filter.
|
|
368
368
|
*/
|
|
369
|
-
const
|
|
370
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
371
|
-
if (
|
|
369
|
+
const graphQLIdFilterInputToPrismaStringFilter = (input) => {
|
|
370
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
371
|
+
if (input === null || input === undefined) {
|
|
372
372
|
return undefined;
|
|
373
373
|
}
|
|
374
374
|
// Return the Prisma filter.
|
|
375
375
|
return {
|
|
376
|
-
contains:
|
|
377
|
-
endsWith:
|
|
378
|
-
equals:
|
|
379
|
-
gt:
|
|
380
|
-
gte:
|
|
381
|
-
in:
|
|
382
|
-
lt:
|
|
383
|
-
lte:
|
|
384
|
-
mode: graphQLQueryModeToPrismaQueryMode(
|
|
385
|
-
not:
|
|
386
|
-
notIn:
|
|
387
|
-
startsWith:
|
|
376
|
+
contains: input.contains ?? undefined,
|
|
377
|
+
endsWith: input.endsWith ?? undefined,
|
|
378
|
+
equals: input.equals ?? undefined,
|
|
379
|
+
gt: input.gt ?? undefined,
|
|
380
|
+
gte: input.gte ?? undefined,
|
|
381
|
+
in: input.in?.filter((o) => !!o),
|
|
382
|
+
lt: input.lt ?? undefined,
|
|
383
|
+
lte: input.lte ?? undefined,
|
|
384
|
+
mode: graphQLQueryModeToPrismaQueryMode(input.mode),
|
|
385
|
+
not: graphQLNestedIdFilterInputToPrismaNestedStringFilter(input.not),
|
|
386
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
387
|
+
startsWith: input.startsWith ?? undefined,
|
|
388
388
|
};
|
|
389
389
|
};
|
|
390
390
|
|
|
391
391
|
/**
|
|
392
|
-
* Maps the GraphQL nested id nullable filter to the Prisma nested string nullable filter.
|
|
393
|
-
* @param
|
|
392
|
+
* Maps the GraphQL nested id nullable filter input to the Prisma nested string nullable filter.
|
|
393
|
+
* @param input The GraphQL filter input.
|
|
394
394
|
* @returns The Prisma filter.
|
|
395
395
|
*/
|
|
396
|
-
const
|
|
397
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
398
|
-
if (
|
|
396
|
+
const graphQLNestedIdNullableFilterInputToPrismaNestedStringNullableFilter = (input) => {
|
|
397
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
398
|
+
if (input === null || input === undefined) {
|
|
399
399
|
return undefined;
|
|
400
400
|
}
|
|
401
401
|
// Return the Prisma filter.
|
|
402
402
|
return {
|
|
403
|
-
contains:
|
|
404
|
-
endsWith:
|
|
405
|
-
equals:
|
|
406
|
-
gt:
|
|
407
|
-
gte:
|
|
408
|
-
in:
|
|
409
|
-
lt:
|
|
410
|
-
lte:
|
|
411
|
-
not:
|
|
412
|
-
notIn:
|
|
413
|
-
startsWith:
|
|
403
|
+
contains: input.contains ?? undefined,
|
|
404
|
+
endsWith: input.endsWith ?? undefined,
|
|
405
|
+
equals: input.equals,
|
|
406
|
+
gt: input.gt ?? undefined,
|
|
407
|
+
gte: input.gte ?? undefined,
|
|
408
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
409
|
+
lt: input.lt ?? undefined,
|
|
410
|
+
lte: input.lte ?? undefined,
|
|
411
|
+
not: input.not ? graphQLNestedIdNullableFilterInputToPrismaNestedStringNullableFilter(input.not) : input.not,
|
|
412
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
413
|
+
startsWith: input.startsWith ?? undefined,
|
|
414
414
|
};
|
|
415
415
|
};
|
|
416
416
|
|
|
417
417
|
/**
|
|
418
|
-
* Maps the GraphQL id nullable filter to the Prisma string nullable filter.
|
|
419
|
-
* @param
|
|
418
|
+
* Maps the GraphQL id nullable filter input to the Prisma string nullable filter.
|
|
419
|
+
* @param input The GraphQL filter input.
|
|
420
420
|
* @returns The Prisma string.
|
|
421
421
|
*/
|
|
422
|
-
const
|
|
423
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
424
|
-
if (
|
|
422
|
+
const graphQLIdNullableFilterInputToPrismaStringNullableFilter = (input) => {
|
|
423
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
424
|
+
if (input === null || input === undefined) {
|
|
425
425
|
return undefined;
|
|
426
426
|
}
|
|
427
427
|
// Return the Prisma filter.
|
|
428
428
|
return {
|
|
429
|
-
contains:
|
|
430
|
-
endsWith:
|
|
431
|
-
equals:
|
|
432
|
-
gt:
|
|
433
|
-
gte:
|
|
434
|
-
in:
|
|
435
|
-
lt:
|
|
436
|
-
lte:
|
|
437
|
-
mode: graphQLQueryModeToPrismaQueryMode(
|
|
438
|
-
not:
|
|
439
|
-
notIn:
|
|
440
|
-
startsWith:
|
|
429
|
+
contains: input.contains ?? undefined,
|
|
430
|
+
endsWith: input.endsWith ?? undefined,
|
|
431
|
+
equals: input.equals,
|
|
432
|
+
gt: input.gt ?? undefined,
|
|
433
|
+
gte: input.gte ?? undefined,
|
|
434
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
435
|
+
lt: input.lt ?? undefined,
|
|
436
|
+
lte: input.lte ?? undefined,
|
|
437
|
+
mode: graphQLQueryModeToPrismaQueryMode(input.mode),
|
|
438
|
+
not: input.not ? graphQLNestedIdNullableFilterInputToPrismaNestedStringNullableFilter(input.not) : input.not,
|
|
439
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
440
|
+
startsWith: input.startsWith ?? undefined,
|
|
441
441
|
};
|
|
442
442
|
};
|
|
443
443
|
|
|
444
444
|
/**
|
|
445
|
-
* Maps the GraphQL nested int filter to a Prisma nested int filter.
|
|
446
|
-
* @param
|
|
445
|
+
* Maps the GraphQL nested int filter input to a Prisma nested int filter.
|
|
446
|
+
* @param input The GraphQL filter input.
|
|
447
447
|
* @returns The Prisma filter.
|
|
448
448
|
*/
|
|
449
|
-
const
|
|
450
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
451
|
-
if (
|
|
449
|
+
const graphQLNestedIntFilterInputToPrismaNestedIntFilter = (input) => {
|
|
450
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
451
|
+
if (input === null || input === undefined) {
|
|
452
452
|
return undefined;
|
|
453
453
|
}
|
|
454
454
|
// Return the Prisma filter.
|
|
455
455
|
return {
|
|
456
|
-
equals:
|
|
457
|
-
in:
|
|
458
|
-
notIn:
|
|
459
|
-
lt:
|
|
460
|
-
lte:
|
|
461
|
-
gt:
|
|
462
|
-
gte:
|
|
463
|
-
not:
|
|
456
|
+
equals: input.equals ?? undefined,
|
|
457
|
+
in: input.in?.filter((o) => !!o),
|
|
458
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
459
|
+
lt: input.lt ?? undefined,
|
|
460
|
+
lte: input.lte ?? undefined,
|
|
461
|
+
gt: input.gt ?? undefined,
|
|
462
|
+
gte: input.gte ?? undefined,
|
|
463
|
+
not: graphQLNestedIntFilterInputToPrismaNestedIntFilter(input.not),
|
|
464
464
|
};
|
|
465
465
|
};
|
|
466
466
|
|
|
467
467
|
/**
|
|
468
|
-
* Map the GraphQL int filter to a Prisma int filter.
|
|
469
|
-
* @param
|
|
468
|
+
* Map the GraphQL int filter input to a Prisma int filter.
|
|
469
|
+
* @param input The GraphQL filter input.
|
|
470
470
|
* @returns The Prisma filter.
|
|
471
471
|
*/
|
|
472
|
-
const
|
|
473
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
474
|
-
if (
|
|
472
|
+
const graphQLIntFilterInputToPrismaIntFilter = (input) => {
|
|
473
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
474
|
+
if (input === null || input === undefined) {
|
|
475
475
|
return undefined;
|
|
476
476
|
}
|
|
477
477
|
// Return the Prisma filter.
|
|
478
478
|
return {
|
|
479
|
-
equals:
|
|
480
|
-
in:
|
|
481
|
-
notIn:
|
|
482
|
-
lt:
|
|
483
|
-
lte:
|
|
484
|
-
gt:
|
|
485
|
-
gte:
|
|
486
|
-
not:
|
|
479
|
+
equals: input.equals ?? undefined,
|
|
480
|
+
in: input.in?.filter((o) => !!o),
|
|
481
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
482
|
+
lt: input.lt ?? undefined,
|
|
483
|
+
lte: input.lte ?? undefined,
|
|
484
|
+
gt: input.gt ?? undefined,
|
|
485
|
+
gte: input.gte ?? undefined,
|
|
486
|
+
not: graphQLNestedIntFilterInputToPrismaNestedIntFilter(input.not),
|
|
487
487
|
};
|
|
488
488
|
};
|
|
489
489
|
|
|
490
490
|
/**
|
|
491
|
-
* Maps the GraphQL nested int nullable filter to a Prisma nested int nullable filter.
|
|
492
|
-
* @param
|
|
491
|
+
* Maps the GraphQL nested int nullable filter input to a Prisma nested int nullable filter.
|
|
492
|
+
* @param input The GraphQL filter input.
|
|
493
493
|
* @returns The Prisma filter.
|
|
494
494
|
*/
|
|
495
|
-
const
|
|
496
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
497
|
-
if (
|
|
495
|
+
const graphQLNestedIntNullableFilterInputToPrismaNestedIntNullableFilter = (input) => {
|
|
496
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
497
|
+
if (input === null || input === undefined) {
|
|
498
498
|
return undefined;
|
|
499
499
|
}
|
|
500
500
|
// Return the Prisma filter.
|
|
501
501
|
return {
|
|
502
|
-
equals:
|
|
503
|
-
in:
|
|
504
|
-
notIn:
|
|
505
|
-
lt:
|
|
506
|
-
lte:
|
|
507
|
-
gt:
|
|
508
|
-
gte:
|
|
509
|
-
not:
|
|
502
|
+
equals: input.equals,
|
|
503
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
504
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
505
|
+
lt: input.lt ?? undefined,
|
|
506
|
+
lte: input.lte ?? undefined,
|
|
507
|
+
gt: input.gt ?? undefined,
|
|
508
|
+
gte: input.gte ?? undefined,
|
|
509
|
+
not: input.not ? graphQLNestedIntNullableFilterInputToPrismaNestedIntNullableFilter(input.not) : input.not,
|
|
510
510
|
};
|
|
511
511
|
};
|
|
512
512
|
|
|
513
513
|
/**
|
|
514
|
-
* Maps the GraphQL int nullable filter to a Prisma int nullable filter.
|
|
515
|
-
* @param
|
|
514
|
+
* Maps the GraphQL int nullable filter input to a Prisma int nullable filter.
|
|
515
|
+
* @param input The GraphQL filter input.
|
|
516
516
|
* @returns The Prisma filter.
|
|
517
517
|
*/
|
|
518
|
-
const
|
|
519
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
520
|
-
if (
|
|
518
|
+
const graphQLIntNullableFilterInputToPrismaIntNullableFilter = (input) => {
|
|
519
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
520
|
+
if (input === null || input === undefined) {
|
|
521
521
|
return undefined;
|
|
522
522
|
}
|
|
523
523
|
// Return the Prisma filter.
|
|
524
524
|
return {
|
|
525
|
-
equals:
|
|
526
|
-
in:
|
|
527
|
-
notIn:
|
|
528
|
-
lt:
|
|
529
|
-
lte:
|
|
530
|
-
gt:
|
|
531
|
-
gte:
|
|
532
|
-
not:
|
|
525
|
+
equals: input.equals,
|
|
526
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
527
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
528
|
+
lt: input.lt ?? undefined,
|
|
529
|
+
lte: input.lte ?? undefined,
|
|
530
|
+
gt: input.gt ?? undefined,
|
|
531
|
+
gte: input.gte ?? undefined,
|
|
532
|
+
not: input.not ? graphQLNestedIntNullableFilterInputToPrismaNestedIntNullableFilter(input.not) : input.not,
|
|
533
533
|
};
|
|
534
534
|
};
|
|
535
535
|
|
|
536
536
|
/**
|
|
537
|
-
* Maps the GraphQL nested string filter to a Prisma nested string filter.
|
|
538
|
-
* @param
|
|
537
|
+
* Maps the GraphQL nested string filter input to a Prisma nested string filter.
|
|
538
|
+
* @param input The GraphQL filter input.
|
|
539
539
|
* @returns The Prisma filter.
|
|
540
540
|
*/
|
|
541
|
-
const
|
|
542
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
543
|
-
if (
|
|
541
|
+
const graphQLNestedStringFilterInputToPrismaNestedStringFilter = (input) => {
|
|
542
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
543
|
+
if (input === null || input === undefined) {
|
|
544
544
|
return undefined;
|
|
545
545
|
}
|
|
546
546
|
// Return the Prisma filter.
|
|
547
547
|
return {
|
|
548
|
-
equals:
|
|
549
|
-
in:
|
|
550
|
-
notIn:
|
|
551
|
-
lt:
|
|
552
|
-
lte:
|
|
553
|
-
gt:
|
|
554
|
-
gte:
|
|
555
|
-
contains:
|
|
556
|
-
startsWith:
|
|
557
|
-
endsWith:
|
|
558
|
-
not:
|
|
548
|
+
equals: input.equals ?? undefined,
|
|
549
|
+
in: input.in?.filter((o) => !!o),
|
|
550
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
551
|
+
lt: input.lt ?? undefined,
|
|
552
|
+
lte: input.lte ?? undefined,
|
|
553
|
+
gt: input.gt ?? undefined,
|
|
554
|
+
gte: input.gte ?? undefined,
|
|
555
|
+
contains: input.contains ?? undefined,
|
|
556
|
+
startsWith: input.startsWith ?? undefined,
|
|
557
|
+
endsWith: input.endsWith ?? undefined,
|
|
558
|
+
not: graphQLNestedStringFilterInputToPrismaNestedStringFilter(input.not),
|
|
559
559
|
};
|
|
560
560
|
};
|
|
561
561
|
|
|
562
562
|
/**
|
|
563
|
-
* Maps the GraphQL nested string nullable filter to a Prisma nested string nullable filter.
|
|
564
|
-
* @param
|
|
563
|
+
* Maps the GraphQL nested string nullable filter input to a Prisma nested string nullable filter.
|
|
564
|
+
* @param input The GraphQL filter input.
|
|
565
565
|
* @returns The Prisma afilter.
|
|
566
566
|
*/
|
|
567
|
-
const
|
|
568
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
569
|
-
if (
|
|
567
|
+
const graphQLNestedStringNullableFilterInputToPrismaNestedStringNullableFilter = (input) => {
|
|
568
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
569
|
+
if (input === null || input === undefined) {
|
|
570
570
|
return undefined;
|
|
571
571
|
}
|
|
572
572
|
// Return the Prisma filter.
|
|
573
573
|
return {
|
|
574
|
-
equals:
|
|
575
|
-
in:
|
|
576
|
-
notIn:
|
|
577
|
-
lt:
|
|
578
|
-
lte:
|
|
579
|
-
gt:
|
|
580
|
-
gte:
|
|
581
|
-
contains:
|
|
582
|
-
startsWith:
|
|
583
|
-
endsWith:
|
|
584
|
-
not:
|
|
574
|
+
equals: input.equals,
|
|
575
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
576
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
577
|
+
lt: input.lt ?? undefined,
|
|
578
|
+
lte: input.lte ?? undefined,
|
|
579
|
+
gt: input.gt ?? undefined,
|
|
580
|
+
gte: input.gte ?? undefined,
|
|
581
|
+
contains: input.contains ?? undefined,
|
|
582
|
+
startsWith: input.startsWith ?? undefined,
|
|
583
|
+
endsWith: input.endsWith ?? undefined,
|
|
584
|
+
not: input.not ? graphQLNestedStringNullableFilterInputToPrismaNestedStringNullableFilter(input.not) : input.not,
|
|
585
585
|
};
|
|
586
586
|
};
|
|
587
587
|
|
|
588
588
|
/**
|
|
589
|
-
* Maps the GraphQL string filter to a Prisma string filter.
|
|
590
|
-
* @param
|
|
589
|
+
* Maps the GraphQL string filter input to a Prisma string filter.
|
|
590
|
+
* @param input The GraphQL filter input.
|
|
591
591
|
* @returns The Prisma filter.
|
|
592
592
|
*/
|
|
593
|
-
const
|
|
594
|
-
// If the GraphQL filter is null or undefined, return undefined.
|
|
595
|
-
if (
|
|
593
|
+
const graphQLStringFilterInputToPrismaStringFilter = (input) => {
|
|
594
|
+
// If the GraphQL filter input is null or undefined, return undefined.
|
|
595
|
+
if (input === null || input === undefined) {
|
|
596
596
|
return undefined;
|
|
597
597
|
}
|
|
598
598
|
// Return the Prisma filter.
|
|
599
599
|
return {
|
|
600
|
-
equals:
|
|
601
|
-
in:
|
|
602
|
-
notIn:
|
|
603
|
-
lt:
|
|
604
|
-
lte:
|
|
605
|
-
gt:
|
|
606
|
-
gte:
|
|
607
|
-
contains:
|
|
608
|
-
startsWith:
|
|
609
|
-
endsWith:
|
|
610
|
-
mode: graphQLQueryModeToPrismaQueryMode(
|
|
611
|
-
not:
|
|
600
|
+
equals: input.equals ?? undefined,
|
|
601
|
+
in: input.in?.filter((o) => !!o),
|
|
602
|
+
notIn: input.notIn?.filter((o) => !!o),
|
|
603
|
+
lt: input.lt ?? undefined,
|
|
604
|
+
lte: input.lte ?? undefined,
|
|
605
|
+
gt: input.gt ?? undefined,
|
|
606
|
+
gte: input.gte ?? undefined,
|
|
607
|
+
contains: input.contains ?? undefined,
|
|
608
|
+
startsWith: input.startsWith ?? undefined,
|
|
609
|
+
endsWith: input.endsWith ?? undefined,
|
|
610
|
+
mode: graphQLQueryModeToPrismaQueryMode(input.mode),
|
|
611
|
+
not: graphQLNestedStringFilterInputToPrismaNestedStringFilter(input.not),
|
|
612
612
|
};
|
|
613
613
|
};
|
|
614
614
|
|
|
615
615
|
/**
|
|
616
|
-
* Maps the GraphQL string nullable filter to a Prisma string nullable filter.
|
|
617
|
-
* @param
|
|
616
|
+
* Maps the GraphQL string nullable filter input to a Prisma string nullable filter.
|
|
617
|
+
* @param input The GraphQL filter.
|
|
618
618
|
* @returns The Prisma filter.
|
|
619
619
|
*/
|
|
620
|
-
const
|
|
621
|
-
// If the GraphQL filter is null or undefined, return undefined
|
|
622
|
-
if (
|
|
620
|
+
const graphQLStringNullableFilterInputToPrismaStringNullableFilter = (input) => {
|
|
621
|
+
// If the GraphQL filter input is null or undefined, return undefined
|
|
622
|
+
if (input === null || input === undefined) {
|
|
623
623
|
return undefined;
|
|
624
624
|
}
|
|
625
625
|
// Return the Prisma filter
|
|
626
626
|
return {
|
|
627
|
-
equals:
|
|
628
|
-
in:
|
|
629
|
-
notIn:
|
|
630
|
-
lt:
|
|
631
|
-
lte:
|
|
632
|
-
gt:
|
|
633
|
-
gte:
|
|
634
|
-
contains:
|
|
635
|
-
startsWith:
|
|
636
|
-
endsWith:
|
|
637
|
-
mode: graphQLQueryModeToPrismaQueryMode(
|
|
638
|
-
not:
|
|
627
|
+
equals: input.equals,
|
|
628
|
+
in: input.in ? input.in.filter((o) => !!o) : input.in,
|
|
629
|
+
notIn: input.notIn ? input.notIn.filter((o) => !!o) : input.notIn,
|
|
630
|
+
lt: input.lt ?? undefined,
|
|
631
|
+
lte: input.lte ?? undefined,
|
|
632
|
+
gt: input.gt ?? undefined,
|
|
633
|
+
gte: input.gte ?? undefined,
|
|
634
|
+
contains: input.contains ?? undefined,
|
|
635
|
+
startsWith: input.startsWith ?? undefined,
|
|
636
|
+
endsWith: input.endsWith ?? undefined,
|
|
637
|
+
mode: graphQLQueryModeToPrismaQueryMode(input.mode),
|
|
638
|
+
not: input.not ? graphQLNestedStringNullableFilterInputToPrismaNestedStringNullableFilter(input.not) : input.not,
|
|
639
639
|
};
|
|
640
640
|
};
|
|
641
641
|
|
|
@@ -654,56 +654,56 @@ const graphQLSortOrderToPrismaSortOrder = (sortOrder) => {
|
|
|
654
654
|
};
|
|
655
655
|
|
|
656
656
|
/**
|
|
657
|
-
* Maps the GraphQL order
|
|
658
|
-
* @param
|
|
659
|
-
* @returns The Prisma order
|
|
657
|
+
* Maps the GraphQL order input to a Prisma order input.
|
|
658
|
+
* @param input The GraphQL order input.
|
|
659
|
+
* @returns The Prisma order input.
|
|
660
660
|
*/
|
|
661
|
-
const
|
|
661
|
+
const graphQLOrderInputToPrismaOrderInput = (input) => {
|
|
662
662
|
// Return the Prisma order by.
|
|
663
|
-
return Object.fromEntries(Object.entries(
|
|
663
|
+
return Object.fromEntries(Object.entries(input).map(([key, value]) => {
|
|
664
664
|
return [key, graphQLSortOrderToPrismaSortOrder(value)];
|
|
665
665
|
}));
|
|
666
666
|
};
|
|
667
667
|
|
|
668
668
|
/**
|
|
669
|
-
* Maps the GraphQL order
|
|
670
|
-
* @param
|
|
671
|
-
* @returns The Prisma order
|
|
669
|
+
* Maps the GraphQL order inputs to the Prisma order inputs.
|
|
670
|
+
* @param inputs The GraphQL order inputs.
|
|
671
|
+
* @returns The Prisma order inputs.
|
|
672
672
|
*/
|
|
673
|
-
const
|
|
674
|
-
// If the GraphQL order
|
|
675
|
-
if (
|
|
673
|
+
const graphQLOrderInputsToPrismaOrderInputs = (inputs) => {
|
|
674
|
+
// If the GraphQL order inputs is null or undefined, return undefined.
|
|
675
|
+
if (inputs === null || inputs === undefined) {
|
|
676
676
|
return undefined;
|
|
677
677
|
}
|
|
678
|
-
// Return the Prisma order
|
|
679
|
-
return
|
|
678
|
+
// Return the Prisma order inputs.
|
|
679
|
+
return inputs.map(graphQLOrderInputToPrismaOrderInput);
|
|
680
680
|
};
|
|
681
681
|
|
|
682
|
-
exports.
|
|
683
|
-
exports.
|
|
682
|
+
exports.graphQLBooleanFilterInputToPrismaBooleanFilter = graphQLBooleanFilterInputToPrismaBooleanFilter;
|
|
683
|
+
exports.graphQLBooleanNullableFilterInputToPrismaBooleanNullableFilter = graphQLBooleanNullableFilterInputToPrismaBooleanNullableFilter;
|
|
684
684
|
exports.graphQLCursorToPrismaWhereInput = graphQLCursorToPrismaWhereInput;
|
|
685
|
-
exports.
|
|
686
|
-
exports.
|
|
687
|
-
exports.
|
|
688
|
-
exports.
|
|
689
|
-
exports.
|
|
690
|
-
exports.
|
|
691
|
-
exports.
|
|
692
|
-
exports.
|
|
693
|
-
exports.
|
|
694
|
-
exports.
|
|
695
|
-
exports.
|
|
696
|
-
exports.
|
|
697
|
-
exports.
|
|
698
|
-
exports.
|
|
699
|
-
exports.
|
|
700
|
-
exports.
|
|
701
|
-
exports.
|
|
702
|
-
exports.
|
|
703
|
-
exports.
|
|
704
|
-
exports.
|
|
685
|
+
exports.graphQLDateTimeFilterInputToPrismaDateTimeFilter = graphQLDateTimeFilterInputToPrismaDateTimeFilter;
|
|
686
|
+
exports.graphQLDateTimeNullableFilterInputToPrismaDateTimeNullableFilter = graphQLDateTimeNullableFilterInputToPrismaDateTimeNullableFilter;
|
|
687
|
+
exports.graphQLFloatFilterInputToPrismaFloatFilter = graphQLFloatFilterInputToPrismaFloatFilter;
|
|
688
|
+
exports.graphQLFloatNullableFilterInputToPrismaFloatNullableFilter = graphQLFloatNullableFilterInputToPrismaFloatNullableFilter;
|
|
689
|
+
exports.graphQLIdFilterInputToPrismaStringFilter = graphQLIdFilterInputToPrismaStringFilter;
|
|
690
|
+
exports.graphQLIdNullableFilterInputToPrismaStringNullableFilter = graphQLIdNullableFilterInputToPrismaStringNullableFilter;
|
|
691
|
+
exports.graphQLIntFilterInputToPrismaIntFilter = graphQLIntFilterInputToPrismaIntFilter;
|
|
692
|
+
exports.graphQLIntNullableFilterInputToPrismaIntNullableFilter = graphQLIntNullableFilterInputToPrismaIntNullableFilter;
|
|
693
|
+
exports.graphQLNestedDateTimeFilterInputToPrismaNestedDateTimeFilter = graphQLNestedDateTimeFilterInputToPrismaNestedDateTimeFilter;
|
|
694
|
+
exports.graphQLNestedDateTimeNullableFilterInputToPrismaNestedDateTimeNullableFilter = graphQLNestedDateTimeNullableFilterInputToPrismaNestedDateTimeNullableFilter;
|
|
695
|
+
exports.graphQLNestedFloatFilterInputToPrismaNestedFloatFilter = graphQLNestedFloatFilterInputToPrismaNestedFloatFilter;
|
|
696
|
+
exports.graphQLNestedFloatNullableFilterInputToPrismaNestedFloatNullableFilter = graphQLNestedFloatNullableFilterInputToPrismaNestedFloatNullableFilter;
|
|
697
|
+
exports.graphQLNestedIdFilterInputToPrismaNestedStringFilter = graphQLNestedIdFilterInputToPrismaNestedStringFilter;
|
|
698
|
+
exports.graphQLNestedIdNullableFilterInputToPrismaNestedStringNullableFilter = graphQLNestedIdNullableFilterInputToPrismaNestedStringNullableFilter;
|
|
699
|
+
exports.graphQLNestedIntFilterInputToPrismaNestedIntFilter = graphQLNestedIntFilterInputToPrismaNestedIntFilter;
|
|
700
|
+
exports.graphQLNestedIntNullableFilterInputToPrismaNestedIntNullableFilter = graphQLNestedIntNullableFilterInputToPrismaNestedIntNullableFilter;
|
|
701
|
+
exports.graphQLNestedStringFilterInputToPrismaNestedStringFilter = graphQLNestedStringFilterInputToPrismaNestedStringFilter;
|
|
702
|
+
exports.graphQLNestedStringNullableFilterInputToPrismaNestedStringNullableFilter = graphQLNestedStringNullableFilterInputToPrismaNestedStringNullableFilter;
|
|
703
|
+
exports.graphQLOrderInputToPrismaOrderInput = graphQLOrderInputToPrismaOrderInput;
|
|
704
|
+
exports.graphQLOrderInputsToPrismaOrderInputs = graphQLOrderInputsToPrismaOrderInputs;
|
|
705
705
|
exports.graphQLQueryModeToPrismaQueryMode = graphQLQueryModeToPrismaQueryMode;
|
|
706
706
|
exports.graphQLSortOrderToPrismaSortOrder = graphQLSortOrderToPrismaSortOrder;
|
|
707
|
-
exports.
|
|
708
|
-
exports.
|
|
707
|
+
exports.graphQLStringFilterInputToPrismaStringFilter = graphQLStringFilterInputToPrismaStringFilter;
|
|
708
|
+
exports.graphQLStringNullableFilterInputToPrismaStringNullableFilter = graphQLStringNullableFilterInputToPrismaStringNullableFilter;
|
|
709
709
|
//# sourceMappingURL=index.js.map
|