tgstation-server 6.12.0
The /tg/station 13 server suite
Loading...
Searching...
No Matches
20200529171541_MYFixForeignKey.Designer.cs
Go to the documentation of this file.
1// <auto-generated />
2using System;
3using Microsoft.EntityFrameworkCore;
4using Microsoft.EntityFrameworkCore.Infrastructure;
5using Microsoft.EntityFrameworkCore.Migrations;
6
8{
9 [DbContext(typeof(MySqlDatabaseContext))]
10 [Migration("20200529171541_MYFixForeignKey")]
11 partial class MYFixForeignKey
12 {
14 protected override void BuildTargetModel(ModelBuilder modelBuilder)
15 {
16#pragma warning disable 612, 618
17 modelBuilder
18 .HasAnnotation("ProductVersion", "3.1.4")
19 .HasAnnotation("Relational:MaxIdentifierLength", 64);
20
21 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatBot", b =>
22 {
23 b.Property<long>("Id")
24 .ValueGeneratedOnAdd()
25 .HasColumnType("bigint");
26
27 b.Property<ushort?>("ChannelLimit")
28 .IsRequired()
29 .HasColumnType("smallint unsigned");
30
31 b.Property<string>("ConnectionString")
32 .IsRequired()
33 .HasColumnType("longtext CHARACTER SET utf8mb4")
34 .HasMaxLength(10000);
35
36 b.Property<bool?>("Enabled")
37 .HasColumnType("tinyint(1)");
38
39 b.Property<long>("InstanceId")
40 .HasColumnType("bigint");
41
42 b.Property<string>("Name")
43 .IsRequired()
44 .HasColumnType("varchar(100) CHARACTER SET utf8mb4")
45 .HasMaxLength(100);
46
47 b.Property<int>("Provider")
48 .HasColumnType("int");
49
50 b.Property<uint?>("ReconnectionInterval")
51 .IsRequired()
52 .HasColumnType("int unsigned");
53
54 b.HasKey("Id");
55
56 b.HasIndex("InstanceId", "Name")
57 .IsUnique();
58
59 b.ToTable("ChatBots");
60 });
61
62 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatChannel", b =>
63 {
64 b.Property<long>("Id")
65 .ValueGeneratedOnAdd()
66 .HasColumnType("bigint");
67
68 b.Property<long>("ChatSettingsId")
69 .HasColumnType("bigint");
70
71 b.Property<ulong?>("DiscordChannelId")
72 .HasColumnType("bigint unsigned");
73
74 b.Property<string>("IrcChannel")
75 .HasColumnType("varchar(100) CHARACTER SET utf8mb4")
76 .HasMaxLength(100);
77
78 b.Property<bool?>("IsAdminChannel")
79 .IsRequired()
80 .HasColumnType("tinyint(1)");
81
82 b.Property<bool?>("IsUpdatesChannel")
83 .IsRequired()
84 .HasColumnType("tinyint(1)");
85
86 b.Property<bool?>("IsWatchdogChannel")
87 .IsRequired()
88 .HasColumnType("tinyint(1)");
89
90 b.Property<string>("Tag")
91 .HasColumnType("longtext CHARACTER SET utf8mb4")
92 .HasMaxLength(10000);
93
94 b.HasKey("Id");
95
96 b.HasIndex("ChatSettingsId", "DiscordChannelId")
97 .IsUnique();
98
99 b.HasIndex("ChatSettingsId", "IrcChannel")
100 .IsUnique();
101
102 b.ToTable("ChatChannels");
103 });
104
105 modelBuilder.Entity("Tgstation.Server.Host.Models.CompileJob", b =>
106 {
107 b.Property<long>("Id")
108 .ValueGeneratedOnAdd()
109 .HasColumnType("bigint");
110
111 b.Property<string>("ByondVersion")
112 .IsRequired()
113 .HasColumnType("longtext CHARACTER SET utf8mb4");
114
115 b.Property<int?>("DMApiMajorVersion")
116 .HasColumnType("int");
117
118 b.Property<int?>("DMApiMinorVersion")
119 .HasColumnType("int");
120
121 b.Property<int?>("DMApiPatchVersion")
122 .HasColumnType("int");
123
124 b.Property<Guid?>("DirectoryName")
125 .IsRequired()
126 .HasColumnType("char(36)");
127
128 b.Property<string>("DmeName")
129 .IsRequired()
130 .HasColumnType("longtext CHARACTER SET utf8mb4");
131
132 b.Property<long>("JobId")
133 .HasColumnType("bigint");
134
135 b.Property<int>("MinimumSecurityLevel")
136 .HasColumnType("int");
137
138 b.Property<string>("Output")
139 .IsRequired()
140 .HasColumnType("longtext CHARACTER SET utf8mb4");
141
142 b.Property<long>("RevisionInformationId")
143 .HasColumnType("bigint");
144
145 b.HasKey("Id");
146
147 b.HasIndex("DirectoryName");
148
149 b.HasIndex("JobId")
150 .IsUnique();
151
152 b.HasIndex("RevisionInformationId");
153
154 b.ToTable("CompileJobs");
155 });
156
157 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
158 {
159 b.Property<long>("Id")
160 .ValueGeneratedOnAdd()
161 .HasColumnType("bigint");
162
163 b.Property<bool?>("AllowWebClient")
164 .IsRequired()
165 .HasColumnType("tinyint(1)");
166
167 b.Property<bool?>("AutoStart")
168 .IsRequired()
169 .HasColumnType("tinyint(1)");
170
171 b.Property<uint?>("HeartbeatSeconds")
172 .IsRequired()
173 .HasColumnType("int unsigned");
174
175 b.Property<long>("InstanceId")
176 .HasColumnType("bigint");
177
178 b.Property<ushort?>("PrimaryPort")
179 .IsRequired()
180 .HasColumnType("smallint unsigned");
181
182 b.Property<ushort?>("SecondaryPort")
183 .IsRequired()
184 .HasColumnType("smallint unsigned");
185
186 b.Property<int>("SecurityLevel")
187 .HasColumnType("int");
188
189 b.Property<uint?>("StartupTimeout")
190 .IsRequired()
191 .HasColumnType("int unsigned");
192
193 b.HasKey("Id");
194
195 b.HasIndex("InstanceId")
196 .IsUnique();
197
198 b.ToTable("DreamDaemonSettings");
199 });
200
201 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamMakerSettings", b =>
202 {
203 b.Property<long>("Id")
204 .ValueGeneratedOnAdd()
205 .HasColumnType("bigint");
206
207 b.Property<ushort?>("ApiValidationPort")
208 .IsRequired()
209 .HasColumnType("smallint unsigned");
210
211 b.Property<int>("ApiValidationSecurityLevel")
212 .HasColumnType("int");
213
214 b.Property<long>("InstanceId")
215 .HasColumnType("bigint");
216
217 b.Property<string>("ProjectName")
218 .HasColumnType("longtext CHARACTER SET utf8mb4")
219 .HasMaxLength(10000);
220
221 b.HasKey("Id");
222
223 b.HasIndex("InstanceId")
224 .IsUnique();
225
226 b.ToTable("DreamMakerSettings");
227 });
228
229 modelBuilder.Entity("Tgstation.Server.Host.Models.DualReattachInformation", b =>
230 {
231 b.Property<long>("Id")
232 .ValueGeneratedOnAdd()
233 .HasColumnType("bigint");
234
235 b.Property<long?>("AlphaId")
236 .HasColumnType("bigint");
237
238 b.Property<bool>("AlphaIsActive")
239 .HasColumnType("tinyint(1)");
240
241 b.Property<long?>("BravoId")
242 .HasColumnType("bigint");
243
244 b.Property<long>("InstanceId")
245 .HasColumnType("bigint");
246
247 b.HasKey("Id");
248
249 b.HasIndex("AlphaId");
250
251 b.HasIndex("BravoId");
252
253 b.HasIndex("InstanceId")
254 .IsUnique();
255
256 b.ToTable("WatchdogReattachInformations");
257 });
258
259 modelBuilder.Entity("Tgstation.Server.Host.Models.Instance", b =>
260 {
261 b.Property<long>("Id")
262 .ValueGeneratedOnAdd()
263 .HasColumnType("bigint");
264
265 b.Property<uint?>("AutoUpdateInterval")
266 .IsRequired()
267 .HasColumnType("int unsigned");
268
269 b.Property<ushort?>("ChatBotLimit")
270 .IsRequired()
271 .HasColumnType("smallint unsigned");
272
273 b.Property<int>("ConfigurationType")
274 .HasColumnType("int");
275
276 b.Property<string>("Name")
277 .IsRequired()
278 .HasColumnType("longtext CHARACTER SET utf8mb4")
279 .HasMaxLength(10000);
280
281 b.Property<bool?>("Online")
282 .IsRequired()
283 .HasColumnType("tinyint(1)");
284
285 b.Property<string>("Path")
286 .IsRequired()
287 .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
288
289 b.HasKey("Id");
290
291 b.HasIndex("Path")
292 .IsUnique();
293
294 b.ToTable("Instances");
295 });
296
297 modelBuilder.Entity("Tgstation.Server.Host.Models.InstanceUser", b =>
298 {
299 b.Property<long>("Id")
300 .ValueGeneratedOnAdd()
301 .HasColumnType("bigint");
302
303 b.Property<ulong>("ByondRights")
304 .HasColumnType("bigint unsigned");
305
306 b.Property<ulong>("ChatBotRights")
307 .HasColumnType("bigint unsigned");
308
309 b.Property<ulong>("ConfigurationRights")
310 .HasColumnType("bigint unsigned");
311
312 b.Property<ulong>("DreamDaemonRights")
313 .HasColumnType("bigint unsigned");
314
315 b.Property<ulong>("DreamMakerRights")
316 .HasColumnType("bigint unsigned");
317
318 b.Property<long>("InstanceId")
319 .HasColumnType("bigint");
320
321 b.Property<ulong>("InstanceUserRights")
322 .HasColumnType("bigint unsigned");
323
324 b.Property<ulong>("RepositoryRights")
325 .HasColumnType("bigint unsigned");
326
327 b.Property<long?>("UserId")
328 .IsRequired()
329 .HasColumnType("bigint");
330
331 b.HasKey("Id");
332
333 b.HasIndex("InstanceId");
334
335 b.HasIndex("UserId", "InstanceId")
336 .IsUnique();
337
338 b.ToTable("InstanceUsers");
339 });
340
341 modelBuilder.Entity("Tgstation.Server.Host.Models.Job", b =>
342 {
343 b.Property<long>("Id")
344 .ValueGeneratedOnAdd()
345 .HasColumnType("bigint");
346
347 b.Property<ulong?>("CancelRight")
348 .HasColumnType("bigint unsigned");
349
350 b.Property<ulong?>("CancelRightsType")
351 .HasColumnType("bigint unsigned");
352
353 b.Property<bool?>("Cancelled")
354 .IsRequired()
355 .HasColumnType("tinyint(1)");
356
357 b.Property<long?>("CancelledById")
358 .HasColumnType("bigint");
359
360 b.Property<string>("Description")
361 .IsRequired()
362 .HasColumnType("longtext CHARACTER SET utf8mb4");
363
364 b.Property<uint?>("ErrorCode")
365 .HasColumnType("int unsigned");
366
367 b.Property<string>("ExceptionDetails")
368 .HasColumnType("longtext CHARACTER SET utf8mb4");
369
370 b.Property<long>("InstanceId")
371 .HasColumnType("bigint");
372
373 b.Property<DateTimeOffset?>("StartedAt")
374 .IsRequired()
375 .HasColumnType("datetime(6)");
376
377 b.Property<long>("StartedById")
378 .HasColumnType("bigint");
379
380 b.Property<DateTimeOffset?>("StoppedAt")
381 .HasColumnType("datetime(6)");
382
383 b.HasKey("Id");
384
385 b.HasIndex("CancelledById");
386
387 b.HasIndex("InstanceId");
388
389 b.HasIndex("StartedById");
390
391 b.ToTable("Jobs");
392 });
393
394 modelBuilder.Entity("Tgstation.Server.Host.Models.ReattachInformation", b =>
395 {
396 b.Property<long>("Id")
397 .ValueGeneratedOnAdd()
398 .HasColumnType("bigint");
399
400 b.Property<string>("AccessIdentifier")
401 .IsRequired()
402 .HasColumnType("longtext CHARACTER SET utf8mb4");
403
404 b.Property<long>("CompileJobId")
405 .HasColumnType("bigint");
406
407 b.Property<bool>("IsPrimary")
408 .HasColumnType("tinyint(1)");
409
410 b.Property<int>("LaunchSecurityLevel")
411 .HasColumnType("int");
412
413 b.Property<ushort>("Port")
414 .HasColumnType("smallint unsigned");
415
416 b.Property<int>("ProcessId")
417 .HasColumnType("int");
418
419 b.Property<int>("RebootState")
420 .HasColumnType("int");
421
422 b.HasKey("Id");
423
424 b.HasIndex("CompileJobId");
425
426 b.ToTable("ReattachInformations");
427 });
428
429 modelBuilder.Entity("Tgstation.Server.Host.Models.RepositorySettings", b =>
430 {
431 b.Property<long>("Id")
432 .ValueGeneratedOnAdd()
433 .HasColumnType("bigint");
434
435 b.Property<string>("AccessToken")
436 .HasColumnType("longtext CHARACTER SET utf8mb4")
437 .HasMaxLength(10000);
438
439 b.Property<string>("AccessUser")
440 .HasColumnType("longtext CHARACTER SET utf8mb4")
441 .HasMaxLength(10000);
442
443 b.Property<bool?>("AutoUpdatesKeepTestMerges")
444 .IsRequired()
445 .HasColumnType("tinyint(1)");
446
447 b.Property<bool?>("AutoUpdatesSynchronize")
448 .IsRequired()
449 .HasColumnType("tinyint(1)");
450
451 b.Property<string>("CommitterEmail")
452 .IsRequired()
453 .HasColumnType("longtext CHARACTER SET utf8mb4")
454 .HasMaxLength(10000);
455
456 b.Property<string>("CommitterName")
457 .IsRequired()
458 .HasColumnType("longtext CHARACTER SET utf8mb4")
459 .HasMaxLength(10000);
460
461 b.Property<long>("InstanceId")
462 .HasColumnType("bigint");
463
464 b.Property<bool?>("PostTestMergeComment")
465 .IsRequired()
466 .HasColumnType("tinyint(1)");
467
468 b.Property<bool?>("PushTestMergeCommits")
469 .IsRequired()
470 .HasColumnType("tinyint(1)");
471
472 b.Property<bool?>("ShowTestMergeCommitters")
473 .IsRequired()
474 .HasColumnType("tinyint(1)");
475
476 b.HasKey("Id");
477
478 b.HasIndex("InstanceId")
479 .IsUnique();
480
481 b.ToTable("RepositorySettings");
482 });
483
484 modelBuilder.Entity("Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
485 {
486 b.Property<long>("Id")
487 .ValueGeneratedOnAdd()
488 .HasColumnType("bigint");
489
490 b.Property<long>("RevisionInformationId")
491 .HasColumnType("bigint");
492
493 b.Property<long>("TestMergeId")
494 .HasColumnType("bigint");
495
496 b.HasKey("Id");
497
498 b.HasIndex("RevisionInformationId");
499
500 b.HasIndex("TestMergeId");
501
502 b.ToTable("RevInfoTestMerges");
503 });
504
505 modelBuilder.Entity("Tgstation.Server.Host.Models.RevisionInformation", b =>
506 {
507 b.Property<long>("Id")
508 .ValueGeneratedOnAdd()
509 .HasColumnType("bigint");
510
511 b.Property<string>("CommitSha")
512 .IsRequired()
513 .HasColumnType("varchar(40) CHARACTER SET utf8mb4")
514 .HasMaxLength(40);
515
516 b.Property<long>("InstanceId")
517 .HasColumnType("bigint");
518
519 b.Property<string>("OriginCommitSha")
520 .IsRequired()
521 .HasColumnType("varchar(40) CHARACTER SET utf8mb4")
522 .HasMaxLength(40);
523
524 b.HasKey("Id");
525
526 b.HasIndex("InstanceId", "CommitSha")
527 .IsUnique();
528
529 b.ToTable("RevisionInformations");
530 });
531
532 modelBuilder.Entity("Tgstation.Server.Host.Models.TestMerge", b =>
533 {
534 b.Property<long>("Id")
535 .ValueGeneratedOnAdd()
536 .HasColumnType("bigint");
537
538 b.Property<string>("Author")
539 .IsRequired()
540 .HasColumnType("longtext CHARACTER SET utf8mb4");
541
542 b.Property<string>("BodyAtMerge")
543 .IsRequired()
544 .HasColumnType("longtext CHARACTER SET utf8mb4");
545
546 b.Property<string>("Comment")
547 .HasColumnType("longtext CHARACTER SET utf8mb4")
548 .HasMaxLength(10000);
549
550 b.Property<DateTimeOffset>("MergedAt")
551 .HasColumnType("datetime(6)");
552
553 b.Property<long>("MergedById")
554 .HasColumnType("bigint");
555
556 b.Property<int>("Number")
557 .HasColumnType("int");
558
559 b.Property<long?>("PrimaryRevisionInformationId")
560 .IsRequired()
561 .HasColumnType("bigint");
562
563 b.Property<string>("PullRequestRevision")
564 .IsRequired()
565 .HasColumnType("varchar(40) CHARACTER SET utf8mb4")
566 .HasMaxLength(40);
567
568 b.Property<string>("TitleAtMerge")
569 .IsRequired()
570 .HasColumnType("longtext CHARACTER SET utf8mb4");
571
572 b.Property<string>("Url")
573 .IsRequired()
574 .HasColumnType("longtext CHARACTER SET utf8mb4");
575
576 b.HasKey("Id");
577
578 b.HasIndex("MergedById");
579
580 b.HasIndex("PrimaryRevisionInformationId")
581 .IsUnique();
582
583 b.ToTable("TestMerges");
584 });
585
586 modelBuilder.Entity("Tgstation.Server.Host.Models.User", b =>
587 {
588 b.Property<long?>("Id")
589 .ValueGeneratedOnAdd()
590 .HasColumnType("bigint");
591
592 b.Property<ulong>("AdministrationRights")
593 .HasColumnType("bigint unsigned");
594
595 b.Property<string>("CanonicalName")
596 .IsRequired()
597 .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
598
599 b.Property<DateTimeOffset?>("CreatedAt")
600 .IsRequired()
601 .HasColumnType("datetime(6)");
602
603 b.Property<long?>("CreatedById")
604 .HasColumnType("bigint");
605
606 b.Property<bool?>("Enabled")
607 .IsRequired()
608 .HasColumnType("tinyint(1)");
609
610 b.Property<ulong>("InstanceManagerRights")
611 .HasColumnType("bigint unsigned");
612
613 b.Property<DateTimeOffset?>("LastPasswordUpdate")
614 .HasColumnType("datetime(6)");
615
616 b.Property<string>("Name")
617 .IsRequired()
618 .HasColumnType("longtext CHARACTER SET utf8mb4")
619 .HasMaxLength(10000);
620
621 b.Property<string>("PasswordHash")
622 .HasColumnType("longtext CHARACTER SET utf8mb4");
623
624 b.Property<string>("SystemIdentifier")
625 .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
626
627 b.HasKey("Id");
628
629 b.HasIndex("CanonicalName")
630 .IsUnique();
631
632 b.HasIndex("CreatedById");
633
634 b.HasIndex("SystemIdentifier")
635 .IsUnique();
636
637 b.ToTable("Users");
638 });
639
640 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatBot", b =>
641 {
642 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
643 .WithMany("ChatSettings")
644 .HasForeignKey("InstanceId")
645 .OnDelete(DeleteBehavior.Cascade)
646 .IsRequired();
647 });
648
649 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatChannel", b =>
650 {
651 b.HasOne("Tgstation.Server.Host.Models.ChatBot", "ChatSettings")
652 .WithMany("Channels")
653 .HasForeignKey("ChatSettingsId")
654 .OnDelete(DeleteBehavior.Cascade)
655 .IsRequired();
656 });
657
658 modelBuilder.Entity("Tgstation.Server.Host.Models.CompileJob", b =>
659 {
660 b.HasOne("Tgstation.Server.Host.Models.Job", "Job")
661 .WithOne()
662 .HasForeignKey("Tgstation.Server.Host.Models.CompileJob", "JobId")
663 .OnDelete(DeleteBehavior.Cascade)
664 .IsRequired();
665
666 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "RevisionInformation")
667 .WithMany("CompileJobs")
668 .HasForeignKey("RevisionInformationId")
669 .OnDelete(DeleteBehavior.Cascade)
670 .IsRequired();
671 });
672
673 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
674 {
675 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
676 .WithOne("DreamDaemonSettings")
677 .HasForeignKey("Tgstation.Server.Host.Models.DreamDaemonSettings", "InstanceId")
678 .OnDelete(DeleteBehavior.Cascade)
679 .IsRequired();
680 });
681
682 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamMakerSettings", b =>
683 {
684 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
685 .WithOne("DreamMakerSettings")
686 .HasForeignKey("Tgstation.Server.Host.Models.DreamMakerSettings", "InstanceId")
687 .OnDelete(DeleteBehavior.Cascade)
688 .IsRequired();
689 });
690
691 modelBuilder.Entity("Tgstation.Server.Host.Models.DualReattachInformation", b =>
692 {
693 b.HasOne("Tgstation.Server.Host.Models.ReattachInformation", "Alpha")
694 .WithMany()
695 .HasForeignKey("AlphaId");
696
697 b.HasOne("Tgstation.Server.Host.Models.ReattachInformation", "Bravo")
698 .WithMany()
699 .HasForeignKey("BravoId");
700
701 b.HasOne("Tgstation.Server.Host.Models.Instance", null)
702 .WithOne("WatchdogReattachInformation")
703 .HasForeignKey("Tgstation.Server.Host.Models.DualReattachInformation", "InstanceId")
704 .OnDelete(DeleteBehavior.Cascade)
705 .IsRequired();
706 });
707
708 modelBuilder.Entity("Tgstation.Server.Host.Models.InstanceUser", b =>
709 {
710 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
711 .WithMany("InstanceUsers")
712 .HasForeignKey("InstanceId")
713 .OnDelete(DeleteBehavior.Cascade)
714 .IsRequired();
715
716 b.HasOne("Tgstation.Server.Host.Models.User", null)
717 .WithMany("InstanceUsers")
718 .HasForeignKey("UserId")
719 .OnDelete(DeleteBehavior.Cascade)
720 .IsRequired();
721 });
722
723 modelBuilder.Entity("Tgstation.Server.Host.Models.Job", b =>
724 {
725 b.HasOne("Tgstation.Server.Host.Models.User", "CancelledBy")
726 .WithMany()
727 .HasForeignKey("CancelledById");
728
729 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
730 .WithMany("Jobs")
731 .HasForeignKey("InstanceId")
732 .OnDelete(DeleteBehavior.Cascade)
733 .IsRequired();
734
735 b.HasOne("Tgstation.Server.Host.Models.User", "StartedBy")
736 .WithMany()
737 .HasForeignKey("StartedById")
738 .OnDelete(DeleteBehavior.Cascade)
739 .IsRequired();
740 });
741
742 modelBuilder.Entity("Tgstation.Server.Host.Models.ReattachInformation", b =>
743 {
744 b.HasOne("Tgstation.Server.Host.Models.CompileJob", "CompileJob")
745 .WithMany()
746 .HasForeignKey("CompileJobId")
747 .OnDelete(DeleteBehavior.Cascade)
748 .IsRequired();
749 });
750
751 modelBuilder.Entity("Tgstation.Server.Host.Models.RepositorySettings", b =>
752 {
753 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
754 .WithOne("RepositorySettings")
755 .HasForeignKey("Tgstation.Server.Host.Models.RepositorySettings", "InstanceId")
756 .OnDelete(DeleteBehavior.Cascade)
757 .IsRequired();
758 });
759
760 modelBuilder.Entity("Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
761 {
762 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "RevisionInformation")
763 .WithMany("ActiveTestMerges")
764 .HasForeignKey("RevisionInformationId")
765 .OnDelete(DeleteBehavior.Cascade)
766 .IsRequired();
767
768 b.HasOne("Tgstation.Server.Host.Models.TestMerge", "TestMerge")
769 .WithMany("RevisonInformations")
770 .HasForeignKey("TestMergeId")
771 .OnDelete(DeleteBehavior.ClientNoAction)
772 .IsRequired();
773 });
774
775 modelBuilder.Entity("Tgstation.Server.Host.Models.RevisionInformation", b =>
776 {
777 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
778 .WithMany("RevisionInformations")
779 .HasForeignKey("InstanceId")
780 .OnDelete(DeleteBehavior.Cascade)
781 .IsRequired();
782 });
783
784 modelBuilder.Entity("Tgstation.Server.Host.Models.TestMerge", b =>
785 {
786 b.HasOne("Tgstation.Server.Host.Models.User", "MergedBy")
787 .WithMany("TestMerges")
788 .HasForeignKey("MergedById")
789 .OnDelete(DeleteBehavior.Restrict)
790 .IsRequired();
791
792 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "PrimaryRevisionInformation")
793 .WithOne("PrimaryTestMerge")
794 .HasForeignKey("Tgstation.Server.Host.Models.TestMerge", "PrimaryRevisionInformationId")
795 .OnDelete(DeleteBehavior.Cascade)
796 .IsRequired();
797 });
798
799 modelBuilder.Entity("Tgstation.Server.Host.Models.User", b =>
800 {
801 b.HasOne("Tgstation.Server.Host.Models.User", "CreatedBy")
802 .WithMany("CreatedUsers")
803 .HasForeignKey("CreatedById");
804 });
805#pragma warning restore 612, 618
806 }
807 }
808}