17#pragma warning disable 612, 618
19 .HasAnnotation(
"ProductVersion",
"8.0.6")
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?>(
"IsSystemChannel")
89 .HasColumnType(
"boolean");
91 b.Property<
bool?>(
"IsUpdatesChannel")
93 .HasColumnType(
"boolean");
95 b.Property<
bool?>(
"IsWatchdogChannel")
97 .HasColumnType(
"boolean");
99 b.Property<
string>(
"Tag")
101 .HasColumnType(
"character varying(10000)");
105 b.HasIndex(
"ChatSettingsId",
"DiscordChannelId")
108 b.HasIndex(
"ChatSettingsId",
"IrcChannel")
111 b.ToTable(
"ChatChannels");
114 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
116 b.Property<
long?>(
"Id")
117 .ValueGeneratedOnAdd()
118 .HasColumnType(
"bigint");
120 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
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<
string>(
"EngineVersion")
141 .HasColumnType(
"text");
143 b.Property<
long?>(
"GitHubDeploymentId")
144 .HasColumnType(
"bigint");
146 b.Property<
long?>(
"GitHubRepoId")
147 .HasColumnType(
"bigint");
149 b.Property<
long>(
"JobId")
150 .HasColumnType(
"bigint");
152 b.Property<
int?>(
"MinimumSecurityLevel")
153 .HasColumnType(
"integer");
155 b.Property<
string>(
"Output")
157 .HasColumnType(
"text");
159 b.Property<
string>(
"RepositoryOrigin")
160 .HasColumnType(
"text");
162 b.Property<
long>(
"RevisionInformationId")
163 .HasColumnType(
"bigint");
167 b.HasIndex(
"DirectoryName");
172 b.HasIndex(
"RevisionInformationId");
174 b.ToTable(
"CompileJobs");
177 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
179 b.Property<
long>(
"Id")
180 .ValueGeneratedOnAdd()
181 .HasColumnType(
"bigint");
183 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
185 b.Property<
string>(
"AdditionalParameters")
188 .HasColumnType(
"character varying(10000)");
190 b.Property<
bool?>(
"AllowWebClient")
192 .HasColumnType(
"boolean");
194 b.Property<
bool?>(
"AutoStart")
196 .HasColumnType(
"boolean");
198 b.Property<
bool?>(
"DumpOnHealthCheckRestart")
200 .HasColumnType(
"boolean");
202 b.Property<
long>(
"HealthCheckSeconds")
203 .HasColumnType(
"bigint");
205 b.Property<
long>(
"InstanceId")
206 .HasColumnType(
"bigint");
208 b.Property<
bool?>(
"LogOutput")
210 .HasColumnType(
"boolean");
212 b.Property<
long>(
"MapThreads")
213 .HasColumnType(
"bigint");
215 b.Property<
bool?>(
"Minidumps")
217 .HasColumnType(
"boolean");
219 b.Property<
int>(
"Port")
220 .HasColumnType(
"integer");
222 b.Property<
int>(
"SecurityLevel")
223 .HasColumnType(
"integer");
225 b.Property<
bool?>(
"StartProfiler")
227 .HasColumnType(
"boolean");
229 b.Property<
long>(
"StartupTimeout")
230 .HasColumnType(
"bigint");
232 b.Property<
long>(
"TopicRequestTimeout")
233 .HasColumnType(
"bigint");
235 b.Property<
int>(
"Visibility")
236 .HasColumnType(
"integer");
240 b.HasIndex(
"InstanceId")
243 b.ToTable(
"DreamDaemonSettings");
246 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
248 b.Property<
long>(
"Id")
249 .ValueGeneratedOnAdd()
250 .HasColumnType(
"bigint");
252 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
254 b.Property<
int>(
"ApiValidationPort")
255 .HasColumnType(
"integer");
257 b.Property<
int>(
"ApiValidationSecurityLevel")
258 .HasColumnType(
"integer");
260 b.Property<
string>(
"CompilerAdditionalArguments")
262 .HasColumnType(
"character varying(10000)");
264 b.Property<
long>(
"InstanceId")
265 .HasColumnType(
"bigint");
267 b.Property<
string>(
"ProjectName")
269 .HasColumnType(
"character varying(10000)");
271 b.Property<
bool?>(
"RequireDMApiValidation")
273 .HasColumnType(
"boolean");
275 b.Property<TimeSpan?>(
"Timeout")
277 .HasColumnType(
"interval");
281 b.HasIndex(
"InstanceId")
284 b.ToTable(
"DreamMakerSettings");
287 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Instance", b =>
289 b.Property<
long?>(
"Id")
290 .ValueGeneratedOnAdd()
291 .HasColumnType(
"bigint");
293 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
295 b.Property<
string>(
"AutoUpdateCron")
298 .HasColumnType(
"character varying(10000)");
300 b.Property<
long>(
"AutoUpdateInterval")
301 .HasColumnType(
"bigint");
303 b.Property<
int>(
"ChatBotLimit")
304 .HasColumnType(
"integer");
306 b.Property<
int>(
"ConfigurationType")
307 .HasColumnType(
"integer");
309 b.Property<
string>(
"Name")
312 .HasColumnType(
"character varying(100)");
314 b.Property<
bool?>(
"Online")
316 .HasColumnType(
"boolean");
318 b.Property<
string>(
"Path")
320 .HasColumnType(
"text");
322 b.Property<
string>(
"SwarmIdentifer")
323 .HasColumnType(
"text");
327 b.HasIndex(
"Path",
"SwarmIdentifer")
330 b.ToTable(
"Instances");
333 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
335 b.Property<
long>(
"Id")
336 .ValueGeneratedOnAdd()
337 .HasColumnType(
"bigint");
339 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
341 b.Property<decimal>(
"ChatBotRights")
342 .HasColumnType(
"numeric(20,0)");
344 b.Property<decimal>(
"ConfigurationRights")
345 .HasColumnType(
"numeric(20,0)");
347 b.Property<decimal>(
"DreamDaemonRights")
348 .HasColumnType(
"numeric(20,0)");
350 b.Property<decimal>(
"DreamMakerRights")
351 .HasColumnType(
"numeric(20,0)");
353 b.Property<decimal>(
"EngineRights")
354 .HasColumnType(
"numeric(20,0)");
356 b.Property<
long>(
"InstanceId")
357 .HasColumnType(
"bigint");
359 b.Property<decimal>(
"InstancePermissionSetRights")
360 .HasColumnType(
"numeric(20,0)");
362 b.Property<
long>(
"PermissionSetId")
363 .HasColumnType(
"bigint");
365 b.Property<decimal>(
"RepositoryRights")
366 .HasColumnType(
"numeric(20,0)");
370 b.HasIndex(
"InstanceId");
372 b.HasIndex(
"PermissionSetId",
"InstanceId")
375 b.ToTable(
"InstancePermissionSets");
378 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
380 b.Property<
long?>(
"Id")
381 .ValueGeneratedOnAdd()
382 .HasColumnType(
"bigint");
384 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
386 b.Property<decimal?>(
"CancelRight")
387 .HasColumnType(
"numeric(20,0)");
389 b.Property<decimal?>(
"CancelRightsType")
390 .HasColumnType(
"numeric(20,0)");
392 b.Property<
bool?>(
"Cancelled")
394 .HasColumnType(
"boolean");
396 b.Property<
long?>(
"CancelledById")
397 .HasColumnType(
"bigint");
399 b.Property<
string>(
"Description")
401 .HasColumnType(
"text");
403 b.Property<
long?>(
"ErrorCode")
404 .HasColumnType(
"bigint");
406 b.Property<
string>(
"ExceptionDetails")
407 .HasColumnType(
"text");
409 b.Property<
long>(
"InstanceId")
410 .HasColumnType(
"bigint");
412 b.Property<
byte>(
"JobCode")
413 .HasColumnType(
"smallint");
415 b.Property<DateTimeOffset?>(
"StartedAt")
417 .HasColumnType(
"timestamp with time zone");
419 b.Property<
long>(
"StartedById")
420 .HasColumnType(
"bigint");
422 b.Property<DateTimeOffset?>(
"StoppedAt")
423 .HasColumnType(
"timestamp with time zone");
427 b.HasIndex(
"CancelledById");
429 b.HasIndex(
"InstanceId");
431 b.HasIndex(
"StartedById");
436 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
438 b.Property<
long>(
"Id")
439 .ValueGeneratedOnAdd()
440 .HasColumnType(
"bigint");
442 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
444 b.Property<
string>(
"ExternalUserId")
447 .HasColumnType(
"character varying(100)");
449 b.Property<
int>(
"Provider")
450 .HasColumnType(
"integer");
452 b.Property<
long?>(
"UserId")
453 .HasColumnType(
"bigint");
457 b.HasIndex(
"UserId");
459 b.HasIndex(
"Provider",
"ExternalUserId")
462 b.ToTable(
"OAuthConnections");
465 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
467 b.Property<
long?>(
"Id")
468 .ValueGeneratedOnAdd()
469 .HasColumnType(
"bigint");
471 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
473 b.Property<decimal>(
"AdministrationRights")
474 .HasColumnType(
"numeric(20,0)");
476 b.Property<
long?>(
"GroupId")
477 .HasColumnType(
"bigint");
479 b.Property<decimal>(
"InstanceManagerRights")
480 .HasColumnType(
"numeric(20,0)");
482 b.Property<
long?>(
"UserId")
483 .HasColumnType(
"bigint");
487 b.HasIndex(
"GroupId")
493 b.ToTable(
"PermissionSets");
496 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
498 b.Property<
long?>(
"Id")
499 .ValueGeneratedOnAdd()
500 .HasColumnType(
"bigint");
502 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
504 b.Property<
string>(
"AccessIdentifier")
506 .HasColumnType(
"text");
508 b.Property<
long>(
"CompileJobId")
509 .HasColumnType(
"bigint");
511 b.Property<
long?>(
"InitialCompileJobId")
512 .HasColumnType(
"bigint");
514 b.Property<
int>(
"LaunchSecurityLevel")
515 .HasColumnType(
"integer");
517 b.Property<
int>(
"LaunchVisibility")
518 .HasColumnType(
"integer");
520 b.Property<
int>(
"Port")
521 .HasColumnType(
"integer");
523 b.Property<
int>(
"ProcessId")
524 .HasColumnType(
"integer");
526 b.Property<
int>(
"RebootState")
527 .HasColumnType(
"integer");
529 b.Property<
int?>(
"TopicPort")
530 .HasColumnType(
"integer");
534 b.HasIndex(
"CompileJobId");
536 b.HasIndex(
"InitialCompileJobId");
538 b.ToTable(
"ReattachInformations");
541 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
543 b.Property<
long>(
"Id")
544 .ValueGeneratedOnAdd()
545 .HasColumnType(
"bigint");
547 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
549 b.Property<
string>(
"AccessToken")
551 .HasColumnType(
"character varying(10000)");
553 b.Property<
string>(
"AccessUser")
555 .HasColumnType(
"character varying(10000)");
557 b.Property<
bool?>(
"AutoUpdatesKeepTestMerges")
559 .HasColumnType(
"boolean");
561 b.Property<
bool?>(
"AutoUpdatesSynchronize")
563 .HasColumnType(
"boolean");
565 b.Property<
string>(
"CommitterEmail")
568 .HasColumnType(
"character varying(10000)");
570 b.Property<
string>(
"CommitterName")
573 .HasColumnType(
"character varying(10000)");
575 b.Property<
bool?>(
"CreateGitHubDeployments")
577 .HasColumnType(
"boolean");
579 b.Property<
long>(
"InstanceId")
580 .HasColumnType(
"bigint");
582 b.Property<
bool?>(
"PostTestMergeComment")
584 .HasColumnType(
"boolean");
586 b.Property<
bool?>(
"PushTestMergeCommits")
588 .HasColumnType(
"boolean");
590 b.Property<
bool?>(
"ShowTestMergeCommitters")
592 .HasColumnType(
"boolean");
594 b.Property<
bool?>(
"UpdateSubmodules")
596 .HasColumnType(
"boolean");
600 b.HasIndex(
"InstanceId")
603 b.ToTable(
"RepositorySettings");
606 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
608 b.Property<
long>(
"Id")
609 .ValueGeneratedOnAdd()
610 .HasColumnType(
"bigint");
612 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
614 b.Property<
long>(
"RevisionInformationId")
615 .HasColumnType(
"bigint");
617 b.Property<
long>(
"TestMergeId")
618 .HasColumnType(
"bigint");
622 b.HasIndex(
"RevisionInformationId");
624 b.HasIndex(
"TestMergeId");
626 b.ToTable(
"RevInfoTestMerges");
629 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
631 b.Property<
long>(
"Id")
632 .ValueGeneratedOnAdd()
633 .HasColumnType(
"bigint");
635 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
637 b.Property<
string>(
"CommitSha")
640 .HasColumnType(
"character varying(40)");
642 b.Property<
long>(
"InstanceId")
643 .HasColumnType(
"bigint");
645 b.Property<
string>(
"OriginCommitSha")
648 .HasColumnType(
"character varying(40)");
650 b.Property<DateTimeOffset>(
"Timestamp")
651 .HasColumnType(
"timestamp with time zone");
655 b.HasIndex(
"InstanceId",
"CommitSha")
658 b.ToTable(
"RevisionInformations");
661 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
663 b.Property<
long>(
"Id")
664 .ValueGeneratedOnAdd()
665 .HasColumnType(
"bigint");
667 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long>(
"Id"));
669 b.Property<
string>(
"Author")
671 .HasColumnType(
"text");
673 b.Property<
string>(
"BodyAtMerge")
675 .HasColumnType(
"text");
677 b.Property<
string>(
"Comment")
679 .HasColumnType(
"character varying(10000)");
681 b.Property<DateTimeOffset>(
"MergedAt")
682 .HasColumnType(
"timestamp with time zone");
684 b.Property<
long>(
"MergedById")
685 .HasColumnType(
"bigint");
687 b.Property<
int>(
"Number")
688 .HasColumnType(
"integer");
690 b.Property<
long?>(
"PrimaryRevisionInformationId")
692 .HasColumnType(
"bigint");
694 b.Property<
string>(
"TargetCommitSha")
697 .HasColumnType(
"character varying(40)");
699 b.Property<
string>(
"TitleAtMerge")
701 .HasColumnType(
"text");
703 b.Property<
string>(
"Url")
705 .HasColumnType(
"text");
709 b.HasIndex(
"MergedById");
711 b.HasIndex(
"PrimaryRevisionInformationId")
714 b.ToTable(
"TestMerges");
717 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
719 b.Property<
long?>(
"Id")
720 .ValueGeneratedOnAdd()
721 .HasColumnType(
"bigint");
723 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
725 b.Property<
string>(
"CanonicalName")
728 .HasColumnType(
"character varying(100)");
730 b.Property<DateTimeOffset?>(
"CreatedAt")
732 .HasColumnType(
"timestamp with time zone");
734 b.Property<
long?>(
"CreatedById")
735 .HasColumnType(
"bigint");
737 b.Property<
bool?>(
"Enabled")
739 .HasColumnType(
"boolean");
741 b.Property<
long?>(
"GroupId")
742 .HasColumnType(
"bigint");
744 b.Property<DateTimeOffset?>(
"LastPasswordUpdate")
745 .HasColumnType(
"timestamp with time zone");
747 b.Property<
string>(
"Name")
750 .HasColumnType(
"character varying(100)");
752 b.Property<
string>(
"PasswordHash")
753 .HasColumnType(
"text");
755 b.Property<
string>(
"SystemIdentifier")
757 .HasColumnType(
"character varying(100)");
761 b.HasIndex(
"CanonicalName")
764 b.HasIndex(
"CreatedById");
766 b.HasIndex(
"GroupId");
768 b.HasIndex(
"SystemIdentifier")
774 modelBuilder.Entity(
"Tgstation.Server.Host.Models.UserGroup", b =>
776 b.Property<
long?>(
"Id")
777 .ValueGeneratedOnAdd()
778 .HasColumnType(
"bigint");
780 NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<
long?>(
"Id"));
782 b.Property<
string>(
"Name")
785 .HasColumnType(
"character varying(100)");
795 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
797 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
798 .WithMany(
"ChatSettings")
799 .HasForeignKey(
"InstanceId")
800 .OnDelete(DeleteBehavior.Cascade)
803 b.Navigation(
"Instance");
806 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatChannel", b =>
808 b.HasOne(
"Tgstation.Server.Host.Models.ChatBot",
"ChatSettings")
809 .WithMany(
"Channels")
810 .HasForeignKey(
"ChatSettingsId")
811 .OnDelete(DeleteBehavior.Cascade)
814 b.Navigation(
"ChatSettings");
817 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
819 b.HasOne(
"Tgstation.Server.Host.Models.Job",
"Job")
821 .HasForeignKey(
"Tgstation.Server.Host.Models.CompileJob",
"JobId")
822 .OnDelete(DeleteBehavior.Cascade)
825 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
826 .WithMany(
"CompileJobs")
827 .HasForeignKey(
"RevisionInformationId")
828 .OnDelete(DeleteBehavior.Cascade)
833 b.Navigation(
"RevisionInformation");
836 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
838 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
839 .WithOne(
"DreamDaemonSettings")
840 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamDaemonSettings",
"InstanceId")
841 .OnDelete(DeleteBehavior.Cascade)
844 b.Navigation(
"Instance");
847 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
849 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
850 .WithOne(
"DreamMakerSettings")
851 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamMakerSettings",
"InstanceId")
852 .OnDelete(DeleteBehavior.Cascade)
855 b.Navigation(
"Instance");
858 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
860 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
861 .WithMany(
"InstancePermissionSets")
862 .HasForeignKey(
"InstanceId")
863 .OnDelete(DeleteBehavior.Cascade)
866 b.HasOne(
"Tgstation.Server.Host.Models.PermissionSet",
"PermissionSet")
867 .WithMany(
"InstancePermissionSets")
868 .HasForeignKey(
"PermissionSetId")
869 .OnDelete(DeleteBehavior.Cascade)
872 b.Navigation(
"Instance");
874 b.Navigation(
"PermissionSet");
877 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
879 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CancelledBy")
881 .HasForeignKey(
"CancelledById");
883 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
885 .HasForeignKey(
"InstanceId")
886 .OnDelete(DeleteBehavior.Cascade)
889 b.HasOne(
"Tgstation.Server.Host.Models.User",
"StartedBy")
891 .HasForeignKey(
"StartedById")
892 .OnDelete(DeleteBehavior.Cascade)
895 b.Navigation(
"CancelledBy");
897 b.Navigation(
"Instance");
899 b.Navigation(
"StartedBy");
902 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
904 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
905 .WithMany(
"OAuthConnections")
906 .HasForeignKey(
"UserId")
907 .OnDelete(DeleteBehavior.Cascade);
909 b.Navigation(
"User");
912 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
914 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
915 .WithOne(
"PermissionSet")
916 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"GroupId")
917 .OnDelete(DeleteBehavior.Cascade);
919 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
920 .WithOne(
"PermissionSet")
921 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"UserId")
922 .OnDelete(DeleteBehavior.Cascade);
924 b.Navigation(
"Group");
926 b.Navigation(
"User");
929 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
931 b.HasOne(
"Tgstation.Server.Host.Models.CompileJob",
"CompileJob")
933 .HasForeignKey(
"CompileJobId")
934 .OnDelete(DeleteBehavior.Cascade)
937 b.HasOne(
"Tgstation.Server.Host.Models.CompileJob",
"InitialCompileJob")
939 .HasForeignKey(
"InitialCompileJobId");
941 b.Navigation(
"CompileJob");
943 b.Navigation(
"InitialCompileJob");
946 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
948 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
949 .WithOne(
"RepositorySettings")
950 .HasForeignKey(
"Tgstation.Server.Host.Models.RepositorySettings",
"InstanceId")
951 .OnDelete(DeleteBehavior.Cascade)
954 b.Navigation(
"Instance");
957 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
959 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
960 .WithMany(
"ActiveTestMerges")
961 .HasForeignKey(
"RevisionInformationId")
962 .OnDelete(DeleteBehavior.Cascade)
965 b.HasOne(
"Tgstation.Server.Host.Models.TestMerge",
"TestMerge")
966 .WithMany(
"RevisonInformations")
967 .HasForeignKey(
"TestMergeId")
968 .OnDelete(DeleteBehavior.ClientNoAction)
971 b.Navigation(
"RevisionInformation");
973 b.Navigation(
"TestMerge");
976 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
978 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
979 .WithMany(
"RevisionInformations")
980 .HasForeignKey(
"InstanceId")
981 .OnDelete(DeleteBehavior.Cascade)
984 b.Navigation(
"Instance");
987 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
989 b.HasOne(
"Tgstation.Server.Host.Models.User",
"MergedBy")
990 .WithMany(
"TestMerges")
991 .HasForeignKey(
"MergedById")
992 .OnDelete(DeleteBehavior.Restrict)
995 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"PrimaryRevisionInformation")
996 .WithOne(
"PrimaryTestMerge")
997 .HasForeignKey(
"Tgstation.Server.Host.Models.TestMerge",
"PrimaryRevisionInformationId")
998 .OnDelete(DeleteBehavior.Cascade)
1001 b.Navigation(
"MergedBy");
1003 b.Navigation(
"PrimaryRevisionInformation");
1006 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
1008 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CreatedBy")
1009 .WithMany(
"CreatedUsers")
1010 .HasForeignKey(
"CreatedById");
1012 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
1014 .HasForeignKey(
"GroupId");
1016 b.Navigation(
"CreatedBy");
1018 b.Navigation(
"Group");
1021 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
1023 b.Navigation(
"Channels");
1026 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Instance", b =>
1028 b.Navigation(
"ChatSettings");
1030 b.Navigation(
"DreamDaemonSettings");
1032 b.Navigation(
"DreamMakerSettings");
1034 b.Navigation(
"InstancePermissionSets");
1036 b.Navigation(
"Jobs");
1038 b.Navigation(
"RepositorySettings");
1040 b.Navigation(
"RevisionInformations");
1043 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
1045 b.Navigation(
"InstancePermissionSets");
1048 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
1050 b.Navigation(
"ActiveTestMerges");
1052 b.Navigation(
"CompileJobs");
1054 b.Navigation(
"PrimaryTestMerge");
1057 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
1059 b.Navigation(
"RevisonInformations");
1062 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
1064 b.Navigation(
"CreatedUsers");
1066 b.Navigation(
"OAuthConnections");
1068 b.Navigation(
"PermissionSet");
1070 b.Navigation(
"TestMerges");
1073 modelBuilder.Entity(
"Tgstation.Server.Host.Models.UserGroup", b =>
1075 b.Navigation(
"PermissionSet")
1078 b.Navigation(
"Users");
1080#pragma warning restore 612, 618