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");
541 b.HasIndex(
"InstanceId")
544 b.ToTable(
"RepositorySettings");
547 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
549 b.Property<
long>(
"Id")
550 .ValueGeneratedOnAdd()
551 .HasColumnType(
"bigint")
552 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
554 b.Property<
long>(
"RevisionInformationId")
555 .HasColumnType(
"bigint");
557 b.Property<
long>(
"TestMergeId")
558 .HasColumnType(
"bigint");
562 b.HasIndex(
"RevisionInformationId");
564 b.HasIndex(
"TestMergeId");
566 b.ToTable(
"RevInfoTestMerges");
569 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
571 b.Property<
long>(
"Id")
572 .ValueGeneratedOnAdd()
573 .HasColumnType(
"bigint")
574 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
576 b.Property<
string>(
"CommitSha")
578 .HasColumnType(
"character varying(40)")
581 b.Property<
long>(
"InstanceId")
582 .HasColumnType(
"bigint");
584 b.Property<
string>(
"OriginCommitSha")
586 .HasColumnType(
"character varying(40)")
589 b.Property<DateTimeOffset>(
"Timestamp")
590 .HasColumnType(
"timestamp with time zone");
594 b.HasIndex(
"InstanceId",
"CommitSha")
597 b.ToTable(
"RevisionInformations");
600 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
602 b.Property<
long>(
"Id")
603 .ValueGeneratedOnAdd()
604 .HasColumnType(
"bigint")
605 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
607 b.Property<
string>(
"Author")
609 .HasColumnType(
"text");
611 b.Property<
string>(
"BodyAtMerge")
613 .HasColumnType(
"text");
615 b.Property<
string>(
"Comment")
616 .HasColumnType(
"character varying(10000)")
617 .HasMaxLength(10000);
619 b.Property<DateTimeOffset>(
"MergedAt")
620 .HasColumnType(
"timestamp with time zone");
622 b.Property<
long>(
"MergedById")
623 .HasColumnType(
"bigint");
625 b.Property<
int>(
"Number")
626 .HasColumnType(
"integer");
628 b.Property<
long?>(
"PrimaryRevisionInformationId")
630 .HasColumnType(
"bigint");
632 b.Property<
string>(
"TargetCommitSha")
634 .HasColumnType(
"character varying(40)")
637 b.Property<
string>(
"TitleAtMerge")
639 .HasColumnType(
"text");
641 b.Property<
string>(
"Url")
643 .HasColumnType(
"text");
647 b.HasIndex(
"MergedById");
649 b.HasIndex(
"PrimaryRevisionInformationId")
652 b.ToTable(
"TestMerges");
655 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
657 b.Property<
long?>(
"Id")
658 .ValueGeneratedOnAdd()
659 .HasColumnType(
"bigint")
660 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
662 b.Property<
string>(
"CanonicalName")
664 .HasColumnType(
"character varying(100)")
667 b.Property<DateTimeOffset?>(
"CreatedAt")
669 .HasColumnType(
"timestamp with time zone");
671 b.Property<
long?>(
"CreatedById")
672 .HasColumnType(
"bigint");
674 b.Property<
bool?>(
"Enabled")
676 .HasColumnType(
"boolean");
678 b.Property<
long?>(
"GroupId")
679 .HasColumnType(
"bigint");
681 b.Property<DateTimeOffset?>(
"LastPasswordUpdate")
682 .HasColumnType(
"timestamp with time zone");
684 b.Property<
string>(
"Name")
686 .HasColumnType(
"character varying(100)")
689 b.Property<
string>(
"PasswordHash")
690 .HasColumnType(
"text");
692 b.Property<
string>(
"SystemIdentifier")
693 .HasColumnType(
"character varying(100)")
698 b.HasIndex(
"CanonicalName")
701 b.HasIndex(
"CreatedById");
703 b.HasIndex(
"GroupId");
705 b.HasIndex(
"SystemIdentifier")
711 modelBuilder.Entity(
"Tgstation.Server.Host.Models.UserGroup", b =>
713 b.Property<
long?>(
"Id")
714 .ValueGeneratedOnAdd()
715 .HasColumnType(
"bigint")
716 .HasAnnotation(
"Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
718 b.Property<
string>(
"Name")
720 .HasColumnType(
"character varying(100)")
731 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
733 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
734 .WithMany(
"ChatSettings")
735 .HasForeignKey(
"InstanceId")
736 .OnDelete(DeleteBehavior.Cascade)
740 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatChannel", b =>
742 b.HasOne(
"Tgstation.Server.Host.Models.ChatBot",
"ChatSettings")
743 .WithMany(
"Channels")
744 .HasForeignKey(
"ChatSettingsId")
745 .OnDelete(DeleteBehavior.Cascade)
749 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
751 b.HasOne(
"Tgstation.Server.Host.Models.Job",
"Job")
753 .HasForeignKey(
"Tgstation.Server.Host.Models.CompileJob",
"JobId")
754 .OnDelete(DeleteBehavior.Cascade)
757 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
758 .WithMany(
"CompileJobs")
759 .HasForeignKey(
"RevisionInformationId")
760 .OnDelete(DeleteBehavior.Cascade)
764 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
766 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
767 .WithOne(
"DreamDaemonSettings")
768 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamDaemonSettings",
"InstanceId")
769 .OnDelete(DeleteBehavior.Cascade)
773 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
775 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
776 .WithOne(
"DreamMakerSettings")
777 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamMakerSettings",
"InstanceId")
778 .OnDelete(DeleteBehavior.Cascade)
782 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
784 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
785 .WithMany(
"InstancePermissionSets")
786 .HasForeignKey(
"InstanceId")
787 .OnDelete(DeleteBehavior.Cascade)
790 b.HasOne(
"Tgstation.Server.Host.Models.PermissionSet",
"PermissionSet")
791 .WithMany(
"InstancePermissionSets")
792 .HasForeignKey(
"PermissionSetId")
793 .OnDelete(DeleteBehavior.Cascade)
797 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
799 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CancelledBy")
801 .HasForeignKey(
"CancelledById");
803 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
805 .HasForeignKey(
"InstanceId")
806 .OnDelete(DeleteBehavior.Cascade)
809 b.HasOne(
"Tgstation.Server.Host.Models.User",
"StartedBy")
811 .HasForeignKey(
"StartedById")
812 .OnDelete(DeleteBehavior.Cascade)
816 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
818 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
819 .WithMany(
"OAuthConnections")
820 .HasForeignKey(
"UserId")
821 .OnDelete(DeleteBehavior.Cascade);
824 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
826 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
827 .WithOne(
"PermissionSet")
828 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"GroupId")
829 .OnDelete(DeleteBehavior.Cascade);
831 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
832 .WithOne(
"PermissionSet")
833 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"UserId")
834 .OnDelete(DeleteBehavior.Cascade);
837 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
839 b.HasOne(
"Tgstation.Server.Host.Models.CompileJob",
"CompileJob")
841 .HasForeignKey(
"CompileJobId")
842 .OnDelete(DeleteBehavior.Cascade)
846 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
848 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
849 .WithOne(
"RepositorySettings")
850 .HasForeignKey(
"Tgstation.Server.Host.Models.RepositorySettings",
"InstanceId")
851 .OnDelete(DeleteBehavior.Cascade)
855 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
857 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
858 .WithMany(
"ActiveTestMerges")
859 .HasForeignKey(
"RevisionInformationId")
860 .OnDelete(DeleteBehavior.Cascade)
863 b.HasOne(
"Tgstation.Server.Host.Models.TestMerge",
"TestMerge")
864 .WithMany(
"RevisonInformations")
865 .HasForeignKey(
"TestMergeId")
866 .OnDelete(DeleteBehavior.ClientNoAction)
870 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
872 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
873 .WithMany(
"RevisionInformations")
874 .HasForeignKey(
"InstanceId")
875 .OnDelete(DeleteBehavior.Cascade)
879 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
881 b.HasOne(
"Tgstation.Server.Host.Models.User",
"MergedBy")
882 .WithMany(
"TestMerges")
883 .HasForeignKey(
"MergedById")
884 .OnDelete(DeleteBehavior.Restrict)
887 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"PrimaryRevisionInformation")
888 .WithOne(
"PrimaryTestMerge")
889 .HasForeignKey(
"Tgstation.Server.Host.Models.TestMerge",
"PrimaryRevisionInformationId")
890 .OnDelete(DeleteBehavior.Cascade)
894 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
896 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CreatedBy")
897 .WithMany(
"CreatedUsers")
898 .HasForeignKey(
"CreatedById");
900 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
902 .HasForeignKey(
"GroupId");
904#pragma warning restore 612, 618