JellyfinDbModelSnapshot.cs 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399
  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.3");
  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. b.HasKey("Id");
  98. b.ToTable("ImageInfo");
  99. });
  100. modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>
  101. {
  102. b.Property<int>("Id")
  103. .ValueGeneratedOnAdd()
  104. .HasColumnType("INTEGER");
  105. b.Property<int>("Kind")
  106. .HasColumnType("INTEGER");
  107. b.Property<Guid?>("Permission_GroupPermissions_Id")
  108. .HasColumnType("TEXT");
  109. b.Property<Guid?>("Permission_Permissions_Guid")
  110. .HasColumnType("TEXT");
  111. b.Property<uint>("RowVersion")
  112. .IsConcurrencyToken()
  113. .HasColumnType("INTEGER");
  114. b.Property<bool>("Value")
  115. .HasColumnType("INTEGER");
  116. b.HasKey("Id");
  117. b.HasIndex("Permission_GroupPermissions_Id");
  118. b.HasIndex("Permission_Permissions_Guid");
  119. b.ToTable("Permissions");
  120. });
  121. modelBuilder.Entity("Jellyfin.Data.Entities.Preference", b =>
  122. {
  123. b.Property<int>("Id")
  124. .ValueGeneratedOnAdd()
  125. .HasColumnType("INTEGER");
  126. b.Property<int>("Kind")
  127. .HasColumnType("INTEGER");
  128. b.Property<Guid?>("Preference_Preferences_Guid")
  129. .HasColumnType("TEXT");
  130. b.Property<Guid?>("Preference_Preferences_Id")
  131. .HasColumnType("TEXT");
  132. b.Property<uint>("RowVersion")
  133. .IsConcurrencyToken()
  134. .HasColumnType("INTEGER");
  135. b.Property<string>("Value")
  136. .IsRequired()
  137. .HasColumnType("TEXT")
  138. .HasMaxLength(65535);
  139. b.HasKey("Id");
  140. b.HasIndex("Preference_Preferences_Guid");
  141. b.HasIndex("Preference_Preferences_Id");
  142. b.ToTable("Preferences");
  143. });
  144. modelBuilder.Entity("Jellyfin.Data.Entities.ProviderMapping", b =>
  145. {
  146. b.Property<int>("Id")
  147. .ValueGeneratedOnAdd()
  148. .HasColumnType("INTEGER");
  149. b.Property<string>("ProviderData")
  150. .IsRequired()
  151. .HasColumnType("TEXT")
  152. .HasMaxLength(65535);
  153. b.Property<Guid?>("ProviderMapping_ProviderMappings_Id")
  154. .HasColumnType("TEXT");
  155. b.Property<string>("ProviderName")
  156. .IsRequired()
  157. .HasColumnType("TEXT")
  158. .HasMaxLength(255);
  159. b.Property<string>("ProviderSecrets")
  160. .IsRequired()
  161. .HasColumnType("TEXT")
  162. .HasMaxLength(65535);
  163. b.Property<uint>("RowVersion")
  164. .IsConcurrencyToken()
  165. .HasColumnType("INTEGER");
  166. b.HasKey("Id");
  167. b.HasIndex("ProviderMapping_ProviderMappings_Id");
  168. b.ToTable("ProviderMapping");
  169. });
  170. modelBuilder.Entity("Jellyfin.Data.Entities.User", b =>
  171. {
  172. b.Property<Guid>("Id")
  173. .ValueGeneratedOnAdd()
  174. .HasColumnType("TEXT");
  175. b.Property<string>("AudioLanguagePreference")
  176. .HasColumnType("TEXT")
  177. .HasMaxLength(255);
  178. b.Property<string>("AuthenticationProviderId")
  179. .IsRequired()
  180. .HasColumnType("TEXT")
  181. .HasMaxLength(255);
  182. b.Property<bool>("DisplayCollectionsView")
  183. .HasColumnType("INTEGER");
  184. b.Property<bool>("DisplayMissingEpisodes")
  185. .HasColumnType("INTEGER");
  186. b.Property<string>("EasyPassword")
  187. .HasColumnType("TEXT")
  188. .HasMaxLength(65535);
  189. b.Property<bool>("EnableAutoLogin")
  190. .HasColumnType("INTEGER");
  191. b.Property<bool>("EnableLocalPassword")
  192. .HasColumnType("INTEGER");
  193. b.Property<bool>("EnableNextEpisodeAutoPlay")
  194. .HasColumnType("INTEGER");
  195. b.Property<bool>("EnableUserPreferenceAccess")
  196. .HasColumnType("INTEGER");
  197. b.Property<bool>("HidePlayedInLatest")
  198. .HasColumnType("INTEGER");
  199. b.Property<long>("InternalId")
  200. .HasColumnType("INTEGER");
  201. b.Property<int>("InvalidLoginAttemptCount")
  202. .HasColumnType("INTEGER");
  203. b.Property<DateTime>("LastActivityDate")
  204. .HasColumnType("TEXT");
  205. b.Property<DateTime>("LastLoginDate")
  206. .HasColumnType("TEXT");
  207. b.Property<int?>("LoginAttemptsBeforeLockout")
  208. .HasColumnType("INTEGER");
  209. b.Property<int?>("MaxParentalAgeRating")
  210. .HasColumnType("INTEGER");
  211. b.Property<bool>("MustUpdatePassword")
  212. .HasColumnType("INTEGER");
  213. b.Property<string>("Password")
  214. .HasColumnType("TEXT")
  215. .HasMaxLength(65535);
  216. b.Property<string>("PasswordResetProviderId")
  217. .IsRequired()
  218. .HasColumnType("TEXT")
  219. .HasMaxLength(255);
  220. b.Property<bool>("PlayDefaultAudioTrack")
  221. .HasColumnType("INTEGER");
  222. b.Property<int?>("ProfileImageId")
  223. .HasColumnType("INTEGER");
  224. b.Property<bool>("RememberAudioSelections")
  225. .HasColumnType("INTEGER");
  226. b.Property<bool>("RememberSubtitleSelections")
  227. .HasColumnType("INTEGER");
  228. b.Property<int?>("RemoteClientBitrateLimit")
  229. .HasColumnType("INTEGER");
  230. b.Property<uint>("RowVersion")
  231. .IsConcurrencyToken()
  232. .HasColumnType("INTEGER");
  233. b.Property<string>("SubtitleLanguagePreference")
  234. .HasColumnType("TEXT")
  235. .HasMaxLength(255);
  236. b.Property<int>("SubtitleMode")
  237. .HasColumnType("INTEGER");
  238. b.Property<string>("Username")
  239. .IsRequired()
  240. .HasColumnType("TEXT")
  241. .HasMaxLength(255);
  242. b.HasKey("Id");
  243. b.HasIndex("ProfileImageId");
  244. b.ToTable("Users");
  245. });
  246. modelBuilder.Entity("Jellyfin.Data.Entities.AccessSchedule", b =>
  247. {
  248. b.HasOne("Jellyfin.Data.Entities.User", null)
  249. .WithMany("AccessSchedules")
  250. .HasForeignKey("UserId")
  251. .OnDelete(DeleteBehavior.Cascade)
  252. .IsRequired();
  253. });
  254. modelBuilder.Entity("Jellyfin.Data.Entities.Group", b =>
  255. {
  256. b.HasOne("Jellyfin.Data.Entities.User", null)
  257. .WithMany("Groups")
  258. .HasForeignKey("Group_Groups_Guid");
  259. });
  260. modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>
  261. {
  262. b.HasOne("Jellyfin.Data.Entities.Group", null)
  263. .WithMany("Permissions")
  264. .HasForeignKey("Permission_GroupPermissions_Id");
  265. b.HasOne("Jellyfin.Data.Entities.User", null)
  266. .WithMany("Permissions")
  267. .HasForeignKey("Permission_Permissions_Guid");
  268. });
  269. modelBuilder.Entity("Jellyfin.Data.Entities.Preference", b =>
  270. {
  271. b.HasOne("Jellyfin.Data.Entities.User", null)
  272. .WithMany("Preferences")
  273. .HasForeignKey("Preference_Preferences_Guid");
  274. b.HasOne("Jellyfin.Data.Entities.Group", null)
  275. .WithMany("Preferences")
  276. .HasForeignKey("Preference_Preferences_Id");
  277. });
  278. modelBuilder.Entity("Jellyfin.Data.Entities.ProviderMapping", b =>
  279. {
  280. b.HasOne("Jellyfin.Data.Entities.Group", null)
  281. .WithMany("ProviderMappings")
  282. .HasForeignKey("ProviderMapping_ProviderMappings_Id");
  283. b.HasOne("Jellyfin.Data.Entities.User", null)
  284. .WithMany("ProviderMappings")
  285. .HasForeignKey("ProviderMapping_ProviderMappings_Id");
  286. });
  287. modelBuilder.Entity("Jellyfin.Data.Entities.User", b =>
  288. {
  289. b.HasOne("Jellyfin.Data.Entities.ImageInfo", "ProfileImage")
  290. .WithMany()
  291. .HasForeignKey("ProfileImageId");
  292. });
  293. #pragma warning restore 612, 618
  294. }
  295. }
  296. }