schub 0.1.21 → 0.1.23

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.
@@ -0,0 +1,1423 @@
1
+ {
2
+ "version": "6",
3
+ "dialect": "sqlite",
4
+ "id": "099e94d4-598a-41ac-a688-5bbc81d7e44f",
5
+ "prevId": "6a7eb47b-0c94-4361-a295-cd68648e1278",
6
+ "tables": {
7
+ "files": {
8
+ "name": "files",
9
+ "columns": {
10
+ "id": {
11
+ "name": "id",
12
+ "type": "text",
13
+ "primaryKey": true,
14
+ "notNull": true,
15
+ "autoincrement": false
16
+ },
17
+ "project_id": {
18
+ "name": "project_id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true,
22
+ "autoincrement": false
23
+ },
24
+ "file_name": {
25
+ "name": "file_name",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true,
29
+ "autoincrement": false
30
+ },
31
+ "file_kind": {
32
+ "name": "file_kind",
33
+ "type": "text",
34
+ "primaryKey": false,
35
+ "notNull": true,
36
+ "autoincrement": false
37
+ },
38
+ "storage_path": {
39
+ "name": "storage_path",
40
+ "type": "text",
41
+ "primaryKey": false,
42
+ "notNull": true,
43
+ "autoincrement": false
44
+ },
45
+ "mime_type": {
46
+ "name": "mime_type",
47
+ "type": "text",
48
+ "primaryKey": false,
49
+ "notNull": false,
50
+ "autoincrement": false
51
+ },
52
+ "size_bytes": {
53
+ "name": "size_bytes",
54
+ "type": "integer",
55
+ "primaryKey": false,
56
+ "notNull": true,
57
+ "autoincrement": false
58
+ },
59
+ "hash": {
60
+ "name": "hash",
61
+ "type": "text",
62
+ "primaryKey": false,
63
+ "notNull": false,
64
+ "autoincrement": false
65
+ },
66
+ "created_at": {
67
+ "name": "created_at",
68
+ "type": "text",
69
+ "primaryKey": false,
70
+ "notNull": true,
71
+ "autoincrement": false
72
+ },
73
+ "updated_at": {
74
+ "name": "updated_at",
75
+ "type": "text",
76
+ "primaryKey": false,
77
+ "notNull": true,
78
+ "autoincrement": false
79
+ }
80
+ },
81
+ "indexes": {},
82
+ "foreignKeys": {
83
+ "files_project_id_projects_id_fk": {
84
+ "name": "files_project_id_projects_id_fk",
85
+ "tableFrom": "files",
86
+ "tableTo": "projects",
87
+ "columnsFrom": ["project_id"],
88
+ "columnsTo": ["id"],
89
+ "onDelete": "cascade",
90
+ "onUpdate": "no action"
91
+ }
92
+ },
93
+ "compositePrimaryKeys": {},
94
+ "uniqueConstraints": {},
95
+ "checkConstraints": {}
96
+ },
97
+ "project_doc_files": {
98
+ "name": "project_doc_files",
99
+ "columns": {
100
+ "id": {
101
+ "name": "id",
102
+ "type": "text",
103
+ "primaryKey": true,
104
+ "notNull": true,
105
+ "autoincrement": false
106
+ },
107
+ "project_doc_id": {
108
+ "name": "project_doc_id",
109
+ "type": "text",
110
+ "primaryKey": false,
111
+ "notNull": true,
112
+ "autoincrement": false
113
+ },
114
+ "file_id": {
115
+ "name": "file_id",
116
+ "type": "text",
117
+ "primaryKey": false,
118
+ "notNull": true,
119
+ "autoincrement": false
120
+ },
121
+ "created_at": {
122
+ "name": "created_at",
123
+ "type": "text",
124
+ "primaryKey": false,
125
+ "notNull": true,
126
+ "autoincrement": false
127
+ }
128
+ },
129
+ "indexes": {
130
+ "project_doc_files_project_doc_file_idx": {
131
+ "name": "project_doc_files_project_doc_file_idx",
132
+ "columns": ["project_doc_id", "file_id"],
133
+ "isUnique": true
134
+ }
135
+ },
136
+ "foreignKeys": {
137
+ "project_doc_files_project_doc_id_project_docs_id_fk": {
138
+ "name": "project_doc_files_project_doc_id_project_docs_id_fk",
139
+ "tableFrom": "project_doc_files",
140
+ "tableTo": "project_docs",
141
+ "columnsFrom": ["project_doc_id"],
142
+ "columnsTo": ["id"],
143
+ "onDelete": "cascade",
144
+ "onUpdate": "no action"
145
+ },
146
+ "project_doc_files_file_id_files_id_fk": {
147
+ "name": "project_doc_files_file_id_files_id_fk",
148
+ "tableFrom": "project_doc_files",
149
+ "tableTo": "files",
150
+ "columnsFrom": ["file_id"],
151
+ "columnsTo": ["id"],
152
+ "onDelete": "cascade",
153
+ "onUpdate": "no action"
154
+ }
155
+ },
156
+ "compositePrimaryKeys": {},
157
+ "uniqueConstraints": {},
158
+ "checkConstraints": {}
159
+ },
160
+ "project_docs": {
161
+ "name": "project_docs",
162
+ "columns": {
163
+ "id": {
164
+ "name": "id",
165
+ "type": "text",
166
+ "primaryKey": true,
167
+ "notNull": true,
168
+ "autoincrement": false
169
+ },
170
+ "project_id": {
171
+ "name": "project_id",
172
+ "type": "text",
173
+ "primaryKey": false,
174
+ "notNull": true,
175
+ "autoincrement": false
176
+ },
177
+ "last_synced_at": {
178
+ "name": "last_synced_at",
179
+ "type": "text",
180
+ "primaryKey": false,
181
+ "notNull": false,
182
+ "autoincrement": false
183
+ },
184
+ "created_at": {
185
+ "name": "created_at",
186
+ "type": "text",
187
+ "primaryKey": false,
188
+ "notNull": true,
189
+ "autoincrement": false
190
+ },
191
+ "updated_at": {
192
+ "name": "updated_at",
193
+ "type": "text",
194
+ "primaryKey": false,
195
+ "notNull": true,
196
+ "autoincrement": false
197
+ }
198
+ },
199
+ "indexes": {
200
+ "project_docs_project_id_idx": {
201
+ "name": "project_docs_project_id_idx",
202
+ "columns": ["project_id"],
203
+ "isUnique": true
204
+ }
205
+ },
206
+ "foreignKeys": {
207
+ "project_docs_project_id_projects_id_fk": {
208
+ "name": "project_docs_project_id_projects_id_fk",
209
+ "tableFrom": "project_docs",
210
+ "tableTo": "projects",
211
+ "columnsFrom": ["project_id"],
212
+ "columnsTo": ["id"],
213
+ "onDelete": "cascade",
214
+ "onUpdate": "no action"
215
+ }
216
+ },
217
+ "compositePrimaryKeys": {},
218
+ "uniqueConstraints": {},
219
+ "checkConstraints": {}
220
+ },
221
+ "project_repos": {
222
+ "name": "project_repos",
223
+ "columns": {
224
+ "id": {
225
+ "name": "id",
226
+ "type": "text",
227
+ "primaryKey": true,
228
+ "notNull": true,
229
+ "autoincrement": false
230
+ },
231
+ "project_id": {
232
+ "name": "project_id",
233
+ "type": "text",
234
+ "primaryKey": false,
235
+ "notNull": true,
236
+ "autoincrement": false
237
+ },
238
+ "repo_id": {
239
+ "name": "repo_id",
240
+ "type": "text",
241
+ "primaryKey": false,
242
+ "notNull": true,
243
+ "autoincrement": false
244
+ },
245
+ "created_at": {
246
+ "name": "created_at",
247
+ "type": "text",
248
+ "primaryKey": false,
249
+ "notNull": true,
250
+ "autoincrement": false
251
+ }
252
+ },
253
+ "indexes": {},
254
+ "foreignKeys": {
255
+ "project_repos_project_id_projects_id_fk": {
256
+ "name": "project_repos_project_id_projects_id_fk",
257
+ "tableFrom": "project_repos",
258
+ "tableTo": "projects",
259
+ "columnsFrom": ["project_id"],
260
+ "columnsTo": ["id"],
261
+ "onDelete": "cascade",
262
+ "onUpdate": "no action"
263
+ },
264
+ "project_repos_repo_id_repos_id_fk": {
265
+ "name": "project_repos_repo_id_repos_id_fk",
266
+ "tableFrom": "project_repos",
267
+ "tableTo": "repos",
268
+ "columnsFrom": ["repo_id"],
269
+ "columnsTo": ["id"],
270
+ "onDelete": "cascade",
271
+ "onUpdate": "no action"
272
+ }
273
+ },
274
+ "compositePrimaryKeys": {},
275
+ "uniqueConstraints": {},
276
+ "checkConstraints": {}
277
+ },
278
+ "projects": {
279
+ "name": "projects",
280
+ "columns": {
281
+ "id": {
282
+ "name": "id",
283
+ "type": "text",
284
+ "primaryKey": true,
285
+ "notNull": true,
286
+ "autoincrement": false
287
+ },
288
+ "name": {
289
+ "name": "name",
290
+ "type": "text",
291
+ "primaryKey": false,
292
+ "notNull": true,
293
+ "autoincrement": false
294
+ },
295
+ "created_at": {
296
+ "name": "created_at",
297
+ "type": "text",
298
+ "primaryKey": false,
299
+ "notNull": true,
300
+ "autoincrement": false
301
+ },
302
+ "updated_at": {
303
+ "name": "updated_at",
304
+ "type": "text",
305
+ "primaryKey": false,
306
+ "notNull": true,
307
+ "autoincrement": false
308
+ }
309
+ },
310
+ "indexes": {},
311
+ "foreignKeys": {},
312
+ "compositePrimaryKeys": {},
313
+ "uniqueConstraints": {},
314
+ "checkConstraints": {}
315
+ },
316
+ "proposal_files": {
317
+ "name": "proposal_files",
318
+ "columns": {
319
+ "id": {
320
+ "name": "id",
321
+ "type": "text",
322
+ "primaryKey": true,
323
+ "notNull": true,
324
+ "autoincrement": false
325
+ },
326
+ "proposal_id": {
327
+ "name": "proposal_id",
328
+ "type": "text",
329
+ "primaryKey": false,
330
+ "notNull": true,
331
+ "autoincrement": false
332
+ },
333
+ "file_id": {
334
+ "name": "file_id",
335
+ "type": "text",
336
+ "primaryKey": false,
337
+ "notNull": true,
338
+ "autoincrement": false
339
+ },
340
+ "created_at": {
341
+ "name": "created_at",
342
+ "type": "text",
343
+ "primaryKey": false,
344
+ "notNull": true,
345
+ "autoincrement": false
346
+ }
347
+ },
348
+ "indexes": {},
349
+ "foreignKeys": {
350
+ "proposal_files_proposal_id_proposals_id_fk": {
351
+ "name": "proposal_files_proposal_id_proposals_id_fk",
352
+ "tableFrom": "proposal_files",
353
+ "tableTo": "proposals",
354
+ "columnsFrom": ["proposal_id"],
355
+ "columnsTo": ["id"],
356
+ "onDelete": "cascade",
357
+ "onUpdate": "no action"
358
+ },
359
+ "proposal_files_file_id_files_id_fk": {
360
+ "name": "proposal_files_file_id_files_id_fk",
361
+ "tableFrom": "proposal_files",
362
+ "tableTo": "files",
363
+ "columnsFrom": ["file_id"],
364
+ "columnsTo": ["id"],
365
+ "onDelete": "cascade",
366
+ "onUpdate": "no action"
367
+ }
368
+ },
369
+ "compositePrimaryKeys": {},
370
+ "uniqueConstraints": {},
371
+ "checkConstraints": {}
372
+ },
373
+ "proposal_statuses": {
374
+ "name": "proposal_statuses",
375
+ "columns": {
376
+ "id": {
377
+ "name": "id",
378
+ "type": "text",
379
+ "primaryKey": true,
380
+ "notNull": true,
381
+ "autoincrement": false
382
+ },
383
+ "project_id": {
384
+ "name": "project_id",
385
+ "type": "text",
386
+ "primaryKey": false,
387
+ "notNull": true,
388
+ "autoincrement": false
389
+ },
390
+ "name": {
391
+ "name": "name",
392
+ "type": "text",
393
+ "primaryKey": false,
394
+ "notNull": true,
395
+ "autoincrement": false
396
+ },
397
+ "sort_order": {
398
+ "name": "sort_order",
399
+ "type": "integer",
400
+ "primaryKey": false,
401
+ "notNull": true,
402
+ "autoincrement": false
403
+ },
404
+ "is_default": {
405
+ "name": "is_default",
406
+ "type": "integer",
407
+ "primaryKey": false,
408
+ "notNull": true,
409
+ "autoincrement": false
410
+ },
411
+ "created_at": {
412
+ "name": "created_at",
413
+ "type": "text",
414
+ "primaryKey": false,
415
+ "notNull": true,
416
+ "autoincrement": false
417
+ },
418
+ "updated_at": {
419
+ "name": "updated_at",
420
+ "type": "text",
421
+ "primaryKey": false,
422
+ "notNull": true,
423
+ "autoincrement": false
424
+ }
425
+ },
426
+ "indexes": {},
427
+ "foreignKeys": {
428
+ "proposal_statuses_project_id_projects_id_fk": {
429
+ "name": "proposal_statuses_project_id_projects_id_fk",
430
+ "tableFrom": "proposal_statuses",
431
+ "tableTo": "projects",
432
+ "columnsFrom": ["project_id"],
433
+ "columnsTo": ["id"],
434
+ "onDelete": "cascade",
435
+ "onUpdate": "no action"
436
+ }
437
+ },
438
+ "compositePrimaryKeys": {},
439
+ "uniqueConstraints": {},
440
+ "checkConstraints": {}
441
+ },
442
+ "proposals": {
443
+ "name": "proposals",
444
+ "columns": {
445
+ "id": {
446
+ "name": "id",
447
+ "type": "text",
448
+ "primaryKey": true,
449
+ "notNull": true,
450
+ "autoincrement": false
451
+ },
452
+ "shorthand": {
453
+ "name": "shorthand",
454
+ "type": "text",
455
+ "primaryKey": false,
456
+ "notNull": true,
457
+ "autoincrement": false
458
+ },
459
+ "project_id": {
460
+ "name": "project_id",
461
+ "type": "text",
462
+ "primaryKey": false,
463
+ "notNull": true,
464
+ "autoincrement": false
465
+ },
466
+ "repo_id": {
467
+ "name": "repo_id",
468
+ "type": "text",
469
+ "primaryKey": false,
470
+ "notNull": false,
471
+ "autoincrement": false
472
+ },
473
+ "agent": {
474
+ "name": "agent",
475
+ "type": "text",
476
+ "primaryKey": false,
477
+ "notNull": true,
478
+ "autoincrement": false
479
+ },
480
+ "input": {
481
+ "name": "input",
482
+ "type": "text",
483
+ "primaryKey": false,
484
+ "notNull": false,
485
+ "autoincrement": false
486
+ },
487
+ "status": {
488
+ "name": "status",
489
+ "type": "text",
490
+ "primaryKey": false,
491
+ "notNull": true,
492
+ "autoincrement": false,
493
+ "default": "'draft'"
494
+ },
495
+ "archived": {
496
+ "name": "archived",
497
+ "type": "integer",
498
+ "primaryKey": false,
499
+ "notNull": true,
500
+ "autoincrement": false,
501
+ "default": 0
502
+ },
503
+ "staged": {
504
+ "name": "staged",
505
+ "type": "integer",
506
+ "primaryKey": false,
507
+ "notNull": true,
508
+ "autoincrement": false,
509
+ "default": 0
510
+ },
511
+ "created_at": {
512
+ "name": "created_at",
513
+ "type": "text",
514
+ "primaryKey": false,
515
+ "notNull": true,
516
+ "autoincrement": false
517
+ },
518
+ "updated_at": {
519
+ "name": "updated_at",
520
+ "type": "text",
521
+ "primaryKey": false,
522
+ "notNull": true,
523
+ "autoincrement": false
524
+ }
525
+ },
526
+ "indexes": {
527
+ "proposals_project_shorthand_idx": {
528
+ "name": "proposals_project_shorthand_idx",
529
+ "columns": ["project_id", "shorthand"],
530
+ "isUnique": true
531
+ }
532
+ },
533
+ "foreignKeys": {
534
+ "proposals_project_id_projects_id_fk": {
535
+ "name": "proposals_project_id_projects_id_fk",
536
+ "tableFrom": "proposals",
537
+ "tableTo": "projects",
538
+ "columnsFrom": ["project_id"],
539
+ "columnsTo": ["id"],
540
+ "onDelete": "cascade",
541
+ "onUpdate": "no action"
542
+ },
543
+ "proposals_repo_id_repos_id_fk": {
544
+ "name": "proposals_repo_id_repos_id_fk",
545
+ "tableFrom": "proposals",
546
+ "tableTo": "repos",
547
+ "columnsFrom": ["repo_id"],
548
+ "columnsTo": ["id"],
549
+ "onDelete": "set null",
550
+ "onUpdate": "no action"
551
+ }
552
+ },
553
+ "compositePrimaryKeys": {},
554
+ "uniqueConstraints": {},
555
+ "checkConstraints": {}
556
+ },
557
+ "repos": {
558
+ "name": "repos",
559
+ "columns": {
560
+ "id": {
561
+ "name": "id",
562
+ "type": "text",
563
+ "primaryKey": true,
564
+ "notNull": true,
565
+ "autoincrement": false
566
+ },
567
+ "name": {
568
+ "name": "name",
569
+ "type": "text",
570
+ "primaryKey": false,
571
+ "notNull": true,
572
+ "autoincrement": false
573
+ },
574
+ "display_name": {
575
+ "name": "display_name",
576
+ "type": "text",
577
+ "primaryKey": false,
578
+ "notNull": false,
579
+ "autoincrement": false
580
+ },
581
+ "path": {
582
+ "name": "path",
583
+ "type": "text",
584
+ "primaryKey": false,
585
+ "notNull": true,
586
+ "autoincrement": false
587
+ },
588
+ "created_at": {
589
+ "name": "created_at",
590
+ "type": "text",
591
+ "primaryKey": false,
592
+ "notNull": true,
593
+ "autoincrement": false
594
+ },
595
+ "updated_at": {
596
+ "name": "updated_at",
597
+ "type": "text",
598
+ "primaryKey": false,
599
+ "notNull": true,
600
+ "autoincrement": false
601
+ }
602
+ },
603
+ "indexes": {},
604
+ "foreignKeys": {},
605
+ "compositePrimaryKeys": {},
606
+ "uniqueConstraints": {},
607
+ "checkConstraints": {}
608
+ },
609
+ "sessions": {
610
+ "name": "sessions",
611
+ "columns": {
612
+ "id": {
613
+ "name": "id",
614
+ "type": "text",
615
+ "primaryKey": true,
616
+ "notNull": true,
617
+ "autoincrement": false
618
+ },
619
+ "title": {
620
+ "name": "title",
621
+ "type": "text",
622
+ "primaryKey": false,
623
+ "notNull": true,
624
+ "autoincrement": false
625
+ },
626
+ "status": {
627
+ "name": "status",
628
+ "type": "text",
629
+ "primaryKey": false,
630
+ "notNull": true,
631
+ "autoincrement": false,
632
+ "default": "'in_progress'"
633
+ },
634
+ "archived": {
635
+ "name": "archived",
636
+ "type": "integer",
637
+ "primaryKey": false,
638
+ "notNull": true,
639
+ "autoincrement": false,
640
+ "default": 0
641
+ },
642
+ "created": {
643
+ "name": "created",
644
+ "type": "text",
645
+ "primaryKey": false,
646
+ "notNull": false,
647
+ "autoincrement": false
648
+ },
649
+ "last_request_started": {
650
+ "name": "last_request_started",
651
+ "type": "text",
652
+ "primaryKey": false,
653
+ "notNull": false,
654
+ "autoincrement": false
655
+ },
656
+ "last_request_ended": {
657
+ "name": "last_request_ended",
658
+ "type": "text",
659
+ "primaryKey": false,
660
+ "notNull": false,
661
+ "autoincrement": false
662
+ },
663
+ "agent": {
664
+ "name": "agent",
665
+ "type": "text",
666
+ "primaryKey": false,
667
+ "notNull": false,
668
+ "autoincrement": false
669
+ },
670
+ "agent_session_id": {
671
+ "name": "agent_session_id",
672
+ "type": "text",
673
+ "primaryKey": false,
674
+ "notNull": false,
675
+ "autoincrement": false
676
+ },
677
+ "content": {
678
+ "name": "content",
679
+ "type": "text",
680
+ "primaryKey": false,
681
+ "notNull": false,
682
+ "autoincrement": false
683
+ },
684
+ "created_at": {
685
+ "name": "created_at",
686
+ "type": "text",
687
+ "primaryKey": false,
688
+ "notNull": true,
689
+ "autoincrement": false
690
+ },
691
+ "updated_at": {
692
+ "name": "updated_at",
693
+ "type": "text",
694
+ "primaryKey": false,
695
+ "notNull": true,
696
+ "autoincrement": false
697
+ }
698
+ },
699
+ "indexes": {},
700
+ "foreignKeys": {},
701
+ "compositePrimaryKeys": {},
702
+ "uniqueConstraints": {},
703
+ "checkConstraints": {}
704
+ },
705
+ "templates": {
706
+ "name": "templates",
707
+ "columns": {
708
+ "id": {
709
+ "name": "id",
710
+ "type": "text",
711
+ "primaryKey": true,
712
+ "notNull": true,
713
+ "autoincrement": false
714
+ },
715
+ "project_id": {
716
+ "name": "project_id",
717
+ "type": "text",
718
+ "primaryKey": false,
719
+ "notNull": false,
720
+ "autoincrement": false
721
+ },
722
+ "name": {
723
+ "name": "name",
724
+ "type": "text",
725
+ "primaryKey": false,
726
+ "notNull": true,
727
+ "autoincrement": false
728
+ },
729
+ "template_type": {
730
+ "name": "template_type",
731
+ "type": "text",
732
+ "primaryKey": false,
733
+ "notNull": true,
734
+ "autoincrement": false
735
+ },
736
+ "content": {
737
+ "name": "content",
738
+ "type": "text",
739
+ "primaryKey": false,
740
+ "notNull": true,
741
+ "autoincrement": false
742
+ },
743
+ "created_at": {
744
+ "name": "created_at",
745
+ "type": "text",
746
+ "primaryKey": false,
747
+ "notNull": true,
748
+ "autoincrement": false
749
+ },
750
+ "updated_at": {
751
+ "name": "updated_at",
752
+ "type": "text",
753
+ "primaryKey": false,
754
+ "notNull": true,
755
+ "autoincrement": false
756
+ }
757
+ },
758
+ "indexes": {},
759
+ "foreignKeys": {
760
+ "templates_project_id_projects_id_fk": {
761
+ "name": "templates_project_id_projects_id_fk",
762
+ "tableFrom": "templates",
763
+ "tableTo": "projects",
764
+ "columnsFrom": ["project_id"],
765
+ "columnsTo": ["id"],
766
+ "onDelete": "set null",
767
+ "onUpdate": "no action"
768
+ }
769
+ },
770
+ "compositePrimaryKeys": {},
771
+ "uniqueConstraints": {},
772
+ "checkConstraints": {}
773
+ },
774
+ "ticket_files": {
775
+ "name": "ticket_files",
776
+ "columns": {
777
+ "id": {
778
+ "name": "id",
779
+ "type": "text",
780
+ "primaryKey": true,
781
+ "notNull": true,
782
+ "autoincrement": false
783
+ },
784
+ "ticket_id": {
785
+ "name": "ticket_id",
786
+ "type": "text",
787
+ "primaryKey": false,
788
+ "notNull": true,
789
+ "autoincrement": false
790
+ },
791
+ "file_id": {
792
+ "name": "file_id",
793
+ "type": "text",
794
+ "primaryKey": false,
795
+ "notNull": true,
796
+ "autoincrement": false
797
+ },
798
+ "created_at": {
799
+ "name": "created_at",
800
+ "type": "text",
801
+ "primaryKey": false,
802
+ "notNull": true,
803
+ "autoincrement": false
804
+ }
805
+ },
806
+ "indexes": {},
807
+ "foreignKeys": {
808
+ "ticket_files_ticket_id_tickets_id_fk": {
809
+ "name": "ticket_files_ticket_id_tickets_id_fk",
810
+ "tableFrom": "ticket_files",
811
+ "tableTo": "tickets",
812
+ "columnsFrom": ["ticket_id"],
813
+ "columnsTo": ["id"],
814
+ "onDelete": "cascade",
815
+ "onUpdate": "no action"
816
+ },
817
+ "ticket_files_file_id_files_id_fk": {
818
+ "name": "ticket_files_file_id_files_id_fk",
819
+ "tableFrom": "ticket_files",
820
+ "tableTo": "files",
821
+ "columnsFrom": ["file_id"],
822
+ "columnsTo": ["id"],
823
+ "onDelete": "cascade",
824
+ "onUpdate": "no action"
825
+ }
826
+ },
827
+ "compositePrimaryKeys": {},
828
+ "uniqueConstraints": {},
829
+ "checkConstraints": {}
830
+ },
831
+ "ticket_statuses": {
832
+ "name": "ticket_statuses",
833
+ "columns": {
834
+ "id": {
835
+ "name": "id",
836
+ "type": "text",
837
+ "primaryKey": true,
838
+ "notNull": true,
839
+ "autoincrement": false
840
+ },
841
+ "project_id": {
842
+ "name": "project_id",
843
+ "type": "text",
844
+ "primaryKey": false,
845
+ "notNull": true,
846
+ "autoincrement": false
847
+ },
848
+ "name": {
849
+ "name": "name",
850
+ "type": "text",
851
+ "primaryKey": false,
852
+ "notNull": true,
853
+ "autoincrement": false
854
+ },
855
+ "color": {
856
+ "name": "color",
857
+ "type": "text",
858
+ "primaryKey": false,
859
+ "notNull": true,
860
+ "autoincrement": false
861
+ },
862
+ "sort_order": {
863
+ "name": "sort_order",
864
+ "type": "integer",
865
+ "primaryKey": false,
866
+ "notNull": true,
867
+ "autoincrement": false
868
+ },
869
+ "is_default": {
870
+ "name": "is_default",
871
+ "type": "integer",
872
+ "primaryKey": false,
873
+ "notNull": true,
874
+ "autoincrement": false
875
+ },
876
+ "is_open": {
877
+ "name": "is_open",
878
+ "type": "integer",
879
+ "primaryKey": false,
880
+ "notNull": true,
881
+ "autoincrement": false,
882
+ "default": 1
883
+ },
884
+ "can_drag_out": {
885
+ "name": "can_drag_out",
886
+ "type": "integer",
887
+ "primaryKey": false,
888
+ "notNull": true,
889
+ "autoincrement": false
890
+ },
891
+ "can_drag_in": {
892
+ "name": "can_drag_in",
893
+ "type": "integer",
894
+ "primaryKey": false,
895
+ "notNull": true,
896
+ "autoincrement": false
897
+ },
898
+ "can_create": {
899
+ "name": "can_create",
900
+ "type": "integer",
901
+ "primaryKey": false,
902
+ "notNull": true,
903
+ "autoincrement": false
904
+ },
905
+ "can_attempt_on_drop": {
906
+ "name": "can_attempt_on_drop",
907
+ "type": "integer",
908
+ "primaryKey": false,
909
+ "notNull": true,
910
+ "autoincrement": false
911
+ },
912
+ "created_at": {
913
+ "name": "created_at",
914
+ "type": "text",
915
+ "primaryKey": false,
916
+ "notNull": true,
917
+ "autoincrement": false
918
+ },
919
+ "updated_at": {
920
+ "name": "updated_at",
921
+ "type": "text",
922
+ "primaryKey": false,
923
+ "notNull": true,
924
+ "autoincrement": false
925
+ }
926
+ },
927
+ "indexes": {},
928
+ "foreignKeys": {
929
+ "ticket_statuses_project_id_projects_id_fk": {
930
+ "name": "ticket_statuses_project_id_projects_id_fk",
931
+ "tableFrom": "ticket_statuses",
932
+ "tableTo": "projects",
933
+ "columnsFrom": ["project_id"],
934
+ "columnsTo": ["id"],
935
+ "onDelete": "cascade",
936
+ "onUpdate": "no action"
937
+ }
938
+ },
939
+ "compositePrimaryKeys": {},
940
+ "uniqueConstraints": {},
941
+ "checkConstraints": {}
942
+ },
943
+ "ticket_tag_assignments": {
944
+ "name": "ticket_tag_assignments",
945
+ "columns": {
946
+ "id": {
947
+ "name": "id",
948
+ "type": "text",
949
+ "primaryKey": true,
950
+ "notNull": true,
951
+ "autoincrement": false
952
+ },
953
+ "ticket_id": {
954
+ "name": "ticket_id",
955
+ "type": "text",
956
+ "primaryKey": false,
957
+ "notNull": true,
958
+ "autoincrement": false
959
+ },
960
+ "ticket_tag_id": {
961
+ "name": "ticket_tag_id",
962
+ "type": "text",
963
+ "primaryKey": false,
964
+ "notNull": true,
965
+ "autoincrement": false
966
+ },
967
+ "created_at": {
968
+ "name": "created_at",
969
+ "type": "text",
970
+ "primaryKey": false,
971
+ "notNull": true,
972
+ "autoincrement": false
973
+ }
974
+ },
975
+ "indexes": {
976
+ "ticket_tag_assignments_ticket_tag_idx": {
977
+ "name": "ticket_tag_assignments_ticket_tag_idx",
978
+ "columns": ["ticket_id", "ticket_tag_id"],
979
+ "isUnique": true
980
+ }
981
+ },
982
+ "foreignKeys": {
983
+ "ticket_tag_assignments_ticket_id_tickets_id_fk": {
984
+ "name": "ticket_tag_assignments_ticket_id_tickets_id_fk",
985
+ "tableFrom": "ticket_tag_assignments",
986
+ "tableTo": "tickets",
987
+ "columnsFrom": ["ticket_id"],
988
+ "columnsTo": ["id"],
989
+ "onDelete": "cascade",
990
+ "onUpdate": "no action"
991
+ },
992
+ "ticket_tag_assignments_ticket_tag_id_ticket_tags_id_fk": {
993
+ "name": "ticket_tag_assignments_ticket_tag_id_ticket_tags_id_fk",
994
+ "tableFrom": "ticket_tag_assignments",
995
+ "tableTo": "ticket_tags",
996
+ "columnsFrom": ["ticket_tag_id"],
997
+ "columnsTo": ["id"],
998
+ "onDelete": "cascade",
999
+ "onUpdate": "no action"
1000
+ }
1001
+ },
1002
+ "compositePrimaryKeys": {},
1003
+ "uniqueConstraints": {},
1004
+ "checkConstraints": {}
1005
+ },
1006
+ "ticket_tags": {
1007
+ "name": "ticket_tags",
1008
+ "columns": {
1009
+ "id": {
1010
+ "name": "id",
1011
+ "type": "text",
1012
+ "primaryKey": true,
1013
+ "notNull": true,
1014
+ "autoincrement": false
1015
+ },
1016
+ "project_id": {
1017
+ "name": "project_id",
1018
+ "type": "text",
1019
+ "primaryKey": false,
1020
+ "notNull": true,
1021
+ "autoincrement": false
1022
+ },
1023
+ "name": {
1024
+ "name": "name",
1025
+ "type": "text",
1026
+ "primaryKey": false,
1027
+ "notNull": true,
1028
+ "autoincrement": false
1029
+ },
1030
+ "color": {
1031
+ "name": "color",
1032
+ "type": "text",
1033
+ "primaryKey": false,
1034
+ "notNull": true,
1035
+ "autoincrement": false
1036
+ },
1037
+ "created_at": {
1038
+ "name": "created_at",
1039
+ "type": "text",
1040
+ "primaryKey": false,
1041
+ "notNull": true,
1042
+ "autoincrement": false
1043
+ },
1044
+ "updated_at": {
1045
+ "name": "updated_at",
1046
+ "type": "text",
1047
+ "primaryKey": false,
1048
+ "notNull": true,
1049
+ "autoincrement": false
1050
+ }
1051
+ },
1052
+ "indexes": {
1053
+ "ticket_tags_project_name_idx": {
1054
+ "name": "ticket_tags_project_name_idx",
1055
+ "columns": ["project_id", "name"],
1056
+ "isUnique": true
1057
+ }
1058
+ },
1059
+ "foreignKeys": {
1060
+ "ticket_tags_project_id_projects_id_fk": {
1061
+ "name": "ticket_tags_project_id_projects_id_fk",
1062
+ "tableFrom": "ticket_tags",
1063
+ "tableTo": "projects",
1064
+ "columnsFrom": ["project_id"],
1065
+ "columnsTo": ["id"],
1066
+ "onDelete": "cascade",
1067
+ "onUpdate": "no action"
1068
+ }
1069
+ },
1070
+ "compositePrimaryKeys": {},
1071
+ "uniqueConstraints": {},
1072
+ "checkConstraints": {}
1073
+ },
1074
+ "ticket_workspaces": {
1075
+ "name": "ticket_workspaces",
1076
+ "columns": {
1077
+ "id": {
1078
+ "name": "id",
1079
+ "type": "text",
1080
+ "primaryKey": true,
1081
+ "notNull": true,
1082
+ "autoincrement": false
1083
+ },
1084
+ "ticket_id": {
1085
+ "name": "ticket_id",
1086
+ "type": "text",
1087
+ "primaryKey": false,
1088
+ "notNull": true,
1089
+ "autoincrement": false
1090
+ },
1091
+ "workspace_id": {
1092
+ "name": "workspace_id",
1093
+ "type": "text",
1094
+ "primaryKey": false,
1095
+ "notNull": true,
1096
+ "autoincrement": false
1097
+ },
1098
+ "created_at": {
1099
+ "name": "created_at",
1100
+ "type": "text",
1101
+ "primaryKey": false,
1102
+ "notNull": true,
1103
+ "autoincrement": false
1104
+ }
1105
+ },
1106
+ "indexes": {
1107
+ "ticket_workspaces_ticket_workspace_idx": {
1108
+ "name": "ticket_workspaces_ticket_workspace_idx",
1109
+ "columns": ["ticket_id", "workspace_id"],
1110
+ "isUnique": true
1111
+ },
1112
+ "ticket_workspaces_workspace_idx": {
1113
+ "name": "ticket_workspaces_workspace_idx",
1114
+ "columns": ["workspace_id"],
1115
+ "isUnique": true
1116
+ }
1117
+ },
1118
+ "foreignKeys": {
1119
+ "ticket_workspaces_ticket_id_tickets_id_fk": {
1120
+ "name": "ticket_workspaces_ticket_id_tickets_id_fk",
1121
+ "tableFrom": "ticket_workspaces",
1122
+ "tableTo": "tickets",
1123
+ "columnsFrom": ["ticket_id"],
1124
+ "columnsTo": ["id"],
1125
+ "onDelete": "cascade",
1126
+ "onUpdate": "no action"
1127
+ },
1128
+ "ticket_workspaces_workspace_id_workspaces_id_fk": {
1129
+ "name": "ticket_workspaces_workspace_id_workspaces_id_fk",
1130
+ "tableFrom": "ticket_workspaces",
1131
+ "tableTo": "workspaces",
1132
+ "columnsFrom": ["workspace_id"],
1133
+ "columnsTo": ["id"],
1134
+ "onDelete": "cascade",
1135
+ "onUpdate": "no action"
1136
+ }
1137
+ },
1138
+ "compositePrimaryKeys": {},
1139
+ "uniqueConstraints": {},
1140
+ "checkConstraints": {}
1141
+ },
1142
+ "tickets": {
1143
+ "name": "tickets",
1144
+ "columns": {
1145
+ "id": {
1146
+ "name": "id",
1147
+ "type": "text",
1148
+ "primaryKey": true,
1149
+ "notNull": true,
1150
+ "autoincrement": false
1151
+ },
1152
+ "shorthand": {
1153
+ "name": "shorthand",
1154
+ "type": "text",
1155
+ "primaryKey": false,
1156
+ "notNull": true,
1157
+ "autoincrement": false
1158
+ },
1159
+ "project_id": {
1160
+ "name": "project_id",
1161
+ "type": "text",
1162
+ "primaryKey": false,
1163
+ "notNull": true,
1164
+ "autoincrement": false
1165
+ },
1166
+ "proposal_id": {
1167
+ "name": "proposal_id",
1168
+ "type": "text",
1169
+ "primaryKey": false,
1170
+ "notNull": false,
1171
+ "autoincrement": false
1172
+ },
1173
+ "status_id": {
1174
+ "name": "status_id",
1175
+ "type": "text",
1176
+ "primaryKey": false,
1177
+ "notNull": false,
1178
+ "autoincrement": false
1179
+ },
1180
+ "content": {
1181
+ "name": "content",
1182
+ "type": "text",
1183
+ "primaryKey": false,
1184
+ "notNull": false,
1185
+ "autoincrement": false
1186
+ },
1187
+ "input": {
1188
+ "name": "input",
1189
+ "type": "text",
1190
+ "primaryKey": false,
1191
+ "notNull": false,
1192
+ "autoincrement": false
1193
+ },
1194
+ "priority": {
1195
+ "name": "priority",
1196
+ "type": "text",
1197
+ "primaryKey": false,
1198
+ "notNull": false,
1199
+ "autoincrement": false
1200
+ },
1201
+ "parallelizable": {
1202
+ "name": "parallelizable",
1203
+ "type": "text",
1204
+ "primaryKey": false,
1205
+ "notNull": false,
1206
+ "autoincrement": false
1207
+ },
1208
+ "complexity": {
1209
+ "name": "complexity",
1210
+ "type": "text",
1211
+ "primaryKey": false,
1212
+ "notNull": false,
1213
+ "autoincrement": false
1214
+ },
1215
+ "blocked_by": {
1216
+ "name": "blocked_by",
1217
+ "type": "text",
1218
+ "primaryKey": false,
1219
+ "notNull": false,
1220
+ "autoincrement": false
1221
+ },
1222
+ "blocked_reason": {
1223
+ "name": "blocked_reason",
1224
+ "type": "text",
1225
+ "primaryKey": false,
1226
+ "notNull": false,
1227
+ "autoincrement": false
1228
+ },
1229
+ "dependencies": {
1230
+ "name": "dependencies",
1231
+ "type": "text",
1232
+ "primaryKey": false,
1233
+ "notNull": false,
1234
+ "autoincrement": false
1235
+ },
1236
+ "archived": {
1237
+ "name": "archived",
1238
+ "type": "integer",
1239
+ "primaryKey": false,
1240
+ "notNull": true,
1241
+ "autoincrement": false,
1242
+ "default": 0
1243
+ },
1244
+ "staged": {
1245
+ "name": "staged",
1246
+ "type": "integer",
1247
+ "primaryKey": false,
1248
+ "notNull": true,
1249
+ "autoincrement": false,
1250
+ "default": 0
1251
+ },
1252
+ "created_at": {
1253
+ "name": "created_at",
1254
+ "type": "text",
1255
+ "primaryKey": false,
1256
+ "notNull": true,
1257
+ "autoincrement": false
1258
+ },
1259
+ "updated_at": {
1260
+ "name": "updated_at",
1261
+ "type": "text",
1262
+ "primaryKey": false,
1263
+ "notNull": true,
1264
+ "autoincrement": false
1265
+ }
1266
+ },
1267
+ "indexes": {
1268
+ "tickets_project_shorthand_idx": {
1269
+ "name": "tickets_project_shorthand_idx",
1270
+ "columns": ["project_id", "shorthand"],
1271
+ "isUnique": true
1272
+ }
1273
+ },
1274
+ "foreignKeys": {
1275
+ "tickets_project_id_projects_id_fk": {
1276
+ "name": "tickets_project_id_projects_id_fk",
1277
+ "tableFrom": "tickets",
1278
+ "tableTo": "projects",
1279
+ "columnsFrom": ["project_id"],
1280
+ "columnsTo": ["id"],
1281
+ "onDelete": "cascade",
1282
+ "onUpdate": "no action"
1283
+ },
1284
+ "tickets_proposal_id_proposals_id_fk": {
1285
+ "name": "tickets_proposal_id_proposals_id_fk",
1286
+ "tableFrom": "tickets",
1287
+ "tableTo": "proposals",
1288
+ "columnsFrom": ["proposal_id"],
1289
+ "columnsTo": ["id"],
1290
+ "onDelete": "set null",
1291
+ "onUpdate": "no action"
1292
+ },
1293
+ "tickets_status_id_ticket_statuses_id_fk": {
1294
+ "name": "tickets_status_id_ticket_statuses_id_fk",
1295
+ "tableFrom": "tickets",
1296
+ "tableTo": "ticket_statuses",
1297
+ "columnsFrom": ["status_id"],
1298
+ "columnsTo": ["id"],
1299
+ "onDelete": "set null",
1300
+ "onUpdate": "no action"
1301
+ }
1302
+ },
1303
+ "compositePrimaryKeys": {},
1304
+ "uniqueConstraints": {},
1305
+ "checkConstraints": {}
1306
+ },
1307
+ "workspaces": {
1308
+ "name": "workspaces",
1309
+ "columns": {
1310
+ "id": {
1311
+ "name": "id",
1312
+ "type": "text",
1313
+ "primaryKey": true,
1314
+ "notNull": true,
1315
+ "autoincrement": false
1316
+ },
1317
+ "project_id": {
1318
+ "name": "project_id",
1319
+ "type": "text",
1320
+ "primaryKey": false,
1321
+ "notNull": true,
1322
+ "autoincrement": false
1323
+ },
1324
+ "name": {
1325
+ "name": "name",
1326
+ "type": "text",
1327
+ "primaryKey": false,
1328
+ "notNull": true,
1329
+ "autoincrement": false
1330
+ },
1331
+ "session_id": {
1332
+ "name": "session_id",
1333
+ "type": "text",
1334
+ "primaryKey": false,
1335
+ "notNull": false,
1336
+ "autoincrement": false
1337
+ },
1338
+ "branch": {
1339
+ "name": "branch",
1340
+ "type": "text",
1341
+ "primaryKey": false,
1342
+ "notNull": false,
1343
+ "autoincrement": false
1344
+ },
1345
+ "repo_id": {
1346
+ "name": "repo_id",
1347
+ "type": "text",
1348
+ "primaryKey": false,
1349
+ "notNull": false,
1350
+ "autoincrement": false
1351
+ },
1352
+ "worktree_path": {
1353
+ "name": "worktree_path",
1354
+ "type": "text",
1355
+ "primaryKey": false,
1356
+ "notNull": false,
1357
+ "autoincrement": false
1358
+ },
1359
+ "workspace_shorthand": {
1360
+ "name": "workspace_shorthand",
1361
+ "type": "text",
1362
+ "primaryKey": false,
1363
+ "notNull": false,
1364
+ "autoincrement": false
1365
+ },
1366
+ "created_at": {
1367
+ "name": "created_at",
1368
+ "type": "text",
1369
+ "primaryKey": false,
1370
+ "notNull": true,
1371
+ "autoincrement": false
1372
+ },
1373
+ "updated_at": {
1374
+ "name": "updated_at",
1375
+ "type": "text",
1376
+ "primaryKey": false,
1377
+ "notNull": true,
1378
+ "autoincrement": false
1379
+ }
1380
+ },
1381
+ "indexes": {
1382
+ "workspaces_project_workspace_shorthand_idx": {
1383
+ "name": "workspaces_project_workspace_shorthand_idx",
1384
+ "columns": ["project_id", "workspace_shorthand"],
1385
+ "isUnique": true
1386
+ }
1387
+ },
1388
+ "foreignKeys": {
1389
+ "workspaces_project_id_projects_id_fk": {
1390
+ "name": "workspaces_project_id_projects_id_fk",
1391
+ "tableFrom": "workspaces",
1392
+ "tableTo": "projects",
1393
+ "columnsFrom": ["project_id"],
1394
+ "columnsTo": ["id"],
1395
+ "onDelete": "cascade",
1396
+ "onUpdate": "no action"
1397
+ },
1398
+ "workspaces_session_id_sessions_id_fk": {
1399
+ "name": "workspaces_session_id_sessions_id_fk",
1400
+ "tableFrom": "workspaces",
1401
+ "tableTo": "sessions",
1402
+ "columnsFrom": ["session_id"],
1403
+ "columnsTo": ["id"],
1404
+ "onDelete": "set null",
1405
+ "onUpdate": "no action"
1406
+ }
1407
+ },
1408
+ "compositePrimaryKeys": {},
1409
+ "uniqueConstraints": {},
1410
+ "checkConstraints": {}
1411
+ }
1412
+ },
1413
+ "views": {},
1414
+ "enums": {},
1415
+ "_meta": {
1416
+ "schemas": {},
1417
+ "tables": {},
1418
+ "columns": {}
1419
+ },
1420
+ "internal": {
1421
+ "indexes": {}
1422
+ }
1423
+ }