@appweaver/core 1.0.0

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 (271) hide show
  1. package/LICENSE +1 -0
  2. package/README.md +7 -0
  3. package/app/application.d.ts +43 -0
  4. package/app/application.js +112 -0
  5. package/app/create-app.d.ts +32 -0
  6. package/app/create-app.js +38 -0
  7. package/app/index.d.ts +2 -0
  8. package/app/index.js +18 -0
  9. package/app/lifecycle-manager.d.ts +20 -0
  10. package/app/lifecycle-manager.js +42 -0
  11. package/app/load-modules.d.ts +10 -0
  12. package/app/load-modules.js +50 -0
  13. package/app/load-providers.d.ts +8 -0
  14. package/app/load-providers.js +33 -0
  15. package/cache/cache-service.d.ts +72 -0
  16. package/cache/cache-service.js +202 -0
  17. package/cache/cache.d.ts +12 -0
  18. package/cache/cache.js +184 -0
  19. package/cache/caching.d.ts +8 -0
  20. package/cache/caching.js +72 -0
  21. package/cache/eviction/eviction-index.d.ts +35 -0
  22. package/cache/eviction/eviction-index.js +2 -0
  23. package/cache/eviction/fifo-eviction-index.d.ts +7 -0
  24. package/cache/eviction/fifo-eviction-index.js +28 -0
  25. package/cache/eviction/index.d.ts +4 -0
  26. package/cache/eviction/index.js +20 -0
  27. package/cache/eviction/lfu-eviction-index.d.ts +8 -0
  28. package/cache/eviction/lfu-eviction-index.js +82 -0
  29. package/cache/eviction/lru-eviction-index.d.ts +8 -0
  30. package/cache/eviction/lru-eviction-index.js +81 -0
  31. package/cache/index.d.ts +2 -0
  32. package/cache/index.js +18 -0
  33. package/cache/memory-cache.d.ts +4 -0
  34. package/cache/memory-cache.js +12 -0
  35. package/cache/redis-cache.d.ts +4 -0
  36. package/cache/redis-cache.js +12 -0
  37. package/context/context.d.ts +2 -0
  38. package/context/context.js +13 -0
  39. package/context/dependency-injection.d.ts +98 -0
  40. package/context/dependency-injection.js +276 -0
  41. package/context/index.d.ts +2 -0
  42. package/context/index.js +18 -0
  43. package/database/create-client.d.ts +11 -0
  44. package/database/create-client.js +142 -0
  45. package/database/index.d.ts +1 -0
  46. package/database/index.js +17 -0
  47. package/database/prisma-database.d.ts +15 -0
  48. package/database/prisma-database.js +53 -0
  49. package/errors/error-handler.d.ts +3 -0
  50. package/errors/error-handler.js +24 -0
  51. package/errors/error-schema.d.ts +32 -0
  52. package/errors/error-schema.js +31 -0
  53. package/errors/http-error.d.ts +21 -0
  54. package/errors/http-error.js +33 -0
  55. package/errors/index.d.ts +3 -0
  56. package/errors/index.js +19 -0
  57. package/events/node-events.d.ts +7 -0
  58. package/events/node-events.js +39 -0
  59. package/export/export-service.d.ts +19 -0
  60. package/export/export-service.js +154 -0
  61. package/export/index.d.ts +1 -0
  62. package/export/index.js +17 -0
  63. package/factory/create-model.d.ts +2 -0
  64. package/factory/create-model.js +366 -0
  65. package/factory/create-policy.d.ts +2 -0
  66. package/factory/create-policy.js +16 -0
  67. package/factory/create-routes.d.ts +2 -0
  68. package/factory/create-routes.js +21 -0
  69. package/factory/create-service.d.ts +3 -0
  70. package/factory/create-service.js +97 -0
  71. package/factory/index.d.ts +4 -0
  72. package/factory/index.js +20 -0
  73. package/health/health-routes.d.ts +2 -0
  74. package/health/health-routes.js +36 -0
  75. package/health/health-schema.d.ts +45 -0
  76. package/health/health-schema.js +52 -0
  77. package/health/health-service.d.ts +38 -0
  78. package/health/health-service.js +82 -0
  79. package/health/index.d.ts +2 -0
  80. package/health/index.js +18 -0
  81. package/index.d.ts +15 -0
  82. package/index.js +31 -0
  83. package/mailer/email-service.d.ts +36 -0
  84. package/mailer/email-service.js +89 -0
  85. package/mailer/index.d.ts +1 -0
  86. package/mailer/index.js +17 -0
  87. package/mailer/json-mailer.d.ts +7 -0
  88. package/mailer/json-mailer.js +32 -0
  89. package/mailer/smtp-mailer.d.ts +7 -0
  90. package/mailer/smtp-mailer.js +43 -0
  91. package/memory/in-memory.d.ts +24 -0
  92. package/memory/in-memory.js +164 -0
  93. package/memory/redis.d.ts +26 -0
  94. package/memory/redis.js +158 -0
  95. package/package.json +68 -0
  96. package/prisma/client/browser.d.ts +34 -0
  97. package/prisma/client/browser.js +56 -0
  98. package/prisma/client/client.d.ts +53 -0
  99. package/prisma/client/client.js +70 -0
  100. package/prisma/client/commonInputTypes.d.ts +395 -0
  101. package/prisma/client/commonInputTypes.js +11 -0
  102. package/prisma/client/enums.d.ts +1 -0
  103. package/prisma/client/enums.js +11 -0
  104. package/prisma/client/internal/class.d.ts +187 -0
  105. package/prisma/client/internal/class.js +85 -0
  106. package/prisma/client/internal/prismaNamespace.d.ts +987 -0
  107. package/prisma/client/internal/prismaNamespace.js +193 -0
  108. package/prisma/client/internal/prismaNamespaceBrowser.d.ts +125 -0
  109. package/prisma/client/internal/prismaNamespaceBrowser.js +164 -0
  110. package/prisma/client/models/ApiKey.d.ts +1167 -0
  111. package/prisma/client/models/ApiKey.js +2 -0
  112. package/prisma/client/models/File.d.ts +1248 -0
  113. package/prisma/client/models/File.js +2 -0
  114. package/prisma/client/models/OneTimeToken.d.ts +1083 -0
  115. package/prisma/client/models/OneTimeToken.js +2 -0
  116. package/prisma/client/models/Permission.d.ts +1209 -0
  117. package/prisma/client/models/Permission.js +2 -0
  118. package/prisma/client/models/Role.d.ts +1209 -0
  119. package/prisma/client/models/Role.js +2 -0
  120. package/prisma/client/models/Seeder.d.ts +1023 -0
  121. package/prisma/client/models/Seeder.js +2 -0
  122. package/prisma/client/models.d.ts +7 -0
  123. package/prisma/client/models.js +2 -0
  124. package/queue/bull-queue.d.ts +37 -0
  125. package/queue/bull-queue.js +207 -0
  126. package/queue/memory-queue.d.ts +54 -0
  127. package/queue/memory-queue.js +283 -0
  128. package/resource/index.d.ts +4 -0
  129. package/resource/index.js +20 -0
  130. package/resource/resource-loader.d.ts +26 -0
  131. package/resource/resource-loader.js +161 -0
  132. package/resource/resource-routes.d.ts +3 -0
  133. package/resource/resource-routes.js +174 -0
  134. package/resource/resource-schema.d.ts +33 -0
  135. package/resource/resource-schema.js +186 -0
  136. package/resource/resource-service.d.ts +89 -0
  137. package/resource/resource-service.js +772 -0
  138. package/resources.d.ts +9 -0
  139. package/resources.js +24 -0
  140. package/scheduler/cron-scheduler.d.ts +12 -0
  141. package/scheduler/cron-scheduler.js +73 -0
  142. package/security/account/account-routes.d.ts +2 -0
  143. package/security/account/account-routes.js +104 -0
  144. package/security/account/account-schema.d.ts +290 -0
  145. package/security/account/account-schema.js +166 -0
  146. package/security/account/account-service.d.ts +88 -0
  147. package/security/account/account-service.js +218 -0
  148. package/security/account/index.d.ts +3 -0
  149. package/security/account/index.js +19 -0
  150. package/security/api-key/api-key-auth.d.ts +4 -0
  151. package/security/api-key/api-key-auth.js +66 -0
  152. package/security/api-key/index.d.ts +1 -0
  153. package/security/api-key/index.js +17 -0
  154. package/security/auth-routes.d.ts +2 -0
  155. package/security/auth-routes.js +80 -0
  156. package/security/auth-schema.d.ts +215 -0
  157. package/security/auth-schema.js +129 -0
  158. package/security/auth-service.d.ts +117 -0
  159. package/security/auth-service.js +272 -0
  160. package/security/auth.d.ts +3 -0
  161. package/security/auth.js +127 -0
  162. package/security/basic/basic-auth.d.ts +4 -0
  163. package/security/basic/basic-auth.js +32 -0
  164. package/security/basic/index.d.ts +1 -0
  165. package/security/basic/index.js +17 -0
  166. package/security/create-auth-resources.d.ts +6 -0
  167. package/security/create-auth-resources.js +129 -0
  168. package/security/helper.d.ts +127 -0
  169. package/security/helper.js +329 -0
  170. package/security/index.d.ts +4 -0
  171. package/security/index.js +20 -0
  172. package/security/jwt/index.d.ts +2 -0
  173. package/security/jwt/index.js +18 -0
  174. package/security/jwt/jwt-auth.d.ts +4 -0
  175. package/security/jwt/jwt-auth.js +57 -0
  176. package/security/jwt/jwt-keys.d.ts +7 -0
  177. package/security/jwt/jwt-keys.js +43 -0
  178. package/security/oauth2/create-oauth2-plugin.d.ts +17 -0
  179. package/security/oauth2/create-oauth2-plugin.js +85 -0
  180. package/security/oauth2/index.d.ts +3 -0
  181. package/security/oauth2/index.js +19 -0
  182. package/security/oauth2/oauth2-custom.d.ts +7 -0
  183. package/security/oauth2/oauth2-custom.js +40 -0
  184. package/security/oauth2/oauth2-facebook.d.ts +1 -0
  185. package/security/oauth2/oauth2-facebook.js +30 -0
  186. package/security/oauth2/oauth2-google.d.ts +1 -0
  187. package/security/oauth2/oauth2-google.js +28 -0
  188. package/security/oauth2/oauth2-schema.d.ts +10 -0
  189. package/security/oauth2/oauth2-schema.js +53 -0
  190. package/security/recaptcha/index.d.ts +2 -0
  191. package/security/recaptcha/index.js +18 -0
  192. package/security/recaptcha/recaptcha-verify.d.ts +1 -0
  193. package/security/recaptcha/recaptcha-verify.js +33 -0
  194. package/security/recaptcha/recaptcha.d.ts +2 -0
  195. package/security/recaptcha/recaptcha.js +22 -0
  196. package/security/resources/api-key/model.d.ts +2 -0
  197. package/security/resources/api-key/model.js +63 -0
  198. package/security/resources/api-key/policy.d.ts +2 -0
  199. package/security/resources/api-key/policy.js +26 -0
  200. package/security/resources/api-key/routes.d.ts +2 -0
  201. package/security/resources/api-key/routes.js +15 -0
  202. package/security/resources/api-key/service.d.ts +3 -0
  203. package/security/resources/api-key/service.js +33 -0
  204. package/security/resources/one-time-token/model.d.ts +2 -0
  205. package/security/resources/one-time-token/model.js +32 -0
  206. package/security/resources/permission/model.d.ts +2 -0
  207. package/security/resources/permission/model.js +16 -0
  208. package/security/resources/role/model.d.ts +2 -0
  209. package/security/resources/role/model.js +22 -0
  210. package/security/store/database-security-store.d.ts +5 -0
  211. package/security/store/database-security-store.js +51 -0
  212. package/security/store/redis-security-store.d.ts +5 -0
  213. package/security/store/redis-security-store.js +32 -0
  214. package/seeder/create-seeder.d.ts +21 -0
  215. package/seeder/create-seeder.js +17 -0
  216. package/seeder/index.d.ts +2 -0
  217. package/seeder/index.js +18 -0
  218. package/seeder/resources/seeder/model.d.ts +2 -0
  219. package/seeder/resources/seeder/model.js +38 -0
  220. package/seeder/seeder.d.ts +20 -0
  221. package/seeder/seeder.js +175 -0
  222. package/server/create-server.d.ts +20 -0
  223. package/server/create-server.js +160 -0
  224. package/server/index.d.ts +4 -0
  225. package/server/index.js +20 -0
  226. package/server/info-route.d.ts +2 -0
  227. package/server/info-route.js +18 -0
  228. package/server/info-schema.d.ts +37 -0
  229. package/server/info-schema.js +19 -0
  230. package/server/register-model.d.ts +2 -0
  231. package/server/register-model.js +12 -0
  232. package/server/register-plugin.d.ts +2 -0
  233. package/server/register-plugin.js +13 -0
  234. package/server/register-route.d.ts +3 -0
  235. package/server/register-route.js +74 -0
  236. package/server/schemas.d.ts +3 -0
  237. package/server/schemas.js +30 -0
  238. package/server/swagger.d.ts +3 -0
  239. package/server/swagger.js +122 -0
  240. package/storage/file-route.d.ts +2 -0
  241. package/storage/file-route.js +39 -0
  242. package/storage/file-schema.d.ts +9 -0
  243. package/storage/file-schema.js +42 -0
  244. package/storage/file-service.d.ts +81 -0
  245. package/storage/file-service.js +384 -0
  246. package/storage/filesystem-storage.d.ts +10 -0
  247. package/storage/filesystem-storage.js +128 -0
  248. package/storage/index.d.ts +2 -0
  249. package/storage/index.js +18 -0
  250. package/storage/resources/file/model.d.ts +2 -0
  251. package/storage/resources/file/model.js +75 -0
  252. package/types/application-context.d.ts +20 -0
  253. package/types/application-context.js +2 -0
  254. package/types/auth.d.ts +31 -0
  255. package/types/auth.js +2 -0
  256. package/types/fastify-extensions.d.ts +24 -0
  257. package/types/fastify-extensions.js +4 -0
  258. package/types/generated.d.ts +193 -0
  259. package/types/generated.js +3 -0
  260. package/types/index.d.ts +4 -0
  261. package/types/index.js +20 -0
  262. package/types/server.d.ts +4 -0
  263. package/types/server.js +2 -0
  264. package/utils/export-util.d.ts +8 -0
  265. package/utils/export-util.js +25 -0
  266. package/utils/file-util.d.ts +64 -0
  267. package/utils/file-util.js +141 -0
  268. package/utils/index.d.ts +3 -0
  269. package/utils/index.js +19 -0
  270. package/utils/schema-util.d.ts +20 -0
  271. package/utils/schema-util.js +37 -0
