18#pragma warning disable 612, 618
20 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn)
21 .HasAnnotation(
"ProductVersion",
"3.1.18")
22 .HasAnnotation(
"Relational:MaxIdentifierLength", 63);
24 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
26 b.Property<
long?>(
"Id")
27 .ValueGeneratedOnAdd()
28 .HasColumnType(
"bigint")
29 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
31 b.Property<
int>(
"ChannelLimit")
32 .HasColumnType(
"integer");
34 b.Property<
string>(
"ConnectionString")
36 .HasColumnType(
"character varying(10000)")
39 b.Property<
bool?>(
"Enabled")
40 .HasColumnType(
"boolean");
42 b.Property<
long>(
"InstanceId")
43 .HasColumnType(
"bigint");
45 b.Property<
string>(
"Name")
47 .HasColumnType(
"character varying(100)")
50 b.Property<
int>(
"Provider")
51 .HasColumnType(
"integer");
53 b.Property<
long>(
"ReconnectionInterval")
54 .HasColumnType(
"bigint");
58 b.HasIndex(
"InstanceId",
"Name")
61 b.ToTable(
"ChatBots");
64 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatChannel", b =>
66 b.Property<
long>(
"Id")
67 .ValueGeneratedOnAdd()
68 .HasColumnType(
"bigint")
69 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
71 b.Property<
long>(
"ChatSettingsId")
72 .HasColumnType(
"bigint");
74 b.Property<decimal?>(
"DiscordChannelId")
75 .HasColumnType(
"numeric(20,0)");
77 b.Property<
string>(
"IrcChannel")
78 .HasColumnType(
"character varying(100)")
81 b.Property<
bool?>(
"IsAdminChannel")
83 .HasColumnType(
"boolean");
85 b.Property<
bool?>(
"IsUpdatesChannel")
87 .HasColumnType(
"boolean");
89 b.Property<
bool?>(
"IsWatchdogChannel")
91 .HasColumnType(
"boolean");
93 b.Property<
string>(
"Tag")
94 .HasColumnType(
"character varying(10000)")
99 b.HasIndex(
"ChatSettingsId",
"DiscordChannelId")
102 b.HasIndex(
"ChatSettingsId",
"IrcChannel")
105 b.ToTable(
"ChatChannels");
108 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
110 b.Property<
long?>(
"Id")
111 .ValueGeneratedOnAdd()
112 .HasColumnType(
"bigint")
113 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
115 b.Property<
string>(
"ByondVersion")
117 .HasColumnType(
"text");
119 b.Property<
int?>(
"DMApiMajorVersion")
120 .HasColumnType(
"integer");
122 b.Property<
int?>(
"DMApiMinorVersion")
123 .HasColumnType(
"integer");
125 b.Property<
int?>(
"DMApiPatchVersion")
126 .HasColumnType(
"integer");
128 b.Property<Guid?>(
"DirectoryName")
130 .HasColumnType(
"uuid");
132 b.Property<
string>(
"DmeName")
134 .HasColumnType(
"text");
136 b.Property<
int?>(
"GitHubDeploymentId")
137 .HasColumnType(
"integer");
139 b.Property<
long?>(
"GitHubRepoId")
140 .HasColumnType(
"bigint");
142 b.Property<
long>(
"JobId")
143 .HasColumnType(
"bigint");
145 b.Property<
int?>(
"MinimumSecurityLevel")
146 .HasColumnType(
"integer");
148 b.Property<
string>(
"Output")
150 .HasColumnType(
"text");
152 b.Property<
string>(
"RepositoryOrigin")
153 .HasColumnType(
"text");
155 b.Property<
long>(
"RevisionInformationId")
156 .HasColumnType(
"bigint");
160 b.HasIndex(
"DirectoryName");
165 b.HasIndex(
"RevisionInformationId");
167 b.ToTable(
"CompileJobs");
170 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
172 b.Property<
long>(
"Id")
173 .ValueGeneratedOnAdd()
174 .HasColumnType(
"bigint")
175 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
177 b.Property<
string>(
"AdditionalParameters")
179 .HasColumnType(
"character varying(10000)")
180 .HasMaxLength(10000);
182 b.Property<
bool?>(
"AllowWebClient")
184 .HasColumnType(
"boolean");
186 b.Property<
bool?>(
"AutoStart")
188 .HasColumnType(
"boolean");
190 b.Property<
long>(
"HeartbeatSeconds")
191 .HasColumnType(
"bigint");
193 b.Property<
long>(
"InstanceId")
194 .HasColumnType(
"bigint");
196 b.Property<
int>(
"Port")
197 .HasColumnType(
"integer");
199 b.Property<
int>(
"SecurityLevel")
200 .HasColumnType(
"integer");
202 b.Property<
long>(
"StartupTimeout")
203 .HasColumnType(
"bigint");
205 b.Property<
long>(
"TopicRequestTimeout")
206 .HasColumnType(
"bigint");
208 b.Property<
int>(
"Visibility")
209 .HasColumnType(
"integer");
213 b.HasIndex(
"InstanceId")
216 b.ToTable(
"DreamDaemonSettings");
219 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
221 b.Property<
long>(
"Id")
222 .ValueGeneratedOnAdd()
223 .HasColumnType(
"bigint")
224 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
226 b.Property<
int>(
"ApiValidationPort")
227 .HasColumnType(
"integer");
229 b.Property<
int>(
"ApiValidationSecurityLevel")
230 .HasColumnType(
"integer");
232 b.Property<
long>(
"InstanceId")
233 .HasColumnType(
"bigint");
235 b.Property<
string>(
"ProjectName")
236 .HasColumnType(
"character varying(10000)")
237 .HasMaxLength(10000);
239 b.Property<
bool?>(
"RequireDMApiValidation")
241 .HasColumnType(
"boolean");
243 b.Property<TimeSpan?>(
"Timeout")
245 .HasColumnType(
"interval");
249 b.HasIndex(
"InstanceId")
252 b.ToTable(
"DreamMakerSettings");
255 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Instance", b =>
257 b.Property<
long?>(
"Id")
258 .ValueGeneratedOnAdd()
259 .HasColumnType(
"bigint")
260 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
262 b.Property<
long>(
"AutoUpdateInterval")
263 .HasColumnType(
"bigint");
265 b.Property<
int>(
"ChatBotLimit")
266 .HasColumnType(
"integer");
268 b.Property<
int>(
"ConfigurationType")
269 .HasColumnType(
"integer");
271 b.Property<
string>(
"Name")
273 .HasColumnType(
"character varying(100)")
276 b.Property<
bool?>(
"Online")
278 .HasColumnType(
"boolean");
280 b.Property<
string>(
"Path")
282 .HasColumnType(
"text");
284 b.Property<
string>(
"SwarmIdentifer")
285 .HasColumnType(
"text");
289 b.HasIndex(
"Path",
"SwarmIdentifer")
292 b.ToTable(
"Instances");
295 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
297 b.Property<
long>(
"Id")
298 .ValueGeneratedOnAdd()
299 .HasColumnType(
"bigint")
300 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
302 b.Property<decimal>(
"ByondRights")
303 .HasColumnType(
"numeric(20,0)");
305 b.Property<decimal>(
"ChatBotRights")
306 .HasColumnType(
"numeric(20,0)");
308 b.Property<decimal>(
"ConfigurationRights")
309 .HasColumnType(
"numeric(20,0)");
311 b.Property<decimal>(
"DreamDaemonRights")
312 .HasColumnType(
"numeric(20,0)");
314 b.Property<decimal>(
"DreamMakerRights")
315 .HasColumnType(
"numeric(20,0)");
317 b.Property<
long>(
"InstanceId")
318 .HasColumnType(
"bigint");
320 b.Property<decimal>(
"InstancePermissionSetRights")
321 .HasColumnType(
"numeric(20,0)");
323 b.Property<
long>(
"PermissionSetId")
324 .HasColumnType(
"bigint");
326 b.Property<decimal>(
"RepositoryRights")
327 .HasColumnType(
"numeric(20,0)");
331 b.HasIndex(
"InstanceId");
333 b.HasIndex(
"PermissionSetId",
"InstanceId")
336 b.ToTable(
"InstancePermissionSets");
339 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
341 b.Property<
long?>(
"Id")
342 .ValueGeneratedOnAdd()
343 .HasColumnType(
"bigint")
344 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
346 b.Property<decimal?>(
"CancelRight")
347 .HasColumnType(
"numeric(20,0)");
349 b.Property<decimal?>(
"CancelRightsType")
350 .HasColumnType(
"numeric(20,0)");
352 b.Property<
bool?>(
"Cancelled")
354 .HasColumnType(
"boolean");
356 b.Property<
long?>(
"CancelledById")
357 .HasColumnType(
"bigint");
359 b.Property<
string>(
"Description")
361 .HasColumnType(
"text");
363 b.Property<
long?>(
"ErrorCode")
364 .HasColumnType(
"bigint");
366 b.Property<
string>(
"ExceptionDetails")
367 .HasColumnType(
"text");
369 b.Property<
long>(
"InstanceId")
370 .HasColumnType(
"bigint");
372 b.Property<DateTimeOffset?>(
"StartedAt")
374 .HasColumnType(
"timestamp with time zone");
376 b.Property<
long>(
"StartedById")
377 .HasColumnType(
"bigint");
379 b.Property<DateTimeOffset?>(
"StoppedAt")
380 .HasColumnType(
"timestamp with time zone");
384 b.HasIndex(
"CancelledById");
386 b.HasIndex(
"InstanceId");
388 b.HasIndex(
"StartedById");
393 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
395 b.Property<
long>(
"Id")
396 .ValueGeneratedOnAdd()
397 .HasColumnType(
"bigint")
398 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
400 b.Property<
string>(
"ExternalUserId")
402 .HasColumnType(
"character varying(100)")
405 b.Property<
int>(
"Provider")
406 .HasColumnType(
"integer");
408 b.Property<
long?>(
"UserId")
409 .HasColumnType(
"bigint");
413 b.HasIndex(
"UserId");
415 b.HasIndex(
"Provider",
"ExternalUserId")
418 b.ToTable(
"OAuthConnections");
421 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
423 b.Property<
long?>(
"Id")
424 .ValueGeneratedOnAdd()
425 .HasColumnType(
"bigint")
426 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
428 b.Property<decimal>(
"AdministrationRights")
429 .HasColumnType(
"numeric(20,0)");
431 b.Property<
long?>(
"GroupId")
432 .HasColumnType(
"bigint");
434 b.Property<decimal>(
"InstanceManagerRights")
435 .HasColumnType(
"numeric(20,0)");
437 b.Property<
long?>(
"UserId")
438 .HasColumnType(
"bigint");
442 b.HasIndex(
"GroupId")
448 b.ToTable(
"PermissionSets");
451 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
453 b.Property<
long>(
"Id")
454 .ValueGeneratedOnAdd()
455 .HasColumnType(
"bigint")
456 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
458 b.Property<
string>(
"AccessIdentifier")
460 .HasColumnType(
"text");
462 b.Property<
long>(
"CompileJobId")
463 .HasColumnType(
"bigint");
465 b.Property<
int>(
"LaunchSecurityLevel")
466 .HasColumnType(
"integer");
468 b.Property<
int>(
"LaunchVisibility")
469 .HasColumnType(
"integer");
471 b.Property<
int>(
"Port")
472 .HasColumnType(
"integer");
474 b.Property<
int>(
"ProcessId")
475 .HasColumnType(
"integer");
477 b.Property<
int>(
"RebootState")
478 .HasColumnType(
"integer");
482 b.HasIndex(
"CompileJobId");
484 b.ToTable(
"ReattachInformations");
487 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
489 b.Property<
long>(
"Id")
490 .ValueGeneratedOnAdd()
491 .HasColumnType(
"bigint")
492 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
494 b.Property<
string>(
"AccessToken")
495 .HasColumnType(
"character varying(10000)")
496 .HasMaxLength(10000);
498 b.Property<
string>(
"AccessUser")
499 .HasColumnType(
"character varying(10000)")
500 .HasMaxLength(10000);
502 b.Property<
bool?>(
"AutoUpdatesKeepTestMerges")
504 .HasColumnType(
"boolean");
506 b.Property<
bool?>(
"AutoUpdatesSynchronize")
508 .HasColumnType(
"boolean");
510 b.Property<
string>(
"CommitterEmail")
512 .HasColumnType(
"character varying(10000)")
513 .HasMaxLength(10000);
515 b.Property<
string>(
"CommitterName")
517 .HasColumnType(
"character varying(10000)")
518 .HasMaxLength(10000);
520 b.Property<
bool?>(
"CreateGitHubDeployments")
522 .HasColumnType(
"boolean");
524 b.Property<
long>(
"InstanceId")
525 .HasColumnType(
"bigint");
527 b.Property<
bool?>(
"PostTestMergeComment")
529 .HasColumnType(
"boolean");
531 b.Property<
bool?>(
"PushTestMergeCommits")
533 .HasColumnType(
"boolean");
535 b.Property<
bool?>(
"ShowTestMergeCommitters")
537 .HasColumnType(
"boolean");
539 b.Property<
bool?>(
"UpdateSubmodules")
541 .HasColumnType(
"boolean");
545 b.HasIndex(
"InstanceId")
548 b.ToTable(
"RepositorySettings");
551 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
553 b.Property<
long>(
"Id")
554 .ValueGeneratedOnAdd()
555 .HasColumnType(
"bigint")
556 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
558 b.Property<
long>(
"RevisionInformationId")
559 .HasColumnType(
"bigint");
561 b.Property<
long>(
"TestMergeId")
562 .HasColumnType(
"bigint");
566 b.HasIndex(
"RevisionInformationId");
568 b.HasIndex(
"TestMergeId");
570 b.ToTable(
"RevInfoTestMerges");
573 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
575 b.Property<
long>(
"Id")
576 .ValueGeneratedOnAdd()
577 .HasColumnType(
"bigint")
578 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
580 b.Property<
string>(
"CommitSha")
582 .HasColumnType(
"character varying(40)")
585 b.Property<
long>(
"InstanceId")
586 .HasColumnType(
"bigint");
588 b.Property<
string>(
"OriginCommitSha")
590 .HasColumnType(
"character varying(40)")
593 b.Property<DateTimeOffset>(
"Timestamp")
594 .HasColumnType(
"timestamp with time zone");
598 b.HasIndex(
"InstanceId",
"CommitSha")
601 b.ToTable(
"RevisionInformations");
604 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
606 b.Property<
long>(
"Id")
607 .ValueGeneratedOnAdd()
608 .HasColumnType(
"bigint")
609 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
611 b.Property<
string>(
"Author")
613 .HasColumnType(
"text");
615 b.Property<
string>(
"BodyAtMerge")
617 .HasColumnType(
"text");
619 b.Property<
string>(
"Comment")
620 .HasColumnType(
"character varying(10000)")
621 .HasMaxLength(10000);
623 b.Property<DateTimeOffset>(
"MergedAt")
624 .HasColumnType(
"timestamp with time zone");
626 b.Property<
long>(
"MergedById")
627 .HasColumnType(
"bigint");
629 b.Property<
int>(
"Number")
630 .HasColumnType(
"integer");
632 b.Property<
long?>(
"PrimaryRevisionInformationId")
634 .HasColumnType(
"bigint");
636 b.Property<
string>(
"TargetCommitSha")
638 .HasColumnType(
"character varying(40)")
641 b.Property<
string>(
"TitleAtMerge")
643 .HasColumnType(
"text");
645 b.Property<
string>(
"Url")
647 .HasColumnType(
"text");
651 b.HasIndex(
"MergedById");
653 b.HasIndex(
"PrimaryRevisionInformationId")
656 b.ToTable(
"TestMerges");
659 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
661 b.Property<
long?>(
"Id")
662 .ValueGeneratedOnAdd()
663 .HasColumnType(
"bigint")
664 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
666 b.Property<
string>(
"CanonicalName")
668 .HasColumnType(
"character varying(100)")
671 b.Property<DateTimeOffset?>(
"CreatedAt")
673 .HasColumnType(
"timestamp with time zone");
675 b.Property<
long?>(
"CreatedById")
676 .HasColumnType(
"bigint");
678 b.Property<
bool?>(
"Enabled")
680 .HasColumnType(
"boolean");
682 b.Property<
long?>(
"GroupId")
683 .HasColumnType(
"bigint");
685 b.Property<DateTimeOffset?>(
"LastPasswordUpdate")
686 .HasColumnType(
"timestamp with time zone");
688 b.Property<
string>(
"Name")
690 .HasColumnType(
"character varying(100)")
693 b.Property<
string>(
"PasswordHash")
694 .HasColumnType(
"text");
696 b.Property<
string>(
"SystemIdentifier")
697 .HasColumnType(
"character varying(100)")
702 b.HasIndex(
"CanonicalName")
705 b.HasIndex(
"CreatedById");
707 b.HasIndex(
"GroupId");
709 b.HasIndex(
"SystemIdentifier")
715 modelBuilder.Entity(
"Tgstation.Server.Host.Models.UserGroup", b =>
717 b.Property<
long?>(
"Id")
718 .ValueGeneratedOnAdd()
719 .HasColumnType(
"bigint")
720 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
722 b.Property<
string>(
"Name")
724 .HasColumnType(
"character varying(100)")
735 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
737 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
738 .WithMany(
"ChatSettings")
739 .HasForeignKey(
"InstanceId")
740 .OnDelete(DeleteBehavior.Cascade)
744 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatChannel", b =>
746 b.HasOne(
"Tgstation.Server.Host.Models.ChatBot",
"ChatSettings")
747 .WithMany(
"Channels")
748 .HasForeignKey(
"ChatSettingsId")
749 .OnDelete(DeleteBehavior.Cascade)
753 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
755 b.HasOne(
"Tgstation.Server.Host.Models.Job",
"Job")
757 .HasForeignKey(
"Tgstation.Server.Host.Models.CompileJob",
"JobId")
758 .OnDelete(DeleteBehavior.Cascade)
761 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
762 .WithMany(
"CompileJobs")
763 .HasForeignKey(
"RevisionInformationId")
764 .OnDelete(DeleteBehavior.Cascade)
768 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
770 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
771 .WithOne(
"DreamDaemonSettings")
772 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamDaemonSettings",
"InstanceId")
773 .OnDelete(DeleteBehavior.Cascade)
777 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
779 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
780 .WithOne(
"DreamMakerSettings")
781 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamMakerSettings",
"InstanceId")
782 .OnDelete(DeleteBehavior.Cascade)
786 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
788 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
789 .WithMany(
"InstancePermissionSets")
790 .HasForeignKey(
"InstanceId")
791 .OnDelete(DeleteBehavior.Cascade)
794 b.HasOne(
"Tgstation.Server.Host.Models.PermissionSet",
"PermissionSet")
795 .WithMany(
"InstancePermissionSets")
796 .HasForeignKey(
"PermissionSetId")
797 .OnDelete(DeleteBehavior.Cascade)
801 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
803 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CancelledBy")
805 .HasForeignKey(
"CancelledById");
807 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
809 .HasForeignKey(
"InstanceId")
810 .OnDelete(DeleteBehavior.Cascade)
813 b.HasOne(
"Tgstation.Server.Host.Models.User",
"StartedBy")
815 .HasForeignKey(
"StartedById")
816 .OnDelete(DeleteBehavior.Cascade)
820 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
822 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
823 .WithMany(
"OAuthConnections")
824 .HasForeignKey(
"UserId")
825 .OnDelete(DeleteBehavior.Cascade);
828 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
830 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
831 .WithOne(
"PermissionSet")
832 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"GroupId")
833 .OnDelete(DeleteBehavior.Cascade);
835 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
836 .WithOne(
"PermissionSet")
837 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"UserId")
838 .OnDelete(DeleteBehavior.Cascade);
841 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
843 b.HasOne(
"Tgstation.Server.Host.Models.CompileJob",
"CompileJob")
845 .HasForeignKey(
"CompileJobId")
846 .OnDelete(DeleteBehavior.Cascade)
850 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
852 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
853 .WithOne(
"RepositorySettings")
854 .HasForeignKey(
"Tgstation.Server.Host.Models.RepositorySettings",
"InstanceId")
855 .OnDelete(DeleteBehavior.Cascade)
859 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
861 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
862 .WithMany(
"ActiveTestMerges")
863 .HasForeignKey(
"RevisionInformationId")
864 .OnDelete(DeleteBehavior.Cascade)
867 b.HasOne(
"Tgstation.Server.Host.Models.TestMerge",
"TestMerge")
868 .WithMany(
"RevisonInformations")
869 .HasForeignKey(
"TestMergeId")
870 .OnDelete(DeleteBehavior.ClientNoAction)
874 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
876 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
877 .WithMany(
"RevisionInformations")
878 .HasForeignKey(
"InstanceId")
879 .OnDelete(DeleteBehavior.Cascade)
883 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
885 b.HasOne(
"Tgstation.Server.Host.Models.User",
"MergedBy")
886 .WithMany(
"TestMerges")
887 .HasForeignKey(
"MergedById")
888 .OnDelete(DeleteBehavior.Restrict)
891 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"PrimaryRevisionInformation")
892 .WithOne(
"PrimaryTestMerge")
893 .HasForeignKey(
"Tgstation.Server.Host.Models.TestMerge",
"PrimaryRevisionInformationId")
894 .OnDelete(DeleteBehavior.Cascade)
898 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
900 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CreatedBy")
901 .WithMany(
"CreatedUsers")
902 .HasForeignKey(
"CreatedById");
904 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
906 .HasForeignKey(
"GroupId");
908#pragma warning restore 612, 618