@happyvertical/smrt-users 0.49.3 → 0.49.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/{TerminalAuthService-D6i0WoaZ.js → TerminalAuthService-BuOM9zbU.js} +2 -2
- package/dist/chunks/{TerminalAuthService-D6i0WoaZ.js.map → TerminalAuthService-BuOM9zbU.js.map} +1 -1
- package/dist/index.js +3 -3
- package/dist/manifest.json +868 -94
- package/dist/smrt-knowledge.json +16 -16
- package/dist/sveltekit.js +1 -1
- package/package.json +9 -9
package/dist/manifest.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"version": "1.0.0",
|
|
3
3
|
"timestamp": 0,
|
|
4
4
|
"packageName": "@happyvertical/smrt-users",
|
|
5
|
-
"packageVersion": "0.49.
|
|
5
|
+
"packageVersion": "0.49.4",
|
|
6
6
|
"objects": {
|
|
7
7
|
"@happyvertical/smrt-users:AccessRequestCollection": {
|
|
8
8
|
"name": "accessrequestcollection",
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
"collectionExportName": "AccessRequestCollectionCollection",
|
|
74
74
|
"schema": {
|
|
75
75
|
"tableName": "access_requests",
|
|
76
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"access_requests\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp\n);",
|
|
76
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"access_requests\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"email\" TEXT NOT NULL DEFAULT '',\n \"name\" TEXT,\n \"status\" TEXT,\n \"source\" TEXT DEFAULT '',\n \"request_context\" TEXT DEFAULT '{}',\n \"note\" TEXT,\n \"requested_at\" TIMESTAMP,\n \"decided_at\" TIMESTAMP,\n \"decided_by\" TEXT,\n \"resulting_user_id\" TEXT,\n \"tenant_hint\" TEXT\n);",
|
|
77
77
|
"columns": {
|
|
78
78
|
"id": {
|
|
79
79
|
"type": "UUID",
|
|
@@ -99,6 +99,64 @@
|
|
|
99
99
|
"type": "TIMESTAMP",
|
|
100
100
|
"notNull": true,
|
|
101
101
|
"default": "current_timestamp"
|
|
102
|
+
},
|
|
103
|
+
"email": {
|
|
104
|
+
"type": "TEXT",
|
|
105
|
+
"notNull": true,
|
|
106
|
+
"unique": false,
|
|
107
|
+
"default": ""
|
|
108
|
+
},
|
|
109
|
+
"name": {
|
|
110
|
+
"type": "TEXT",
|
|
111
|
+
"notNull": false,
|
|
112
|
+
"unique": false
|
|
113
|
+
},
|
|
114
|
+
"status": {
|
|
115
|
+
"type": "TEXT",
|
|
116
|
+
"notNull": false,
|
|
117
|
+
"unique": false
|
|
118
|
+
},
|
|
119
|
+
"source": {
|
|
120
|
+
"type": "TEXT",
|
|
121
|
+
"notNull": false,
|
|
122
|
+
"unique": false,
|
|
123
|
+
"default": ""
|
|
124
|
+
},
|
|
125
|
+
"request_context": {
|
|
126
|
+
"type": "TEXT",
|
|
127
|
+
"notNull": false,
|
|
128
|
+
"unique": false,
|
|
129
|
+
"default": "{}"
|
|
130
|
+
},
|
|
131
|
+
"note": {
|
|
132
|
+
"type": "TEXT",
|
|
133
|
+
"notNull": false,
|
|
134
|
+
"unique": false
|
|
135
|
+
},
|
|
136
|
+
"requested_at": {
|
|
137
|
+
"type": "TIMESTAMP",
|
|
138
|
+
"notNull": false,
|
|
139
|
+
"unique": false
|
|
140
|
+
},
|
|
141
|
+
"decided_at": {
|
|
142
|
+
"type": "TIMESTAMP",
|
|
143
|
+
"notNull": false,
|
|
144
|
+
"unique": false
|
|
145
|
+
},
|
|
146
|
+
"decided_by": {
|
|
147
|
+
"type": "TEXT",
|
|
148
|
+
"notNull": false,
|
|
149
|
+
"unique": false
|
|
150
|
+
},
|
|
151
|
+
"resulting_user_id": {
|
|
152
|
+
"type": "TEXT",
|
|
153
|
+
"notNull": false,
|
|
154
|
+
"unique": false
|
|
155
|
+
},
|
|
156
|
+
"tenant_hint": {
|
|
157
|
+
"type": "TEXT",
|
|
158
|
+
"notNull": false,
|
|
159
|
+
"unique": false
|
|
102
160
|
}
|
|
103
161
|
},
|
|
104
162
|
"indexes": [
|
|
@@ -107,8 +165,25 @@
|
|
|
107
165
|
"columns": [
|
|
108
166
|
"slug",
|
|
109
167
|
"context"
|
|
110
|
-
]
|
|
111
|
-
|
|
168
|
+
]
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
"name": "access_requests_email_idx",
|
|
172
|
+
"columns": [
|
|
173
|
+
"email"
|
|
174
|
+
]
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
"name": "access_requests_status_idx",
|
|
178
|
+
"columns": [
|
|
179
|
+
"status"
|
|
180
|
+
]
|
|
181
|
+
},
|
|
182
|
+
{
|
|
183
|
+
"name": "access_requests_source_idx",
|
|
184
|
+
"columns": [
|
|
185
|
+
"source"
|
|
186
|
+
]
|
|
112
187
|
},
|
|
113
188
|
{
|
|
114
189
|
"name": "access_requests_created_at_idx",
|
|
@@ -117,7 +192,7 @@
|
|
|
117
192
|
]
|
|
118
193
|
}
|
|
119
194
|
],
|
|
120
|
-
"version": "
|
|
195
|
+
"version": "f396996f"
|
|
121
196
|
}
|
|
122
197
|
},
|
|
123
198
|
"@happyvertical/smrt-users:UsersCliAuthApproveLimitCollection": {
|
|
@@ -179,7 +254,7 @@
|
|
|
179
254
|
"collectionExportName": "UsersCliAuthApproveLimitCollectionCollection",
|
|
180
255
|
"schema": {
|
|
181
256
|
"tableName": "users_cli_auth_approve_limits",
|
|
182
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"users_cli_auth_approve_limits\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp\n);",
|
|
257
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"users_cli_auth_approve_limits\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"user_id\" UUID NOT NULL UNIQUE,\n \"attempt_count\" INTEGER NOT NULL DEFAULT 0,\n \"window_started_at\" TIMESTAMP NOT NULL\n);",
|
|
183
258
|
"columns": {
|
|
184
259
|
"id": {
|
|
185
260
|
"type": "UUID",
|
|
@@ -205,6 +280,29 @@
|
|
|
205
280
|
"type": "TIMESTAMP",
|
|
206
281
|
"notNull": true,
|
|
207
282
|
"default": "current_timestamp"
|
|
283
|
+
},
|
|
284
|
+
"user_id": {
|
|
285
|
+
"type": "UUID",
|
|
286
|
+
"referenceKind": "foreignKey",
|
|
287
|
+
"notNull": true,
|
|
288
|
+
"unique": true,
|
|
289
|
+
"foreignKey": {
|
|
290
|
+
"table": "users",
|
|
291
|
+
"column": "id",
|
|
292
|
+
"onDelete": "NO ACTION",
|
|
293
|
+
"onUpdate": "CASCADE"
|
|
294
|
+
}
|
|
295
|
+
},
|
|
296
|
+
"attempt_count": {
|
|
297
|
+
"type": "INTEGER",
|
|
298
|
+
"notNull": true,
|
|
299
|
+
"unique": false,
|
|
300
|
+
"default": 0
|
|
301
|
+
},
|
|
302
|
+
"window_started_at": {
|
|
303
|
+
"type": "TIMESTAMP",
|
|
304
|
+
"notNull": true,
|
|
305
|
+
"unique": false
|
|
208
306
|
}
|
|
209
307
|
},
|
|
210
308
|
"indexes": [
|
|
@@ -223,7 +321,7 @@
|
|
|
223
321
|
]
|
|
224
322
|
}
|
|
225
323
|
],
|
|
226
|
-
"version": "
|
|
324
|
+
"version": "c45c02de"
|
|
227
325
|
}
|
|
228
326
|
},
|
|
229
327
|
"@happyvertical/smrt-users:UsersCliAuthRequestCollection": {
|
|
@@ -318,7 +416,7 @@
|
|
|
318
416
|
"collectionExportName": "UsersCliAuthRequestCollectionCollection",
|
|
319
417
|
"schema": {
|
|
320
418
|
"tableName": "users_cli_auth_requests",
|
|
321
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"users_cli_auth_requests\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp\n);",
|
|
419
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"users_cli_auth_requests\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"user_code\" TEXT NOT NULL UNIQUE,\n \"device_code_hash\" TEXT NOT NULL UNIQUE,\n \"status\" TEXT,\n \"user_id\" UUID,\n \"tenant_id\" UUID,\n \"session_id\" UUID,\n \"expires_at\" TIMESTAMP,\n \"approved_at\" TIMESTAMP\n);",
|
|
322
420
|
"columns": {
|
|
323
421
|
"id": {
|
|
324
422
|
"type": "UUID",
|
|
@@ -344,6 +442,67 @@
|
|
|
344
442
|
"type": "TIMESTAMP",
|
|
345
443
|
"notNull": true,
|
|
346
444
|
"default": "current_timestamp"
|
|
445
|
+
},
|
|
446
|
+
"user_code": {
|
|
447
|
+
"type": "TEXT",
|
|
448
|
+
"notNull": true,
|
|
449
|
+
"unique": true
|
|
450
|
+
},
|
|
451
|
+
"device_code_hash": {
|
|
452
|
+
"type": "TEXT",
|
|
453
|
+
"notNull": true,
|
|
454
|
+
"unique": true
|
|
455
|
+
},
|
|
456
|
+
"status": {
|
|
457
|
+
"type": "TEXT",
|
|
458
|
+
"notNull": false,
|
|
459
|
+
"unique": false
|
|
460
|
+
},
|
|
461
|
+
"user_id": {
|
|
462
|
+
"type": "UUID",
|
|
463
|
+
"referenceKind": "foreignKey",
|
|
464
|
+
"notNull": false,
|
|
465
|
+
"unique": false,
|
|
466
|
+
"foreignKey": {
|
|
467
|
+
"table": "users",
|
|
468
|
+
"column": "id",
|
|
469
|
+
"onDelete": "NO ACTION",
|
|
470
|
+
"onUpdate": "CASCADE"
|
|
471
|
+
}
|
|
472
|
+
},
|
|
473
|
+
"tenant_id": {
|
|
474
|
+
"type": "UUID",
|
|
475
|
+
"referenceKind": "foreignKey",
|
|
476
|
+
"notNull": false,
|
|
477
|
+
"unique": false,
|
|
478
|
+
"foreignKey": {
|
|
479
|
+
"table": "tenants",
|
|
480
|
+
"column": "id",
|
|
481
|
+
"onDelete": "NO ACTION",
|
|
482
|
+
"onUpdate": "CASCADE"
|
|
483
|
+
}
|
|
484
|
+
},
|
|
485
|
+
"session_id": {
|
|
486
|
+
"type": "UUID",
|
|
487
|
+
"referenceKind": "foreignKey",
|
|
488
|
+
"notNull": false,
|
|
489
|
+
"unique": false,
|
|
490
|
+
"foreignKey": {
|
|
491
|
+
"table": "sessions",
|
|
492
|
+
"column": "id",
|
|
493
|
+
"onDelete": "NO ACTION",
|
|
494
|
+
"onUpdate": "CASCADE"
|
|
495
|
+
}
|
|
496
|
+
},
|
|
497
|
+
"expires_at": {
|
|
498
|
+
"type": "TIMESTAMP",
|
|
499
|
+
"notNull": false,
|
|
500
|
+
"unique": false
|
|
501
|
+
},
|
|
502
|
+
"approved_at": {
|
|
503
|
+
"type": "TIMESTAMP",
|
|
504
|
+
"notNull": false,
|
|
505
|
+
"unique": false
|
|
347
506
|
}
|
|
348
507
|
},
|
|
349
508
|
"indexes": [
|
|
@@ -355,14 +514,38 @@
|
|
|
355
514
|
],
|
|
356
515
|
"unique": true
|
|
357
516
|
},
|
|
517
|
+
{
|
|
518
|
+
"name": "users_cli_auth_requests_expires_at_idx",
|
|
519
|
+
"columns": [
|
|
520
|
+
"expires_at"
|
|
521
|
+
]
|
|
522
|
+
},
|
|
358
523
|
{
|
|
359
524
|
"name": "users_cli_auth_requests_created_at_idx",
|
|
360
525
|
"columns": [
|
|
361
526
|
"created_at"
|
|
362
527
|
]
|
|
528
|
+
},
|
|
529
|
+
{
|
|
530
|
+
"name": "users_cli_auth_requests_user_id_idx",
|
|
531
|
+
"columns": [
|
|
532
|
+
"user_id"
|
|
533
|
+
]
|
|
534
|
+
},
|
|
535
|
+
{
|
|
536
|
+
"name": "users_cli_auth_requests_tenant_id_idx",
|
|
537
|
+
"columns": [
|
|
538
|
+
"tenant_id"
|
|
539
|
+
]
|
|
540
|
+
},
|
|
541
|
+
{
|
|
542
|
+
"name": "users_cli_auth_requests_session_id_idx",
|
|
543
|
+
"columns": [
|
|
544
|
+
"session_id"
|
|
545
|
+
]
|
|
363
546
|
}
|
|
364
547
|
],
|
|
365
|
-
"version": "
|
|
548
|
+
"version": "713ae04c"
|
|
366
549
|
}
|
|
367
550
|
},
|
|
368
551
|
"@happyvertical/smrt-users:GroupCollection": {
|
|
@@ -414,8 +597,8 @@
|
|
|
414
597
|
"exportName": "GroupCollection",
|
|
415
598
|
"collectionExportName": "GroupCollectionCollection",
|
|
416
599
|
"schema": {
|
|
417
|
-
"tableName": "
|
|
418
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
600
|
+
"tableName": "groups",
|
|
601
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"groups\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID NOT NULL,\n \"name\" TEXT DEFAULT '',\n \"description\" TEXT DEFAULT ''\n);",
|
|
419
602
|
"columns": {
|
|
420
603
|
"id": {
|
|
421
604
|
"type": "UUID",
|
|
@@ -441,11 +624,35 @@
|
|
|
441
624
|
"type": "TIMESTAMP",
|
|
442
625
|
"notNull": true,
|
|
443
626
|
"default": "current_timestamp"
|
|
627
|
+
},
|
|
628
|
+
"tenant_id": {
|
|
629
|
+
"type": "UUID",
|
|
630
|
+
"referenceKind": "foreignKey",
|
|
631
|
+
"notNull": true,
|
|
632
|
+
"unique": false,
|
|
633
|
+
"foreignKey": {
|
|
634
|
+
"table": "tenants",
|
|
635
|
+
"column": "id",
|
|
636
|
+
"onDelete": "NO ACTION",
|
|
637
|
+
"onUpdate": "CASCADE"
|
|
638
|
+
}
|
|
639
|
+
},
|
|
640
|
+
"name": {
|
|
641
|
+
"type": "TEXT",
|
|
642
|
+
"notNull": false,
|
|
643
|
+
"unique": false,
|
|
644
|
+
"default": ""
|
|
645
|
+
},
|
|
646
|
+
"description": {
|
|
647
|
+
"type": "TEXT",
|
|
648
|
+
"notNull": false,
|
|
649
|
+
"unique": false,
|
|
650
|
+
"default": ""
|
|
444
651
|
}
|
|
445
652
|
},
|
|
446
653
|
"indexes": [
|
|
447
654
|
{
|
|
448
|
-
"name": "
|
|
655
|
+
"name": "groups_slug_context_idx",
|
|
449
656
|
"columns": [
|
|
450
657
|
"slug",
|
|
451
658
|
"context"
|
|
@@ -453,13 +660,19 @@
|
|
|
453
660
|
"unique": true
|
|
454
661
|
},
|
|
455
662
|
{
|
|
456
|
-
"name": "
|
|
663
|
+
"name": "groups_created_at_idx",
|
|
457
664
|
"columns": [
|
|
458
665
|
"created_at"
|
|
459
666
|
]
|
|
667
|
+
},
|
|
668
|
+
{
|
|
669
|
+
"name": "groups_tenant_id_idx",
|
|
670
|
+
"columns": [
|
|
671
|
+
"tenant_id"
|
|
672
|
+
]
|
|
460
673
|
}
|
|
461
674
|
],
|
|
462
|
-
"version": "
|
|
675
|
+
"version": "1824c19b"
|
|
463
676
|
}
|
|
464
677
|
},
|
|
465
678
|
"@happyvertical/smrt-users:GroupMemberCollection": {
|
|
@@ -610,8 +823,8 @@
|
|
|
610
823
|
"exportName": "GroupMemberCollection",
|
|
611
824
|
"collectionExportName": "GroupMemberCollectionCollection",
|
|
612
825
|
"schema": {
|
|
613
|
-
"tableName": "
|
|
614
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
826
|
+
"tableName": "group_members",
|
|
827
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"group_members\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"group_id\" UUID NOT NULL,\n \"user_id\" UUID NOT NULL\n);",
|
|
615
828
|
"columns": {
|
|
616
829
|
"id": {
|
|
617
830
|
"type": "UUID",
|
|
@@ -637,11 +850,35 @@
|
|
|
637
850
|
"type": "TIMESTAMP",
|
|
638
851
|
"notNull": true,
|
|
639
852
|
"default": "current_timestamp"
|
|
853
|
+
},
|
|
854
|
+
"group_id": {
|
|
855
|
+
"type": "UUID",
|
|
856
|
+
"referenceKind": "foreignKey",
|
|
857
|
+
"notNull": true,
|
|
858
|
+
"unique": false,
|
|
859
|
+
"foreignKey": {
|
|
860
|
+
"table": "groups",
|
|
861
|
+
"column": "id",
|
|
862
|
+
"onDelete": "NO ACTION",
|
|
863
|
+
"onUpdate": "CASCADE"
|
|
864
|
+
}
|
|
865
|
+
},
|
|
866
|
+
"user_id": {
|
|
867
|
+
"type": "UUID",
|
|
868
|
+
"referenceKind": "foreignKey",
|
|
869
|
+
"notNull": true,
|
|
870
|
+
"unique": false,
|
|
871
|
+
"foreignKey": {
|
|
872
|
+
"table": "users",
|
|
873
|
+
"column": "id",
|
|
874
|
+
"onDelete": "NO ACTION",
|
|
875
|
+
"onUpdate": "CASCADE"
|
|
876
|
+
}
|
|
640
877
|
}
|
|
641
878
|
},
|
|
642
879
|
"indexes": [
|
|
643
880
|
{
|
|
644
|
-
"name": "
|
|
881
|
+
"name": "group_members_slug_context_idx",
|
|
645
882
|
"columns": [
|
|
646
883
|
"slug",
|
|
647
884
|
"context"
|
|
@@ -649,13 +886,25 @@
|
|
|
649
886
|
"unique": true
|
|
650
887
|
},
|
|
651
888
|
{
|
|
652
|
-
"name": "
|
|
889
|
+
"name": "group_members_created_at_idx",
|
|
653
890
|
"columns": [
|
|
654
891
|
"created_at"
|
|
655
892
|
]
|
|
893
|
+
},
|
|
894
|
+
{
|
|
895
|
+
"name": "group_members_group_id_idx",
|
|
896
|
+
"columns": [
|
|
897
|
+
"group_id"
|
|
898
|
+
]
|
|
899
|
+
},
|
|
900
|
+
{
|
|
901
|
+
"name": "group_members_user_id_idx",
|
|
902
|
+
"columns": [
|
|
903
|
+
"user_id"
|
|
904
|
+
]
|
|
656
905
|
}
|
|
657
906
|
],
|
|
658
|
-
"version": "
|
|
907
|
+
"version": "ed4d1187"
|
|
659
908
|
}
|
|
660
909
|
},
|
|
661
910
|
"@happyvertical/smrt-users:GroupRoleCollection": {
|
|
@@ -773,8 +1022,8 @@
|
|
|
773
1022
|
"exportName": "GroupRoleCollection",
|
|
774
1023
|
"collectionExportName": "GroupRoleCollectionCollection",
|
|
775
1024
|
"schema": {
|
|
776
|
-
"tableName": "
|
|
777
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
1025
|
+
"tableName": "group_roles",
|
|
1026
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"group_roles\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"group_id\" UUID NOT NULL,\n \"role_id\" UUID NOT NULL\n);",
|
|
778
1027
|
"columns": {
|
|
779
1028
|
"id": {
|
|
780
1029
|
"type": "UUID",
|
|
@@ -800,11 +1049,35 @@
|
|
|
800
1049
|
"type": "TIMESTAMP",
|
|
801
1050
|
"notNull": true,
|
|
802
1051
|
"default": "current_timestamp"
|
|
1052
|
+
},
|
|
1053
|
+
"group_id": {
|
|
1054
|
+
"type": "UUID",
|
|
1055
|
+
"referenceKind": "foreignKey",
|
|
1056
|
+
"notNull": true,
|
|
1057
|
+
"unique": false,
|
|
1058
|
+
"foreignKey": {
|
|
1059
|
+
"table": "groups",
|
|
1060
|
+
"column": "id",
|
|
1061
|
+
"onDelete": "NO ACTION",
|
|
1062
|
+
"onUpdate": "CASCADE"
|
|
1063
|
+
}
|
|
1064
|
+
},
|
|
1065
|
+
"role_id": {
|
|
1066
|
+
"type": "UUID",
|
|
1067
|
+
"referenceKind": "foreignKey",
|
|
1068
|
+
"notNull": true,
|
|
1069
|
+
"unique": false,
|
|
1070
|
+
"foreignKey": {
|
|
1071
|
+
"table": "roles",
|
|
1072
|
+
"column": "id",
|
|
1073
|
+
"onDelete": "NO ACTION",
|
|
1074
|
+
"onUpdate": "CASCADE"
|
|
1075
|
+
}
|
|
803
1076
|
}
|
|
804
1077
|
},
|
|
805
1078
|
"indexes": [
|
|
806
1079
|
{
|
|
807
|
-
"name": "
|
|
1080
|
+
"name": "group_roles_slug_context_idx",
|
|
808
1081
|
"columns": [
|
|
809
1082
|
"slug",
|
|
810
1083
|
"context"
|
|
@@ -812,13 +1085,25 @@
|
|
|
812
1085
|
"unique": true
|
|
813
1086
|
},
|
|
814
1087
|
{
|
|
815
|
-
"name": "
|
|
1088
|
+
"name": "group_roles_created_at_idx",
|
|
816
1089
|
"columns": [
|
|
817
1090
|
"created_at"
|
|
818
1091
|
]
|
|
1092
|
+
},
|
|
1093
|
+
{
|
|
1094
|
+
"name": "group_roles_group_id_idx",
|
|
1095
|
+
"columns": [
|
|
1096
|
+
"group_id"
|
|
1097
|
+
]
|
|
1098
|
+
},
|
|
1099
|
+
{
|
|
1100
|
+
"name": "group_roles_role_id_idx",
|
|
1101
|
+
"columns": [
|
|
1102
|
+
"role_id"
|
|
1103
|
+
]
|
|
819
1104
|
}
|
|
820
1105
|
],
|
|
821
|
-
"version": "
|
|
1106
|
+
"version": "b1e35f93"
|
|
822
1107
|
}
|
|
823
1108
|
},
|
|
824
1109
|
"@happyvertical/smrt-users:UsersMagicLinkTokenCollection": {
|
|
@@ -885,7 +1170,7 @@
|
|
|
885
1170
|
"collectionExportName": "UsersMagicLinkTokenCollectionCollection",
|
|
886
1171
|
"schema": {
|
|
887
1172
|
"tableName": "users_magic_link_tokens",
|
|
888
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"users_magic_link_tokens\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp\n);",
|
|
1173
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"users_magic_link_tokens\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"nonce\" TEXT NOT NULL UNIQUE DEFAULT '',\n \"email\" TEXT DEFAULT '',\n \"used\" BOOLEAN DEFAULT FALSE,\n \"expires_at\" TIMESTAMP\n);",
|
|
889
1174
|
"columns": {
|
|
890
1175
|
"id": {
|
|
891
1176
|
"type": "UUID",
|
|
@@ -911,6 +1196,29 @@
|
|
|
911
1196
|
"type": "TIMESTAMP",
|
|
912
1197
|
"notNull": true,
|
|
913
1198
|
"default": "current_timestamp"
|
|
1199
|
+
},
|
|
1200
|
+
"nonce": {
|
|
1201
|
+
"type": "TEXT",
|
|
1202
|
+
"notNull": true,
|
|
1203
|
+
"unique": true,
|
|
1204
|
+
"default": ""
|
|
1205
|
+
},
|
|
1206
|
+
"email": {
|
|
1207
|
+
"type": "TEXT",
|
|
1208
|
+
"notNull": false,
|
|
1209
|
+
"unique": false,
|
|
1210
|
+
"default": ""
|
|
1211
|
+
},
|
|
1212
|
+
"used": {
|
|
1213
|
+
"type": "BOOLEAN",
|
|
1214
|
+
"notNull": false,
|
|
1215
|
+
"unique": false,
|
|
1216
|
+
"default": false
|
|
1217
|
+
},
|
|
1218
|
+
"expires_at": {
|
|
1219
|
+
"type": "TIMESTAMP",
|
|
1220
|
+
"notNull": false,
|
|
1221
|
+
"unique": false
|
|
914
1222
|
}
|
|
915
1223
|
},
|
|
916
1224
|
"indexes": [
|
|
@@ -922,6 +1230,12 @@
|
|
|
922
1230
|
],
|
|
923
1231
|
"unique": true
|
|
924
1232
|
},
|
|
1233
|
+
{
|
|
1234
|
+
"name": "users_magic_link_tokens_expires_at_idx",
|
|
1235
|
+
"columns": [
|
|
1236
|
+
"expires_at"
|
|
1237
|
+
]
|
|
1238
|
+
},
|
|
925
1239
|
{
|
|
926
1240
|
"name": "users_magic_link_tokens_created_at_idx",
|
|
927
1241
|
"columns": [
|
|
@@ -929,7 +1243,7 @@
|
|
|
929
1243
|
]
|
|
930
1244
|
}
|
|
931
1245
|
],
|
|
932
|
-
"version": "
|
|
1246
|
+
"version": "537853d3"
|
|
933
1247
|
}
|
|
934
1248
|
},
|
|
935
1249
|
"@happyvertical/smrt-users:MembershipCollection": {
|
|
@@ -1051,8 +1365,8 @@
|
|
|
1051
1365
|
"exportName": "MembershipCollection",
|
|
1052
1366
|
"collectionExportName": "MembershipCollectionCollection",
|
|
1053
1367
|
"schema": {
|
|
1054
|
-
"tableName": "
|
|
1055
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
1368
|
+
"tableName": "memberships",
|
|
1369
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"memberships\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"user_id\" UUID NOT NULL,\n \"tenant_id\" UUID NOT NULL,\n \"role_id\" UUID NOT NULL,\n \"status\" TEXT\n);",
|
|
1056
1370
|
"columns": {
|
|
1057
1371
|
"id": {
|
|
1058
1372
|
"type": "UUID",
|
|
@@ -1069,20 +1383,61 @@
|
|
|
1069
1383
|
"notNull": true,
|
|
1070
1384
|
"default": ""
|
|
1071
1385
|
},
|
|
1072
|
-
"created_at": {
|
|
1073
|
-
"type": "TIMESTAMP",
|
|
1386
|
+
"created_at": {
|
|
1387
|
+
"type": "TIMESTAMP",
|
|
1388
|
+
"notNull": true,
|
|
1389
|
+
"default": "current_timestamp"
|
|
1390
|
+
},
|
|
1391
|
+
"updated_at": {
|
|
1392
|
+
"type": "TIMESTAMP",
|
|
1393
|
+
"notNull": true,
|
|
1394
|
+
"default": "current_timestamp"
|
|
1395
|
+
},
|
|
1396
|
+
"user_id": {
|
|
1397
|
+
"type": "UUID",
|
|
1398
|
+
"referenceKind": "foreignKey",
|
|
1399
|
+
"notNull": true,
|
|
1400
|
+
"unique": false,
|
|
1401
|
+
"foreignKey": {
|
|
1402
|
+
"table": "users",
|
|
1403
|
+
"column": "id",
|
|
1404
|
+
"onDelete": "NO ACTION",
|
|
1405
|
+
"onUpdate": "CASCADE"
|
|
1406
|
+
}
|
|
1407
|
+
},
|
|
1408
|
+
"tenant_id": {
|
|
1409
|
+
"type": "UUID",
|
|
1410
|
+
"referenceKind": "foreignKey",
|
|
1411
|
+
"notNull": true,
|
|
1412
|
+
"unique": false,
|
|
1413
|
+
"foreignKey": {
|
|
1414
|
+
"table": "tenants",
|
|
1415
|
+
"column": "id",
|
|
1416
|
+
"onDelete": "NO ACTION",
|
|
1417
|
+
"onUpdate": "CASCADE"
|
|
1418
|
+
}
|
|
1419
|
+
},
|
|
1420
|
+
"role_id": {
|
|
1421
|
+
"type": "UUID",
|
|
1422
|
+
"referenceKind": "foreignKey",
|
|
1074
1423
|
"notNull": true,
|
|
1075
|
-
"
|
|
1424
|
+
"unique": false,
|
|
1425
|
+
"foreignKey": {
|
|
1426
|
+
"table": "roles",
|
|
1427
|
+
"column": "id",
|
|
1428
|
+
"onDelete": "NO ACTION",
|
|
1429
|
+
"onUpdate": "CASCADE"
|
|
1430
|
+
}
|
|
1076
1431
|
},
|
|
1077
|
-
"
|
|
1078
|
-
"type": "
|
|
1079
|
-
"notNull":
|
|
1080
|
-
"
|
|
1432
|
+
"status": {
|
|
1433
|
+
"type": "TEXT",
|
|
1434
|
+
"notNull": false,
|
|
1435
|
+
"unique": false
|
|
1081
1436
|
}
|
|
1082
1437
|
},
|
|
1083
1438
|
"indexes": [
|
|
1084
1439
|
{
|
|
1085
|
-
"name": "
|
|
1440
|
+
"name": "memberships_slug_context_idx",
|
|
1086
1441
|
"columns": [
|
|
1087
1442
|
"slug",
|
|
1088
1443
|
"context"
|
|
@@ -1090,13 +1445,32 @@
|
|
|
1090
1445
|
"unique": true
|
|
1091
1446
|
},
|
|
1092
1447
|
{
|
|
1093
|
-
"name": "
|
|
1448
|
+
"name": "memberships_tenant_id_user_id_idx",
|
|
1449
|
+
"columns": [
|
|
1450
|
+
"tenant_id",
|
|
1451
|
+
"user_id"
|
|
1452
|
+
]
|
|
1453
|
+
},
|
|
1454
|
+
{
|
|
1455
|
+
"name": "memberships_created_at_idx",
|
|
1094
1456
|
"columns": [
|
|
1095
1457
|
"created_at"
|
|
1096
1458
|
]
|
|
1459
|
+
},
|
|
1460
|
+
{
|
|
1461
|
+
"name": "memberships_user_id_idx",
|
|
1462
|
+
"columns": [
|
|
1463
|
+
"user_id"
|
|
1464
|
+
]
|
|
1465
|
+
},
|
|
1466
|
+
{
|
|
1467
|
+
"name": "memberships_role_id_idx",
|
|
1468
|
+
"columns": [
|
|
1469
|
+
"role_id"
|
|
1470
|
+
]
|
|
1097
1471
|
}
|
|
1098
1472
|
],
|
|
1099
|
-
"version": "
|
|
1473
|
+
"version": "ebfd11e0"
|
|
1100
1474
|
}
|
|
1101
1475
|
},
|
|
1102
1476
|
"@happyvertical/smrt-users:MembershipOverrideCollection": {
|
|
@@ -1266,8 +1640,8 @@
|
|
|
1266
1640
|
"exportName": "MembershipOverrideCollection",
|
|
1267
1641
|
"collectionExportName": "MembershipOverrideCollectionCollection",
|
|
1268
1642
|
"schema": {
|
|
1269
|
-
"tableName": "
|
|
1270
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
1643
|
+
"tableName": "membership_overrides",
|
|
1644
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"membership_overrides\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"membership_id\" UUID NOT NULL,\n \"permission_id\" UUID NOT NULL,\n \"effect\" TEXT\n);",
|
|
1271
1645
|
"columns": {
|
|
1272
1646
|
"id": {
|
|
1273
1647
|
"type": "UUID",
|
|
@@ -1293,11 +1667,40 @@
|
|
|
1293
1667
|
"type": "TIMESTAMP",
|
|
1294
1668
|
"notNull": true,
|
|
1295
1669
|
"default": "current_timestamp"
|
|
1670
|
+
},
|
|
1671
|
+
"membership_id": {
|
|
1672
|
+
"type": "UUID",
|
|
1673
|
+
"referenceKind": "foreignKey",
|
|
1674
|
+
"notNull": true,
|
|
1675
|
+
"unique": false,
|
|
1676
|
+
"foreignKey": {
|
|
1677
|
+
"table": "memberships",
|
|
1678
|
+
"column": "id",
|
|
1679
|
+
"onDelete": "NO ACTION",
|
|
1680
|
+
"onUpdate": "CASCADE"
|
|
1681
|
+
}
|
|
1682
|
+
},
|
|
1683
|
+
"permission_id": {
|
|
1684
|
+
"type": "UUID",
|
|
1685
|
+
"referenceKind": "foreignKey",
|
|
1686
|
+
"notNull": true,
|
|
1687
|
+
"unique": false,
|
|
1688
|
+
"foreignKey": {
|
|
1689
|
+
"table": "permissions",
|
|
1690
|
+
"column": "id",
|
|
1691
|
+
"onDelete": "NO ACTION",
|
|
1692
|
+
"onUpdate": "CASCADE"
|
|
1693
|
+
}
|
|
1694
|
+
},
|
|
1695
|
+
"effect": {
|
|
1696
|
+
"type": "TEXT",
|
|
1697
|
+
"notNull": false,
|
|
1698
|
+
"unique": false
|
|
1296
1699
|
}
|
|
1297
1700
|
},
|
|
1298
1701
|
"indexes": [
|
|
1299
1702
|
{
|
|
1300
|
-
"name": "
|
|
1703
|
+
"name": "membership_overrides_slug_context_idx",
|
|
1301
1704
|
"columns": [
|
|
1302
1705
|
"slug",
|
|
1303
1706
|
"context"
|
|
@@ -1305,13 +1708,25 @@
|
|
|
1305
1708
|
"unique": true
|
|
1306
1709
|
},
|
|
1307
1710
|
{
|
|
1308
|
-
"name": "
|
|
1711
|
+
"name": "membership_overrides_created_at_idx",
|
|
1309
1712
|
"columns": [
|
|
1310
1713
|
"created_at"
|
|
1311
1714
|
]
|
|
1715
|
+
},
|
|
1716
|
+
{
|
|
1717
|
+
"name": "membership_overrides_membership_id_idx",
|
|
1718
|
+
"columns": [
|
|
1719
|
+
"membership_id"
|
|
1720
|
+
]
|
|
1721
|
+
},
|
|
1722
|
+
{
|
|
1723
|
+
"name": "membership_overrides_permission_id_idx",
|
|
1724
|
+
"columns": [
|
|
1725
|
+
"permission_id"
|
|
1726
|
+
]
|
|
1312
1727
|
}
|
|
1313
1728
|
],
|
|
1314
|
-
"version": "
|
|
1729
|
+
"version": "25fe9da8"
|
|
1315
1730
|
}
|
|
1316
1731
|
},
|
|
1317
1732
|
"@happyvertical/smrt-users:PermissionCollection": {
|
|
@@ -1402,8 +1817,8 @@
|
|
|
1402
1817
|
"exportName": "PermissionCollection",
|
|
1403
1818
|
"collectionExportName": "PermissionCollectionCollection",
|
|
1404
1819
|
"schema": {
|
|
1405
|
-
"tableName": "
|
|
1406
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
1820
|
+
"tableName": "permissions",
|
|
1821
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"permissions\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"name\" TEXT DEFAULT '',\n \"description\" TEXT DEFAULT '',\n \"category\" TEXT DEFAULT ''\n);",
|
|
1407
1822
|
"columns": {
|
|
1408
1823
|
"id": {
|
|
1409
1824
|
"type": "UUID",
|
|
@@ -1429,11 +1844,29 @@
|
|
|
1429
1844
|
"type": "TIMESTAMP",
|
|
1430
1845
|
"notNull": true,
|
|
1431
1846
|
"default": "current_timestamp"
|
|
1847
|
+
},
|
|
1848
|
+
"name": {
|
|
1849
|
+
"type": "TEXT",
|
|
1850
|
+
"notNull": false,
|
|
1851
|
+
"unique": false,
|
|
1852
|
+
"default": ""
|
|
1853
|
+
},
|
|
1854
|
+
"description": {
|
|
1855
|
+
"type": "TEXT",
|
|
1856
|
+
"notNull": false,
|
|
1857
|
+
"unique": false,
|
|
1858
|
+
"default": ""
|
|
1859
|
+
},
|
|
1860
|
+
"category": {
|
|
1861
|
+
"type": "TEXT",
|
|
1862
|
+
"notNull": false,
|
|
1863
|
+
"unique": false,
|
|
1864
|
+
"default": ""
|
|
1432
1865
|
}
|
|
1433
1866
|
},
|
|
1434
1867
|
"indexes": [
|
|
1435
1868
|
{
|
|
1436
|
-
"name": "
|
|
1869
|
+
"name": "permissions_slug_context_idx",
|
|
1437
1870
|
"columns": [
|
|
1438
1871
|
"slug",
|
|
1439
1872
|
"context"
|
|
@@ -1441,13 +1874,13 @@
|
|
|
1441
1874
|
"unique": true
|
|
1442
1875
|
},
|
|
1443
1876
|
{
|
|
1444
|
-
"name": "
|
|
1877
|
+
"name": "permissions_created_at_idx",
|
|
1445
1878
|
"columns": [
|
|
1446
1879
|
"created_at"
|
|
1447
1880
|
]
|
|
1448
1881
|
}
|
|
1449
1882
|
],
|
|
1450
|
-
"version": "
|
|
1883
|
+
"version": "4c81b2af"
|
|
1451
1884
|
}
|
|
1452
1885
|
},
|
|
1453
1886
|
"@happyvertical/smrt-users:RoleCollection": {
|
|
@@ -1549,8 +1982,8 @@
|
|
|
1549
1982
|
"exportName": "RoleCollection",
|
|
1550
1983
|
"collectionExportName": "RoleCollectionCollection",
|
|
1551
1984
|
"schema": {
|
|
1552
|
-
"tableName": "
|
|
1553
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
1985
|
+
"tableName": "roles",
|
|
1986
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"roles\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID,\n \"name\" TEXT DEFAULT '',\n \"description\" TEXT DEFAULT '',\n \"is_system\" BOOLEAN DEFAULT FALSE,\n \"inherits_to_descendants\" BOOLEAN DEFAULT FALSE\n);",
|
|
1554
1987
|
"columns": {
|
|
1555
1988
|
"id": {
|
|
1556
1989
|
"type": "UUID",
|
|
@@ -1576,11 +2009,47 @@
|
|
|
1576
2009
|
"type": "TIMESTAMP",
|
|
1577
2010
|
"notNull": true,
|
|
1578
2011
|
"default": "current_timestamp"
|
|
2012
|
+
},
|
|
2013
|
+
"tenant_id": {
|
|
2014
|
+
"type": "UUID",
|
|
2015
|
+
"referenceKind": "foreignKey",
|
|
2016
|
+
"notNull": false,
|
|
2017
|
+
"unique": false,
|
|
2018
|
+
"foreignKey": {
|
|
2019
|
+
"table": "tenants",
|
|
2020
|
+
"column": "id",
|
|
2021
|
+
"onDelete": "NO ACTION",
|
|
2022
|
+
"onUpdate": "CASCADE"
|
|
2023
|
+
}
|
|
2024
|
+
},
|
|
2025
|
+
"name": {
|
|
2026
|
+
"type": "TEXT",
|
|
2027
|
+
"notNull": false,
|
|
2028
|
+
"unique": false,
|
|
2029
|
+
"default": ""
|
|
2030
|
+
},
|
|
2031
|
+
"description": {
|
|
2032
|
+
"type": "TEXT",
|
|
2033
|
+
"notNull": false,
|
|
2034
|
+
"unique": false,
|
|
2035
|
+
"default": ""
|
|
2036
|
+
},
|
|
2037
|
+
"is_system": {
|
|
2038
|
+
"type": "BOOLEAN",
|
|
2039
|
+
"notNull": false,
|
|
2040
|
+
"unique": false,
|
|
2041
|
+
"default": false
|
|
2042
|
+
},
|
|
2043
|
+
"inherits_to_descendants": {
|
|
2044
|
+
"type": "BOOLEAN",
|
|
2045
|
+
"notNull": false,
|
|
2046
|
+
"unique": false,
|
|
2047
|
+
"default": false
|
|
1579
2048
|
}
|
|
1580
2049
|
},
|
|
1581
2050
|
"indexes": [
|
|
1582
2051
|
{
|
|
1583
|
-
"name": "
|
|
2052
|
+
"name": "roles_slug_context_idx",
|
|
1584
2053
|
"columns": [
|
|
1585
2054
|
"slug",
|
|
1586
2055
|
"context"
|
|
@@ -1588,13 +2057,19 @@
|
|
|
1588
2057
|
"unique": true
|
|
1589
2058
|
},
|
|
1590
2059
|
{
|
|
1591
|
-
"name": "
|
|
2060
|
+
"name": "roles_created_at_idx",
|
|
1592
2061
|
"columns": [
|
|
1593
2062
|
"created_at"
|
|
1594
2063
|
]
|
|
2064
|
+
},
|
|
2065
|
+
{
|
|
2066
|
+
"name": "roles_tenant_id_idx",
|
|
2067
|
+
"columns": [
|
|
2068
|
+
"tenant_id"
|
|
2069
|
+
]
|
|
1595
2070
|
}
|
|
1596
2071
|
],
|
|
1597
|
-
"version": "
|
|
2072
|
+
"version": "47369d9d"
|
|
1598
2073
|
}
|
|
1599
2074
|
},
|
|
1600
2075
|
"@happyvertical/smrt-users:RolePermissionCollection": {
|
|
@@ -1745,8 +2220,8 @@
|
|
|
1745
2220
|
"exportName": "RolePermissionCollection",
|
|
1746
2221
|
"collectionExportName": "RolePermissionCollectionCollection",
|
|
1747
2222
|
"schema": {
|
|
1748
|
-
"tableName": "
|
|
1749
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
2223
|
+
"tableName": "role_permissions",
|
|
2224
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"role_permissions\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"role_id\" UUID NOT NULL,\n \"permission_id\" UUID NOT NULL\n);",
|
|
1750
2225
|
"columns": {
|
|
1751
2226
|
"id": {
|
|
1752
2227
|
"type": "UUID",
|
|
@@ -1772,11 +2247,35 @@
|
|
|
1772
2247
|
"type": "TIMESTAMP",
|
|
1773
2248
|
"notNull": true,
|
|
1774
2249
|
"default": "current_timestamp"
|
|
2250
|
+
},
|
|
2251
|
+
"role_id": {
|
|
2252
|
+
"type": "UUID",
|
|
2253
|
+
"referenceKind": "foreignKey",
|
|
2254
|
+
"notNull": true,
|
|
2255
|
+
"unique": false,
|
|
2256
|
+
"foreignKey": {
|
|
2257
|
+
"table": "roles",
|
|
2258
|
+
"column": "id",
|
|
2259
|
+
"onDelete": "NO ACTION",
|
|
2260
|
+
"onUpdate": "CASCADE"
|
|
2261
|
+
}
|
|
2262
|
+
},
|
|
2263
|
+
"permission_id": {
|
|
2264
|
+
"type": "UUID",
|
|
2265
|
+
"referenceKind": "foreignKey",
|
|
2266
|
+
"notNull": true,
|
|
2267
|
+
"unique": false,
|
|
2268
|
+
"foreignKey": {
|
|
2269
|
+
"table": "permissions",
|
|
2270
|
+
"column": "id",
|
|
2271
|
+
"onDelete": "NO ACTION",
|
|
2272
|
+
"onUpdate": "CASCADE"
|
|
2273
|
+
}
|
|
1775
2274
|
}
|
|
1776
2275
|
},
|
|
1777
2276
|
"indexes": [
|
|
1778
2277
|
{
|
|
1779
|
-
"name": "
|
|
2278
|
+
"name": "role_permissions_slug_context_idx",
|
|
1780
2279
|
"columns": [
|
|
1781
2280
|
"slug",
|
|
1782
2281
|
"context"
|
|
@@ -1784,13 +2283,25 @@
|
|
|
1784
2283
|
"unique": true
|
|
1785
2284
|
},
|
|
1786
2285
|
{
|
|
1787
|
-
"name": "
|
|
2286
|
+
"name": "role_permissions_created_at_idx",
|
|
1788
2287
|
"columns": [
|
|
1789
2288
|
"created_at"
|
|
1790
2289
|
]
|
|
2290
|
+
},
|
|
2291
|
+
{
|
|
2292
|
+
"name": "role_permissions_role_id_idx",
|
|
2293
|
+
"columns": [
|
|
2294
|
+
"role_id"
|
|
2295
|
+
]
|
|
2296
|
+
},
|
|
2297
|
+
{
|
|
2298
|
+
"name": "role_permissions_permission_id_idx",
|
|
2299
|
+
"columns": [
|
|
2300
|
+
"permission_id"
|
|
2301
|
+
]
|
|
1791
2302
|
}
|
|
1792
2303
|
],
|
|
1793
|
-
"version": "
|
|
2304
|
+
"version": "4dfed3ac"
|
|
1794
2305
|
}
|
|
1795
2306
|
},
|
|
1796
2307
|
"@happyvertical/smrt-users:SessionCollection": {
|
|
@@ -2018,8 +2529,8 @@
|
|
|
2018
2529
|
"exportName": "SessionCollection",
|
|
2019
2530
|
"collectionExportName": "SessionCollectionCollection",
|
|
2020
2531
|
"schema": {
|
|
2021
|
-
"tableName": "
|
|
2022
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
2532
|
+
"tableName": "sessions",
|
|
2533
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"sessions\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"user_id\" UUID,\n \"tenant_id\" UUID,\n \"status\" TEXT,\n \"expires_at\" TIMESTAMP,\n \"user_agent\" TEXT DEFAULT '',\n \"ip_address\" TEXT DEFAULT '',\n \"last_accessed_at\" TIMESTAMP,\n \"data\" JSON DEFAULT '{}'\n);",
|
|
2023
2534
|
"columns": {
|
|
2024
2535
|
"id": {
|
|
2025
2536
|
"type": "UUID",
|
|
@@ -2031,25 +2542,82 @@
|
|
|
2031
2542
|
"type": "TEXT",
|
|
2032
2543
|
"notNull": true
|
|
2033
2544
|
},
|
|
2034
|
-
"context": {
|
|
2545
|
+
"context": {
|
|
2546
|
+
"type": "TEXT",
|
|
2547
|
+
"notNull": true,
|
|
2548
|
+
"default": ""
|
|
2549
|
+
},
|
|
2550
|
+
"created_at": {
|
|
2551
|
+
"type": "TIMESTAMP",
|
|
2552
|
+
"notNull": true,
|
|
2553
|
+
"default": "current_timestamp"
|
|
2554
|
+
},
|
|
2555
|
+
"updated_at": {
|
|
2556
|
+
"type": "TIMESTAMP",
|
|
2557
|
+
"notNull": true,
|
|
2558
|
+
"default": "current_timestamp"
|
|
2559
|
+
},
|
|
2560
|
+
"user_id": {
|
|
2561
|
+
"type": "UUID",
|
|
2562
|
+
"referenceKind": "foreignKey",
|
|
2563
|
+
"notNull": false,
|
|
2564
|
+
"unique": false,
|
|
2565
|
+
"foreignKey": {
|
|
2566
|
+
"table": "users",
|
|
2567
|
+
"column": "id",
|
|
2568
|
+
"onDelete": "NO ACTION",
|
|
2569
|
+
"onUpdate": "CASCADE"
|
|
2570
|
+
}
|
|
2571
|
+
},
|
|
2572
|
+
"tenant_id": {
|
|
2573
|
+
"type": "UUID",
|
|
2574
|
+
"referenceKind": "foreignKey",
|
|
2575
|
+
"notNull": false,
|
|
2576
|
+
"unique": false,
|
|
2577
|
+
"foreignKey": {
|
|
2578
|
+
"table": "tenants",
|
|
2579
|
+
"column": "id",
|
|
2580
|
+
"onDelete": "NO ACTION",
|
|
2581
|
+
"onUpdate": "CASCADE"
|
|
2582
|
+
}
|
|
2583
|
+
},
|
|
2584
|
+
"status": {
|
|
2585
|
+
"type": "TEXT",
|
|
2586
|
+
"notNull": false,
|
|
2587
|
+
"unique": false
|
|
2588
|
+
},
|
|
2589
|
+
"expires_at": {
|
|
2590
|
+
"type": "TIMESTAMP",
|
|
2591
|
+
"notNull": false,
|
|
2592
|
+
"unique": false
|
|
2593
|
+
},
|
|
2594
|
+
"user_agent": {
|
|
2595
|
+
"type": "TEXT",
|
|
2596
|
+
"notNull": false,
|
|
2597
|
+
"unique": false,
|
|
2598
|
+
"default": ""
|
|
2599
|
+
},
|
|
2600
|
+
"ip_address": {
|
|
2035
2601
|
"type": "TEXT",
|
|
2036
|
-
"notNull":
|
|
2602
|
+
"notNull": false,
|
|
2603
|
+
"unique": false,
|
|
2037
2604
|
"default": ""
|
|
2038
2605
|
},
|
|
2039
|
-
"
|
|
2606
|
+
"last_accessed_at": {
|
|
2040
2607
|
"type": "TIMESTAMP",
|
|
2041
|
-
"notNull":
|
|
2042
|
-
"
|
|
2608
|
+
"notNull": false,
|
|
2609
|
+
"unique": false
|
|
2043
2610
|
},
|
|
2044
|
-
"
|
|
2045
|
-
"type": "
|
|
2046
|
-
"notNull":
|
|
2047
|
-
"
|
|
2611
|
+
"data": {
|
|
2612
|
+
"type": "JSON",
|
|
2613
|
+
"notNull": false,
|
|
2614
|
+
"unique": false,
|
|
2615
|
+
"default": {}
|
|
2048
2616
|
}
|
|
2049
2617
|
},
|
|
2050
2618
|
"indexes": [
|
|
2051
2619
|
{
|
|
2052
|
-
"name": "
|
|
2620
|
+
"name": "sessions_slug_context_idx",
|
|
2053
2621
|
"columns": [
|
|
2054
2622
|
"slug",
|
|
2055
2623
|
"context"
|
|
@@ -2057,13 +2625,31 @@
|
|
|
2057
2625
|
"unique": true
|
|
2058
2626
|
},
|
|
2059
2627
|
{
|
|
2060
|
-
"name": "
|
|
2628
|
+
"name": "sessions_expires_at_idx",
|
|
2629
|
+
"columns": [
|
|
2630
|
+
"expires_at"
|
|
2631
|
+
]
|
|
2632
|
+
},
|
|
2633
|
+
{
|
|
2634
|
+
"name": "sessions_created_at_idx",
|
|
2061
2635
|
"columns": [
|
|
2062
2636
|
"created_at"
|
|
2063
2637
|
]
|
|
2638
|
+
},
|
|
2639
|
+
{
|
|
2640
|
+
"name": "sessions_user_id_idx",
|
|
2641
|
+
"columns": [
|
|
2642
|
+
"user_id"
|
|
2643
|
+
]
|
|
2644
|
+
},
|
|
2645
|
+
{
|
|
2646
|
+
"name": "sessions_tenant_id_idx",
|
|
2647
|
+
"columns": [
|
|
2648
|
+
"tenant_id"
|
|
2649
|
+
]
|
|
2064
2650
|
}
|
|
2065
2651
|
],
|
|
2066
|
-
"version": "
|
|
2652
|
+
"version": "dc55d351"
|
|
2067
2653
|
}
|
|
2068
2654
|
},
|
|
2069
2655
|
"@happyvertical/smrt-users:TenantCollection": {
|
|
@@ -2350,8 +2936,8 @@
|
|
|
2350
2936
|
"exportName": "TenantCollection",
|
|
2351
2937
|
"collectionExportName": "TenantCollectionCollection",
|
|
2352
2938
|
"schema": {
|
|
2353
|
-
"tableName": "
|
|
2354
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
2939
|
+
"tableName": "tenants",
|
|
2940
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"tenants\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"_meta_type\" TEXT NOT NULL,\n \"_meta_data\" JSON,\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"name\" TEXT DEFAULT '',\n \"status\" TEXT,\n \"description\" TEXT DEFAULT '',\n \"parent_tenant_id\" UUID,\n \"hierarchy_level\" INTEGER DEFAULT 0,\n \"hierarchy_path\" TEXT DEFAULT '',\n \"cascade_permissions\" BOOLEAN DEFAULT TRUE,\n \"inherit_permissions\" BOOLEAN DEFAULT TRUE\n);",
|
|
2355
2941
|
"columns": {
|
|
2356
2942
|
"id": {
|
|
2357
2943
|
"type": "UUID",
|
|
@@ -2368,6 +2954,14 @@
|
|
|
2368
2954
|
"notNull": true,
|
|
2369
2955
|
"default": ""
|
|
2370
2956
|
},
|
|
2957
|
+
"_meta_type": {
|
|
2958
|
+
"type": "TEXT",
|
|
2959
|
+
"notNull": true
|
|
2960
|
+
},
|
|
2961
|
+
"_meta_data": {
|
|
2962
|
+
"type": "JSON",
|
|
2963
|
+
"notNull": false
|
|
2964
|
+
},
|
|
2371
2965
|
"created_at": {
|
|
2372
2966
|
"type": "TIMESTAMP",
|
|
2373
2967
|
"notNull": true,
|
|
@@ -2377,25 +2971,83 @@
|
|
|
2377
2971
|
"type": "TIMESTAMP",
|
|
2378
2972
|
"notNull": true,
|
|
2379
2973
|
"default": "current_timestamp"
|
|
2974
|
+
},
|
|
2975
|
+
"name": {
|
|
2976
|
+
"type": "TEXT",
|
|
2977
|
+
"notNull": false,
|
|
2978
|
+
"default": ""
|
|
2979
|
+
},
|
|
2980
|
+
"status": {
|
|
2981
|
+
"type": "TEXT",
|
|
2982
|
+
"notNull": false
|
|
2983
|
+
},
|
|
2984
|
+
"description": {
|
|
2985
|
+
"type": "TEXT",
|
|
2986
|
+
"notNull": false,
|
|
2987
|
+
"default": ""
|
|
2988
|
+
},
|
|
2989
|
+
"parent_tenant_id": {
|
|
2990
|
+
"type": "UUID",
|
|
2991
|
+
"referenceKind": "foreignKey",
|
|
2992
|
+
"notNull": false,
|
|
2993
|
+
"foreignKey": {
|
|
2994
|
+
"table": "tenants",
|
|
2995
|
+
"column": "id",
|
|
2996
|
+
"onDelete": "NO ACTION",
|
|
2997
|
+
"onUpdate": "CASCADE"
|
|
2998
|
+
}
|
|
2999
|
+
},
|
|
3000
|
+
"hierarchy_level": {
|
|
3001
|
+
"type": "INTEGER",
|
|
3002
|
+
"notNull": false,
|
|
3003
|
+
"default": 0
|
|
3004
|
+
},
|
|
3005
|
+
"hierarchy_path": {
|
|
3006
|
+
"type": "TEXT",
|
|
3007
|
+
"notNull": false,
|
|
3008
|
+
"default": ""
|
|
3009
|
+
},
|
|
3010
|
+
"cascade_permissions": {
|
|
3011
|
+
"type": "BOOLEAN",
|
|
3012
|
+
"notNull": false,
|
|
3013
|
+
"default": true
|
|
3014
|
+
},
|
|
3015
|
+
"inherit_permissions": {
|
|
3016
|
+
"type": "BOOLEAN",
|
|
3017
|
+
"notNull": false,
|
|
3018
|
+
"default": true
|
|
2380
3019
|
}
|
|
2381
3020
|
},
|
|
2382
3021
|
"indexes": [
|
|
2383
3022
|
{
|
|
2384
|
-
"name": "
|
|
3023
|
+
"name": "tenants_slug_context_meta_type_idx",
|
|
2385
3024
|
"columns": [
|
|
2386
3025
|
"slug",
|
|
2387
|
-
"context"
|
|
3026
|
+
"context",
|
|
3027
|
+
"_meta_type"
|
|
2388
3028
|
],
|
|
2389
3029
|
"unique": true
|
|
2390
3030
|
},
|
|
2391
3031
|
{
|
|
2392
|
-
"name": "
|
|
3032
|
+
"name": "tenants_meta_type_idx",
|
|
3033
|
+
"columns": [
|
|
3034
|
+
"_meta_type"
|
|
3035
|
+
]
|
|
3036
|
+
},
|
|
3037
|
+
{
|
|
3038
|
+
"name": "tenants_created_at_idx",
|
|
2393
3039
|
"columns": [
|
|
2394
3040
|
"created_at"
|
|
2395
3041
|
]
|
|
3042
|
+
},
|
|
3043
|
+
{
|
|
3044
|
+
"name": "tenants_parent_tenant_id_idx",
|
|
3045
|
+
"columns": [
|
|
3046
|
+
"parent_tenant_id"
|
|
3047
|
+
]
|
|
2396
3048
|
}
|
|
2397
3049
|
],
|
|
2398
|
-
"version": "
|
|
3050
|
+
"version": "934f7025"
|
|
2399
3051
|
}
|
|
2400
3052
|
},
|
|
2401
3053
|
"@happyvertical/smrt-users:TenantIntegrationCollection": {
|
|
@@ -2469,7 +3121,7 @@
|
|
|
2469
3121
|
"collectionExportName": "TenantIntegrationCollectionCollection",
|
|
2470
3122
|
"schema": {
|
|
2471
3123
|
"tableName": "tenant_integrations",
|
|
2472
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"tenant_integrations\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp\n);",
|
|
3124
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"tenant_integrations\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID NOT NULL,\n \"provider\" TEXT DEFAULT 'aws',\n \"external_ids\" TEXT,\n \"status\" TEXT DEFAULT 'unprovisioned',\n \"last_checked_at\" TIMESTAMP,\n \"last_check_summary\" TEXT,\n \"last_error\" TEXT\n);",
|
|
2473
3125
|
"columns": {
|
|
2474
3126
|
"id": {
|
|
2475
3127
|
"type": "UUID",
|
|
@@ -2495,25 +3147,72 @@
|
|
|
2495
3147
|
"type": "TIMESTAMP",
|
|
2496
3148
|
"notNull": true,
|
|
2497
3149
|
"default": "current_timestamp"
|
|
3150
|
+
},
|
|
3151
|
+
"tenant_id": {
|
|
3152
|
+
"type": "UUID",
|
|
3153
|
+
"referenceKind": "tenantId",
|
|
3154
|
+
"notNull": true,
|
|
3155
|
+
"unique": false
|
|
3156
|
+
},
|
|
3157
|
+
"provider": {
|
|
3158
|
+
"type": "TEXT",
|
|
3159
|
+
"notNull": false,
|
|
3160
|
+
"unique": false,
|
|
3161
|
+
"default": "aws"
|
|
3162
|
+
},
|
|
3163
|
+
"external_ids": {
|
|
3164
|
+
"type": "TEXT",
|
|
3165
|
+
"notNull": false,
|
|
3166
|
+
"unique": false
|
|
3167
|
+
},
|
|
3168
|
+
"status": {
|
|
3169
|
+
"type": "TEXT",
|
|
3170
|
+
"notNull": false,
|
|
3171
|
+
"unique": false,
|
|
3172
|
+
"default": "unprovisioned"
|
|
3173
|
+
},
|
|
3174
|
+
"last_checked_at": {
|
|
3175
|
+
"type": "TIMESTAMP",
|
|
3176
|
+
"notNull": false,
|
|
3177
|
+
"unique": false
|
|
3178
|
+
},
|
|
3179
|
+
"last_check_summary": {
|
|
3180
|
+
"type": "TEXT",
|
|
3181
|
+
"notNull": false,
|
|
3182
|
+
"unique": false
|
|
3183
|
+
},
|
|
3184
|
+
"last_error": {
|
|
3185
|
+
"type": "TEXT",
|
|
3186
|
+
"notNull": false,
|
|
3187
|
+
"unique": false
|
|
2498
3188
|
}
|
|
2499
3189
|
},
|
|
2500
3190
|
"indexes": [
|
|
3191
|
+
{
|
|
3192
|
+
"name": "tenant_integrations_tenant_id_provider_idx",
|
|
3193
|
+
"columns": [
|
|
3194
|
+
"tenant_id",
|
|
3195
|
+
"provider"
|
|
3196
|
+
],
|
|
3197
|
+
"unique": true,
|
|
3198
|
+
"nullsNotDistinct": true
|
|
3199
|
+
},
|
|
2501
3200
|
{
|
|
2502
3201
|
"name": "tenant_integrations_slug_context_idx",
|
|
2503
3202
|
"columns": [
|
|
2504
3203
|
"slug",
|
|
2505
3204
|
"context"
|
|
2506
|
-
]
|
|
2507
|
-
"unique": true
|
|
3205
|
+
]
|
|
2508
3206
|
},
|
|
2509
3207
|
{
|
|
2510
|
-
"name": "
|
|
3208
|
+
"name": "tenant_integrations_tenant_id_created_at_idx",
|
|
2511
3209
|
"columns": [
|
|
3210
|
+
"tenant_id",
|
|
2512
3211
|
"created_at"
|
|
2513
3212
|
]
|
|
2514
3213
|
}
|
|
2515
3214
|
],
|
|
2516
|
-
"version": "
|
|
3215
|
+
"version": "3ed31966"
|
|
2517
3216
|
}
|
|
2518
3217
|
},
|
|
2519
3218
|
"@happyvertical/smrt-users:TenantPermissionOverrideCollection": {
|
|
@@ -2800,8 +3499,8 @@
|
|
|
2800
3499
|
"exportName": "TenantPermissionOverrideCollection",
|
|
2801
3500
|
"collectionExportName": "TenantPermissionOverrideCollectionCollection",
|
|
2802
3501
|
"schema": {
|
|
2803
|
-
"tableName": "
|
|
2804
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
3502
|
+
"tableName": "tenant_permission_overrides",
|
|
3503
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"tenant_permission_overrides\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID NOT NULL,\n \"permission_id\" UUID NOT NULL,\n \"effect\" TEXT\n);",
|
|
2805
3504
|
"columns": {
|
|
2806
3505
|
"id": {
|
|
2807
3506
|
"type": "UUID",
|
|
@@ -2827,11 +3526,40 @@
|
|
|
2827
3526
|
"type": "TIMESTAMP",
|
|
2828
3527
|
"notNull": true,
|
|
2829
3528
|
"default": "current_timestamp"
|
|
3529
|
+
},
|
|
3530
|
+
"tenant_id": {
|
|
3531
|
+
"type": "UUID",
|
|
3532
|
+
"referenceKind": "foreignKey",
|
|
3533
|
+
"notNull": true,
|
|
3534
|
+
"unique": false,
|
|
3535
|
+
"foreignKey": {
|
|
3536
|
+
"table": "tenants",
|
|
3537
|
+
"column": "id",
|
|
3538
|
+
"onDelete": "NO ACTION",
|
|
3539
|
+
"onUpdate": "CASCADE"
|
|
3540
|
+
}
|
|
3541
|
+
},
|
|
3542
|
+
"permission_id": {
|
|
3543
|
+
"type": "UUID",
|
|
3544
|
+
"referenceKind": "foreignKey",
|
|
3545
|
+
"notNull": true,
|
|
3546
|
+
"unique": false,
|
|
3547
|
+
"foreignKey": {
|
|
3548
|
+
"table": "permissions",
|
|
3549
|
+
"column": "id",
|
|
3550
|
+
"onDelete": "NO ACTION",
|
|
3551
|
+
"onUpdate": "CASCADE"
|
|
3552
|
+
}
|
|
3553
|
+
},
|
|
3554
|
+
"effect": {
|
|
3555
|
+
"type": "TEXT",
|
|
3556
|
+
"notNull": false,
|
|
3557
|
+
"unique": false
|
|
2830
3558
|
}
|
|
2831
3559
|
},
|
|
2832
3560
|
"indexes": [
|
|
2833
3561
|
{
|
|
2834
|
-
"name": "
|
|
3562
|
+
"name": "tenant_permission_overrides_slug_context_idx",
|
|
2835
3563
|
"columns": [
|
|
2836
3564
|
"slug",
|
|
2837
3565
|
"context"
|
|
@@ -2839,13 +3567,25 @@
|
|
|
2839
3567
|
"unique": true
|
|
2840
3568
|
},
|
|
2841
3569
|
{
|
|
2842
|
-
"name": "
|
|
3570
|
+
"name": "tenant_permission_overrides_created_at_idx",
|
|
2843
3571
|
"columns": [
|
|
2844
3572
|
"created_at"
|
|
2845
3573
|
]
|
|
3574
|
+
},
|
|
3575
|
+
{
|
|
3576
|
+
"name": "tenant_permission_overrides_tenant_id_idx",
|
|
3577
|
+
"columns": [
|
|
3578
|
+
"tenant_id"
|
|
3579
|
+
]
|
|
3580
|
+
},
|
|
3581
|
+
{
|
|
3582
|
+
"name": "tenant_permission_overrides_permission_id_idx",
|
|
3583
|
+
"columns": [
|
|
3584
|
+
"permission_id"
|
|
3585
|
+
]
|
|
2846
3586
|
}
|
|
2847
3587
|
],
|
|
2848
|
-
"version": "
|
|
3588
|
+
"version": "95b78bdd"
|
|
2849
3589
|
}
|
|
2850
3590
|
},
|
|
2851
3591
|
"@happyvertical/smrt-users:UserCollection": {
|
|
@@ -2973,8 +3713,8 @@
|
|
|
2973
3713
|
"exportName": "UserCollection",
|
|
2974
3714
|
"collectionExportName": "UserCollectionCollection",
|
|
2975
3715
|
"schema": {
|
|
2976
|
-
"tableName": "
|
|
2977
|
-
"ddl": "CREATE TABLE IF NOT EXISTS \"
|
|
3716
|
+
"tableName": "users",
|
|
3717
|
+
"ddl": "CREATE TABLE IF NOT EXISTS \"users\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"profile_id\" UUID UNIQUE,\n \"email\" TEXT DEFAULT '',\n \"email_key\" TEXT UNIQUE,\n \"status\" TEXT,\n \"last_login_at\" TIMESTAMP\n);",
|
|
2978
3718
|
"columns": {
|
|
2979
3719
|
"id": {
|
|
2980
3720
|
"type": "UUID",
|
|
@@ -3000,11 +3740,38 @@
|
|
|
3000
3740
|
"type": "TIMESTAMP",
|
|
3001
3741
|
"notNull": true,
|
|
3002
3742
|
"default": "current_timestamp"
|
|
3743
|
+
},
|
|
3744
|
+
"profile_id": {
|
|
3745
|
+
"type": "UUID",
|
|
3746
|
+
"referenceKind": "crossPackageRef",
|
|
3747
|
+
"notNull": false,
|
|
3748
|
+
"unique": true
|
|
3749
|
+
},
|
|
3750
|
+
"email": {
|
|
3751
|
+
"type": "TEXT",
|
|
3752
|
+
"notNull": false,
|
|
3753
|
+
"unique": false,
|
|
3754
|
+
"default": ""
|
|
3755
|
+
},
|
|
3756
|
+
"email_key": {
|
|
3757
|
+
"type": "TEXT",
|
|
3758
|
+
"notNull": false,
|
|
3759
|
+
"unique": true
|
|
3760
|
+
},
|
|
3761
|
+
"status": {
|
|
3762
|
+
"type": "TEXT",
|
|
3763
|
+
"notNull": false,
|
|
3764
|
+
"unique": false
|
|
3765
|
+
},
|
|
3766
|
+
"last_login_at": {
|
|
3767
|
+
"type": "TIMESTAMP",
|
|
3768
|
+
"notNull": false,
|
|
3769
|
+
"unique": false
|
|
3003
3770
|
}
|
|
3004
3771
|
},
|
|
3005
3772
|
"indexes": [
|
|
3006
3773
|
{
|
|
3007
|
-
"name": "
|
|
3774
|
+
"name": "users_slug_context_idx",
|
|
3008
3775
|
"columns": [
|
|
3009
3776
|
"slug",
|
|
3010
3777
|
"context"
|
|
@@ -3012,13 +3779,19 @@
|
|
|
3012
3779
|
"unique": true
|
|
3013
3780
|
},
|
|
3014
3781
|
{
|
|
3015
|
-
"name": "
|
|
3782
|
+
"name": "users_email_idx",
|
|
3783
|
+
"columns": [
|
|
3784
|
+
"email"
|
|
3785
|
+
]
|
|
3786
|
+
},
|
|
3787
|
+
{
|
|
3788
|
+
"name": "users_created_at_idx",
|
|
3016
3789
|
"columns": [
|
|
3017
3790
|
"created_at"
|
|
3018
3791
|
]
|
|
3019
3792
|
}
|
|
3020
3793
|
],
|
|
3021
|
-
"version": "
|
|
3794
|
+
"version": "38fd1677"
|
|
3022
3795
|
}
|
|
3023
3796
|
},
|
|
3024
3797
|
"@happyvertical/smrt-users:AccessRequest": {
|
|
@@ -5981,7 +6754,8 @@
|
|
|
5981
6754
|
"tenant_id",
|
|
5982
6755
|
"provider"
|
|
5983
6756
|
],
|
|
5984
|
-
"unique": true
|
|
6757
|
+
"unique": true,
|
|
6758
|
+
"nullsNotDistinct": true
|
|
5985
6759
|
},
|
|
5986
6760
|
{
|
|
5987
6761
|
"name": "tenant_integrations_slug_context_idx",
|