JellyfinDbModelSnapshot.cs 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403
  1. // <auto-generated />
  2. using System;
  3. using Jellyfin.Server.Implementations;
  4. using Microsoft.EntityFrameworkCore;
  5. using Microsoft.EntityFrameworkCore.Infrastructure;
  6. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  7. namespace Jellyfin.Server.Implementations.Migrations
  8. {
  9. [DbContext(typeof(JellyfinDb))]
  10. partial class JellyfinDbModelSnapshot : ModelSnapshot
  11. {
  12. protected override void BuildModel(ModelBuilder modelBuilder)
  13. {
  14. #pragma warning disable 612, 618
  15. modelBuilder
  16. .HasDefaultSchema("jellyfin")
  17. .HasAnnotation("ProductVersion", "3.1.4");
  18. modelBuilder.Entity("Jellyfin.Data.Entities.AccessSchedule", b =>
  19. {
  20. b.Property<int>("Id")
  21. .ValueGeneratedOnAdd()
  22. .HasColumnType("INTEGER");
  23. b.Property<int>("DayOfWeek")
  24. .HasColumnType("INTEGER");
  25. b.Property<double>("EndHour")
  26. .HasColumnType("REAL");
  27. b.Property<double>("StartHour")
  28. .HasColumnType("REAL");
  29. b.Property<Guid>("UserId")
  30. .HasColumnType("TEXT");
  31. b.HasKey("Id");
  32. b.HasIndex("UserId");
  33. b.ToTable("AccessSchedule");
  34. });
  35. modelBuilder.Entity("Jellyfin.Data.Entities.ActivityLog", b =>
  36. {
  37. b.Property<int>("Id")
  38. .ValueGeneratedOnAdd()
  39. .HasColumnType("INTEGER");
  40. b.Property<DateTime>("DateCreated")
  41. .HasColumnType("TEXT");
  42. b.Property<string>("ItemId")
  43. .HasColumnType("TEXT")
  44. .HasMaxLength(256);
  45. b.Property<int>("LogSeverity")
  46. .HasColumnType("INTEGER");
  47. b.Property<string>("Name")
  48. .IsRequired()
  49. .HasColumnType("TEXT")
  50. .HasMaxLength(512);
  51. b.Property<string>("Overview")
  52. .HasColumnType("TEXT")
  53. .HasMaxLength(512);
  54. b.Property<uint>("RowVersion")
  55. .IsConcurrencyToken()
  56. .HasColumnType("INTEGER");
  57. b.Property<string>("ShortOverview")
  58. .HasColumnType("TEXT")
  59. .HasMaxLength(512);
  60. b.Property<string>("Type")
  61. .IsRequired()
  62. .HasColumnType("TEXT")
  63. .HasMaxLength(256);
  64. b.Property<Guid>("UserId")
  65. .HasColumnType("TEXT");
  66. b.HasKey("Id");
  67. b.ToTable("ActivityLogs");
  68. });
  69. modelBuilder.Entity("Jellyfin.Data.Entities.Group", b =>
  70. {
  71. b.Property<Guid>("Id")
  72. .ValueGeneratedOnAdd()
  73. .HasColumnType("TEXT");
  74. b.Property<Guid?>("Group_Groups_Guid")
  75. .HasColumnType("TEXT");
  76. b.Property<string>("Name")
  77. .IsRequired()
  78. .HasColumnType("TEXT")
  79. .HasMaxLength(255);
  80. b.Property<uint>("RowVersion")
  81. .IsConcurrencyToken()
  82. .HasColumnType("INTEGER");
  83. b.HasKey("Id");
  84. b.HasIndex("Group_Groups_Guid");
  85. b.ToTable("Groups");
  86. });
  87. modelBuilder.Entity("Jellyfin.Data.Entities.ImageInfo", b =>
  88. {
  89. b.Property<int>("Id")
  90. .ValueGeneratedOnAdd()
  91. .HasColumnType("INTEGER");
  92. b.Property<DateTime>("LastModified")
  93. .HasColumnType("TEXT");
  94. b.Property<string>("Path")
  95. .IsRequired()
  96. .HasColumnType("TEXT")
  97. .HasMaxLength(512);
  98. b.HasKey("Id");
  99. b.ToTable("ImageInfo");
  100. });
  101. modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>
  102. {
  103. b.Property<int>("Id")
  104. .ValueGeneratedOnAdd()
  105. .HasColumnType("INTEGER");
  106. b.Property<int>("Kind")
  107. .HasColumnType("INTEGER");
  108. b.Property<Guid?>("Permission_GroupPermissions_Id")
  109. .HasColumnType("TEXT");
  110. b.Property<Guid?>("Permission_Permissions_Guid")
  111. .HasColumnType("TEXT");
  112. b.Property<uint>("RowVersion")
  113. .IsConcurrencyToken()
  114. .HasColumnType("INTEGER");
  115. b.Property<bool>("Value")
  116. .HasColumnType("INTEGER");
  117. b.HasKey("Id");
  118. b.HasIndex("Permission_GroupPermissions_Id");
  119. b.HasIndex("Permission_Permissions_Guid");
  120. b.ToTable("Permissions");
  121. });
  122. modelBuilder.Entity("Jellyfin.Data.Entities.Preference", b =>
  123. {
  124. b.Property<int>("Id")
  125. .ValueGeneratedOnAdd()
  126. .HasColumnType("INTEGER");
  127. b.Property<int>("Kind")
  128. .HasColumnType("INTEGER");
  129. b.Property<Guid?>("Preference_Preferences_Guid")
  130. .HasColumnType("TEXT");
  131. b.Property<Guid?>("Preference_Preferences_Id")
  132. .HasColumnType("TEXT");
  133. b.Property<uint>("RowVersion")
  134. .IsConcurrencyToken()
  135. .HasColumnType("INTEGER");
  136. b.Property<string>("Value")
  137. .IsRequired()
  138. .HasColumnType("TEXT")
  139. .HasMaxLength(65535);
  140. b.HasKey("Id");
  141. b.HasIndex("Preference_Preferences_Guid");
  142. b.HasIndex("Preference_Preferences_Id");
  143. b.ToTable("Preferences");
  144. });
  145. modelBuilder.Entity("Jellyfin.Data.Entities.ProviderMapping", b =>
  146. {
  147. b.Property<int>("Id")
  148. .ValueGeneratedOnAdd()
  149. .HasColumnType("INTEGER");
  150. b.Property<string>("ProviderData")
  151. .IsRequired()
  152. .HasColumnType("TEXT")
  153. .HasMaxLength(65535);
  154. b.Property<Guid?>("ProviderMapping_ProviderMappings_Id")
  155. .HasColumnType("TEXT");
  156. b.Property<string>("ProviderName")
  157. .IsRequired()
  158. .HasColumnType("TEXT")
  159. .HasMaxLength(255);
  160. b.Property<string>("ProviderSecrets")
  161. .IsRequired()
  162. .HasColumnType("TEXT")
  163. .HasMaxLength(65535);
  164. b.Property<uint>("RowVersion")
  165. .IsConcurrencyToken()
  166. .HasColumnType("INTEGER");
  167. b.HasKey("Id");
  168. b.HasIndex("ProviderMapping_ProviderMappings_Id");
  169. b.ToTable("ProviderMapping");
  170. });
  171. modelBuilder.Entity("Jellyfin.Data.Entities.User", b =>
  172. {
  173. b.Property<Guid>("Id")
  174. .ValueGeneratedOnAdd()
  175. .HasColumnType("TEXT");
  176. b.Property<string>("AudioLanguagePreference")
  177. .HasColumnType("TEXT")
  178. .HasMaxLength(255);
  179. b.Property<string>("AuthenticationProviderId")
  180. .IsRequired()
  181. .HasColumnType("TEXT")
  182. .HasMaxLength(255);
  183. b.Property<bool>("DisplayCollectionsView")
  184. .HasColumnType("INTEGER");
  185. b.Property<bool>("DisplayMissingEpisodes")
  186. .HasColumnType("INTEGER");
  187. b.Property<string>("EasyPassword")
  188. .HasColumnType("TEXT")
  189. .HasMaxLength(65535);
  190. b.Property<bool>("EnableAutoLogin")
  191. .HasColumnType("INTEGER");
  192. b.Property<bool>("EnableLocalPassword")
  193. .HasColumnType("INTEGER");
  194. b.Property<bool>("EnableNextEpisodeAutoPlay")
  195. .HasColumnType("INTEGER");
  196. b.Property<bool>("EnableUserPreferenceAccess")
  197. .HasColumnType("INTEGER");
  198. b.Property<bool>("HidePlayedInLatest")
  199. .HasColumnType("INTEGER");
  200. b.Property<long>("InternalId")
  201. .HasColumnType("INTEGER");
  202. b.Property<int>("InvalidLoginAttemptCount")
  203. .HasColumnType("INTEGER");
  204. b.Property<DateTime>("LastActivityDate")
  205. .HasColumnType("TEXT");
  206. b.Property<DateTime>("LastLoginDate")
  207. .HasColumnType("TEXT");
  208. b.Property<int?>("LoginAttemptsBeforeLockout")
  209. .HasColumnType("INTEGER");
  210. b.Property<int?>("MaxParentalAgeRating")
  211. .HasColumnType("INTEGER");
  212. b.Property<bool>("MustUpdatePassword")
  213. .HasColumnType("INTEGER");
  214. b.Property<string>("Password")
  215. .HasColumnType("TEXT")
  216. .HasMaxLength(65535);
  217. b.Property<string>("PasswordResetProviderId")
  218. .IsRequired()
  219. .HasColumnType("TEXT")
  220. .HasMaxLength(255);
  221. b.Property<bool>("PlayDefaultAudioTrack")
  222. .HasColumnType("INTEGER");
  223. b.Property<int?>("ProfileImageId")
  224. .HasColumnType("INTEGER");
  225. b.Property<bool>("RememberAudioSelections")
  226. .HasColumnType("INTEGER");
  227. b.Property<bool>("RememberSubtitleSelections")
  228. .HasColumnType("INTEGER");
  229. b.Property<int?>("RemoteClientBitrateLimit")
  230. .HasColumnType("INTEGER");
  231. b.Property<uint>("RowVersion")
  232. .IsConcurrencyToken()
  233. .HasColumnType("INTEGER");
  234. b.Property<string>("SubtitleLanguagePreference")
  235. .HasColumnType("TEXT")
  236. .HasMaxLength(255);
  237. b.Property<int>("SubtitleMode")
  238. .HasColumnType("INTEGER");
  239. b.Property<int>("SyncPlayAccess")
  240. .HasColumnType("INTEGER");
  241. b.Property<string>("Username")
  242. .IsRequired()
  243. .HasColumnType("TEXT")
  244. .HasMaxLength(255);
  245. b.HasKey("Id");
  246. b.HasIndex("ProfileImageId");
  247. b.ToTable("Users");
  248. });
  249. modelBuilder.Entity("Jellyfin.Data.Entities.AccessSchedule", b =>
  250. {
  251. b.HasOne("Jellyfin.Data.Entities.User", null)
  252. .WithMany("AccessSchedules")
  253. .HasForeignKey("UserId")
  254. .OnDelete(DeleteBehavior.Cascade)
  255. .IsRequired();
  256. });
  257. modelBuilder.Entity("Jellyfin.Data.Entities.Group", b =>
  258. {
  259. b.HasOne("Jellyfin.Data.Entities.User", null)
  260. .WithMany("Groups")
  261. .HasForeignKey("Group_Groups_Guid");
  262. });
  263. modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>
  264. {
  265. b.HasOne("Jellyfin.Data.Entities.Group", null)
  266. .WithMany("Permissions")
  267. .HasForeignKey("Permission_GroupPermissions_Id");
  268. b.HasOne("Jellyfin.Data.Entities.User", null)
  269. .WithMany("Permissions")
  270. .HasForeignKey("Permission_Permissions_Guid");
  271. });
  272. modelBuilder.Entity("Jellyfin.Data.Entities.Preference", b =>
  273. {
  274. b.HasOne("Jellyfin.Data.Entities.User", null)
  275. .WithMany("Preferences")
  276. .HasForeignKey("Preference_Preferences_Guid");
  277. b.HasOne("Jellyfin.Data.Entities.Group", null)
  278. .WithMany("Preferences")
  279. .HasForeignKey("Preference_Preferences_Id");
  280. });
  281. modelBuilder.Entity("Jellyfin.Data.Entities.ProviderMapping", b =>
  282. {
  283. b.HasOne("Jellyfin.Data.Entities.Group", null)
  284. .WithMany("ProviderMappings")
  285. .HasForeignKey("ProviderMapping_ProviderMappings_Id");
  286. b.HasOne("Jellyfin.Data.Entities.User", null)
  287. .WithMany("ProviderMappings")
  288. .HasForeignKey("ProviderMapping_ProviderMappings_Id");
  289. });
  290. modelBuilder.Entity("Jellyfin.Data.Entities.User", b =>
  291. {
  292. b.HasOne("Jellyfin.Data.Entities.ImageInfo", "ProfileImage")
  293. .WithMany()
  294. .HasForeignKey("ProfileImageId");
  295. });
  296. #pragma warning restore 612, 618
  297. }
  298. }
  299. }