@tiddlywiki/mws 0.1.14 → 0.2.1

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.
Files changed (117) hide show
  1. package/README.md +41 -20
  2. package/dist/metafile-esm.json +1 -1
  3. package/dist/mws.js +40121 -20116
  4. package/dist/mws.js.map +1 -1
  5. package/mws.run.mjs +28 -8
  6. package/package.json +20 -33
  7. package/plugins/client/plugin.info +1 -1
  8. package/plugins/client/src/multiwikiclientadaptor.ts +6 -34
  9. package/plugins/client/src/mws.d.ts +2 -1
  10. package/plugins/client/src/new-multiwikiclientadaptor.ts +634 -0
  11. package/plugins/client/src/types.d.ts +2531 -1036
  12. package/plugins/client/tiddlers/managetiddleraction.js +0 -5
  13. package/plugins/client/tiddlers/syncer/new-multiwikiclientadaptor.js +432 -0
  14. package/plugins/client/tiddlers/syncer/syncer.js +123 -241
  15. package/plugins/client/tsconfig.json +5 -1
  16. package/prisma/browser.ts +2 -0
  17. package/prisma/client/browser.ts +84 -0
  18. package/prisma/client/client.ts +108 -0
  19. package/prisma/client/commonInputTypes.ts +598 -0
  20. package/prisma/client/enums.ts +42 -0
  21. package/prisma/client/internal/class.ts +326 -0
  22. package/prisma/client/internal/prismaNamespace.ts +1870 -0
  23. package/prisma/client/internal/prismaNamespaceBrowser.ts +259 -0
  24. package/prisma/client/models/Bag.ts +1701 -0
  25. package/prisma/client/models/BagPermission.ts +1284 -0
  26. package/prisma/client/models/Recipe.ts +1722 -0
  27. package/prisma/client/models/RecipeBag.ts +1518 -0
  28. package/prisma/client/models/RecipePermission.ts +1284 -0
  29. package/prisma/client/models/Roles.ts +1316 -0
  30. package/prisma/client/models/Sessions.ts +1344 -0
  31. package/prisma/client/models/Settings.ts +1093 -0
  32. package/prisma/client/models/Template.ts +1477 -0
  33. package/prisma/client/models/TemplatePermission.ts +1284 -0
  34. package/prisma/client/models/Tiddler.ts +1434 -0
  35. package/prisma/client/models/TiddlerEvent.ts +1360 -0
  36. package/prisma/client/models/Users.ts +1579 -0
  37. package/prisma/client/models.ts +24 -0
  38. package/prisma/client/pjtg.ts +183 -0
  39. package/prisma/index.ts +74 -0
  40. package/prisma/migrations/20260708160259_init/migration.sql +172 -0
  41. package/prisma/migrations-v1/migration_lock.toml +3 -0
  42. package/prisma/package.json +12 -0
  43. package/prisma/schema.prisma +147 -89
  44. package/prisma/types.ts +9 -0
  45. package/public/.default.html +1 -0
  46. package/public/admin-vanilla/fish.svg +399 -0
  47. package/public/admin-vanilla/fish2.svg +389 -0
  48. package/public/admin-vanilla/main-LYDE4NDJ.css +1 -0
  49. package/public/admin-vanilla/main-Y4GDO4MD.js +1797 -0
  50. package/public/admin-vanilla/main-Y4GDO4MD.js.map +7 -0
  51. package/public/admin-vanilla/normalize.css +349 -0
  52. package/public/admin-vanilla/polyfill-ADOI2A4V.js +2 -0
  53. package/public/admin-vanilla/polyfill-ADOI2A4V.js.map +7 -0
  54. package/public/{react-admin → admin-vanilla}/site.webmanifest +1 -1
  55. package/public/admin-vanilla.html +62 -0
  56. package/public/admin-vanilla.json +1 -0
  57. package/public/{react-admin → stats}/stats.html +5 -2
  58. package/public/{react-admin → stats}/stats.js +2 -1
  59. package/scripts/build-docs.sh +30 -0
  60. package/scripts/helpers.mjs +107 -0
  61. package/scripts/json.js +8 -0
  62. package/scripts/scripts.mjs +114 -0
  63. package/prisma/client/client.d.ts +0 -1
  64. package/prisma/client/client.js +0 -3
  65. package/prisma/client/default.d.ts +0 -1
  66. package/prisma/client/default.js +0 -3
  67. package/prisma/client/edge.d.ts +0 -1
  68. package/prisma/client/edge.js +0 -297
  69. package/prisma/client/index-browser.js +0 -275
  70. package/prisma/client/index.d.ts +0 -17770
  71. package/prisma/client/index.js +0 -324
  72. package/prisma/client/package.json +0 -173
  73. package/prisma/client/query_engine_bg.js +0 -811
  74. package/prisma/client/query_engine_bg.wasm +0 -0
  75. package/prisma/client/runtime/edge-esm.js +0 -10000
  76. package/prisma/client/runtime/edge.js +0 -10036
  77. package/prisma/client/runtime/index-browser.d.ts +0 -370
  78. package/prisma/client/runtime/index-browser.js +0 -2300
  79. package/prisma/client/runtime/library.d.ts +0 -3681
  80. package/prisma/client/runtime/library.js +0 -10604
  81. package/prisma/client/runtime/react-native.js +0 -10629
  82. package/prisma/client/runtime/wasm-compiler-edge.js +0 -11238
  83. package/prisma/client/runtime/wasm-engine-edge.js +0 -7801
  84. package/prisma/client/schema.prisma +0 -156
  85. package/prisma/client/wasm-edge-light-loader.mjs +0 -4
  86. package/prisma/client/wasm-worker-loader.mjs +0 -4
  87. package/prisma/client/wasm.d.ts +0 -1
  88. package/prisma/client/wasm.js +0 -304
  89. package/prisma/global.ts +0 -53
  90. package/public/react-admin/chunk-YALWN5OT.js +0 -2
  91. package/public/react-admin/esm-L4WLVWJN.js +0 -3
  92. package/public/react-admin/esm-L4WLVWJN.js.map +0 -7
  93. package/public/react-admin/esm-QMNGI3LF.js +0 -3
  94. package/public/react-admin/esm-QMNGI3LF.js.map +0 -7
  95. package/public/react-admin/index.html +0 -36
  96. package/public/react-admin/main.js +0 -268
  97. package/public/react-admin/main.js.map +0 -7
  98. package/public/react-admin/stats.json +0 -1
  99. package/scripts.mjs +0 -142
  100. /package/prisma/{migrations → migrations-v1}/20250606001949_init/migration.sql +0 -0
  101. /package/prisma/{migrations → migrations-v1}/20250613000526_remove_group/migration.sql +0 -0
  102. /package/prisma/{migrations → migrations-v1}/20250620014502_settings/migration.sql +0 -0
  103. /package/prisma/{migrations → migrations-v1}/20250707205229_recipes/migration.sql +0 -0
  104. /package/public/{react-admin → admin-vanilla}/android-chrome-192x192.png +0 -0
  105. /package/public/{react-admin → admin-vanilla}/android-chrome-512x512.png +0 -0
  106. /package/public/{react-admin → admin-vanilla}/apple-touch-icon.png +0 -0
  107. /package/public/{react-admin → admin-vanilla}/favicon-16x16.png +0 -0
  108. /package/public/{react-admin → admin-vanilla}/favicon-32x32.png +0 -0
  109. /package/public/{react-admin → admin-vanilla}/favicon.ico +0 -0
  110. /package/public/{react-admin → admin-vanilla}/favicon.png +0 -0
  111. /package/public/{react-admin/chunk-YALWN5OT.js.map → admin-vanilla/main-LYDE4NDJ.css.map} +0 -0
  112. /package/public/{react-admin → admin-vanilla}/missing-favicon.png +0 -0
  113. /package/public/{react-admin → admin-vanilla}/motovun-jack.jpg +0 -0
  114. /package/public/{react-admin → admin-vanilla}/mws-icon.png +0 -0
  115. /package/public/{react-admin → admin-vanilla}/vite.svg +0 -0
  116. /package/public/{react-admin → stats}/stats.css +0 -0
  117. /package/public/{react-admin → stats}/stats.svg +0 -0