@@ -0,0 +1,1209 @@
1
+ import type * as runtime from "@prisma/client/runtime/client";
2
+ import type * as Prisma from "../internal/prismaNamespace";
3
+ /**
4
+ * Model Role
5
+ *
6
+ */
7
+ export type RoleModel = runtime.Types.Result.DefaultSelection<Prisma.$RolePayload>;
8
+ export type AggregateRole = {
9
+ _count: RoleCountAggregateOutputType | null;
10
+ _avg: RoleAvgAggregateOutputType | null;
11
+ _sum: RoleSumAggregateOutputType | null;
12
+ _min: RoleMinAggregateOutputType | null;
13
+ _max: RoleMaxAggregateOutputType | null;
14
+ };
15
+ export type RoleAvgAggregateOutputType = {
16
+ id: number | null;
17
+ };
18
+ export type RoleSumAggregateOutputType = {
19
+ id: number | null;
20
+ };
21
+ export type RoleMinAggregateOutputType = {
22
+ id: number | null;
23
+ name: string | null;
24
+ updatedAt: Date | null;
25
+ createdAt: Date | null;
26
+ };
27
+ export type RoleMaxAggregateOutputType = {
28
+ id: number | null;
29
+ name: string | null;
30
+ updatedAt: Date | null;
31
+ createdAt: Date | null;
32
+ };
33
+ export type RoleCountAggregateOutputType = {
34
+ id: number;
35
+ name: number;
36
+ updatedAt: number;
37
+ createdAt: number;
38
+ _all: number;
39
+ };
40
+ export type RoleAvgAggregateInputType = {
41
+ id?: true;
42
+ };
43
+ export type RoleSumAggregateInputType = {
44
+ id?: true;
45
+ };
46
+ export type RoleMinAggregateInputType = {
47
+ id?: true;
48
+ name?: true;
49
+ updatedAt?: true;
50
+ createdAt?: true;
51
+ };
52
+ export type RoleMaxAggregateInputType = {
53
+ id?: true;
54
+ name?: true;
55
+ updatedAt?: true;
56
+ createdAt?: true;
57
+ };
58
+ export type RoleCountAggregateInputType = {
59
+ id?: true;
60
+ name?: true;
61
+ updatedAt?: true;
62
+ createdAt?: true;
63
+ _all?: true;
64
+ };
65
+ export type RoleAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
66
+ /**
67
+ * Filter which Role to aggregate.
68
+ */
69
+ where?: Prisma.RoleWhereInput;
70
+ /**
71
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
72
+ *
73
+ * Determine the order of Roles to fetch.
74
+ */
75
+ orderBy?: Prisma.RoleOrderByWithRelationInput | Prisma.RoleOrderByWithRelationInput[];
76
+ /**
77
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
78
+ *
79
+ * Sets the start position
80
+ */
81
+ cursor?: Prisma.RoleWhereUniqueInput;
82
+ /**
83
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
84
+ *
85
+ * Take `±n` Roles from the position of the cursor.
86
+ */
87
+ take?: number;
88
+ /**
89
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
90
+ *
91
+ * Skip the first `n` Roles.
92
+ */
93
+ skip?: number;
94
+ /**
95
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
96
+ *
97
+ * Count returned Roles
98
+ **/
99
+ _count?: true | RoleCountAggregateInputType;
100
+ /**
101
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
102
+ *
103
+ * Select which fields to average
104
+ **/
105
+ _avg?: RoleAvgAggregateInputType;
106
+ /**
107
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
108
+ *
109
+ * Select which fields to sum
110
+ **/
111
+ _sum?: RoleSumAggregateInputType;
112
+ /**
113
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
114
+ *
115
+ * Select which fields to find the minimum value
116
+ **/
117
+ _min?: RoleMinAggregateInputType;
118
+ /**
119
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
120
+ *
121
+ * Select which fields to find the maximum value
122
+ **/
123
+ _max?: RoleMaxAggregateInputType;
124
+ };
125
+ export type GetRoleAggregateType<T extends RoleAggregateArgs> = {
126
+ [P in keyof T & keyof AggregateRole]: P extends '_count' | 'count' ? T[P] extends true ? number : Prisma.GetScalarType<T[P], AggregateRole[P]> : Prisma.GetScalarType<T[P], AggregateRole[P]>;
127
+ };
128
+ export type RoleGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
129
+ where?: Prisma.RoleWhereInput;
130
+ orderBy?: Prisma.RoleOrderByWithAggregationInput | Prisma.RoleOrderByWithAggregationInput[];
131
+ by: Prisma.RoleScalarFieldEnum[] | Prisma.RoleScalarFieldEnum;
132
+ having?: Prisma.RoleScalarWhereWithAggregatesInput;
133
+ take?: number;
134
+ skip?: number;
135
+ _count?: RoleCountAggregateInputType | true;
136
+ _avg?: RoleAvgAggregateInputType;
137
+ _sum?: RoleSumAggregateInputType;
138
+ _min?: RoleMinAggregateInputType;
139
+ _max?: RoleMaxAggregateInputType;
140
+ };
141
+ export type RoleGroupByOutputType = {
142
+ id: number;
143
+ name: string;
144
+ updatedAt: Date;
145
+ createdAt: Date;
146
+ _count: RoleCountAggregateOutputType | null;
147
+ _avg: RoleAvgAggregateOutputType | null;
148
+ _sum: RoleSumAggregateOutputType | null;
149
+ _min: RoleMinAggregateOutputType | null;
150
+ _max: RoleMaxAggregateOutputType | null;
151
+ };
152
+ export type GetRoleGroupByPayload<T extends RoleGroupByArgs> = Prisma.PrismaPromise<Array<Prisma.PickEnumerable<RoleGroupByOutputType, T['by']> & {
153
+ [P in ((keyof T) & (keyof RoleGroupByOutputType))]: P extends '_count' ? T[P] extends boolean ? number : Prisma.GetScalarType<T[P], RoleGroupByOutputType[P]> : Prisma.GetScalarType<T[P], RoleGroupByOutputType[P]>;
154
+ }>>;
155
+ export type RoleWhereInput = {
156
+ AND?: Prisma.RoleWhereInput | Prisma.RoleWhereInput[];
157
+ OR?: Prisma.RoleWhereInput[];
158
+ NOT?: Prisma.RoleWhereInput | Prisma.RoleWhereInput[];
159
+ id?: Prisma.IntFilter<"Role"> | number;
160
+ name?: Prisma.StringFilter<"Role"> | string;
161
+ updatedAt?: Prisma.DateTimeFilter<"Role"> | Date | string;
162
+ createdAt?: Prisma.DateTimeFilter<"Role"> | Date | string;
163
+ permissions?: Prisma.PermissionListRelationFilter;
164
+ };
165
+ export type RoleOrderByWithRelationInput = {
166
+ id?: Prisma.SortOrder;
167
+ name?: Prisma.SortOrder;
168
+ updatedAt?: Prisma.SortOrder;
169
+ createdAt?: Prisma.SortOrder;
170
+ permissions?: Prisma.PermissionOrderByRelationAggregateInput;
171
+ };
172
+ export type RoleWhereUniqueInput = Prisma.AtLeast<{
173
+ id?: number;
174
+ name?: string;
175
+ AND?: Prisma.RoleWhereInput | Prisma.RoleWhereInput[];
176
+ OR?: Prisma.RoleWhereInput[];
177
+ NOT?: Prisma.RoleWhereInput | Prisma.RoleWhereInput[];
178
+ updatedAt?: Prisma.DateTimeFilter<"Role"> | Date | string;
179
+ createdAt?: Prisma.DateTimeFilter<"Role"> | Date | string;
180
+ permissions?: Prisma.PermissionListRelationFilter;
181
+ }, "id" | "name">;
182
+ export type RoleOrderByWithAggregationInput = {
183
+ id?: Prisma.SortOrder;
184
+ name?: Prisma.SortOrder;
185
+ updatedAt?: Prisma.SortOrder;
186
+ createdAt?: Prisma.SortOrder;
187
+ _count?: Prisma.RoleCountOrderByAggregateInput;
188
+ _avg?: Prisma.RoleAvgOrderByAggregateInput;
189
+ _max?: Prisma.RoleMaxOrderByAggregateInput;
190
+ _min?: Prisma.RoleMinOrderByAggregateInput;
191
+ _sum?: Prisma.RoleSumOrderByAggregateInput;
192
+ };
193
+ export type RoleScalarWhereWithAggregatesInput = {
194
+ AND?: Prisma.RoleScalarWhereWithAggregatesInput | Prisma.RoleScalarWhereWithAggregatesInput[];
195
+ OR?: Prisma.RoleScalarWhereWithAggregatesInput[];
196
+ NOT?: Prisma.RoleScalarWhereWithAggregatesInput | Prisma.RoleScalarWhereWithAggregatesInput[];
197
+ id?: Prisma.IntWithAggregatesFilter<"Role"> | number;
198
+ name?: Prisma.StringWithAggregatesFilter<"Role"> | string;
199
+ updatedAt?: Prisma.DateTimeWithAggregatesFilter<"Role"> | Date | string;
200
+ createdAt?: Prisma.DateTimeWithAggregatesFilter<"Role"> | Date | string;
201
+ };
202
+ export type RoleCreateInput = {
203
+ name: string;
204
+ updatedAt?: Date | string;
205
+ createdAt?: Date | string;
206
+ permissions?: Prisma.PermissionCreateNestedManyWithoutRolesInput;
207
+ };
208
+ export type RoleUncheckedCreateInput = {
209
+ id?: number;
210
+ name: string;
211
+ updatedAt?: Date | string;
212
+ createdAt?: Date | string;
213
+ permissions?: Prisma.PermissionUncheckedCreateNestedManyWithoutRolesInput;
214
+ };
215
+ export type RoleUpdateInput = {
216
+ name?: Prisma.StringFieldUpdateOperationsInput | string;
217
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
218
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
219
+ permissions?: Prisma.PermissionUpdateManyWithoutRolesNestedInput;
220
+ };
221
+ export type RoleUncheckedUpdateInput = {
222
+ id?: Prisma.IntFieldUpdateOperationsInput | number;
223
+ name?: Prisma.StringFieldUpdateOperationsInput | string;
224
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
225
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
226
+ permissions?: Prisma.PermissionUncheckedUpdateManyWithoutRolesNestedInput;
227
+ };
228
+ export type RoleCreateManyInput = {
229
+ id?: number;
230
+ name: string;
231
+ updatedAt?: Date | string;
232
+ createdAt?: Date | string;
233
+ };
234
+ export type RoleUpdateManyMutationInput = {
235
+ name?: Prisma.StringFieldUpdateOperationsInput | string;
236
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
237
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
238
+ };
239
+ export type RoleUncheckedUpdateManyInput = {
240
+ id?: Prisma.IntFieldUpdateOperationsInput | number;
241
+ name?: Prisma.StringFieldUpdateOperationsInput | string;
242
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
243
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
244
+ };
245
+ export type RoleListRelationFilter = {
246
+ every?: Prisma.RoleWhereInput;
247
+ some?: Prisma.RoleWhereInput;
248
+ none?: Prisma.RoleWhereInput;
249
+ };
250
+ export type RoleOrderByRelationAggregateInput = {
251
+ _count?: Prisma.SortOrder;
252
+ };
253
+ export type RoleCountOrderByAggregateInput = {
254
+ id?: Prisma.SortOrder;
255
+ name?: Prisma.SortOrder;
256
+ updatedAt?: Prisma.SortOrder;
257
+ createdAt?: Prisma.SortOrder;
258
+ };
259
+ export type RoleAvgOrderByAggregateInput = {
260
+ id?: Prisma.SortOrder;
261
+ };
262
+ export type RoleMaxOrderByAggregateInput = {
263
+ id?: Prisma.SortOrder;
264
+ name?: Prisma.SortOrder;
265
+ updatedAt?: Prisma.SortOrder;
266
+ createdAt?: Prisma.SortOrder;
267
+ };
268
+ export type RoleMinOrderByAggregateInput = {
269
+ id?: Prisma.SortOrder;
270
+ name?: Prisma.SortOrder;
271
+ updatedAt?: Prisma.SortOrder;
272
+ createdAt?: Prisma.SortOrder;
273
+ };
274
+ export type RoleSumOrderByAggregateInput = {
275
+ id?: Prisma.SortOrder;
276
+ };
277
+ export type RoleCreateNestedManyWithoutPermissionsInput = {
278
+ create?: Prisma.XOR<Prisma.RoleCreateWithoutPermissionsInput, Prisma.RoleUncheckedCreateWithoutPermissionsInput> | Prisma.RoleCreateWithoutPermissionsInput[] | Prisma.RoleUncheckedCreateWithoutPermissionsInput[];
279
+ connectOrCreate?: Prisma.RoleCreateOrConnectWithoutPermissionsInput | Prisma.RoleCreateOrConnectWithoutPermissionsInput[];
280
+ connect?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
281
+ };
282
+ export type RoleUncheckedCreateNestedManyWithoutPermissionsInput = {
283
+ create?: Prisma.XOR<Prisma.RoleCreateWithoutPermissionsInput, Prisma.RoleUncheckedCreateWithoutPermissionsInput> | Prisma.RoleCreateWithoutPermissionsInput[] | Prisma.RoleUncheckedCreateWithoutPermissionsInput[];
284
+ connectOrCreate?: Prisma.RoleCreateOrConnectWithoutPermissionsInput | Prisma.RoleCreateOrConnectWithoutPermissionsInput[];
285
+ connect?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
286
+ };
287
+ export type RoleUpdateManyWithoutPermissionsNestedInput = {
288
+ create?: Prisma.XOR<Prisma.RoleCreateWithoutPermissionsInput, Prisma.RoleUncheckedCreateWithoutPermissionsInput> | Prisma.RoleCreateWithoutPermissionsInput[] | Prisma.RoleUncheckedCreateWithoutPermissionsInput[];
289
+ connectOrCreate?: Prisma.RoleCreateOrConnectWithoutPermissionsInput | Prisma.RoleCreateOrConnectWithoutPermissionsInput[];
290
+ upsert?: Prisma.RoleUpsertWithWhereUniqueWithoutPermissionsInput | Prisma.RoleUpsertWithWhereUniqueWithoutPermissionsInput[];
291
+ set?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
292
+ disconnect?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
293
+ delete?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
294
+ connect?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
295
+ update?: Prisma.RoleUpdateWithWhereUniqueWithoutPermissionsInput | Prisma.RoleUpdateWithWhereUniqueWithoutPermissionsInput[];
296
+ updateMany?: Prisma.RoleUpdateManyWithWhereWithoutPermissionsInput | Prisma.RoleUpdateManyWithWhereWithoutPermissionsInput[];
297
+ deleteMany?: Prisma.RoleScalarWhereInput | Prisma.RoleScalarWhereInput[];
298
+ };
299
+ export type RoleUncheckedUpdateManyWithoutPermissionsNestedInput = {
300
+ create?: Prisma.XOR<Prisma.RoleCreateWithoutPermissionsInput, Prisma.RoleUncheckedCreateWithoutPermissionsInput> | Prisma.RoleCreateWithoutPermissionsInput[] | Prisma.RoleUncheckedCreateWithoutPermissionsInput[];
301
+ connectOrCreate?: Prisma.RoleCreateOrConnectWithoutPermissionsInput | Prisma.RoleCreateOrConnectWithoutPermissionsInput[];
302
+ upsert?: Prisma.RoleUpsertWithWhereUniqueWithoutPermissionsInput | Prisma.RoleUpsertWithWhereUniqueWithoutPermissionsInput[];
303
+ set?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
304
+ disconnect?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
305
+ delete?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
306
+ connect?: Prisma.RoleWhereUniqueInput | Prisma.RoleWhereUniqueInput[];
307
+ update?: Prisma.RoleUpdateWithWhereUniqueWithoutPermissionsInput | Prisma.RoleUpdateWithWhereUniqueWithoutPermissionsInput[];
308
+ updateMany?: Prisma.RoleUpdateManyWithWhereWithoutPermissionsInput | Prisma.RoleUpdateManyWithWhereWithoutPermissionsInput[];
309
+ deleteMany?: Prisma.RoleScalarWhereInput | Prisma.RoleScalarWhereInput[];
310
+ };
311
+ export type RoleCreateWithoutPermissionsInput = {
312
+ name: string;
313
+ updatedAt?: Date | string;
314
+ createdAt?: Date | string;
315
+ };
316
+ export type RoleUncheckedCreateWithoutPermissionsInput = {
317
+ id?: number;
318
+ name: string;
319
+ updatedAt?: Date | string;
320
+ createdAt?: Date | string;
321
+ };
322
+ export type RoleCreateOrConnectWithoutPermissionsInput = {
323
+ where: Prisma.RoleWhereUniqueInput;
324
+ create: Prisma.XOR<Prisma.RoleCreateWithoutPermissionsInput, Prisma.RoleUncheckedCreateWithoutPermissionsInput>;
325
+ };
326
+ export type RoleUpsertWithWhereUniqueWithoutPermissionsInput = {
327
+ where: Prisma.RoleWhereUniqueInput;
328
+ update: Prisma.XOR<Prisma.RoleUpdateWithoutPermissionsInput, Prisma.RoleUncheckedUpdateWithoutPermissionsInput>;
329
+ create: Prisma.XOR<Prisma.RoleCreateWithoutPermissionsInput, Prisma.RoleUncheckedCreateWithoutPermissionsInput>;
330
+ };
331
+ export type RoleUpdateWithWhereUniqueWithoutPermissionsInput = {
332
+ where: Prisma.RoleWhereUniqueInput;
333
+ data: Prisma.XOR<Prisma.RoleUpdateWithoutPermissionsInput, Prisma.RoleUncheckedUpdateWithoutPermissionsInput>;
334
+ };
335
+ export type RoleUpdateManyWithWhereWithoutPermissionsInput = {
336
+ where: Prisma.RoleScalarWhereInput;
337
+ data: Prisma.XOR<Prisma.RoleUpdateManyMutationInput, Prisma.RoleUncheckedUpdateManyWithoutPermissionsInput>;
338
+ };
339
+ export type RoleScalarWhereInput = {
340
+ AND?: Prisma.RoleScalarWhereInput | Prisma.RoleScalarWhereInput[];
341
+ OR?: Prisma.RoleScalarWhereInput[];
342
+ NOT?: Prisma.RoleScalarWhereInput | Prisma.RoleScalarWhereInput[];
343
+ id?: Prisma.IntFilter<"Role"> | number;
344
+ name?: Prisma.StringFilter<"Role"> | string;
345
+ updatedAt?: Prisma.DateTimeFilter<"Role"> | Date | string;
346
+ createdAt?: Prisma.DateTimeFilter<"Role"> | Date | string;
347
+ };
348
+ export type RoleUpdateWithoutPermissionsInput = {
349
+ name?: Prisma.StringFieldUpdateOperationsInput | string;
350
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
351
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
352
+ };
353
+ export type RoleUncheckedUpdateWithoutPermissionsInput = {
354
+ id?: Prisma.IntFieldUpdateOperationsInput | number;
355
+ name?: Prisma.StringFieldUpdateOperationsInput | string;
356
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
357
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
358
+ };
359
+ export type RoleUncheckedUpdateManyWithoutPermissionsInput = {
360
+ id?: Prisma.IntFieldUpdateOperationsInput | number;
361
+ name?: Prisma.StringFieldUpdateOperationsInput | string;
362
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
363
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string;
364
+ };
365
+ /**
366
+ * Count Type RoleCountOutputType
367
+ */
368
+ export type RoleCountOutputType = {
369
+ permissions: number;
370
+ };
371
+ export type RoleCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
372
+ permissions?: boolean | RoleCountOutputTypeCountPermissionsArgs;
373
+ };
374
+ /**
375
+ * RoleCountOutputType without action
376
+ */
377
+ export type RoleCountOutputTypeDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
378
+ /**
379
+ * Select specific fields to fetch from the RoleCountOutputType
380
+ */
381
+ select?: Prisma.RoleCountOutputTypeSelect<ExtArgs> | null;
382
+ };
383
+ /**
384
+ * RoleCountOutputType without action
385
+ */
386
+ export type RoleCountOutputTypeCountPermissionsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
387
+ where?: Prisma.PermissionWhereInput;
388
+ };
389
+ export type RoleSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
390
+ id?: boolean;
391
+ name?: boolean;
392
+ updatedAt?: boolean;
393
+ createdAt?: boolean;
394
+ permissions?: boolean | Prisma.Role$permissionsArgs<ExtArgs>;
395
+ _count?: boolean | Prisma.RoleCountOutputTypeDefaultArgs<ExtArgs>;
396
+ }, ExtArgs["result"]["role"]>;
397
+ export type RoleSelectCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
398
+ id?: boolean;
399
+ name?: boolean;
400
+ updatedAt?: boolean;
401
+ createdAt?: boolean;
402
+ }, ExtArgs["result"]["role"]>;
403
+ export type RoleSelectUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
404
+ id?: boolean;
405
+ name?: boolean;
406
+ updatedAt?: boolean;
407
+ createdAt?: boolean;
408
+ }, ExtArgs["result"]["role"]>;
409
+ export type RoleSelectScalar = {
410
+ id?: boolean;
411
+ name?: boolean;
412
+ updatedAt?: boolean;
413
+ createdAt?: boolean;
414
+ };
415
+ export type RoleOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "name" | "updatedAt" | "createdAt", ExtArgs["result"]["role"]>;
416
+ export type RoleInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
417
+ permissions?: boolean | Prisma.Role$permissionsArgs<ExtArgs>;
418
+ _count?: boolean | Prisma.RoleCountOutputTypeDefaultArgs<ExtArgs>;
419
+ };
420
+ export type RoleIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {};
421
+ export type RoleIncludeUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {};
422
+ export type $RolePayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
423
+ name: "Role";
424
+ objects: {
425
+ /**
426
+ * Related columns
427
+ */
428
+ permissions: Prisma.$PermissionPayload<ExtArgs>[];
429
+ };
430
+ scalars: runtime.Types.Extensions.GetPayloadResult<{
431
+ id: number;
432
+ name: string;
433
+ /**
434
+ * Audit columns
435
+ */
436
+ updatedAt: Date;
437
+ createdAt: Date;
438
+ }, ExtArgs["result"]["role"]>;
439
+ composites: {};
440
+ };
441
+ export type RoleGetPayload<S extends boolean | null | undefined | RoleDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$RolePayload, S>;
442
+ export type RoleCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = Omit<RoleFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
443
+ select?: RoleCountAggregateInputType | true;
444
+ };
445
+ export interface RoleDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
446
+ [K: symbol]: {
447
+ types: Prisma.TypeMap<ExtArgs>['model']['Role'];
448
+ meta: {
449
+ name: 'Role';
450
+ };
451
+ };
452
+ /**
453
+ * Find zero or one Role that matches the filter.
454
+ * @param {RoleFindUniqueArgs} args - Arguments to find a Role
455
+ * @example
456
+ * // Get one Role
457
+ * const role = await prisma.role.findUnique({
458
+ * where: {
459
+ * // ... provide filter here
460
+ * }
461
+ * })
462
+ */
463
+ findUnique<T extends RoleFindUniqueArgs>(args: Prisma.SelectSubset<T, RoleFindUniqueArgs<ExtArgs>>): Prisma.Prisma__RoleClient<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>;
464
+ /**
465
+ * Find one Role that matches the filter or throw an error with `error.code='P2025'`
466
+ * if no matches were found.
467
+ * @param {RoleFindUniqueOrThrowArgs} args - Arguments to find a Role
468
+ * @example
469
+ * // Get one Role
470
+ * const role = await prisma.role.findUniqueOrThrow({
471
+ * where: {
472
+ * // ... provide filter here
473
+ * }
474
+ * })
475
+ */
476
+ findUniqueOrThrow<T extends RoleFindUniqueOrThrowArgs>(args: Prisma.SelectSubset<T, RoleFindUniqueOrThrowArgs<ExtArgs>>): Prisma.Prisma__RoleClient<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
477
+ /**
478
+ * Find the first Role that matches the filter.
479
+ * Note, that providing `undefined` is treated as the value not being there.
480
+ * Read more here: https://pris.ly/d/null-undefined
481
+ * @param {RoleFindFirstArgs} args - Arguments to find a Role
482
+ * @example
483
+ * // Get one Role
484
+ * const role = await prisma.role.findFirst({
485
+ * where: {
486
+ * // ... provide filter here
487
+ * }
488
+ * })
489
+ */
490
+ findFirst<T extends RoleFindFirstArgs>(args?: Prisma.SelectSubset<T, RoleFindFirstArgs<ExtArgs>>): Prisma.Prisma__RoleClient<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>;
491
+ /**
492
+ * Find the first Role that matches the filter or
493
+ * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
494
+ * Note, that providing `undefined` is treated as the value not being there.
495
+ * Read more here: https://pris.ly/d/null-undefined
496
+ * @param {RoleFindFirstOrThrowArgs} args - Arguments to find a Role
497
+ * @example
498
+ * // Get one Role
499
+ * const role = await prisma.role.findFirstOrThrow({
500
+ * where: {
501
+ * // ... provide filter here
502
+ * }
503
+ * })
504
+ */
505
+ findFirstOrThrow<T extends RoleFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, RoleFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__RoleClient<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
506
+ /**
507
+ * Find zero or more Roles that matches the filter.
508
+ * Note, that providing `undefined` is treated as the value not being there.
509
+ * Read more here: https://pris.ly/d/null-undefined
510
+ * @param {RoleFindManyArgs} args - Arguments to filter and select certain fields only.
511
+ * @example
512
+ * // Get all Roles
513
+ * const roles = await prisma.role.findMany()
514
+ *
515
+ * // Get first 10 Roles
516
+ * const roles = await prisma.role.findMany({ take: 10 })
517
+ *
518
+ * // Only select the `id`
519
+ * const roleWithIdOnly = await prisma.role.findMany({ select: { id: true } })
520
+ *
521
+ */
522
+ findMany<T extends RoleFindManyArgs>(args?: Prisma.SelectSubset<T, RoleFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>;
523
+ /**
524
+ * Create a Role.
525
+ * @param {RoleCreateArgs} args - Arguments to create a Role.
526
+ * @example
527
+ * // Create one Role
528
+ * const Role = await prisma.role.create({
529
+ * data: {
530
+ * // ... data to create a Role
531
+ * }
532
+ * })
533
+ *
534
+ */
535
+ create<T extends RoleCreateArgs>(args: Prisma.SelectSubset<T, RoleCreateArgs<ExtArgs>>): Prisma.Prisma__RoleClient<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
536
+ /**
537
+ * Create many Roles.
538
+ * @param {RoleCreateManyArgs} args - Arguments to create many Roles.
539
+ * @example
540
+ * // Create many Roles
541
+ * const role = await prisma.role.createMany({
542
+ * data: [
543
+ * // ... provide data here
544
+ * ]
545
+ * })
546
+ *
547
+ */
548
+ createMany<T extends RoleCreateManyArgs>(args?: Prisma.SelectSubset<T, RoleCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>;
549
+ /**
550
+ * Create many Roles and returns the data saved in the database.
551
+ * @param {RoleCreateManyAndReturnArgs} args - Arguments to create many Roles.
552
+ * @example
553
+ * // Create many Roles
554
+ * const role = await prisma.role.createManyAndReturn({
555
+ * data: [
556
+ * // ... provide data here
557
+ * ]
558
+ * })
559
+ *
560
+ * // Create many Roles and only return the `id`
561
+ * const roleWithIdOnly = await prisma.role.createManyAndReturn({
562
+ * select: { id: true },
563
+ * data: [
564
+ * // ... provide data here
565
+ * ]
566
+ * })
567
+ * Note, that providing `undefined` is treated as the value not being there.
568
+ * Read more here: https://pris.ly/d/null-undefined
569
+ *
570
+ */
571
+ createManyAndReturn<T extends RoleCreateManyAndReturnArgs>(args?: Prisma.SelectSubset<T, RoleCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>;
572
+ /**
573
+ * Delete a Role.
574
+ * @param {RoleDeleteArgs} args - Arguments to delete one Role.
575
+ * @example
576
+ * // Delete one Role
577
+ * const Role = await prisma.role.delete({
578
+ * where: {
579
+ * // ... filter to delete one Role
580
+ * }
581
+ * })
582
+ *
583
+ */
584
+ delete<T extends RoleDeleteArgs>(args: Prisma.SelectSubset<T, RoleDeleteArgs<ExtArgs>>): Prisma.Prisma__RoleClient<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
585
+ /**
586
+ * Update one Role.
587
+ * @param {RoleUpdateArgs} args - Arguments to update one Role.
588
+ * @example
589
+ * // Update one Role
590
+ * const role = await prisma.role.update({
591
+ * where: {
592
+ * // ... provide filter here
593
+ * },
594
+ * data: {
595
+ * // ... provide data here
596
+ * }
597
+ * })
598
+ *
599
+ */
600
+ update<T extends RoleUpdateArgs>(args: Prisma.SelectSubset<T, RoleUpdateArgs<ExtArgs>>): Prisma.Prisma__RoleClient<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
601
+ /**
602
+ * Delete zero or more Roles.
603
+ * @param {RoleDeleteManyArgs} args - Arguments to filter Roles to delete.
604
+ * @example
605
+ * // Delete a few Roles
606
+ * const { count } = await prisma.role.deleteMany({
607
+ * where: {
608
+ * // ... provide filter here
609
+ * }
610
+ * })
611
+ *
612
+ */
613
+ deleteMany<T extends RoleDeleteManyArgs>(args?: Prisma.SelectSubset<T, RoleDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>;
614
+ /**
615
+ * Update zero or more Roles.
616
+ * Note, that providing `undefined` is treated as the value not being there.
617
+ * Read more here: https://pris.ly/d/null-undefined
618
+ * @param {RoleUpdateManyArgs} args - Arguments to update one or more rows.
619
+ * @example
620
+ * // Update many Roles
621
+ * const role = await prisma.role.updateMany({
622
+ * where: {
623
+ * // ... provide filter here
624
+ * },
625
+ * data: {
626
+ * // ... provide data here
627
+ * }
628
+ * })
629
+ *
630
+ */
631
+ updateMany<T extends RoleUpdateManyArgs>(args: Prisma.SelectSubset<T, RoleUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>;
632
+ /**
633
+ * Update zero or more Roles and returns the data updated in the database.
634
+ * @param {RoleUpdateManyAndReturnArgs} args - Arguments to update many Roles.
635
+ * @example
636
+ * // Update many Roles
637
+ * const role = await prisma.role.updateManyAndReturn({
638
+ * where: {
639
+ * // ... provide filter here
640
+ * },
641
+ * data: [
642
+ * // ... provide data here
643
+ * ]
644
+ * })
645
+ *
646
+ * // Update zero or more Roles and only return the `id`
647
+ * const roleWithIdOnly = await prisma.role.updateManyAndReturn({
648
+ * select: { id: true },
649
+ * where: {
650
+ * // ... provide filter here
651
+ * },
652
+ * data: [
653
+ * // ... provide data here
654
+ * ]
655
+ * })
656
+ * Note, that providing `undefined` is treated as the value not being there.
657
+ * Read more here: https://pris.ly/d/null-undefined
658
+ *
659
+ */
660
+ updateManyAndReturn<T extends RoleUpdateManyAndReturnArgs>(args: Prisma.SelectSubset<T, RoleUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>;
661
+ /**
662
+ * Create or update one Role.
663
+ * @param {RoleUpsertArgs} args - Arguments to update or create a Role.
664
+ * @example
665
+ * // Update or create a Role
666
+ * const role = await prisma.role.upsert({
667
+ * create: {
668
+ * // ... data to create a Role
669
+ * },
670
+ * update: {
671
+ * // ... in case it already exists, update
672
+ * },
673
+ * where: {
674
+ * // ... the filter for the Role we want to update
675
+ * }
676
+ * })
677
+ */
678
+ upsert<T extends RoleUpsertArgs>(args: Prisma.SelectSubset<T, RoleUpsertArgs<ExtArgs>>): Prisma.Prisma__RoleClient<runtime.Types.Result.GetResult<Prisma.$RolePayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>;
679
+ /**
680
+ * Count the number of Roles.
681
+ * Note, that providing `undefined` is treated as the value not being there.
682
+ * Read more here: https://pris.ly/d/null-undefined
683
+ * @param {RoleCountArgs} args - Arguments to filter Roles to count.
684
+ * @example
685
+ * // Count the number of Roles
686
+ * const count = await prisma.role.count({
687
+ * where: {
688
+ * // ... the filter for the Roles we want to count
689
+ * }
690
+ * })
691
+ **/
692
+ count<T extends RoleCountArgs>(args?: Prisma.Subset<T, RoleCountArgs>): Prisma.PrismaPromise<T extends runtime.Types.Utils.Record<'select', any> ? T['select'] extends true ? number : Prisma.GetScalarType<T['select'], RoleCountAggregateOutputType> : number>;
693
+ /**
694
+ * Allows you to perform aggregations operations on a Role.
695
+ * Note, that providing `undefined` is treated as the value not being there.
696
+ * Read more here: https://pris.ly/d/null-undefined
697
+ * @param {RoleAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
698
+ * @example
699
+ * // Ordered by age ascending
700
+ * // Where email contains prisma.io
701
+ * // Limited to the 10 users
702
+ * const aggregations = await prisma.user.aggregate({
703
+ * _avg: {
704
+ * age: true,
705
+ * },
706
+ * where: {
707
+ * email: {
708
+ * contains: "prisma.io",
709
+ * },
710
+ * },
711
+ * orderBy: {
712
+ * age: "asc",
713
+ * },
714
+ * take: 10,
715
+ * })
716
+ **/
717
+ aggregate<T extends RoleAggregateArgs>(args: Prisma.Subset<T, RoleAggregateArgs>): Prisma.PrismaPromise<GetRoleAggregateType<T>>;
718
+ /**
719
+ * Group by Role.
720
+ * Note, that providing `undefined` is treated as the value not being there.
721
+ * Read more here: https://pris.ly/d/null-undefined
722
+ * @param {RoleGroupByArgs} args - Group by arguments.
723
+ * @example
724
+ * // Group by city, order by createdAt, get count
725
+ * const result = await prisma.user.groupBy({
726
+ * by: ['city', 'createdAt'],
727
+ * orderBy: {
728
+ * createdAt: true
729
+ * },
730
+ * _count: {
731
+ * _all: true
732
+ * },
733
+ * })
734
+ *
735
+ **/
736
+ groupBy<T extends RoleGroupByArgs, HasSelectOrTake extends Prisma.Or<Prisma.Extends<'skip', Prisma.Keys<T>>, Prisma.Extends<'take', Prisma.Keys<T>>>, OrderByArg extends Prisma.True extends HasSelectOrTake ? {
737
+ orderBy: RoleGroupByArgs['orderBy'];
738
+ } : {
739
+ orderBy?: RoleGroupByArgs['orderBy'];
740
+ }, OrderFields extends Prisma.ExcludeUnderscoreKeys<Prisma.Keys<Prisma.MaybeTupleToUnion<T['orderBy']>>>, ByFields extends Prisma.MaybeTupleToUnion<T['by']>, ByValid extends Prisma.Has<ByFields, OrderFields>, HavingFields extends Prisma.GetHavingFields<T['having']>, HavingValid extends Prisma.Has<ByFields, HavingFields>, ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False, InputErrors extends ByEmpty extends Prisma.True ? `Error: "by" must not be empty.` : HavingValid extends Prisma.False ? {
741
+ [P in HavingFields]: P extends ByFields ? never : P extends string ? `Error: Field "${P}" used in "having" needs to be provided in "by".` : [
742
+ Error,
743
+ 'Field ',
744
+ P,
745
+ ` in "having" needs to be provided in "by"`
746
+ ];
747
+ }[HavingFields] : 'take' extends Prisma.Keys<T> ? 'orderBy' extends Prisma.Keys<T> ? ByValid extends Prisma.True ? {} : {
748
+ [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`;
749
+ }[OrderFields] : 'Error: If you provide "take", you also need to provide "orderBy"' : 'skip' extends Prisma.Keys<T> ? 'orderBy' extends Prisma.Keys<T> ? ByValid extends Prisma.True ? {} : {
750
+ [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`;
751
+ }[OrderFields] : 'Error: If you provide "skip", you also need to provide "orderBy"' : ByValid extends Prisma.True ? {} : {
752
+ [P in OrderFields]: P extends ByFields ? never : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`;
753
+ }[OrderFields]>(args: Prisma.SubsetIntersection<T, RoleGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetRoleGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>;
754
+ /**
755
+ * Fields of the Role model
756
+ */
757
+ readonly fields: RoleFieldRefs;
758
+ }
759
+ /**
760
+ * The delegate class that acts as a "Promise-like" for Role.
761
+ * Why is this prefixed with `Prisma__`?
762
+ * Because we want to prevent naming conflicts as mentioned in
763
+ * https://github.com/prisma/prisma-client-js/issues/707
764
+ */
765
+ export interface Prisma__RoleClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
766
+ readonly [Symbol.toStringTag]: "PrismaPromise";
767
+ permissions<T extends Prisma.Role$permissionsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Role$permissionsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PermissionPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>;
768
+ /**
769
+ * Attaches callbacks for the resolution and/or rejection of the Promise.
770
+ * @param onfulfilled The callback to execute when the Promise is resolved.
771
+ * @param onrejected The callback to execute when the Promise is rejected.
772
+ * @returns A Promise for the completion of which ever callback is executed.
773
+ */
774
+ 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>;
775
+ /**
776
+ * Attaches a callback for only the rejection of the Promise.
777
+ * @param onrejected The callback to execute when the Promise is rejected.
778
+ * @returns A Promise for the completion of the callback.
779
+ */
780
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): runtime.Types.Utils.JsPromise<T | TResult>;
781
+ /**
782
+ * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
783
+ * resolved value cannot be modified from the callback.
784
+ * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
785
+ * @returns A Promise for the completion of the callback.
786
+ */
787
+ finally(onfinally?: (() => void) | undefined | null): runtime.Types.Utils.JsPromise<T>;
788
+ }
789
+ /**
790
+ * Fields of the Role model
791
+ */
792
+ export interface RoleFieldRefs {
793
+ readonly id: Prisma.FieldRef<"Role", 'Int'>;
794
+ readonly name: Prisma.FieldRef<"Role", 'String'>;
795
+ readonly updatedAt: Prisma.FieldRef<"Role", 'DateTime'>;
796
+ readonly createdAt: Prisma.FieldRef<"Role", 'DateTime'>;
797
+ }
798
+ /**
799
+ * Role findUnique
800
+ */
801
+ export type RoleFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
802
+ /**
803
+ * Select specific fields to fetch from the Role
804
+ */
805
+ select?: Prisma.RoleSelect<ExtArgs> | null;
806
+ /**
807
+ * Omit specific fields from the Role
808
+ */
809
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
810
+ /**
811
+ * Choose, which related nodes to fetch as well
812
+ */
813
+ include?: Prisma.RoleInclude<ExtArgs> | null;
814
+ /**
815
+ * Filter, which Role to fetch.
816
+ */
817
+ where: Prisma.RoleWhereUniqueInput;
818
+ };
819
+ /**
820
+ * Role findUniqueOrThrow
821
+ */
822
+ export type RoleFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
823
+ /**
824
+ * Select specific fields to fetch from the Role
825
+ */
826
+ select?: Prisma.RoleSelect<ExtArgs> | null;
827
+ /**
828
+ * Omit specific fields from the Role
829
+ */
830
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
831
+ /**
832
+ * Choose, which related nodes to fetch as well
833
+ */
834
+ include?: Prisma.RoleInclude<ExtArgs> | null;
835
+ /**
836
+ * Filter, which Role to fetch.
837
+ */
838
+ where: Prisma.RoleWhereUniqueInput;
839
+ };
840
+ /**
841
+ * Role findFirst
842
+ */
843
+ export type RoleFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
844
+ /**
845
+ * Select specific fields to fetch from the Role
846
+ */
847
+ select?: Prisma.RoleSelect<ExtArgs> | null;
848
+ /**
849
+ * Omit specific fields from the Role
850
+ */
851
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
852
+ /**
853
+ * Choose, which related nodes to fetch as well
854
+ */
855
+ include?: Prisma.RoleInclude<ExtArgs> | null;
856
+ /**
857
+ * Filter, which Role to fetch.
858
+ */
859
+ where?: Prisma.RoleWhereInput;
860
+ /**
861
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
862
+ *
863
+ * Determine the order of Roles to fetch.
864
+ */
865
+ orderBy?: Prisma.RoleOrderByWithRelationInput | Prisma.RoleOrderByWithRelationInput[];
866
+ /**
867
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
868
+ *
869
+ * Sets the position for searching for Roles.
870
+ */
871
+ cursor?: Prisma.RoleWhereUniqueInput;
872
+ /**
873
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
874
+ *
875
+ * Take `±n` Roles from the position of the cursor.
876
+ */
877
+ take?: number;
878
+ /**
879
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
880
+ *
881
+ * Skip the first `n` Roles.
882
+ */
883
+ skip?: number;
884
+ /**
885
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
886
+ *
887
+ * Filter by unique combinations of Roles.
888
+ */
889
+ distinct?: Prisma.RoleScalarFieldEnum | Prisma.RoleScalarFieldEnum[];
890
+ };
891
+ /**
892
+ * Role findFirstOrThrow
893
+ */
894
+ export type RoleFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
895
+ /**
896
+ * Select specific fields to fetch from the Role
897
+ */
898
+ select?: Prisma.RoleSelect<ExtArgs> | null;
899
+ /**
900
+ * Omit specific fields from the Role
901
+ */
902
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
903
+ /**
904
+ * Choose, which related nodes to fetch as well
905
+ */
906
+ include?: Prisma.RoleInclude<ExtArgs> | null;
907
+ /**
908
+ * Filter, which Role to fetch.
909
+ */
910
+ where?: Prisma.RoleWhereInput;
911
+ /**
912
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
913
+ *
914
+ * Determine the order of Roles to fetch.
915
+ */
916
+ orderBy?: Prisma.RoleOrderByWithRelationInput | Prisma.RoleOrderByWithRelationInput[];
917
+ /**
918
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
919
+ *
920
+ * Sets the position for searching for Roles.
921
+ */
922
+ cursor?: Prisma.RoleWhereUniqueInput;
923
+ /**
924
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
925
+ *
926
+ * Take `±n` Roles from the position of the cursor.
927
+ */
928
+ take?: number;
929
+ /**
930
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
931
+ *
932
+ * Skip the first `n` Roles.
933
+ */
934
+ skip?: number;
935
+ /**
936
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
937
+ *
938
+ * Filter by unique combinations of Roles.
939
+ */
940
+ distinct?: Prisma.RoleScalarFieldEnum | Prisma.RoleScalarFieldEnum[];
941
+ };
942
+ /**
943
+ * Role findMany
944
+ */
945
+ export type RoleFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
946
+ /**
947
+ * Select specific fields to fetch from the Role
948
+ */
949
+ select?: Prisma.RoleSelect<ExtArgs> | null;
950
+ /**
951
+ * Omit specific fields from the Role
952
+ */
953
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
954
+ /**
955
+ * Choose, which related nodes to fetch as well
956
+ */
957
+ include?: Prisma.RoleInclude<ExtArgs> | null;
958
+ /**
959
+ * Filter, which Roles to fetch.
960
+ */
961
+ where?: Prisma.RoleWhereInput;
962
+ /**
963
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
964
+ *
965
+ * Determine the order of Roles to fetch.
966
+ */
967
+ orderBy?: Prisma.RoleOrderByWithRelationInput | Prisma.RoleOrderByWithRelationInput[];
968
+ /**
969
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
970
+ *
971
+ * Sets the position for listing Roles.
972
+ */
973
+ cursor?: Prisma.RoleWhereUniqueInput;
974
+ /**
975
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
976
+ *
977
+ * Take `±n` Roles from the position of the cursor.
978
+ */
979
+ take?: number;
980
+ /**
981
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
982
+ *
983
+ * Skip the first `n` Roles.
984
+ */
985
+ skip?: number;
986
+ /**
987
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
988
+ *
989
+ * Filter by unique combinations of Roles.
990
+ */
991
+ distinct?: Prisma.RoleScalarFieldEnum | Prisma.RoleScalarFieldEnum[];
992
+ };
993
+ /**
994
+ * Role create
995
+ */
996
+ export type RoleCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
997
+ /**
998
+ * Select specific fields to fetch from the Role
999
+ */
1000
+ select?: Prisma.RoleSelect<ExtArgs> | null;
1001
+ /**
1002
+ * Omit specific fields from the Role
1003
+ */
1004
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
1005
+ /**
1006
+ * Choose, which related nodes to fetch as well
1007
+ */
1008
+ include?: Prisma.RoleInclude<ExtArgs> | null;
1009
+ /**
1010
+ * The data needed to create a Role.
1011
+ */
1012
+ data: Prisma.XOR<Prisma.RoleCreateInput, Prisma.RoleUncheckedCreateInput>;
1013
+ };
1014
+ /**
1015
+ * Role createMany
1016
+ */
1017
+ export type RoleCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1018
+ /**
1019
+ * The data used to create many Roles.
1020
+ */
1021
+ data: Prisma.RoleCreateManyInput | Prisma.RoleCreateManyInput[];
1022
+ };
1023
+ /**
1024
+ * Role createManyAndReturn
1025
+ */
1026
+ export type RoleCreateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1027
+ /**
1028
+ * Select specific fields to fetch from the Role
1029
+ */
1030
+ select?: Prisma.RoleSelectCreateManyAndReturn<ExtArgs> | null;
1031
+ /**
1032
+ * Omit specific fields from the Role
1033
+ */
1034
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
1035
+ /**
1036
+ * The data used to create many Roles.
1037
+ */
1038
+ data: Prisma.RoleCreateManyInput | Prisma.RoleCreateManyInput[];
1039
+ };
1040
+ /**
1041
+ * Role update
1042
+ */
1043
+ export type RoleUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1044
+ /**
1045
+ * Select specific fields to fetch from the Role
1046
+ */
1047
+ select?: Prisma.RoleSelect<ExtArgs> | null;
1048
+ /**
1049
+ * Omit specific fields from the Role
1050
+ */
1051
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
1052
+ /**
1053
+ * Choose, which related nodes to fetch as well
1054
+ */
1055
+ include?: Prisma.RoleInclude<ExtArgs> | null;
1056
+ /**
1057
+ * The data needed to update a Role.
1058
+ */
1059
+ data: Prisma.XOR<Prisma.RoleUpdateInput, Prisma.RoleUncheckedUpdateInput>;
1060
+ /**
1061
+ * Choose, which Role to update.
1062
+ */
1063
+ where: Prisma.RoleWhereUniqueInput;
1064
+ };
1065
+ /**
1066
+ * Role updateMany
1067
+ */
1068
+ export type RoleUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1069
+ /**
1070
+ * The data used to update Roles.
1071
+ */
1072
+ data: Prisma.XOR<Prisma.RoleUpdateManyMutationInput, Prisma.RoleUncheckedUpdateManyInput>;
1073
+ /**
1074
+ * Filter which Roles to update
1075
+ */
1076
+ where?: Prisma.RoleWhereInput;
1077
+ /**
1078
+ * Limit how many Roles to update.
1079
+ */
1080
+ limit?: number;
1081
+ };
1082
+ /**
1083
+ * Role updateManyAndReturn
1084
+ */
1085
+ export type RoleUpdateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1086
+ /**
1087
+ * Select specific fields to fetch from the Role
1088
+ */
1089
+ select?: Prisma.RoleSelectUpdateManyAndReturn<ExtArgs> | null;
1090
+ /**
1091
+ * Omit specific fields from the Role
1092
+ */
1093
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
1094
+ /**
1095
+ * The data used to update Roles.
1096
+ */
1097
+ data: Prisma.XOR<Prisma.RoleUpdateManyMutationInput, Prisma.RoleUncheckedUpdateManyInput>;
1098
+ /**
1099
+ * Filter which Roles to update
1100
+ */
1101
+ where?: Prisma.RoleWhereInput;
1102
+ /**
1103
+ * Limit how many Roles to update.
1104
+ */
1105
+ limit?: number;
1106
+ };
1107
+ /**
1108
+ * Role upsert
1109
+ */
1110
+ export type RoleUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1111
+ /**
1112
+ * Select specific fields to fetch from the Role
1113
+ */
1114
+ select?: Prisma.RoleSelect<ExtArgs> | null;
1115
+ /**
1116
+ * Omit specific fields from the Role
1117
+ */
1118
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
1119
+ /**
1120
+ * Choose, which related nodes to fetch as well
1121
+ */
1122
+ include?: Prisma.RoleInclude<ExtArgs> | null;
1123
+ /**
1124
+ * The filter to search for the Role to update in case it exists.
1125
+ */
1126
+ where: Prisma.RoleWhereUniqueInput;
1127
+ /**
1128
+ * In case the Role found by the `where` argument doesn't exist, create a new Role with this data.
1129
+ */
1130
+ create: Prisma.XOR<Prisma.RoleCreateInput, Prisma.RoleUncheckedCreateInput>;
1131
+ /**
1132
+ * In case the Role was found with the provided `where` argument, update it with this data.
1133
+ */
1134
+ update: Prisma.XOR<Prisma.RoleUpdateInput, Prisma.RoleUncheckedUpdateInput>;
1135
+ };
1136
+ /**
1137
+ * Role delete
1138
+ */
1139
+ export type RoleDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1140
+ /**
1141
+ * Select specific fields to fetch from the Role
1142
+ */
1143
+ select?: Prisma.RoleSelect<ExtArgs> | null;
1144
+ /**
1145
+ * Omit specific fields from the Role
1146
+ */
1147
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
1148
+ /**
1149
+ * Choose, which related nodes to fetch as well
1150
+ */
1151
+ include?: Prisma.RoleInclude<ExtArgs> | null;
1152
+ /**
1153
+ * Filter which Role to delete.
1154
+ */
1155
+ where: Prisma.RoleWhereUniqueInput;
1156
+ };
1157
+ /**
1158
+ * Role deleteMany
1159
+ */
1160
+ export type RoleDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1161
+ /**
1162
+ * Filter which Roles to delete
1163
+ */
1164
+ where?: Prisma.RoleWhereInput;
1165
+ /**
1166
+ * Limit how many Roles to delete.
1167
+ */
1168
+ limit?: number;
1169
+ };
1170
+ /**
1171
+ * Role.permissions
1172
+ */
1173
+ export type Role$permissionsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1174
+ /**
1175
+ * Select specific fields to fetch from the Permission
1176
+ */
1177
+ select?: Prisma.PermissionSelect<ExtArgs> | null;
1178
+ /**
1179
+ * Omit specific fields from the Permission
1180
+ */
1181
+ omit?: Prisma.PermissionOmit<ExtArgs> | null;
1182
+ /**
1183
+ * Choose, which related nodes to fetch as well
1184
+ */
1185
+ include?: Prisma.PermissionInclude<ExtArgs> | null;
1186
+ where?: Prisma.PermissionWhereInput;
1187
+ orderBy?: Prisma.PermissionOrderByWithRelationInput | Prisma.PermissionOrderByWithRelationInput[];
1188
+ cursor?: Prisma.PermissionWhereUniqueInput;
1189
+ take?: number;
1190
+ skip?: number;
1191
+ distinct?: Prisma.PermissionScalarFieldEnum | Prisma.PermissionScalarFieldEnum[];
1192
+ };
1193
+ /**
1194
+ * Role without action
1195
+ */
1196
+ export type RoleDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1197
+ /**
1198
+ * Select specific fields to fetch from the Role
1199
+ */
1200
+ select?: Prisma.RoleSelect<ExtArgs> | null;
1201
+ /**
1202
+ * Omit specific fields from the Role
1203
+ */
1204
+ omit?: Prisma.RoleOmit<ExtArgs> | null;
1205
+ /**
1206
+ * Choose, which related nodes to fetch as well
1207
+ */
1208
+ include?: Prisma.RoleInclude<ExtArgs> | null;
1209
+ };