17#pragma warning disable 612, 618
19 .HasAnnotation(
"ProductVersion",
"6.0.15")
20 .HasAnnotation(
"Relational:MaxIdentifierLength", 63);
22 NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
24 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
26 b.Property<
long?>(
"Id")
27 .ValueGeneratedOnAdd()
28 .HasColumnType(
"bigint");
30 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
32 b.Property<
int>(
"ChannelLimit")
33 .HasColumnType(
"integer");
35 b.Property<
string>(
"ConnectionString")
38 .HasColumnType(
"character varying(10000)");
40 b.Property<
bool?>(
"Enabled")
41 .HasColumnType(
"boolean");
43 b.Property<
long>(
"InstanceId")
44 .HasColumnType(
"bigint");
46 b.Property<
string>(
"Name")
49 .HasColumnType(
"character varying(100)");
51 b.Property<
int>(
"Provider")
52 .HasColumnType(
"integer");
54 b.Property<
long>(
"ReconnectionInterval")
55 .HasColumnType(
"bigint");
59 b.HasIndex(
"InstanceId",
"Name")
62 b.ToTable(
"ChatBots");
65 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatChannel", b =>
67 b.Property<
long>(
"Id")
68 .ValueGeneratedOnAdd()
69 .HasColumnType(
"bigint");
71 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
73 b.Property<
long>(
"ChatSettingsId")
74 .HasColumnType(
"bigint");
76 b.Property<decimal?>(
"DiscordChannelId")
77 .HasColumnType(
"numeric(20,0)");
79 b.Property<
string>(
"IrcChannel")
81 .HasColumnType(
"character varying(100)");
83 b.Property<
bool?>(
"IsAdminChannel")
85 .HasColumnType(
"boolean");
87 b.Property<
bool?>(
"IsUpdatesChannel")
89 .HasColumnType(
"boolean");
91 b.Property<
bool?>(
"IsWatchdogChannel")
93 .HasColumnType(
"boolean");
95 b.Property<
string>(
"Tag")
97 .HasColumnType(
"character varying(10000)");
101 b.HasIndex(
"ChatSettingsId",
"DiscordChannelId")
104 b.HasIndex(
"ChatSettingsId",
"IrcChannel")
107 b.ToTable(
"ChatChannels");
110 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
112 b.Property<
long?>(
"Id")
113 .ValueGeneratedOnAdd()
114 .HasColumnType(
"bigint");
116 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
118 b.Property<
string>(
"ByondVersion")
120 .HasColumnType(
"text");
122 b.Property<
int?>(
"DMApiMajorVersion")
123 .HasColumnType(
"integer");
125 b.Property<
int?>(
"DMApiMinorVersion")
126 .HasColumnType(
"integer");
128 b.Property<
int?>(
"DMApiPatchVersion")
129 .HasColumnType(
"integer");
131 b.Property<Guid?>(
"DirectoryName")
133 .HasColumnType(
"uuid");
135 b.Property<
string>(
"DmeName")
137 .HasColumnType(
"text");
139 b.Property<
int?>(
"GitHubDeploymentId")
140 .HasColumnType(
"integer");
142 b.Property<
long?>(
"GitHubRepoId")
143 .HasColumnType(
"bigint");
145 b.Property<
long>(
"JobId")
146 .HasColumnType(
"bigint");
148 b.Property<
int?>(
"MinimumSecurityLevel")
149 .HasColumnType(
"integer");
151 b.Property<
string>(
"Output")
153 .HasColumnType(
"text");
155 b.Property<
string>(
"RepositoryOrigin")
156 .HasColumnType(
"text");
158 b.Property<
long>(
"RevisionInformationId")
159 .HasColumnType(
"bigint");
163 b.HasIndex(
"DirectoryName");
168 b.HasIndex(
"RevisionInformationId");
170 b.ToTable(
"CompileJobs");
173 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
175 b.Property<
long>(
"Id")
176 .ValueGeneratedOnAdd()
177 .HasColumnType(
"bigint");
179 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
181 b.Property<
string>(
"AdditionalParameters")
184 .HasColumnType(
"character varying(10000)");
186 b.Property<
bool?>(
"AllowWebClient")
188 .HasColumnType(
"boolean");
190 b.Property<
bool?>(
"AutoStart")
192 .HasColumnType(
"boolean");
194 b.Property<
bool?>(
"DumpOnHeartbeatRestart")
196 .HasColumnType(
"boolean");
198 b.Property<
long>(
"HeartbeatSeconds")
199 .HasColumnType(
"bigint");
201 b.Property<
long>(
"InstanceId")
202 .HasColumnType(
"bigint");
204 b.Property<
bool?>(
"LogOutput")
206 .HasColumnType(
"boolean");
208 b.Property<
int>(
"Port")
209 .HasColumnType(
"integer");
211 b.Property<
int>(
"SecurityLevel")
212 .HasColumnType(
"integer");
214 b.Property<
bool?>(
"StartProfiler")
216 .HasColumnType(
"boolean");
218 b.Property<
long>(
"StartupTimeout")
219 .HasColumnType(
"bigint");
221 b.Property<
long>(
"TopicRequestTimeout")
222 .HasColumnType(
"bigint");
224 b.Property<
int>(
"Visibility")
225 .HasColumnType(
"integer");
229 b.HasIndex(
"InstanceId")
232 b.ToTable(
"DreamDaemonSettings");
235 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
237 b.Property<
long>(
"Id")
238 .ValueGeneratedOnAdd()
239 .HasColumnType(
"bigint");
241 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
243 b.Property<
int>(
"ApiValidationPort")
244 .HasColumnType(
"integer");
246 b.Property<
int>(
"ApiValidationSecurityLevel")
247 .HasColumnType(
"integer");
249 b.Property<
long>(
"InstanceId")
250 .HasColumnType(
"bigint");
252 b.Property<
string>(
"ProjectName")
254 .HasColumnType(
"character varying(10000)");
256 b.Property<
bool?>(
"RequireDMApiValidation")
258 .HasColumnType(
"boolean");
260 b.Property<TimeSpan?>(
"Timeout")
262 .HasColumnType(
"interval");
266 b.HasIndex(
"InstanceId")
269 b.ToTable(
"DreamMakerSettings");
272 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Instance", b =>
274 b.Property<
long?>(
"Id")
275 .ValueGeneratedOnAdd()
276 .HasColumnType(
"bigint");
278 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
280 b.Property<
long>(
"AutoUpdateInterval")
281 .HasColumnType(
"bigint");
283 b.Property<
int>(
"ChatBotLimit")
284 .HasColumnType(
"integer");
286 b.Property<
int>(
"ConfigurationType")
287 .HasColumnType(
"integer");
289 b.Property<
string>(
"Name")
292 .HasColumnType(
"character varying(100)");
294 b.Property<
bool?>(
"Online")
296 .HasColumnType(
"boolean");
298 b.Property<
string>(
"Path")
300 .HasColumnType(
"text");
302 b.Property<
string>(
"SwarmIdentifer")
303 .HasColumnType(
"text");
307 b.HasIndex(
"Path",
"SwarmIdentifer")
310 b.ToTable(
"Instances");
313 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
315 b.Property<
long>(
"Id")
316 .ValueGeneratedOnAdd()
317 .HasColumnType(
"bigint");
319 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
321 b.Property<decimal>(
"ByondRights")
322 .HasColumnType(
"numeric(20,0)");
324 b.Property<decimal>(
"ChatBotRights")
325 .HasColumnType(
"numeric(20,0)");
327 b.Property<decimal>(
"ConfigurationRights")
328 .HasColumnType(
"numeric(20,0)");
330 b.Property<decimal>(
"DreamDaemonRights")
331 .HasColumnType(
"numeric(20,0)");
333 b.Property<decimal>(
"DreamMakerRights")
334 .HasColumnType(
"numeric(20,0)");
336 b.Property<
long>(
"InstanceId")
337 .HasColumnType(
"bigint");
339 b.Property<decimal>(
"InstancePermissionSetRights")
340 .HasColumnType(
"numeric(20,0)");
342 b.Property<
long>(
"PermissionSetId")
343 .HasColumnType(
"bigint");
345 b.Property<decimal>(
"RepositoryRights")
346 .HasColumnType(
"numeric(20,0)");
350 b.HasIndex(
"InstanceId");
352 b.HasIndex(
"PermissionSetId",
"InstanceId")
355 b.ToTable(
"InstancePermissionSets");
358 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
360 b.Property<
long?>(
"Id")
361 .ValueGeneratedOnAdd()
362 .HasColumnType(
"bigint");
364 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
366 b.Property<decimal?>(
"CancelRight")
367 .HasColumnType(
"numeric(20,0)");
369 b.Property<decimal?>(
"CancelRightsType")
370 .HasColumnType(
"numeric(20,0)");
372 b.Property<
bool?>(
"Cancelled")
374 .HasColumnType(
"boolean");
376 b.Property<
long?>(
"CancelledById")
377 .HasColumnType(
"bigint");
379 b.Property<
string>(
"Description")
381 .HasColumnType(
"text");
383 b.Property<
long?>(
"ErrorCode")
384 .HasColumnType(
"bigint");
386 b.Property<
string>(
"ExceptionDetails")
387 .HasColumnType(
"text");
389 b.Property<
long>(
"InstanceId")
390 .HasColumnType(
"bigint");
392 b.Property<DateTimeOffset?>(
"StartedAt")
394 .HasColumnType(
"timestamp with time zone");
396 b.Property<
long>(
"StartedById")
397 .HasColumnType(
"bigint");
399 b.Property<DateTimeOffset?>(
"StoppedAt")
400 .HasColumnType(
"timestamp with time zone");
404 b.HasIndex(
"CancelledById");
406 b.HasIndex(
"InstanceId");
408 b.HasIndex(
"StartedById");
413 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
415 b.Property<
long>(
"Id")
416 .ValueGeneratedOnAdd()
417 .HasColumnType(
"bigint");
419 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
421 b.Property<
string>(
"ExternalUserId")
424 .HasColumnType(
"character varying(100)");
426 b.Property<
int>(
"Provider")
427 .HasColumnType(
"integer");
429 b.Property<
long?>(
"UserId")
430 .HasColumnType(
"bigint");
434 b.HasIndex(
"UserId");
436 b.HasIndex(
"Provider",
"ExternalUserId")
439 b.ToTable(
"OAuthConnections");
442 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
444 b.Property<
long?>(
"Id")
445 .ValueGeneratedOnAdd()
446 .HasColumnType(
"bigint");
448 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
450 b.Property<decimal>(
"AdministrationRights")
451 .HasColumnType(
"numeric(20,0)");
453 b.Property<
long?>(
"GroupId")
454 .HasColumnType(
"bigint");
456 b.Property<decimal>(
"InstanceManagerRights")
457 .HasColumnType(
"numeric(20,0)");
459 b.Property<
long?>(
"UserId")
460 .HasColumnType(
"bigint");
464 b.HasIndex(
"GroupId")
470 b.ToTable(
"PermissionSets");
473 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
475 b.Property<
long>(
"Id")
476 .ValueGeneratedOnAdd()
477 .HasColumnType(
"bigint");
479 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
481 b.Property<
string>(
"AccessIdentifier")
483 .HasColumnType(
"text");
485 b.Property<
long>(
"CompileJobId")
486 .HasColumnType(
"bigint");
488 b.Property<
long?>(
"InitialCompileJobId")
489 .HasColumnType(
"bigint");
491 b.Property<
int>(
"LaunchSecurityLevel")
492 .HasColumnType(
"integer");
494 b.Property<
int>(
"LaunchVisibility")
495 .HasColumnType(
"integer");
497 b.Property<
int>(
"Port")
498 .HasColumnType(
"integer");
500 b.Property<
int>(
"ProcessId")
501 .HasColumnType(
"integer");
503 b.Property<
int>(
"RebootState")
504 .HasColumnType(
"integer");
508 b.HasIndex(
"CompileJobId");
510 b.HasIndex(
"InitialCompileJobId");
512 b.ToTable(
"ReattachInformations");
515 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
517 b.Property<
long>(
"Id")
518 .ValueGeneratedOnAdd()
519 .HasColumnType(
"bigint");
521 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
523 b.Property<
string>(
"AccessToken")
525 .HasColumnType(
"character varying(10000)");
527 b.Property<
string>(
"AccessUser")
529 .HasColumnType(
"character varying(10000)");
531 b.Property<
bool?>(
"AutoUpdatesKeepTestMerges")
533 .HasColumnType(
"boolean");
535 b.Property<
bool?>(
"AutoUpdatesSynchronize")
537 .HasColumnType(
"boolean");
539 b.Property<
string>(
"CommitterEmail")
542 .HasColumnType(
"character varying(10000)");
544 b.Property<
string>(
"CommitterName")
547 .HasColumnType(
"character varying(10000)");
549 b.Property<
bool?>(
"CreateGitHubDeployments")
551 .HasColumnType(
"boolean");
553 b.Property<
long>(
"InstanceId")
554 .HasColumnType(
"bigint");
556 b.Property<
bool?>(
"PostTestMergeComment")
558 .HasColumnType(
"boolean");
560 b.Property<
bool?>(
"PushTestMergeCommits")
562 .HasColumnType(
"boolean");
564 b.Property<
bool?>(
"ShowTestMergeCommitters")
566 .HasColumnType(
"boolean");
568 b.Property<
bool?>(
"UpdateSubmodules")
570 .HasColumnType(
"boolean");
574 b.HasIndex(
"InstanceId")
577 b.ToTable(
"RepositorySettings");
580 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
582 b.Property<
long>(
"Id")
583 .ValueGeneratedOnAdd()
584 .HasColumnType(
"bigint");
586 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
588 b.Property<
long>(
"RevisionInformationId")
589 .HasColumnType(
"bigint");
591 b.Property<
long>(
"TestMergeId")
592 .HasColumnType(
"bigint");
596 b.HasIndex(
"RevisionInformationId");
598 b.HasIndex(
"TestMergeId");
600 b.ToTable(
"RevInfoTestMerges");
603 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
605 b.Property<
long>(
"Id")
606 .ValueGeneratedOnAdd()
607 .HasColumnType(
"bigint");
609 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
611 b.Property<
string>(
"CommitSha")
614 .HasColumnType(
"character varying(40)");
616 b.Property<
long>(
"InstanceId")
617 .HasColumnType(
"bigint");
619 b.Property<
string>(
"OriginCommitSha")
622 .HasColumnType(
"character varying(40)");
624 b.Property<DateTimeOffset>(
"Timestamp")
625 .HasColumnType(
"timestamp with time zone");
629 b.HasIndex(
"InstanceId",
"CommitSha")
632 b.ToTable(
"RevisionInformations");
635 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
637 b.Property<
long>(
"Id")
638 .ValueGeneratedOnAdd()
639 .HasColumnType(
"bigint");
641 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
643 b.Property<
string>(
"Author")
645 .HasColumnType(
"text");
647 b.Property<
string>(
"BodyAtMerge")
649 .HasColumnType(
"text");
651 b.Property<
string>(
"Comment")
653 .HasColumnType(
"character varying(10000)");
655 b.Property<DateTimeOffset>(
"MergedAt")
656 .HasColumnType(
"timestamp with time zone");
658 b.Property<
long>(
"MergedById")
659 .HasColumnType(
"bigint");
661 b.Property<
int>(
"Number")
662 .HasColumnType(
"integer");
664 b.Property<
long?>(
"PrimaryRevisionInformationId")
666 .HasColumnType(
"bigint");
668 b.Property<
string>(
"TargetCommitSha")
671 .HasColumnType(
"character varying(40)");
673 b.Property<
string>(
"TitleAtMerge")
675 .HasColumnType(
"text");
677 b.Property<
string>(
"Url")
679 .HasColumnType(
"text");
683 b.HasIndex(
"MergedById");
685 b.HasIndex(
"PrimaryRevisionInformationId")
688 b.ToTable(
"TestMerges");
691 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
693 b.Property<
long?>(
"Id")
694 .ValueGeneratedOnAdd()
695 .HasColumnType(
"bigint");
697 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
699 b.Property<
string>(
"CanonicalName")
702 .HasColumnType(
"character varying(100)");
704 b.Property<DateTimeOffset?>(
"CreatedAt")
706 .HasColumnType(
"timestamp with time zone");
708 b.Property<
long?>(
"CreatedById")
709 .HasColumnType(
"bigint");
711 b.Property<
bool?>(
"Enabled")
713 .HasColumnType(
"boolean");
715 b.Property<
long?>(
"GroupId")
716 .HasColumnType(
"bigint");
718 b.Property<DateTimeOffset?>(
"LastPasswordUpdate")
719 .HasColumnType(
"timestamp with time zone");
721 b.Property<
string>(
"Name")
724 .HasColumnType(
"character varying(100)");
726 b.Property<
string>(
"PasswordHash")
727 .HasColumnType(
"text");
729 b.Property<
string>(
"SystemIdentifier")
731 .HasColumnType(
"character varying(100)");
735 b.HasIndex(
"CanonicalName")
738 b.HasIndex(
"CreatedById");
740 b.HasIndex(
"GroupId");
742 b.HasIndex(
"SystemIdentifier")
748 modelBuilder.Entity(
"Tgstation.Server.Host.Models.UserGroup", b =>
750 b.Property<
long?>(
"Id")
751 .ValueGeneratedOnAdd()
752 .HasColumnType(
"bigint");
754 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
756 b.Property<
string>(
"Name")
759 .HasColumnType(
"character varying(100)");
769 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
771 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
772 .WithMany(
"ChatSettings")
773 .HasForeignKey(
"InstanceId")
774 .OnDelete(DeleteBehavior.Cascade)
777 b.Navigation(
"Instance");
780 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatChannel", b =>
782 b.HasOne(
"Tgstation.Server.Host.Models.ChatBot",
"ChatSettings")
783 .WithMany(
"Channels")
784 .HasForeignKey(
"ChatSettingsId")
785 .OnDelete(DeleteBehavior.Cascade)
788 b.Navigation(
"ChatSettings");
791 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
793 b.HasOne(
"Tgstation.Server.Host.Models.Job",
"Job")
795 .HasForeignKey(
"Tgstation.Server.Host.Models.CompileJob",
"JobId")
796 .OnDelete(DeleteBehavior.Cascade)
799 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
800 .WithMany(
"CompileJobs")
801 .HasForeignKey(
"RevisionInformationId")
802 .OnDelete(DeleteBehavior.Cascade)
807 b.Navigation(
"RevisionInformation");
810 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
812 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
813 .WithOne(
"DreamDaemonSettings")
814 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamDaemonSettings",
"InstanceId")
815 .OnDelete(DeleteBehavior.Cascade)
818 b.Navigation(
"Instance");
821 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
823 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
824 .WithOne(
"DreamMakerSettings")
825 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamMakerSettings",
"InstanceId")
826 .OnDelete(DeleteBehavior.Cascade)
829 b.Navigation(
"Instance");
832 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
834 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
835 .WithMany(
"InstancePermissionSets")
836 .HasForeignKey(
"InstanceId")
837 .OnDelete(DeleteBehavior.Cascade)
840 b.HasOne(
"Tgstation.Server.Host.Models.PermissionSet",
"PermissionSet")
841 .WithMany(
"InstancePermissionSets")
842 .HasForeignKey(
"PermissionSetId")
843 .OnDelete(DeleteBehavior.Cascade)
846 b.Navigation(
"Instance");
848 b.Navigation(
"PermissionSet");
851 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
853 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CancelledBy")
855 .HasForeignKey(
"CancelledById");
857 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
859 .HasForeignKey(
"InstanceId")
860 .OnDelete(DeleteBehavior.Cascade)
863 b.HasOne(
"Tgstation.Server.Host.Models.User",
"StartedBy")
865 .HasForeignKey(
"StartedById")
866 .OnDelete(DeleteBehavior.Cascade)
869 b.Navigation(
"CancelledBy");
871 b.Navigation(
"Instance");
873 b.Navigation(
"StartedBy");
876 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
878 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
879 .WithMany(
"OAuthConnections")
880 .HasForeignKey(
"UserId")
881 .OnDelete(DeleteBehavior.Cascade);
883 b.Navigation(
"User");
886 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
888 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
889 .WithOne(
"PermissionSet")
890 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"GroupId")
891 .OnDelete(DeleteBehavior.Cascade);
893 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
894 .WithOne(
"PermissionSet")
895 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"UserId")
896 .OnDelete(DeleteBehavior.Cascade);
898 b.Navigation(
"Group");
900 b.Navigation(
"User");
903 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
905 b.HasOne(
"Tgstation.Server.Host.Models.CompileJob",
"CompileJob")
907 .HasForeignKey(
"CompileJobId")
908 .OnDelete(DeleteBehavior.Cascade)
911 b.HasOne(
"Tgstation.Server.Host.Models.CompileJob",
"InitialCompileJob")
913 .HasForeignKey(
"InitialCompileJobId");
915 b.Navigation(
"CompileJob");
917 b.Navigation(
"InitialCompileJob");
920 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
922 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
923 .WithOne(
"RepositorySettings")
924 .HasForeignKey(
"Tgstation.Server.Host.Models.RepositorySettings",
"InstanceId")
925 .OnDelete(DeleteBehavior.Cascade)
928 b.Navigation(
"Instance");
931 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
933 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
934 .WithMany(
"ActiveTestMerges")
935 .HasForeignKey(
"RevisionInformationId")
936 .OnDelete(DeleteBehavior.Cascade)
939 b.HasOne(
"Tgstation.Server.Host.Models.TestMerge",
"TestMerge")
940 .WithMany(
"RevisonInformations")
941 .HasForeignKey(
"TestMergeId")
942 .OnDelete(DeleteBehavior.ClientNoAction)
945 b.Navigation(
"RevisionInformation");
947 b.Navigation(
"TestMerge");
950 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
952 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
953 .WithMany(
"RevisionInformations")
954 .HasForeignKey(
"InstanceId")
955 .OnDelete(DeleteBehavior.Cascade)
958 b.Navigation(
"Instance");
961 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
963 b.HasOne(
"Tgstation.Server.Host.Models.User",
"MergedBy")
964 .WithMany(
"TestMerges")
965 .HasForeignKey(
"MergedById")
966 .OnDelete(DeleteBehavior.Restrict)
969 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"PrimaryRevisionInformation")
970 .WithOne(
"PrimaryTestMerge")
971 .HasForeignKey(
"Tgstation.Server.Host.Models.TestMerge",
"PrimaryRevisionInformationId")
972 .OnDelete(DeleteBehavior.Cascade)
975 b.Navigation(
"MergedBy");
977 b.Navigation(
"PrimaryRevisionInformation");
980 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
982 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CreatedBy")
983 .WithMany(
"CreatedUsers")
984 .HasForeignKey(
"CreatedById");
986 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
988 .HasForeignKey(
"GroupId");
990 b.Navigation(
"CreatedBy");
992 b.Navigation(
"Group");
995 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
997 b.Navigation(
"Channels");
1000 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Instance", b =>
1002 b.Navigation(
"ChatSettings");
1004 b.Navigation(
"DreamDaemonSettings");
1006 b.Navigation(
"DreamMakerSettings");
1008 b.Navigation(
"InstancePermissionSets");
1010 b.Navigation(
"Jobs");
1012 b.Navigation(
"RepositorySettings");
1014 b.Navigation(
"RevisionInformations");
1017 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
1019 b.Navigation(
"InstancePermissionSets");
1022 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
1024 b.Navigation(
"ActiveTestMerges");
1026 b.Navigation(
"CompileJobs");
1028 b.Navigation(
"PrimaryTestMerge");
1031 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
1033 b.Navigation(
"RevisonInformations");
1036 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
1038 b.Navigation(
"CreatedUsers");
1040 b.Navigation(
"OAuthConnections");
1042 b.Navigation(
"PermissionSet");
1044 b.Navigation(
"TestMerges");
1047 modelBuilder.Entity(
"Tgstation.Server.Host.Models.UserGroup", b =>
1049 b.Navigation(
"PermissionSet")
1052 b.Navigation(
"Users");
1054#pragma warning restore 612, 618