@@ -0,0 +1,1316 @@
1
+
2
+ /* !!! This is code generated by Prisma. Do not edit directly. !!! */
3
+ /* eslint-disable */
4
+ // biome-ignore-all lint: generated file
5
+ // @ts-nocheck
6
+ /*
7
+ * This file exports the `Roles` model and its related types.
8
+ *
9
+ * 🟢 You can import this file directly.
10
+ */
11
+
12
+ import type * as PJTG from '../pjtg';
13
+ import type * as runtime from "@prisma/client/runtime/client"
14
+ import type * as $Enums from "../enums.ts"
15
+ import type * as Prisma from "../internal/prismaNamespace.ts"
16
+
17
+ /**
18
+ * Model Roles
19
+ *
20
+ */
21
+ export type RolesModel = runtime.Types.Result.DefaultSelection<Prisma.$RolesPayload>
22
+
23
+ export type AggregateRoles = {
24
+ _count: RolesCountAggregateOutputType | null
25
+ _min: RolesMinAggregateOutputType | null
26
+ _max: RolesMaxAggregateOutputType | null
27
+ }
28
+
29
+ export type RolesMinAggregateOutputType = {
30
+ role_id: string | null
31
+ role_name: string | null
32
+ description: string | null
33
+ }
34
+
35
+ export type RolesMaxAggregateOutputType = {
36
+ role_id: string | null
37
+ role_name: string | null
38
+ description: string | null
39
+ }
40
+
41
+ export type RolesCountAggregateOutputType = {
42
+ role_id: number
43
+ role_name: number
44
+ description: number
45
+ _all: number
46
+ }
47
+
48
+
49
+ export type RolesMinAggregateInputType = {
50
+ role_id?: true
51
+ role_name?: true
52
+ description?: true
53
+ }
54
+
55
+ export type RolesMaxAggregateInputType = {
56
+ role_id?: true
57
+ role_name?: true
58
+ description?: true
59
+ }
60
+
61
+ export type RolesCountAggregateInputType = {
62
+ role_id?: true
63
+ role_name?: true
64
+ description?: true
65
+ _all?: true
66
+ }
67
+
68
+ export type RolesAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
69
+ /**
70
+ * Filter which Roles to aggregate.
71
+ */
72
+ where?: Prisma.RolesWhereInput
73
+ /**
74
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
75
+ *
76
+ * Determine the order of Roles to fetch.
77
+ */
78
+ orderBy?: Prisma.RolesOrderByWithRelationInput | Prisma.RolesOrderByWithRelationInput[]
79
+ /**
80
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
81
+ *
82
+ * Sets the start position
83
+ */
84
+ cursor?: Prisma.RolesWhereUniqueInput
85
+ /**
86
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
87
+ *
88
+ * Take `±n` Roles from the position of the cursor.
89
+ */
90
+ take?: number
91
+ /**
92
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
93
+ *
94
+ * Skip the first `n` Roles.
95
+ */
96
+ skip?: number
97
+ /**
98
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
99
+ *
100
+ * Count returned Roles
101
+ **/
102
+ _count?: true | RolesCountAggregateInputType
103
+ /**
104
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
105
+ *
106
+ * Select which fields to find the minimum value
107
+ **/
108
+ _min?: RolesMinAggregateInputType
109
+ /**
110
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
111
+ *
112
+ * Select which fields to find the maximum value
113
+ **/
114
+ _max?: RolesMaxAggregateInputType
115
+ }
116
+
117
+ export type GetRolesAggregateType<T extends RolesAggregateArgs> = {
118
+ [P in keyof T & keyof AggregateRoles]: P extends '_count' | 'count'
119
+ ? T[P] extends true
120
+ ? number
121
+ : Prisma.GetScalarType<T[P], AggregateRoles[P]>
122
+ : Prisma.GetScalarType<T[P], AggregateRoles[P]>
123
+ }
124
+
125
+
126
+
127
+
128
+ export type RolesGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
129
+ where?: Prisma.RolesWhereInput
130
+ orderBy?: Prisma.RolesOrderByWithAggregationInput | Prisma.RolesOrderByWithAggregationInput[]
131
+ by: Prisma.RolesScalarFieldEnum[] | Prisma.RolesScalarFieldEnum
132
+ having?: Prisma.RolesScalarWhereWithAggregatesInput
133
+ take?: number
134
+ skip?: number
135
+ _count?: RolesCountAggregateInputType | true
136
+ _min?: RolesMinAggregateInputType
137
+ _max?: RolesMaxAggregateInputType
138
+ }
139
+
140
+ export type RolesGroupByOutputType = {
141
+ role_id: string
142
+ role_name: string
143
+ description: string | null
144
+ _count: RolesCountAggregateOutputType | null
145
+ _min: RolesMinAggregateOutputType | null
146
+ _max: RolesMaxAggregateOutputType | null
147
+ }
148
+
149
+ export type GetRolesGroupByPayload<T extends RolesGroupByArgs> = Prisma.PrismaPromise<
150
+ Array<
151
+ Prisma.PickEnumerable<RolesGroupByOutputType, T['by']> &
152
+ {
153
+ [P in ((keyof T) & (keyof RolesGroupByOutputType))]: P extends '_count'
154
+ ? T[P] extends boolean
155
+ ? number
156
+ : Prisma.GetScalarType<T[P], RolesGroupByOutputType[P]>
157
+ : Prisma.GetScalarType<T[P], RolesGroupByOutputType[P]>
158
+ }
159
+ >
160
+ >
161
+
162
+
163
+
164
+ export type RolesWhereInput = {
165
+ AND?: Prisma.RolesWhereInput | Prisma.RolesWhereInput[]
166
+ OR?: Prisma.RolesWhereInput[]
167
+ NOT?: Prisma.RolesWhereInput | Prisma.RolesWhereInput[]
168
+ role_id?: Prisma.StringFilter<"Roles"> | string
169
+ role_name?: Prisma.StringFilter<"Roles"> | string
170
+ description?: Prisma.StringNullableFilter<"Roles"> | string | null
171
+ users?: Prisma.UsersListRelationFilter
172
+ }
173
+
174
+ export type RolesOrderByWithRelationInput = {
175
+ role_id?: Prisma.SortOrder
176
+ role_name?: Prisma.SortOrder
177
+ description?: Prisma.SortOrderInput | Prisma.SortOrder
178
+ users?: Prisma.UsersOrderByRelationAggregateInput
179
+ }
180
+
181
+ export type RolesWhereUniqueInput = Prisma.AtLeast<{
182
+ role_id?: string
183
+ role_name?: string
184
+ AND?: Prisma.RolesWhereInput | Prisma.RolesWhereInput[]
185
+ OR?: Prisma.RolesWhereInput[]
186
+ NOT?: Prisma.RolesWhereInput | Prisma.RolesWhereInput[]
187
+ description?: Prisma.StringNullableFilter<"Roles"> | string | null
188
+ users?: Prisma.UsersListRelationFilter
189
+ }, "role_id" | "role_name">
190
+
191
+ export type RolesOrderByWithAggregationInput = {
192
+ role_id?: Prisma.SortOrder
193
+ role_name?: Prisma.SortOrder
194
+ description?: Prisma.SortOrderInput | Prisma.SortOrder
195
+ _count?: Prisma.RolesCountOrderByAggregateInput
196
+ _max?: Prisma.RolesMaxOrderByAggregateInput
197
+ _min?: Prisma.RolesMinOrderByAggregateInput
198
+ }
199
+
200
+ export type RolesScalarWhereWithAggregatesInput = {
201
+ AND?: Prisma.RolesScalarWhereWithAggregatesInput | Prisma.RolesScalarWhereWithAggregatesInput[]
202
+ OR?: Prisma.RolesScalarWhereWithAggregatesInput[]
203
+ NOT?: Prisma.RolesScalarWhereWithAggregatesInput | Prisma.RolesScalarWhereWithAggregatesInput[]
204
+ role_id?: Prisma.StringWithAggregatesFilter<"Roles"> | string
205
+ role_name?: Prisma.StringWithAggregatesFilter<"Roles"> | string
206
+ description?: Prisma.StringNullableWithAggregatesFilter<"Roles"> | string | null
207
+ }
208
+
209
+ export type RolesCreateInput = {
210
+ role_id?: string
211
+ role_name: string
212
+ description?: string | null
213
+ users?: Prisma.UsersCreateNestedManyWithoutRolesInput
214
+ }
215
+
216
+ export type RolesUncheckedCreateInput = {
217
+ role_id?: string
218
+ role_name: string
219
+ description?: string | null
220
+ users?: Prisma.UsersUncheckedCreateNestedManyWithoutRolesInput
221
+ }
222
+
223
+ export type RolesUpdateInput = {
224
+ role_id?: Prisma.StringFieldUpdateOperationsInput | string
225
+ role_name?: Prisma.StringFieldUpdateOperationsInput | string
226
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
227
+ users?: Prisma.UsersUpdateManyWithoutRolesNestedInput
228
+ }
229
+
230
+ export type RolesUncheckedUpdateInput = {
231
+ role_id?: Prisma.StringFieldUpdateOperationsInput | string
232
+ role_name?: Prisma.StringFieldUpdateOperationsInput | string
233
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
234
+ users?: Prisma.UsersUncheckedUpdateManyWithoutRolesNestedInput
235
+ }
236
+
237
+ export type RolesCreateManyInput = {
238
+ role_id?: string
239
+ role_name: string
240
+ description?: string | null
241
+ }
242
+
243
+ export type RolesUpdateManyMutationInput = {
244
+ role_id?: Prisma.StringFieldUpdateOperationsInput | string
245
+ role_name?: Prisma.StringFieldUpdateOperationsInput | string
246
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
247
+ }
248
+
249
+ export type RolesUncheckedUpdateManyInput = {
250
+ role_id?: Prisma.StringFieldUpdateOperationsInput | string
251
+ role_name?: Prisma.StringFieldUpdateOperationsInput | string
252
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
253
+ }
254
+
255
+ export type RolesCountOrderByAggregateInput = {
256
+ role_id?: Prisma.SortOrder
257
+ role_name?: Prisma.SortOrder
258
+ description?: Prisma.SortOrder
259
+ }
260
+
261
+ export type RolesMaxOrderByAggregateInput = {
262
+ role_id?: Prisma.SortOrder
263
+ role_name?: Prisma.SortOrder
264
+ description?: Prisma.SortOrder
265
+ }
266
+
267
+ export type RolesMinOrderByAggregateInput = {
268
+ role_id?: Prisma.SortOrder
269
+ role_name?: Prisma.SortOrder
270
+ description?: Prisma.SortOrder
271
+ }
272
+
273
+ export type RolesListRelationFilter = {
274
+ every?: Prisma.RolesWhereInput
275
+ some?: Prisma.RolesWhereInput
276
+ none?: Prisma.RolesWhereInput
277
+ }
278
+
279
+ export type RolesOrderByRelationAggregateInput = {
280
+ _count?: Prisma.SortOrder
281
+ }
282
+
283
+ export type NullableStringFieldUpdateOperationsInput = {
284
+ set?: string | null
285
+ }
286
+
287
+ export type RolesCreateNestedManyWithoutUsersInput = {
288
+ create?: Prisma.XOR<Prisma.RolesCreateWithoutUsersInput, Prisma.RolesUncheckedCreateWithoutUsersInput> | Prisma.RolesCreateWithoutUsersInput[] | Prisma.RolesUncheckedCreateWithoutUsersInput[]
289
+ connectOrCreate?: Prisma.RolesCreateOrConnectWithoutUsersInput | Prisma.RolesCreateOrConnectWithoutUsersInput[]
290
+ connect?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
291
+ }
292
+
293
+ export type RolesUncheckedCreateNestedManyWithoutUsersInput = {
294
+ create?: Prisma.XOR<Prisma.RolesCreateWithoutUsersInput, Prisma.RolesUncheckedCreateWithoutUsersInput> | Prisma.RolesCreateWithoutUsersInput[] | Prisma.RolesUncheckedCreateWithoutUsersInput[]
295
+ connectOrCreate?: Prisma.RolesCreateOrConnectWithoutUsersInput | Prisma.RolesCreateOrConnectWithoutUsersInput[]
296
+ connect?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
297
+ }
298
+
299
+ export type RolesUpdateManyWithoutUsersNestedInput = {
300
+ create?: Prisma.XOR<Prisma.RolesCreateWithoutUsersInput, Prisma.RolesUncheckedCreateWithoutUsersInput> | Prisma.RolesCreateWithoutUsersInput[] | Prisma.RolesUncheckedCreateWithoutUsersInput[]
301
+ connectOrCreate?: Prisma.RolesCreateOrConnectWithoutUsersInput | Prisma.RolesCreateOrConnectWithoutUsersInput[]
302
+ upsert?: Prisma.RolesUpsertWithWhereUniqueWithoutUsersInput | Prisma.RolesUpsertWithWhereUniqueWithoutUsersInput[]
303
+ set?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
304
+ disconnect?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
305
+ delete?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
306
+ connect?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
307
+ update?: Prisma.RolesUpdateWithWhereUniqueWithoutUsersInput | Prisma.RolesUpdateWithWhereUniqueWithoutUsersInput[]
308
+ updateMany?: Prisma.RolesUpdateManyWithWhereWithoutUsersInput | Prisma.RolesUpdateManyWithWhereWithoutUsersInput[]
309
+ deleteMany?: Prisma.RolesScalarWhereInput | Prisma.RolesScalarWhereInput[]
310
+ }
311
+
312
+ export type RolesUncheckedUpdateManyWithoutUsersNestedInput = {
313
+ create?: Prisma.XOR<Prisma.RolesCreateWithoutUsersInput, Prisma.RolesUncheckedCreateWithoutUsersInput> | Prisma.RolesCreateWithoutUsersInput[] | Prisma.RolesUncheckedCreateWithoutUsersInput[]
314
+ connectOrCreate?: Prisma.RolesCreateOrConnectWithoutUsersInput | Prisma.RolesCreateOrConnectWithoutUsersInput[]
315
+ upsert?: Prisma.RolesUpsertWithWhereUniqueWithoutUsersInput | Prisma.RolesUpsertWithWhereUniqueWithoutUsersInput[]
316
+ set?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
317
+ disconnect?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
318
+ delete?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
319
+ connect?: Prisma.RolesWhereUniqueInput | Prisma.RolesWhereUniqueInput[]
320
+ update?: Prisma.RolesUpdateWithWhereUniqueWithoutUsersInput | Prisma.RolesUpdateWithWhereUniqueWithoutUsersInput[]
321
+ updateMany?: Prisma.RolesUpdateManyWithWhereWithoutUsersInput | Prisma.RolesUpdateManyWithWhereWithoutUsersInput[]
322
+ deleteMany?: Prisma.RolesScalarWhereInput | Prisma.RolesScalarWhereInput[]
323
+ }
324
+
325
+ export type RolesCreateWithoutUsersInput = {
326
+ role_id?: string
327
+ role_name: string
328
+ description?: string | null
329
+ }
330
+
331
+ export type RolesUncheckedCreateWithoutUsersInput = {
332
+ role_id?: string
333
+ role_name: string
334
+ description?: string | null
335
+ }
336
+
337
+ export type RolesCreateOrConnectWithoutUsersInput = {
338
+ where: Prisma.RolesWhereUniqueInput
339
+ create: Prisma.XOR<Prisma.RolesCreateWithoutUsersInput, Prisma.RolesUncheckedCreateWithoutUsersInput>
340
+ }
341
+
342
+ export type RolesUpsertWithWhereUniqueWithoutUsersInput = {
343
+ where: Prisma.RolesWhereUniqueInput
344
+ update: Prisma.XOR<Prisma.RolesUpdateWithoutUsersInput, Prisma.RolesUncheckedUpdateWithoutUsersInput>
345
+ create: Prisma.XOR<Prisma.RolesCreateWithoutUsersInput, Prisma.RolesUncheckedCreateWithoutUsersInput>
346
+ }
347
+
348
+ export type RolesUpdateWithWhereUniqueWithoutUsersInput = {
349
+ where: Prisma.RolesWhereUniqueInput
350
+ data: Prisma.XOR<Prisma.RolesUpdateWithoutUsersInput, Prisma.RolesUncheckedUpdateWithoutUsersInput>
351
+ }
352
+
353
+ export type RolesUpdateManyWithWhereWithoutUsersInput = {
354
+ where: Prisma.RolesScalarWhereInput
355
+ data: Prisma.XOR<Prisma.RolesUpdateManyMutationInput, Prisma.RolesUncheckedUpdateManyWithoutUsersInput>
356
+ }
357
+
358
+ export type RolesScalarWhereInput = {
359
+ AND?: Prisma.RolesScalarWhereInput | Prisma.RolesScalarWhereInput[]
360
+ OR?: Prisma.RolesScalarWhereInput[]
361
+ NOT?: Prisma.RolesScalarWhereInput | Prisma.RolesScalarWhereInput[]
362
+ role_id?: Prisma.StringFilter<"Roles"> | string
363
+ role_name?: Prisma.StringFilter<"Roles"> | string
364
+ description?: Prisma.StringNullableFilter<"Roles"> | string | null
365
+ }
366
+
367
+ export type RolesUpdateWithoutUsersInput = {
368
+ role_id?: Prisma.StringFieldUpdateOperationsInput | string
369
+ role_name?: Prisma.StringFieldUpdateOperationsInput | string
370
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
371
+ }
372
+
373
+ export type RolesUncheckedUpdateWithoutUsersInput = {
374
+ role_id?: Prisma.StringFieldUpdateOperationsInput | string
375
+ role_name?: Prisma.StringFieldUpdateOperationsInput | string
376
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
377
+ }
378
+
379
+ export type RolesUncheckedUpdateManyWithoutUsersInput = {
380
+ role_id?: Prisma.StringFieldUpdateOperationsInput | string
381
+ role_name?: Prisma.StringFieldUpdateOperationsInput | string
382
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
383
+ }
384
+
385
+
386
+ /**
387
+ * Count Type RolesCountOutputType
388
+ */
389
+
390
+ export type RolesCountOutputType = {
391
+ users: number
392
+ }
393
+
394
+ export type RolesCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
395
+ users?: boolean | RolesCountOutputTypeCountUsersArgs
396
+ }
397
+
398
+ /**
399
+ * RolesCountOutputType without action
400
+ */
401
+ export type RolesCountOutputTypeDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
402
+ /**
403
+ * Select specific fields to fetch from the RolesCountOutputType
404
+ */
405
+ select?: Prisma.RolesCountOutputTypeSelect<ExtArgs> | null
406
+ }
407
+
408
+ /**
409
+ * RolesCountOutputType without action
410
+ */
411
+ export type RolesCountOutputTypeCountUsersArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
412
+ where?: Prisma.UsersWhereInput
413
+ }
414
+
415
+
416
+ export type RolesSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
417
+ role_id?: boolean
418
+ role_name?: boolean
419
+ description?: boolean
420
+ users?: boolean | Prisma.Roles$usersArgs<ExtArgs>
421
+ _count?: boolean | Prisma.RolesCountOutputTypeDefaultArgs<ExtArgs>
422
+ }, ExtArgs["result"]["roles"]>
423
+
424
+ export type RolesSelectCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
425
+ role_id?: boolean
426
+ role_name?: boolean
427
+ description?: boolean
428
+ }, ExtArgs["result"]["roles"]>
429
+
430
+ export type RolesSelectUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
431
+ role_id?: boolean
432
+ role_name?: boolean
433
+ description?: boolean
434
+ }, ExtArgs["result"]["roles"]>
435
+
436
+ export type RolesSelectScalar = {
437
+ role_id?: boolean
438
+ role_name?: boolean
439
+ description?: boolean
440
+ }
441
+
442
+ export type RolesOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"role_id" | "role_name" | "description", ExtArgs["result"]["roles"]>
443
+ export type RolesInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
444
+ users?: boolean | Prisma.Roles$usersArgs<ExtArgs>
445
+ _count?: boolean | Prisma.RolesCountOutputTypeDefaultArgs<ExtArgs>
446
+ }
447
+ export type RolesIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {}
448
+ export type RolesIncludeUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {}
449
+
450
+ export type $RolesPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
451
+ name: "Roles"
452
+ objects: {
453
+ users: Prisma.$UsersPayload<ExtArgs>[]
454
+ }
455
+ scalars: runtime.Types.Extensions.GetPayloadResult<{
456
+ role_id: string
457
+ role_name: string
458
+ description: string | null
459
+ }, ExtArgs["result"]["roles"]>
460
+ composites: {}
461
+ }
462
+
463
+ export type RolesGetPayload<S extends boolean | null | undefined | RolesDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$RolesPayload, S>
464
+
465
+ export type RolesCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> =
466
+ Omit<RolesFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
467
+ select?: RolesCountAggregateInputType | true
468
+ }
469
+
470
+ export interface RolesDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
471
+ [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Roles'], meta: { name: 'Roles' } }
472
+ /**
473
+ * Find zero or one Roles that matches the filter.
474
+ * @param {RolesFindUniqueArgs} args - Arguments to find a Roles
475
+ * @example
476
+ * // Get one Roles
477
+ * const roles = await prisma.roles.findUnique({
478
+ * where: {
479
+ * // ... provide filter here
480
+ * }
481
+ * })
482
+ */
483
+ findUnique<T extends RolesFindUniqueArgs>(args: Prisma.SelectSubset<T, RolesFindUniqueArgs<ExtArgs>>): Prisma.Prisma__RolesClient<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
484
+
485
+ /**
486
+ * Find one Roles that matches the filter or throw an error with `error.code='P2025'`
487
+ * if no matches were found.
488
+ * @param {RolesFindUniqueOrThrowArgs} args - Arguments to find a Roles
489
+ * @example
490
+ * // Get one Roles
491
+ * const roles = await prisma.roles.findUniqueOrThrow({
492
+ * where: {
493
+ * // ... provide filter here
494
+ * }
495
+ * })
496
+ */
497
+ findUniqueOrThrow<T extends RolesFindUniqueOrThrowArgs>(args: Prisma.SelectSubset<T, RolesFindUniqueOrThrowArgs<ExtArgs>>): Prisma.Prisma__RolesClient<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
498
+
499
+ /**
500
+ * Find the first Roles that matches the filter.
501
+ * Note, that providing `undefined` is treated as the value not being there.
502
+ * Read more here: https://pris.ly/d/null-undefined
503
+ * @param {RolesFindFirstArgs} args - Arguments to find a Roles
504
+ * @example
505
+ * // Get one Roles
506
+ * const roles = await prisma.roles.findFirst({
507
+ * where: {
508
+ * // ... provide filter here
509
+ * }
510
+ * })
511
+ */
512
+ findFirst<T extends RolesFindFirstArgs>(args?: Prisma.SelectSubset<T, RolesFindFirstArgs<ExtArgs>>): Prisma.Prisma__RolesClient<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
513
+
514
+ /**
515
+ * Find the first Roles that matches the filter or
516
+ * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
517
+ * Note, that providing `undefined` is treated as the value not being there.
518
+ * Read more here: https://pris.ly/d/null-undefined
519
+ * @param {RolesFindFirstOrThrowArgs} args - Arguments to find a Roles
520
+ * @example
521
+ * // Get one Roles
522
+ * const roles = await prisma.roles.findFirstOrThrow({
523
+ * where: {
524
+ * // ... provide filter here
525
+ * }
526
+ * })
527
+ */
528
+ findFirstOrThrow<T extends RolesFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, RolesFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__RolesClient<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
529
+
530
+ /**
531
+ * Find zero or more Roles that matches the filter.
532
+ * Note, that providing `undefined` is treated as the value not being there.
533
+ * Read more here: https://pris.ly/d/null-undefined
534
+ * @param {RolesFindManyArgs} args - Arguments to filter and select certain fields only.
535
+ * @example
536
+ * // Get all Roles
537
+ * const roles = await prisma.roles.findMany()
538
+ *
539
+ * // Get first 10 Roles
540
+ * const roles = await prisma.roles.findMany({ take: 10 })
541
+ *
542
+ * // Only select the `role_id`
543
+ * const rolesWithRole_idOnly = await prisma.roles.findMany({ select: { role_id: true } })
544
+ *
545
+ */
546
+ findMany<T extends RolesFindManyArgs>(args?: Prisma.SelectSubset<T, RolesFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>
547
+
548
+ /**
549
+ * Create a Roles.
550
+ * @param {RolesCreateArgs} args - Arguments to create a Roles.
551
+ * @example
552
+ * // Create one Roles
553
+ * const Roles = await prisma.roles.create({
554
+ * data: {
555
+ * // ... data to create a Roles
556
+ * }
557
+ * })
558
+ *
559
+ */
560
+ create<T extends RolesCreateArgs>(args: Prisma.SelectSubset<T, RolesCreateArgs<ExtArgs>>): Prisma.Prisma__RolesClient<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
561
+
562
+ /**
563
+ * Create many Roles.
564
+ * @param {RolesCreateManyArgs} args - Arguments to create many Roles.
565
+ * @example
566
+ * // Create many Roles
567
+ * const roles = await prisma.roles.createMany({
568
+ * data: [
569
+ * // ... provide data here
570
+ * ]
571
+ * })
572
+ *
573
+ */
574
+ createMany<T extends RolesCreateManyArgs>(args?: Prisma.SelectSubset<T, RolesCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
575
+
576
+ /**
577
+ * Create many Roles and returns the data saved in the database.
578
+ * @param {RolesCreateManyAndReturnArgs} args - Arguments to create many Roles.
579
+ * @example
580
+ * // Create many Roles
581
+ * const roles = await prisma.roles.createManyAndReturn({
582
+ * data: [
583
+ * // ... provide data here
584
+ * ]
585
+ * })
586
+ *
587
+ * // Create many Roles and only return the `role_id`
588
+ * const rolesWithRole_idOnly = await prisma.roles.createManyAndReturn({
589
+ * select: { role_id: true },
590
+ * data: [
591
+ * // ... provide data here
592
+ * ]
593
+ * })
594
+ * Note, that providing `undefined` is treated as the value not being there.
595
+ * Read more here: https://pris.ly/d/null-undefined
596
+ *
597
+ */
598
+ createManyAndReturn<T extends RolesCreateManyAndReturnArgs>(args?: Prisma.SelectSubset<T, RolesCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>
599
+
600
+ /**
601
+ * Delete a Roles.
602
+ * @param {RolesDeleteArgs} args - Arguments to delete one Roles.
603
+ * @example
604
+ * // Delete one Roles
605
+ * const Roles = await prisma.roles.delete({
606
+ * where: {
607
+ * // ... filter to delete one Roles
608
+ * }
609
+ * })
610
+ *
611
+ */
612
+ delete<T extends RolesDeleteArgs>(args: Prisma.SelectSubset<T, RolesDeleteArgs<ExtArgs>>): Prisma.Prisma__RolesClient<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
613
+
614
+ /**
615
+ * Update one Roles.
616
+ * @param {RolesUpdateArgs} args - Arguments to update one Roles.
617
+ * @example
618
+ * // Update one Roles
619
+ * const roles = await prisma.roles.update({
620
+ * where: {
621
+ * // ... provide filter here
622
+ * },
623
+ * data: {
624
+ * // ... provide data here
625
+ * }
626
+ * })
627
+ *
628
+ */
629
+ update<T extends RolesUpdateArgs>(args: Prisma.SelectSubset<T, RolesUpdateArgs<ExtArgs>>): Prisma.Prisma__RolesClient<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
630
+
631
+ /**
632
+ * Delete zero or more Roles.
633
+ * @param {RolesDeleteManyArgs} args - Arguments to filter Roles to delete.
634
+ * @example
635
+ * // Delete a few Roles
636
+ * const { count } = await prisma.roles.deleteMany({
637
+ * where: {
638
+ * // ... provide filter here
639
+ * }
640
+ * })
641
+ *
642
+ */
643
+ deleteMany<T extends RolesDeleteManyArgs>(args?: Prisma.SelectSubset<T, RolesDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
644
+
645
+ /**
646
+ * Update zero or more Roles.
647
+ * Note, that providing `undefined` is treated as the value not being there.
648
+ * Read more here: https://pris.ly/d/null-undefined
649
+ * @param {RolesUpdateManyArgs} args - Arguments to update one or more rows.
650
+ * @example
651
+ * // Update many Roles
652
+ * const roles = await prisma.roles.updateMany({
653
+ * where: {
654
+ * // ... provide filter here
655
+ * },
656
+ * data: {
657
+ * // ... provide data here
658
+ * }
659
+ * })
660
+ *
661
+ */
662
+ updateMany<T extends RolesUpdateManyArgs>(args: Prisma.SelectSubset<T, RolesUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
663
+
664
+ /**
665
+ * Update zero or more Roles and returns the data updated in the database.
666
+ * @param {RolesUpdateManyAndReturnArgs} args - Arguments to update many Roles.
667
+ * @example
668
+ * // Update many Roles
669
+ * const roles = await prisma.roles.updateManyAndReturn({
670
+ * where: {
671
+ * // ... provide filter here
672
+ * },
673
+ * data: [
674
+ * // ... provide data here
675
+ * ]
676
+ * })
677
+ *
678
+ * // Update zero or more Roles and only return the `role_id`
679
+ * const rolesWithRole_idOnly = await prisma.roles.updateManyAndReturn({
680
+ * select: { role_id: true },
681
+ * where: {
682
+ * // ... provide filter here
683
+ * },
684
+ * data: [
685
+ * // ... provide data here
686
+ * ]
687
+ * })
688
+ * Note, that providing `undefined` is treated as the value not being there.
689
+ * Read more here: https://pris.ly/d/null-undefined
690
+ *
691
+ */
692
+ updateManyAndReturn<T extends RolesUpdateManyAndReturnArgs>(args: Prisma.SelectSubset<T, RolesUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>
693
+
694
+ /**
695
+ * Create or update one Roles.
696
+ * @param {RolesUpsertArgs} args - Arguments to update or create a Roles.
697
+ * @example
698
+ * // Update or create a Roles
699
+ * const roles = await prisma.roles.upsert({
700
+ * create: {
701
+ * // ... data to create a Roles
702
+ * },
703
+ * update: {
704
+ * // ... in case it already exists, update
705
+ * },
706
+ * where: {
707
+ * // ... the filter for the Roles we want to update
708
+ * }
709
+ * })
710
+ */
711
+ upsert<T extends RolesUpsertArgs>(args: Prisma.SelectSubset<T, RolesUpsertArgs<ExtArgs>>): Prisma.Prisma__RolesClient<runtime.Types.Result.GetResult<Prisma.$RolesPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
712
+
713
+
714
+ /**
715
+ * Count the number of Roles.
716
+ * Note, that providing `undefined` is treated as the value not being there.
717
+ * Read more here: https://pris.ly/d/null-undefined
718
+ * @param {RolesCountArgs} args - Arguments to filter Roles to count.
719
+ * @example
720
+ * // Count the number of Roles
721
+ * const count = await prisma.roles.count({
722
+ * where: {
723
+ * // ... the filter for the Roles we want to count
724
+ * }
725
+ * })
726
+ **/
727
+ count<T extends RolesCountArgs>(
728
+ args?: Prisma.Subset<T, RolesCountArgs>,
729
+ ): Prisma.PrismaPromise<
730
+ T extends runtime.Types.Utils.Record<'select', any>
731
+ ? T['select'] extends true
732
+ ? number
733
+ : Prisma.GetScalarType<T['select'], RolesCountAggregateOutputType>
734
+ : number
735
+ >
736
+
737
+ /**
738
+ * Allows you to perform aggregations operations on a Roles.
739
+ * Note, that providing `undefined` is treated as the value not being there.
740
+ * Read more here: https://pris.ly/d/null-undefined
741
+ * @param {RolesAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
742
+ * @example
743
+ * // Ordered by age ascending
744
+ * // Where email contains prisma.io
745
+ * // Limited to the 10 users
746
+ * const aggregations = await prisma.user.aggregate({
747
+ * _avg: {
748
+ * age: true,
749
+ * },
750
+ * where: {
751
+ * email: {
752
+ * contains: "prisma.io",
753
+ * },
754
+ * },
755
+ * orderBy: {
756
+ * age: "asc",
757
+ * },
758
+ * take: 10,
759
+ * })
760
+ **/
761
+ aggregate<T extends RolesAggregateArgs>(args: Prisma.Subset<T, RolesAggregateArgs>): Prisma.PrismaPromise<GetRolesAggregateType<T>>
762
+
763
+ /**
764
+ * Group by Roles.
765
+ * Note, that providing `undefined` is treated as the value not being there.
766
+ * Read more here: https://pris.ly/d/null-undefined
767
+ * @param {RolesGroupByArgs} args - Group by arguments.
768
+ * @example
769
+ * // Group by city, order by createdAt, get count
770
+ * const result = await prisma.user.groupBy({
771
+ * by: ['city', 'createdAt'],
772
+ * orderBy: {
773
+ * createdAt: true
774
+ * },
775
+ * _count: {
776
+ * _all: true
777
+ * },
778
+ * })
779
+ *
780
+ **/
781
+ groupBy<
782
+ T extends RolesGroupByArgs,
783
+ HasSelectOrTake extends Prisma.Or<
784
+ Prisma.Extends<'skip', Prisma.Keys<T>>,
785
+ Prisma.Extends<'take', Prisma.Keys<T>>
786
+ >,
787
+ OrderByArg extends Prisma.True extends HasSelectOrTake
788
+ ? { orderBy: RolesGroupByArgs['orderBy'] }
789
+ : { orderBy?: RolesGroupByArgs['orderBy'] },
790
+ OrderFields extends Prisma.ExcludeUnderscoreKeys<Prisma.Keys<Prisma.MaybeTupleToUnion<T['orderBy']>>>,
791
+ ByFields extends Prisma.MaybeTupleToUnion<T['by']>,
792
+ ByValid extends Prisma.Has<ByFields, OrderFields>,
793
+ HavingFields extends Prisma.GetHavingFields<T['having']>,
794
+ HavingValid extends Prisma.Has<ByFields, HavingFields>,
795
+ ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False,
796
+ InputErrors extends ByEmpty extends Prisma.True
797
+ ? `Error: "by" must not be empty.`
798
+ : HavingValid extends Prisma.False
799
+ ? {
800
+ [P in HavingFields]: P extends ByFields
801
+ ? never
802
+ : P extends string
803
+ ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
804
+ : [
805
+ Error,
806
+ 'Field ',
807
+ P,
808
+ ` in "having" needs to be provided in "by"`,
809
+ ]
810
+ }[HavingFields]
811
+ : 'take' extends Prisma.Keys<T>
812
+ ? 'orderBy' extends Prisma.Keys<T>
813
+ ? ByValid extends Prisma.True
814
+ ? {}
815
+ : {
816
+ [P in OrderFields]: P extends ByFields
817
+ ? never
818
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
819
+ }[OrderFields]
820
+ : 'Error: If you provide "take", you also need to provide "orderBy"'
821
+ : 'skip' extends Prisma.Keys<T>
822
+ ? 'orderBy' extends Prisma.Keys<T>
823
+ ? ByValid extends Prisma.True
824
+ ? {}
825
+ : {
826
+ [P in OrderFields]: P extends ByFields
827
+ ? never
828
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
829
+ }[OrderFields]
830
+ : 'Error: If you provide "skip", you also need to provide "orderBy"'
831
+ : ByValid extends Prisma.True
832
+ ? {}
833
+ : {
834
+ [P in OrderFields]: P extends ByFields
835
+ ? never
836
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
837
+ }[OrderFields]
838
+ >(args: Prisma.SubsetIntersection<T, RolesGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetRolesGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
839
+ /**
840
+ * Fields of the Roles model
841
+ */
842
+ readonly fields: RolesFieldRefs;
843
+ }
844
+
845
+ /**
846
+ * The delegate class that acts as a "Promise-like" for Roles.
847
+ * Why is this prefixed with `Prisma__`?
848
+ * Because we want to prevent naming conflicts as mentioned in
849
+ * https://github.com/prisma/prisma-client-js/issues/707
850
+ */
851
+ export interface Prisma__RolesClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
852
+ readonly [Symbol.toStringTag]: "PrismaPromise"
853
+ users<T extends Prisma.Roles$usersArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Roles$usersArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$UsersPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
854
+ /**
855
+ * Attaches callbacks for the resolution and/or rejection of the Promise.
856
+ * @param onfulfilled The callback to execute when the Promise is resolved.
857
+ * @param onrejected The callback to execute when the Promise is rejected.
858
+ * @returns A Promise for the completion of which ever callback is executed.
859
+ */
860
+ 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>
861
+ /**
862
+ * Attaches a callback for only the rejection of the Promise.
863
+ * @param onrejected The callback to execute when the Promise is rejected.
864
+ * @returns A Promise for the completion of the callback.
865
+ */
866
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): runtime.Types.Utils.JsPromise<T | TResult>
867
+ /**
868
+ * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
869
+ * resolved value cannot be modified from the callback.
870
+ * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
871
+ * @returns A Promise for the completion of the callback.
872
+ */
873
+ finally(onfinally?: (() => void) | undefined | null): runtime.Types.Utils.JsPromise<T>
874
+ }
875
+
876
+
877
+
878
+
879
+ /**
880
+ * Fields of the Roles model
881
+ */
882
+ export interface RolesFieldRefs {
883
+ readonly role_id: Prisma.FieldRef<"Roles", 'String'>
884
+ readonly role_name: Prisma.FieldRef<"Roles", 'String'>
885
+ readonly description: Prisma.FieldRef<"Roles", 'String'>
886
+ }
887
+
888
+
889
+ // Custom InputTypes
890
+ /**
891
+ * Roles findUnique
892
+ */
893
+ export type RolesFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
894
+ /**
895
+ * Select specific fields to fetch from the Roles
896
+ */
897
+ select?: Prisma.RolesSelect<ExtArgs> | null
898
+ /**
899
+ * Omit specific fields from the Roles
900
+ */
901
+ omit?: Prisma.RolesOmit<ExtArgs> | null
902
+ /**
903
+ * Choose, which related nodes to fetch as well
904
+ */
905
+ include?: Prisma.RolesInclude<ExtArgs> | null
906
+ /**
907
+ * Filter, which Roles to fetch.
908
+ */
909
+ where: Prisma.RolesWhereUniqueInput
910
+ }
911
+
912
+ /**
913
+ * Roles findUniqueOrThrow
914
+ */
915
+ export type RolesFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
916
+ /**
917
+ * Select specific fields to fetch from the Roles
918
+ */
919
+ select?: Prisma.RolesSelect<ExtArgs> | null
920
+ /**
921
+ * Omit specific fields from the Roles
922
+ */
923
+ omit?: Prisma.RolesOmit<ExtArgs> | null
924
+ /**
925
+ * Choose, which related nodes to fetch as well
926
+ */
927
+ include?: Prisma.RolesInclude<ExtArgs> | null
928
+ /**
929
+ * Filter, which Roles to fetch.
930
+ */
931
+ where: Prisma.RolesWhereUniqueInput
932
+ }
933
+
934
+ /**
935
+ * Roles findFirst
936
+ */
937
+ export type RolesFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
938
+ /**
939
+ * Select specific fields to fetch from the Roles
940
+ */
941
+ select?: Prisma.RolesSelect<ExtArgs> | null
942
+ /**
943
+ * Omit specific fields from the Roles
944
+ */
945
+ omit?: Prisma.RolesOmit<ExtArgs> | null
946
+ /**
947
+ * Choose, which related nodes to fetch as well
948
+ */
949
+ include?: Prisma.RolesInclude<ExtArgs> | null
950
+ /**
951
+ * Filter, which Roles to fetch.
952
+ */
953
+ where?: Prisma.RolesWhereInput
954
+ /**
955
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
956
+ *
957
+ * Determine the order of Roles to fetch.
958
+ */
959
+ orderBy?: Prisma.RolesOrderByWithRelationInput | Prisma.RolesOrderByWithRelationInput[]
960
+ /**
961
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
962
+ *
963
+ * Sets the position for searching for Roles.
964
+ */
965
+ cursor?: Prisma.RolesWhereUniqueInput
966
+ /**
967
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
968
+ *
969
+ * Take `±n` Roles from the position of the cursor.
970
+ */
971
+ take?: number
972
+ /**
973
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
974
+ *
975
+ * Skip the first `n` Roles.
976
+ */
977
+ skip?: number
978
+ /**
979
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
980
+ *
981
+ * Filter by unique combinations of Roles.
982
+ */
983
+ distinct?: Prisma.RolesScalarFieldEnum | Prisma.RolesScalarFieldEnum[]
984
+ }
985
+
986
+ /**
987
+ * Roles findFirstOrThrow
988
+ */
989
+ export type RolesFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
990
+ /**
991
+ * Select specific fields to fetch from the Roles
992
+ */
993
+ select?: Prisma.RolesSelect<ExtArgs> | null
994
+ /**
995
+ * Omit specific fields from the Roles
996
+ */
997
+ omit?: Prisma.RolesOmit<ExtArgs> | null
998
+ /**
999
+ * Choose, which related nodes to fetch as well
1000
+ */
1001
+ include?: Prisma.RolesInclude<ExtArgs> | null
1002
+ /**
1003
+ * Filter, which Roles to fetch.
1004
+ */
1005
+ where?: Prisma.RolesWhereInput
1006
+ /**
1007
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1008
+ *
1009
+ * Determine the order of Roles to fetch.
1010
+ */
1011
+ orderBy?: Prisma.RolesOrderByWithRelationInput | Prisma.RolesOrderByWithRelationInput[]
1012
+ /**
1013
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1014
+ *
1015
+ * Sets the position for searching for Roles.
1016
+ */
1017
+ cursor?: Prisma.RolesWhereUniqueInput
1018
+ /**
1019
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1020
+ *
1021
+ * Take `±n` Roles from the position of the cursor.
1022
+ */
1023
+ take?: number
1024
+ /**
1025
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1026
+ *
1027
+ * Skip the first `n` Roles.
1028
+ */
1029
+ skip?: number
1030
+ /**
1031
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1032
+ *
1033
+ * Filter by unique combinations of Roles.
1034
+ */
1035
+ distinct?: Prisma.RolesScalarFieldEnum | Prisma.RolesScalarFieldEnum[]
1036
+ }
1037
+
1038
+ /**
1039
+ * Roles findMany
1040
+ */
1041
+ export type RolesFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1042
+ /**
1043
+ * Select specific fields to fetch from the Roles
1044
+ */
1045
+ select?: Prisma.RolesSelect<ExtArgs> | null
1046
+ /**
1047
+ * Omit specific fields from the Roles
1048
+ */
1049
+ omit?: Prisma.RolesOmit<ExtArgs> | null
1050
+ /**
1051
+ * Choose, which related nodes to fetch as well
1052
+ */
1053
+ include?: Prisma.RolesInclude<ExtArgs> | null
1054
+ /**
1055
+ * Filter, which Roles to fetch.
1056
+ */
1057
+ where?: Prisma.RolesWhereInput
1058
+ /**
1059
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1060
+ *
1061
+ * Determine the order of Roles to fetch.
1062
+ */
1063
+ orderBy?: Prisma.RolesOrderByWithRelationInput | Prisma.RolesOrderByWithRelationInput[]
1064
+ /**
1065
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1066
+ *
1067
+ * Sets the position for listing Roles.
1068
+ */
1069
+ cursor?: Prisma.RolesWhereUniqueInput
1070
+ /**
1071
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1072
+ *
1073
+ * Take `±n` Roles from the position of the cursor.
1074
+ */
1075
+ take?: number
1076
+ /**
1077
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1078
+ *
1079
+ * Skip the first `n` Roles.
1080
+ */
1081
+ skip?: number
1082
+ /**
1083
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1084
+ *
1085
+ * Filter by unique combinations of Roles.
1086
+ */
1087
+ distinct?: Prisma.RolesScalarFieldEnum | Prisma.RolesScalarFieldEnum[]
1088
+ }
1089
+
1090
+ /**
1091
+ * Roles create
1092
+ */
1093
+ export type RolesCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1094
+ /**
1095
+ * Select specific fields to fetch from the Roles
1096
+ */
1097
+ select?: Prisma.RolesSelect<ExtArgs> | null
1098
+ /**
1099
+ * Omit specific fields from the Roles
1100
+ */
1101
+ omit?: Prisma.RolesOmit<ExtArgs> | null
1102
+ /**
1103
+ * Choose, which related nodes to fetch as well
1104
+ */
1105
+ include?: Prisma.RolesInclude<ExtArgs> | null
1106
+ /**
1107
+ * The data needed to create a Roles.
1108
+ */
1109
+ data: Prisma.XOR<Prisma.RolesCreateInput, Prisma.RolesUncheckedCreateInput>
1110
+ }
1111
+
1112
+ /**
1113
+ * Roles createMany
1114
+ */
1115
+ export type RolesCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1116
+ /**
1117
+ * The data used to create many Roles.
1118
+ */
1119
+ data: Prisma.RolesCreateManyInput | Prisma.RolesCreateManyInput[]
1120
+ }
1121
+
1122
+ /**
1123
+ * Roles createManyAndReturn
1124
+ */
1125
+ export type RolesCreateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1126
+ /**
1127
+ * Select specific fields to fetch from the Roles
1128
+ */
1129
+ select?: Prisma.RolesSelectCreateManyAndReturn<ExtArgs> | null
1130
+ /**
1131
+ * Omit specific fields from the Roles
1132
+ */
1133
+ omit?: Prisma.RolesOmit<ExtArgs> | null
1134
+ /**
1135
+ * The data used to create many Roles.
1136
+ */
1137
+ data: Prisma.RolesCreateManyInput | Prisma.RolesCreateManyInput[]
1138
+ }
1139
+
1140
+ /**
1141
+ * Roles update
1142
+ */
1143
+ export type RolesUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1144
+ /**
1145
+ * Select specific fields to fetch from the Roles
1146
+ */
1147
+ select?: Prisma.RolesSelect<ExtArgs> | null
1148
+ /**
1149
+ * Omit specific fields from the Roles
1150
+ */
1151
+ omit?: Prisma.RolesOmit<ExtArgs> | null
1152
+ /**
1153
+ * Choose, which related nodes to fetch as well
1154
+ */
1155
+ include?: Prisma.RolesInclude<ExtArgs> | null
1156
+ /**
1157
+ * The data needed to update a Roles.
1158
+ */
1159
+ data: Prisma.XOR<Prisma.RolesUpdateInput, Prisma.RolesUncheckedUpdateInput>
1160
+ /**
1161
+ * Choose, which Roles to update.
1162
+ */
1163
+ where: Prisma.RolesWhereUniqueInput
1164
+ }
1165
+
1166
+ /**
1167
+ * Roles updateMany
1168
+ */
1169
+ export type RolesUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1170
+ /**
1171
+ * The data used to update Roles.
1172
+ */
1173
+ data: Prisma.XOR<Prisma.RolesUpdateManyMutationInput, Prisma.RolesUncheckedUpdateManyInput>
1174
+ /**
1175
+ * Filter which Roles to update
1176
+ */
1177
+ where?: Prisma.RolesWhereInput
1178
+ /**
1179
+ * Limit how many Roles to update.
1180
+ */
1181
+ limit?: number
1182
+ }
1183
+
1184
+ /**
1185
+ * Roles updateManyAndReturn
1186
+ */
1187
+ export type RolesUpdateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1188
+ /**
1189
+ * Select specific fields to fetch from the Roles
1190
+ */
1191
+ select?: Prisma.RolesSelectUpdateManyAndReturn<ExtArgs> | null
1192
+ /**
1193
+ * Omit specific fields from the Roles
1194
+ */
1195
+ omit?: Prisma.RolesOmit<ExtArgs> | null
1196
+ /**
1197
+ * The data used to update Roles.
1198
+ */
1199
+ data: Prisma.XOR<Prisma.RolesUpdateManyMutationInput, Prisma.RolesUncheckedUpdateManyInput>
1200
+ /**
1201
+ * Filter which Roles to update
1202
+ */
1203
+ where?: Prisma.RolesWhereInput
1204
+ /**
1205
+ * Limit how many Roles to update.
1206
+ */
1207
+ limit?: number
1208
+ }
1209
+
1210
+ /**
1211
+ * Roles upsert
1212
+ */
1213
+ export type RolesUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1214
+ /**
1215
+ * Select specific fields to fetch from the Roles
1216
+ */
1217
+ select?: Prisma.RolesSelect<ExtArgs> | null
1218
+ /**
1219
+ * Omit specific fields from the Roles
1220
+ */
1221
+ omit?: Prisma.RolesOmit<ExtArgs> | null
1222
+ /**
1223
+ * Choose, which related nodes to fetch as well
1224
+ */
1225
+ include?: Prisma.RolesInclude<ExtArgs> | null
1226
+ /**
1227
+ * The filter to search for the Roles to update in case it exists.
1228
+ */
1229
+ where: Prisma.RolesWhereUniqueInput
1230
+ /**
1231
+ * In case the Roles found by the `where` argument doesn't exist, create a new Roles with this data.
1232
+ */
1233
+ create: Prisma.XOR<Prisma.RolesCreateInput, Prisma.RolesUncheckedCreateInput>
1234
+ /**
1235
+ * In case the Roles was found with the provided `where` argument, update it with this data.
1236
+ */
1237
+ update: Prisma.XOR<Prisma.RolesUpdateInput, Prisma.RolesUncheckedUpdateInput>
1238
+ }
1239
+
1240
+ /**
1241
+ * Roles delete
1242
+ */
1243
+ export type RolesDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1244
+ /**
1245
+ * Select specific fields to fetch from the Roles
1246
+ */
1247
+ select?: Prisma.RolesSelect<ExtArgs> | null
1248
+ /**
1249
+ * Omit specific fields from the Roles
1250
+ */
1251
+ omit?: Prisma.RolesOmit<ExtArgs> | null
1252
+ /**
1253
+ * Choose, which related nodes to fetch as well
1254
+ */
1255
+ include?: Prisma.RolesInclude<ExtArgs> | null
1256
+ /**
1257
+ * Filter which Roles to delete.
1258
+ */
1259
+ where: Prisma.RolesWhereUniqueInput
1260
+ }
1261
+
1262
+ /**
1263
+ * Roles deleteMany
1264
+ */
1265
+ export type RolesDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1266
+ /**
1267
+ * Filter which Roles to delete
1268
+ */
1269
+ where?: Prisma.RolesWhereInput
1270
+ /**
1271
+ * Limit how many Roles to delete.
1272
+ */
1273
+ limit?: number
1274
+ }
1275
+
1276
+ /**
1277
+ * Roles.users
1278
+ */
1279
+ export type Roles$usersArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1280
+ /**
1281
+ * Select specific fields to fetch from the Users
1282
+ */
1283
+ select?: Prisma.UsersSelect<ExtArgs> | null
1284
+ /**
1285
+ * Omit specific fields from the Users
1286
+ */
1287
+ omit?: Prisma.UsersOmit<ExtArgs> | null
1288
+ /**
1289
+ * Choose, which related nodes to fetch as well
1290
+ */
1291
+ include?: Prisma.UsersInclude<ExtArgs> | null
1292
+ where?: Prisma.UsersWhereInput
1293
+ orderBy?: Prisma.UsersOrderByWithRelationInput | Prisma.UsersOrderByWithRelationInput[]
1294
+ cursor?: Prisma.UsersWhereUniqueInput
1295
+ take?: number
1296
+ skip?: number
1297
+ distinct?: Prisma.UsersScalarFieldEnum | Prisma.UsersScalarFieldEnum[]
1298
+ }
1299
+
1300
+ /**
1301
+ * Roles without action
1302
+ */
1303
+ export type RolesDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1304
+ /**
1305
+ * Select specific fields to fetch from the Roles
1306
+ */
1307
+ select?: Prisma.RolesSelect<ExtArgs> | null
1308
+ /**
1309
+ * Omit specific fields from the Roles
1310
+ */
1311
+ omit?: Prisma.RolesOmit<ExtArgs> | null
1312
+ /**
1313
+ * Choose, which related nodes to fetch as well
1314
+ */
1315
+ include?: Prisma.RolesInclude<ExtArgs> | null
1316
+ }