20200929113112_Init.Designer.cs 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361
  1. // <auto-generated />
  2. using System;
  3. using Content.Server.Database;
  4. using Microsoft.EntityFrameworkCore;
  5. using Microsoft.EntityFrameworkCore.Infrastructure;
  6. using Microsoft.EntityFrameworkCore.Migrations;
  7. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  8. namespace Content.Server.Database.Migrations.Sqlite
  9. {
  10. [DbContext(typeof(SqliteServerDbContext))]
  11. [Migration("20200929113112_Init")]
  12. partial class Init
  13. {
  14. protected override void BuildTargetModel(ModelBuilder modelBuilder)
  15. {
  16. #pragma warning disable 612, 618
  17. modelBuilder
  18. .HasAnnotation("ProductVersion", "3.1.4");
  19. modelBuilder.Entity("Content.Server.Database.Antag", b =>
  20. {
  21. b.Property<int>("Id")
  22. .ValueGeneratedOnAdd()
  23. .HasColumnName("antag_id")
  24. .HasColumnType("INTEGER");
  25. b.Property<string>("AntagName")
  26. .IsRequired()
  27. .HasColumnName("antag_name")
  28. .HasColumnType("TEXT");
  29. b.Property<int>("ProfileId")
  30. .HasColumnName("profile_id")
  31. .HasColumnType("INTEGER");
  32. b.HasKey("Id");
  33. b.HasIndex("ProfileId", "AntagName")
  34. .IsUnique();
  35. b.ToTable("antag");
  36. });
  37. modelBuilder.Entity("Content.Server.Database.AssignedUserId", b =>
  38. {
  39. b.Property<int>("Id")
  40. .ValueGeneratedOnAdd()
  41. .HasColumnName("assigned_user_id_id")
  42. .HasColumnType("INTEGER");
  43. b.Property<Guid>("UserId")
  44. .HasColumnName("user_id")
  45. .HasColumnType("TEXT");
  46. b.Property<string>("UserName")
  47. .IsRequired()
  48. .HasColumnName("user_name")
  49. .HasColumnType("TEXT");
  50. b.HasKey("Id");
  51. b.HasIndex("UserId")
  52. .IsUnique();
  53. b.HasIndex("UserName")
  54. .IsUnique();
  55. b.ToTable("assigned_user_id");
  56. });
  57. modelBuilder.Entity("Content.Server.Database.Job", b =>
  58. {
  59. b.Property<int>("Id")
  60. .ValueGeneratedOnAdd()
  61. .HasColumnName("job_id")
  62. .HasColumnType("INTEGER");
  63. b.Property<string>("JobName")
  64. .IsRequired()
  65. .HasColumnName("job_name")
  66. .HasColumnType("TEXT");
  67. b.Property<int>("Priority")
  68. .HasColumnName("priority")
  69. .HasColumnType("INTEGER");
  70. b.Property<int>("ProfileId")
  71. .HasColumnName("profile_id")
  72. .HasColumnType("INTEGER");
  73. b.HasKey("Id");
  74. b.HasIndex("ProfileId");
  75. b.ToTable("job");
  76. });
  77. modelBuilder.Entity("Content.Server.Database.Preference", b =>
  78. {
  79. b.Property<int>("Id")
  80. .ValueGeneratedOnAdd()
  81. .HasColumnName("preference_id")
  82. .HasColumnType("INTEGER");
  83. b.Property<int>("SelectedCharacterSlot")
  84. .HasColumnName("selected_character_slot")
  85. .HasColumnType("INTEGER");
  86. b.Property<Guid>("UserId")
  87. .HasColumnName("user_id")
  88. .HasColumnType("TEXT");
  89. b.HasKey("Id");
  90. b.HasIndex("UserId")
  91. .IsUnique();
  92. b.ToTable("preference");
  93. });
  94. modelBuilder.Entity("Content.Server.Database.Profile", b =>
  95. {
  96. b.Property<int>("Id")
  97. .ValueGeneratedOnAdd()
  98. .HasColumnName("profile_id")
  99. .HasColumnType("INTEGER");
  100. b.Property<int>("Age")
  101. .HasColumnName("age")
  102. .HasColumnType("INTEGER");
  103. b.Property<string>("CharacterName")
  104. .IsRequired()
  105. .HasColumnName("char_name")
  106. .HasColumnType("TEXT");
  107. b.Property<string>("EyeColor")
  108. .IsRequired()
  109. .HasColumnName("eye_color")
  110. .HasColumnType("TEXT");
  111. b.Property<string>("FacialHairColor")
  112. .IsRequired()
  113. .HasColumnName("facial_hair_color")
  114. .HasColumnType("TEXT");
  115. b.Property<string>("FacialHairName")
  116. .IsRequired()
  117. .HasColumnName("facial_hair_name")
  118. .HasColumnType("TEXT");
  119. b.Property<string>("HairColor")
  120. .IsRequired()
  121. .HasColumnName("hair_color")
  122. .HasColumnType("TEXT");
  123. b.Property<string>("HairName")
  124. .IsRequired()
  125. .HasColumnName("hair_name")
  126. .HasColumnType("TEXT");
  127. b.Property<int>("PreferenceId")
  128. .HasColumnName("preference_id")
  129. .HasColumnType("INTEGER");
  130. b.Property<int>("PreferenceUnavailable")
  131. .HasColumnName("pref_unavailable")
  132. .HasColumnType("INTEGER");
  133. b.Property<string>("Sex")
  134. .IsRequired()
  135. .HasColumnName("sex")
  136. .HasColumnType("TEXT");
  137. b.Property<string>("SkinColor")
  138. .IsRequired()
  139. .HasColumnName("skin_color")
  140. .HasColumnType("TEXT");
  141. b.Property<int>("Slot")
  142. .HasColumnName("slot")
  143. .HasColumnType("INTEGER");
  144. b.HasKey("Id");
  145. b.HasIndex("PreferenceId");
  146. b.HasIndex("Slot", "PreferenceId")
  147. .IsUnique();
  148. b.ToTable("profile");
  149. });
  150. modelBuilder.Entity("Content.Server.Database.SqliteConnectionLog", b =>
  151. {
  152. b.Property<int>("Id")
  153. .ValueGeneratedOnAdd()
  154. .HasColumnName("connection_log_id")
  155. .HasColumnType("INTEGER");
  156. b.Property<string>("Address")
  157. .IsRequired()
  158. .HasColumnName("address")
  159. .HasColumnType("TEXT");
  160. b.Property<DateTime>("Time")
  161. .HasColumnName("time")
  162. .HasColumnType("TEXT");
  163. b.Property<Guid>("UserId")
  164. .HasColumnName("user_id")
  165. .HasColumnType("TEXT");
  166. b.Property<string>("UserName")
  167. .IsRequired()
  168. .HasColumnName("user_name")
  169. .HasColumnType("TEXT");
  170. b.HasKey("Id");
  171. b.ToTable("connection_log");
  172. });
  173. modelBuilder.Entity("Content.Server.Database.SqlitePlayer", b =>
  174. {
  175. b.Property<int>("Id")
  176. .ValueGeneratedOnAdd()
  177. .HasColumnName("player_id")
  178. .HasColumnType("INTEGER");
  179. b.Property<DateTime>("FirstSeenTime")
  180. .HasColumnName("first_seen_time")
  181. .HasColumnType("TEXT");
  182. b.Property<string>("LastSeenAddress")
  183. .IsRequired()
  184. .HasColumnName("last_seen_address")
  185. .HasColumnType("TEXT");
  186. b.Property<DateTime>("LastSeenTime")
  187. .HasColumnName("last_seen_time")
  188. .HasColumnType("TEXT");
  189. b.Property<string>("LastSeenUserName")
  190. .IsRequired()
  191. .HasColumnName("last_seen_user_name")
  192. .HasColumnType("TEXT");
  193. b.Property<Guid>("UserId")
  194. .HasColumnName("user_id")
  195. .HasColumnType("TEXT");
  196. b.HasKey("Id");
  197. b.ToTable("player");
  198. });
  199. modelBuilder.Entity("Content.Server.Database.SqliteServerBan", b =>
  200. {
  201. b.Property<int>("Id")
  202. .ValueGeneratedOnAdd()
  203. .HasColumnName("ban_id")
  204. .HasColumnType("INTEGER");
  205. b.Property<string>("Address")
  206. .HasColumnName("address")
  207. .HasColumnType("TEXT");
  208. b.Property<DateTime>("BanTime")
  209. .HasColumnName("ban_time")
  210. .HasColumnType("TEXT");
  211. b.Property<Guid?>("BanningAdmin")
  212. .HasColumnName("banning_admin")
  213. .HasColumnType("TEXT");
  214. b.Property<DateTime?>("ExpirationTime")
  215. .HasColumnName("expiration_time")
  216. .HasColumnType("TEXT");
  217. b.Property<string>("Reason")
  218. .IsRequired()
  219. .HasColumnName("reason")
  220. .HasColumnType("TEXT");
  221. b.Property<Guid?>("UserId")
  222. .HasColumnName("user_id")
  223. .HasColumnType("TEXT");
  224. b.HasKey("Id");
  225. b.ToTable("ban");
  226. });
  227. modelBuilder.Entity("Content.Server.Database.SqliteServerUnban", b =>
  228. {
  229. b.Property<int>("Id")
  230. .ValueGeneratedOnAdd()
  231. .HasColumnName("unban_id")
  232. .HasColumnType("INTEGER");
  233. b.Property<int>("BanId")
  234. .HasColumnName("ban_id")
  235. .HasColumnType("INTEGER");
  236. b.Property<DateTime>("UnbanTime")
  237. .HasColumnName("unban_time")
  238. .HasColumnType("TEXT");
  239. b.Property<Guid?>("UnbanningAdmin")
  240. .HasColumnName("unbanning_admin")
  241. .HasColumnType("TEXT");
  242. b.HasKey("Id");
  243. b.HasIndex("BanId")
  244. .IsUnique();
  245. b.ToTable("unban");
  246. });
  247. modelBuilder.Entity("Content.Server.Database.Antag", b =>
  248. {
  249. b.HasOne("Content.Server.Database.Profile", "Profile")
  250. .WithMany("Antags")
  251. .HasForeignKey("ProfileId")
  252. .OnDelete(DeleteBehavior.Cascade)
  253. .IsRequired();
  254. });
  255. modelBuilder.Entity("Content.Server.Database.Job", b =>
  256. {
  257. b.HasOne("Content.Server.Database.Profile", "Profile")
  258. .WithMany("Jobs")
  259. .HasForeignKey("ProfileId")
  260. .OnDelete(DeleteBehavior.Cascade)
  261. .IsRequired();
  262. });
  263. modelBuilder.Entity("Content.Server.Database.Profile", b =>
  264. {
  265. b.HasOne("Content.Server.Database.Preference", "Preference")
  266. .WithMany("Profiles")
  267. .HasForeignKey("PreferenceId")
  268. .OnDelete(DeleteBehavior.Cascade)
  269. .IsRequired();
  270. });
  271. modelBuilder.Entity("Content.Server.Database.SqliteServerUnban", b =>
  272. {
  273. b.HasOne("Content.Server.Database.SqliteServerBan", "Ban")
  274. .WithOne("Unban")
  275. .HasForeignKey("Content.Server.Database.SqliteServerUnban", "BanId")
  276. .OnDelete(DeleteBehavior.Cascade)
  277. .IsRequired();
  278. });
  279. #pragma warning restore 612, 618
  280. }
  281. }
  282. }