20241010160703_LibraryDbMigration.Designer.cs 53 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582
  1. // <auto-generated />
  2. using System;
  3. using Jellyfin.Server.Implementations;
  4. using Microsoft.EntityFrameworkCore;
  5. using Microsoft.EntityFrameworkCore.Infrastructure;
  6. using Microsoft.EntityFrameworkCore.Migrations;
  7. using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
  8. #nullable disable
  9. namespace Jellyfin.Server.Implementations.Migrations
  10. {
  11. [DbContext(typeof(JellyfinDbContext))]
  12. [Migration("20241010160703_LibraryDbMigration")]
  13. partial class LibraryDbMigration
  14. {
  15. /// <inheritdoc />
  16. protected override void BuildTargetModel(ModelBuilder modelBuilder)
  17. {
  18. #pragma warning disable 612, 618
  19. modelBuilder.HasAnnotation("ProductVersion", "8.0.10");
  20. modelBuilder.Entity("Jellyfin.Data.Entities.AccessSchedule", b =>
  21. {
  22. b.Property<int>("Id")
  23. .ValueGeneratedOnAdd()
  24. .HasColumnType("INTEGER");
  25. b.Property<int>("DayOfWeek")
  26. .HasColumnType("INTEGER");
  27. b.Property<double>("EndHour")
  28. .HasColumnType("REAL");
  29. b.Property<double>("StartHour")
  30. .HasColumnType("REAL");
  31. b.Property<Guid>("UserId")
  32. .HasColumnType("TEXT");
  33. b.HasKey("Id");
  34. b.HasIndex("UserId");
  35. b.ToTable("AccessSchedules");
  36. });
  37. modelBuilder.Entity("Jellyfin.Data.Entities.ActivityLog", b =>
  38. {
  39. b.Property<int>("Id")
  40. .ValueGeneratedOnAdd()
  41. .HasColumnType("INTEGER");
  42. b.Property<DateTime>("DateCreated")
  43. .HasColumnType("TEXT");
  44. b.Property<string>("ItemId")
  45. .HasMaxLength(256)
  46. .HasColumnType("TEXT");
  47. b.Property<int>("LogSeverity")
  48. .HasColumnType("INTEGER");
  49. b.Property<string>("Name")
  50. .IsRequired()
  51. .HasMaxLength(512)
  52. .HasColumnType("TEXT");
  53. b.Property<string>("Overview")
  54. .HasMaxLength(512)
  55. .HasColumnType("TEXT");
  56. b.Property<uint>("RowVersion")
  57. .IsConcurrencyToken()
  58. .HasColumnType("INTEGER");
  59. b.Property<string>("ShortOverview")
  60. .HasMaxLength(512)
  61. .HasColumnType("TEXT");
  62. b.Property<string>("Type")
  63. .IsRequired()
  64. .HasMaxLength(256)
  65. .HasColumnType("TEXT");
  66. b.Property<Guid>("UserId")
  67. .HasColumnType("TEXT");
  68. b.HasKey("Id");
  69. b.HasIndex("DateCreated");
  70. b.ToTable("ActivityLogs");
  71. });
  72. modelBuilder.Entity("Jellyfin.Data.Entities.AncestorId", b =>
  73. {
  74. b.Property<Guid>("ItemId")
  75. .HasColumnType("TEXT");
  76. b.Property<Guid>("ParentItemId")
  77. .HasColumnType("TEXT");
  78. b.Property<Guid?>("BaseItemEntityId")
  79. .HasColumnType("TEXT");
  80. b.HasKey("ItemId", "ParentItemId");
  81. b.HasIndex("BaseItemEntityId");
  82. b.HasIndex("ParentItemId");
  83. b.ToTable("AncestorIds");
  84. });
  85. modelBuilder.Entity("Jellyfin.Data.Entities.AttachmentStreamInfo", b =>
  86. {
  87. b.Property<Guid>("ItemId")
  88. .HasColumnType("TEXT");
  89. b.Property<int>("Index")
  90. .HasColumnType("INTEGER");
  91. b.Property<string>("Codec")
  92. .IsRequired()
  93. .HasColumnType("TEXT");
  94. b.Property<string>("CodecTag")
  95. .HasColumnType("TEXT");
  96. b.Property<string>("Comment")
  97. .HasColumnType("TEXT");
  98. b.Property<string>("Filename")
  99. .HasColumnType("TEXT");
  100. b.Property<string>("MimeType")
  101. .HasColumnType("TEXT");
  102. b.HasKey("ItemId", "Index");
  103. b.ToTable("AttachmentStreamInfos");
  104. });
  105. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemEntity", b =>
  106. {
  107. b.Property<Guid>("Id")
  108. .ValueGeneratedOnAdd()
  109. .HasColumnType("TEXT");
  110. b.Property<string>("Album")
  111. .HasColumnType("TEXT");
  112. b.Property<string>("AlbumArtists")
  113. .HasColumnType("TEXT");
  114. b.Property<string>("Artists")
  115. .HasColumnType("TEXT");
  116. b.Property<int?>("Audio")
  117. .HasColumnType("INTEGER");
  118. b.Property<string>("ChannelId")
  119. .HasColumnType("TEXT");
  120. b.Property<string>("CleanName")
  121. .HasColumnType("TEXT");
  122. b.Property<float?>("CommunityRating")
  123. .HasColumnType("REAL");
  124. b.Property<float?>("CriticRating")
  125. .HasColumnType("REAL");
  126. b.Property<string>("CustomRating")
  127. .HasColumnType("TEXT");
  128. b.Property<string>("Data")
  129. .HasColumnType("TEXT");
  130. b.Property<DateTime?>("DateCreated")
  131. .HasColumnType("TEXT");
  132. b.Property<DateTime?>("DateLastMediaAdded")
  133. .HasColumnType("TEXT");
  134. b.Property<DateTime?>("DateLastRefreshed")
  135. .HasColumnType("TEXT");
  136. b.Property<DateTime?>("DateLastSaved")
  137. .HasColumnType("TEXT");
  138. b.Property<DateTime?>("DateModified")
  139. .HasColumnType("TEXT");
  140. b.Property<DateTime>("EndDate")
  141. .HasColumnType("TEXT");
  142. b.Property<string>("EpisodeTitle")
  143. .HasColumnType("TEXT");
  144. b.Property<string>("ExternalId")
  145. .HasColumnType("TEXT");
  146. b.Property<string>("ExternalSeriesId")
  147. .HasColumnType("TEXT");
  148. b.Property<string>("ExternalServiceId")
  149. .HasColumnType("TEXT");
  150. b.Property<string>("ExtraIds")
  151. .HasColumnType("TEXT");
  152. b.Property<int?>("ExtraType")
  153. .HasColumnType("INTEGER");
  154. b.Property<string>("ForcedSortName")
  155. .HasColumnType("TEXT");
  156. b.Property<string>("Genres")
  157. .HasColumnType("TEXT");
  158. b.Property<int?>("Height")
  159. .HasColumnType("INTEGER");
  160. b.Property<int?>("IndexNumber")
  161. .HasColumnType("INTEGER");
  162. b.Property<int?>("InheritedParentalRatingValue")
  163. .HasColumnType("INTEGER");
  164. b.Property<bool>("IsFolder")
  165. .HasColumnType("INTEGER");
  166. b.Property<bool>("IsInMixedFolder")
  167. .HasColumnType("INTEGER");
  168. b.Property<bool>("IsLocked")
  169. .HasColumnType("INTEGER");
  170. b.Property<bool>("IsMovie")
  171. .HasColumnType("INTEGER");
  172. b.Property<bool>("IsRepeat")
  173. .HasColumnType("INTEGER");
  174. b.Property<bool>("IsSeries")
  175. .HasColumnType("INTEGER");
  176. b.Property<bool>("IsVirtualItem")
  177. .HasColumnType("INTEGER");
  178. b.Property<float?>("LUFS")
  179. .HasColumnType("REAL");
  180. b.Property<string>("MediaType")
  181. .HasColumnType("TEXT");
  182. b.Property<string>("Name")
  183. .HasColumnType("TEXT");
  184. b.Property<float?>("NormalizationGain")
  185. .HasColumnType("REAL");
  186. b.Property<string>("OfficialRating")
  187. .HasColumnType("TEXT");
  188. b.Property<string>("OriginalTitle")
  189. .HasColumnType("TEXT");
  190. b.Property<string>("Overview")
  191. .HasColumnType("TEXT");
  192. b.Property<string>("OwnerId")
  193. .HasColumnType("TEXT");
  194. b.Property<Guid?>("ParentId")
  195. .HasColumnType("TEXT");
  196. b.Property<int?>("ParentIndexNumber")
  197. .HasColumnType("INTEGER");
  198. b.Property<string>("Path")
  199. .HasColumnType("TEXT");
  200. b.Property<string>("PreferredMetadataCountryCode")
  201. .HasColumnType("TEXT");
  202. b.Property<string>("PreferredMetadataLanguage")
  203. .HasColumnType("TEXT");
  204. b.Property<DateTime?>("PremiereDate")
  205. .HasColumnType("TEXT");
  206. b.Property<string>("PresentationUniqueKey")
  207. .HasColumnType("TEXT");
  208. b.Property<string>("PrimaryVersionId")
  209. .HasColumnType("TEXT");
  210. b.Property<string>("ProductionLocations")
  211. .HasColumnType("TEXT");
  212. b.Property<int?>("ProductionYear")
  213. .HasColumnType("INTEGER");
  214. b.Property<long?>("RunTimeTicks")
  215. .HasColumnType("INTEGER");
  216. b.Property<Guid?>("SeasonId")
  217. .HasColumnType("TEXT");
  218. b.Property<string>("SeasonName")
  219. .HasColumnType("TEXT");
  220. b.Property<Guid?>("SeriesId")
  221. .HasColumnType("TEXT");
  222. b.Property<string>("SeriesName")
  223. .HasColumnType("TEXT");
  224. b.Property<string>("SeriesPresentationUniqueKey")
  225. .HasColumnType("TEXT");
  226. b.Property<string>("ShowId")
  227. .HasColumnType("TEXT");
  228. b.Property<long?>("Size")
  229. .HasColumnType("INTEGER");
  230. b.Property<string>("SortName")
  231. .HasColumnType("TEXT");
  232. b.Property<DateTime>("StartDate")
  233. .HasColumnType("TEXT");
  234. b.Property<string>("Studios")
  235. .HasColumnType("TEXT");
  236. b.Property<string>("Tagline")
  237. .HasColumnType("TEXT");
  238. b.Property<string>("Tags")
  239. .HasColumnType("TEXT");
  240. b.Property<Guid?>("TopParentId")
  241. .HasColumnType("TEXT");
  242. b.Property<int?>("TotalBitrate")
  243. .HasColumnType("INTEGER");
  244. b.Property<string>("Type")
  245. .IsRequired()
  246. .HasColumnType("TEXT");
  247. b.Property<string>("UnratedType")
  248. .HasColumnType("TEXT");
  249. b.Property<string>("UserDataKey")
  250. .HasColumnType("TEXT");
  251. b.Property<int?>("Width")
  252. .HasColumnType("INTEGER");
  253. b.HasKey("Id");
  254. b.HasIndex("ParentId");
  255. b.HasIndex("Path");
  256. b.HasIndex("PresentationUniqueKey");
  257. b.HasIndex("TopParentId", "Id");
  258. b.HasIndex("UserDataKey", "Type");
  259. b.HasIndex("Type", "TopParentId", "Id");
  260. b.HasIndex("Type", "TopParentId", "PresentationUniqueKey");
  261. b.HasIndex("Type", "TopParentId", "StartDate");
  262. b.HasIndex("Id", "Type", "IsFolder", "IsVirtualItem");
  263. b.HasIndex("MediaType", "TopParentId", "IsVirtualItem", "PresentationUniqueKey");
  264. b.HasIndex("Type", "SeriesPresentationUniqueKey", "IsFolder", "IsVirtualItem");
  265. b.HasIndex("Type", "SeriesPresentationUniqueKey", "PresentationUniqueKey", "SortName");
  266. b.HasIndex("IsFolder", "TopParentId", "IsVirtualItem", "PresentationUniqueKey", "DateCreated");
  267. b.HasIndex("Type", "TopParentId", "IsVirtualItem", "PresentationUniqueKey", "DateCreated");
  268. b.ToTable("BaseItems");
  269. });
  270. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemImageInfo", b =>
  271. {
  272. b.Property<Guid>("Id")
  273. .ValueGeneratedOnAdd()
  274. .HasColumnType("TEXT");
  275. b.Property<byte[]>("Blurhash")
  276. .HasColumnType("BLOB");
  277. b.Property<DateTime>("DateModified")
  278. .HasColumnType("TEXT");
  279. b.Property<int>("Height")
  280. .HasColumnType("INTEGER");
  281. b.Property<int>("ImageType")
  282. .HasColumnType("INTEGER");
  283. b.Property<Guid>("ItemId")
  284. .HasColumnType("TEXT");
  285. b.Property<string>("Path")
  286. .IsRequired()
  287. .HasColumnType("TEXT");
  288. b.Property<int>("Width")
  289. .HasColumnType("INTEGER");
  290. b.HasKey("Id");
  291. b.HasIndex("ItemId");
  292. b.ToTable("BaseItemImageInfos");
  293. });
  294. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemMetadataField", b =>
  295. {
  296. b.Property<int>("Id")
  297. .HasColumnType("INTEGER");
  298. b.Property<Guid>("ItemId")
  299. .HasColumnType("TEXT");
  300. b.HasKey("Id", "ItemId");
  301. b.HasIndex("ItemId");
  302. b.ToTable("BaseItemMetadataFields");
  303. });
  304. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemProvider", b =>
  305. {
  306. b.Property<Guid>("ItemId")
  307. .HasColumnType("TEXT");
  308. b.Property<string>("ProviderId")
  309. .HasColumnType("TEXT");
  310. b.Property<string>("ProviderValue")
  311. .IsRequired()
  312. .HasColumnType("TEXT");
  313. b.HasKey("ItemId", "ProviderId");
  314. b.HasIndex("ProviderId", "ProviderValue", "ItemId");
  315. b.ToTable("BaseItemProviders");
  316. });
  317. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemTrailerType", b =>
  318. {
  319. b.Property<int>("Id")
  320. .HasColumnType("INTEGER");
  321. b.Property<Guid>("ItemId")
  322. .HasColumnType("TEXT");
  323. b.HasKey("Id", "ItemId");
  324. b.HasIndex("ItemId");
  325. b.ToTable("BaseItemTrailerTypes");
  326. });
  327. modelBuilder.Entity("Jellyfin.Data.Entities.Chapter", b =>
  328. {
  329. b.Property<Guid>("ItemId")
  330. .HasColumnType("TEXT");
  331. b.Property<int>("ChapterIndex")
  332. .HasColumnType("INTEGER");
  333. b.Property<DateTime?>("ImageDateModified")
  334. .HasColumnType("TEXT");
  335. b.Property<string>("ImagePath")
  336. .HasColumnType("TEXT");
  337. b.Property<string>("Name")
  338. .HasColumnType("TEXT");
  339. b.Property<long>("StartPositionTicks")
  340. .HasColumnType("INTEGER");
  341. b.HasKey("ItemId", "ChapterIndex");
  342. b.ToTable("Chapters");
  343. });
  344. modelBuilder.Entity("Jellyfin.Data.Entities.CustomItemDisplayPreferences", b =>
  345. {
  346. b.Property<int>("Id")
  347. .ValueGeneratedOnAdd()
  348. .HasColumnType("INTEGER");
  349. b.Property<string>("Client")
  350. .IsRequired()
  351. .HasMaxLength(32)
  352. .HasColumnType("TEXT");
  353. b.Property<Guid>("ItemId")
  354. .HasColumnType("TEXT");
  355. b.Property<string>("Key")
  356. .IsRequired()
  357. .HasColumnType("TEXT");
  358. b.Property<Guid>("UserId")
  359. .HasColumnType("TEXT");
  360. b.Property<string>("Value")
  361. .HasColumnType("TEXT");
  362. b.HasKey("Id");
  363. b.HasIndex("UserId", "ItemId", "Client", "Key")
  364. .IsUnique();
  365. b.ToTable("CustomItemDisplayPreferences");
  366. });
  367. modelBuilder.Entity("Jellyfin.Data.Entities.DisplayPreferences", b =>
  368. {
  369. b.Property<int>("Id")
  370. .ValueGeneratedOnAdd()
  371. .HasColumnType("INTEGER");
  372. b.Property<int>("ChromecastVersion")
  373. .HasColumnType("INTEGER");
  374. b.Property<string>("Client")
  375. .IsRequired()
  376. .HasMaxLength(32)
  377. .HasColumnType("TEXT");
  378. b.Property<string>("DashboardTheme")
  379. .HasMaxLength(32)
  380. .HasColumnType("TEXT");
  381. b.Property<bool>("EnableNextVideoInfoOverlay")
  382. .HasColumnType("INTEGER");
  383. b.Property<int?>("IndexBy")
  384. .HasColumnType("INTEGER");
  385. b.Property<Guid>("ItemId")
  386. .HasColumnType("TEXT");
  387. b.Property<int>("ScrollDirection")
  388. .HasColumnType("INTEGER");
  389. b.Property<bool>("ShowBackdrop")
  390. .HasColumnType("INTEGER");
  391. b.Property<bool>("ShowSidebar")
  392. .HasColumnType("INTEGER");
  393. b.Property<int>("SkipBackwardLength")
  394. .HasColumnType("INTEGER");
  395. b.Property<int>("SkipForwardLength")
  396. .HasColumnType("INTEGER");
  397. b.Property<string>("TvHome")
  398. .HasMaxLength(32)
  399. .HasColumnType("TEXT");
  400. b.Property<Guid>("UserId")
  401. .HasColumnType("TEXT");
  402. b.HasKey("Id");
  403. b.HasIndex("UserId", "ItemId", "Client")
  404. .IsUnique();
  405. b.ToTable("DisplayPreferences");
  406. });
  407. modelBuilder.Entity("Jellyfin.Data.Entities.HomeSection", b =>
  408. {
  409. b.Property<int>("Id")
  410. .ValueGeneratedOnAdd()
  411. .HasColumnType("INTEGER");
  412. b.Property<int>("DisplayPreferencesId")
  413. .HasColumnType("INTEGER");
  414. b.Property<int>("Order")
  415. .HasColumnType("INTEGER");
  416. b.Property<int>("Type")
  417. .HasColumnType("INTEGER");
  418. b.HasKey("Id");
  419. b.HasIndex("DisplayPreferencesId");
  420. b.ToTable("HomeSection");
  421. });
  422. modelBuilder.Entity("Jellyfin.Data.Entities.ImageInfo", b =>
  423. {
  424. b.Property<int>("Id")
  425. .ValueGeneratedOnAdd()
  426. .HasColumnType("INTEGER");
  427. b.Property<DateTime>("LastModified")
  428. .HasColumnType("TEXT");
  429. b.Property<string>("Path")
  430. .IsRequired()
  431. .HasMaxLength(512)
  432. .HasColumnType("TEXT");
  433. b.Property<Guid?>("UserId")
  434. .HasColumnType("TEXT");
  435. b.HasKey("Id");
  436. b.HasIndex("UserId")
  437. .IsUnique();
  438. b.ToTable("ImageInfos");
  439. });
  440. modelBuilder.Entity("Jellyfin.Data.Entities.ItemDisplayPreferences", b =>
  441. {
  442. b.Property<int>("Id")
  443. .ValueGeneratedOnAdd()
  444. .HasColumnType("INTEGER");
  445. b.Property<string>("Client")
  446. .IsRequired()
  447. .HasMaxLength(32)
  448. .HasColumnType("TEXT");
  449. b.Property<int?>("IndexBy")
  450. .HasColumnType("INTEGER");
  451. b.Property<Guid>("ItemId")
  452. .HasColumnType("TEXT");
  453. b.Property<bool>("RememberIndexing")
  454. .HasColumnType("INTEGER");
  455. b.Property<bool>("RememberSorting")
  456. .HasColumnType("INTEGER");
  457. b.Property<string>("SortBy")
  458. .IsRequired()
  459. .HasMaxLength(64)
  460. .HasColumnType("TEXT");
  461. b.Property<int>("SortOrder")
  462. .HasColumnType("INTEGER");
  463. b.Property<Guid>("UserId")
  464. .HasColumnType("TEXT");
  465. b.Property<int>("ViewType")
  466. .HasColumnType("INTEGER");
  467. b.HasKey("Id");
  468. b.HasIndex("UserId");
  469. b.ToTable("ItemDisplayPreferences");
  470. });
  471. modelBuilder.Entity("Jellyfin.Data.Entities.ItemValue", b =>
  472. {
  473. b.Property<Guid>("ItemValueId")
  474. .ValueGeneratedOnAdd()
  475. .HasColumnType("TEXT");
  476. b.Property<string>("CleanValue")
  477. .IsRequired()
  478. .HasColumnType("TEXT");
  479. b.Property<int>("Type")
  480. .HasColumnType("INTEGER");
  481. b.Property<string>("Value")
  482. .IsRequired()
  483. .HasColumnType("TEXT");
  484. b.HasKey("ItemValueId");
  485. b.HasIndex("Type", "CleanValue");
  486. b.ToTable("ItemValues");
  487. });
  488. modelBuilder.Entity("Jellyfin.Data.Entities.ItemValueMap", b =>
  489. {
  490. b.Property<Guid>("ItemValueId")
  491. .HasColumnType("TEXT");
  492. b.Property<Guid>("ItemId")
  493. .HasColumnType("TEXT");
  494. b.HasKey("ItemValueId", "ItemId");
  495. b.HasIndex("ItemId");
  496. b.ToTable("ItemValuesMap");
  497. });
  498. modelBuilder.Entity("Jellyfin.Data.Entities.MediaSegment", b =>
  499. {
  500. b.Property<Guid>("Id")
  501. .ValueGeneratedOnAdd()
  502. .HasColumnType("TEXT");
  503. b.Property<long>("EndTicks")
  504. .HasColumnType("INTEGER");
  505. b.Property<Guid>("ItemId")
  506. .HasColumnType("TEXT");
  507. b.Property<string>("SegmentProviderId")
  508. .IsRequired()
  509. .HasColumnType("TEXT");
  510. b.Property<long>("StartTicks")
  511. .HasColumnType("INTEGER");
  512. b.Property<int>("Type")
  513. .HasColumnType("INTEGER");
  514. b.HasKey("Id");
  515. b.ToTable("MediaSegments");
  516. });
  517. modelBuilder.Entity("Jellyfin.Data.Entities.MediaStreamInfo", b =>
  518. {
  519. b.Property<Guid>("ItemId")
  520. .HasColumnType("TEXT");
  521. b.Property<int>("StreamIndex")
  522. .HasColumnType("INTEGER");
  523. b.Property<string>("AspectRatio")
  524. .HasColumnType("TEXT");
  525. b.Property<float>("AverageFrameRate")
  526. .HasColumnType("REAL");
  527. b.Property<int>("BitDepth")
  528. .HasColumnType("INTEGER");
  529. b.Property<int>("BitRate")
  530. .HasColumnType("INTEGER");
  531. b.Property<int>("BlPresentFlag")
  532. .HasColumnType("INTEGER");
  533. b.Property<string>("ChannelLayout")
  534. .HasColumnType("TEXT");
  535. b.Property<int>("Channels")
  536. .HasColumnType("INTEGER");
  537. b.Property<string>("Codec")
  538. .HasColumnType("TEXT");
  539. b.Property<string>("CodecTag")
  540. .IsRequired()
  541. .HasColumnType("TEXT");
  542. b.Property<string>("CodecTimeBase")
  543. .IsRequired()
  544. .HasColumnType("TEXT");
  545. b.Property<string>("ColorPrimaries")
  546. .IsRequired()
  547. .HasColumnType("TEXT");
  548. b.Property<string>("ColorSpace")
  549. .IsRequired()
  550. .HasColumnType("TEXT");
  551. b.Property<string>("ColorTransfer")
  552. .IsRequired()
  553. .HasColumnType("TEXT");
  554. b.Property<string>("Comment")
  555. .IsRequired()
  556. .HasColumnType("TEXT");
  557. b.Property<int>("DvBlSignalCompatibilityId")
  558. .HasColumnType("INTEGER");
  559. b.Property<int>("DvLevel")
  560. .HasColumnType("INTEGER");
  561. b.Property<int>("DvProfile")
  562. .HasColumnType("INTEGER");
  563. b.Property<int>("DvVersionMajor")
  564. .HasColumnType("INTEGER");
  565. b.Property<int>("DvVersionMinor")
  566. .HasColumnType("INTEGER");
  567. b.Property<int>("ElPresentFlag")
  568. .HasColumnType("INTEGER");
  569. b.Property<int>("Height")
  570. .HasColumnType("INTEGER");
  571. b.Property<bool>("IsAnamorphic")
  572. .HasColumnType("INTEGER");
  573. b.Property<bool>("IsAvc")
  574. .HasColumnType("INTEGER");
  575. b.Property<bool>("IsDefault")
  576. .HasColumnType("INTEGER");
  577. b.Property<bool>("IsExternal")
  578. .HasColumnType("INTEGER");
  579. b.Property<bool>("IsForced")
  580. .HasColumnType("INTEGER");
  581. b.Property<bool>("IsHearingImpaired")
  582. .HasColumnType("INTEGER");
  583. b.Property<bool>("IsInterlaced")
  584. .HasColumnType("INTEGER");
  585. b.Property<string>("KeyFrames")
  586. .HasColumnType("TEXT");
  587. b.Property<string>("Language")
  588. .HasColumnType("TEXT");
  589. b.Property<float>("Level")
  590. .HasColumnType("REAL");
  591. b.Property<string>("NalLengthSize")
  592. .IsRequired()
  593. .HasColumnType("TEXT");
  594. b.Property<string>("Path")
  595. .HasColumnType("TEXT");
  596. b.Property<string>("PixelFormat")
  597. .HasColumnType("TEXT");
  598. b.Property<string>("Profile")
  599. .HasColumnType("TEXT");
  600. b.Property<float>("RealFrameRate")
  601. .HasColumnType("REAL");
  602. b.Property<int>("RefFrames")
  603. .HasColumnType("INTEGER");
  604. b.Property<int>("Rotation")
  605. .HasColumnType("INTEGER");
  606. b.Property<int>("RpuPresentFlag")
  607. .HasColumnType("INTEGER");
  608. b.Property<int>("SampleRate")
  609. .HasColumnType("INTEGER");
  610. b.Property<int?>("StreamType")
  611. .HasColumnType("INTEGER");
  612. b.Property<string>("TimeBase")
  613. .IsRequired()
  614. .HasColumnType("TEXT");
  615. b.Property<string>("Title")
  616. .IsRequired()
  617. .HasColumnType("TEXT");
  618. b.Property<int>("Width")
  619. .HasColumnType("INTEGER");
  620. b.HasKey("ItemId", "StreamIndex");
  621. b.HasIndex("StreamIndex");
  622. b.HasIndex("StreamType");
  623. b.HasIndex("StreamIndex", "StreamType");
  624. b.HasIndex("StreamIndex", "StreamType", "Language");
  625. b.ToTable("MediaStreamInfos");
  626. });
  627. modelBuilder.Entity("Jellyfin.Data.Entities.People", b =>
  628. {
  629. b.Property<Guid>("ItemId")
  630. .HasColumnType("TEXT");
  631. b.Property<string>("Role")
  632. .HasColumnType("TEXT");
  633. b.Property<int?>("ListOrder")
  634. .HasColumnType("INTEGER");
  635. b.Property<string>("Name")
  636. .IsRequired()
  637. .HasColumnType("TEXT");
  638. b.Property<string>("PersonType")
  639. .HasColumnType("TEXT");
  640. b.Property<int?>("SortOrder")
  641. .HasColumnType("INTEGER");
  642. b.HasKey("ItemId", "Role", "ListOrder");
  643. b.HasIndex("Name");
  644. b.HasIndex("ItemId", "ListOrder");
  645. b.ToTable("Peoples");
  646. });
  647. modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>
  648. {
  649. b.Property<int>("Id")
  650. .ValueGeneratedOnAdd()
  651. .HasColumnType("INTEGER");
  652. b.Property<int>("Kind")
  653. .HasColumnType("INTEGER");
  654. b.Property<Guid?>("Permission_Permissions_Guid")
  655. .HasColumnType("TEXT");
  656. b.Property<uint>("RowVersion")
  657. .IsConcurrencyToken()
  658. .HasColumnType("INTEGER");
  659. b.Property<Guid?>("UserId")
  660. .HasColumnType("TEXT");
  661. b.Property<bool>("Value")
  662. .HasColumnType("INTEGER");
  663. b.HasKey("Id");
  664. b.HasIndex("UserId", "Kind")
  665. .IsUnique()
  666. .HasFilter("[UserId] IS NOT NULL");
  667. b.ToTable("Permissions");
  668. });
  669. modelBuilder.Entity("Jellyfin.Data.Entities.Preference", b =>
  670. {
  671. b.Property<int>("Id")
  672. .ValueGeneratedOnAdd()
  673. .HasColumnType("INTEGER");
  674. b.Property<int>("Kind")
  675. .HasColumnType("INTEGER");
  676. b.Property<Guid?>("Preference_Preferences_Guid")
  677. .HasColumnType("TEXT");
  678. b.Property<uint>("RowVersion")
  679. .IsConcurrencyToken()
  680. .HasColumnType("INTEGER");
  681. b.Property<Guid?>("UserId")
  682. .HasColumnType("TEXT");
  683. b.Property<string>("Value")
  684. .IsRequired()
  685. .HasMaxLength(65535)
  686. .HasColumnType("TEXT");
  687. b.HasKey("Id");
  688. b.HasIndex("UserId", "Kind")
  689. .IsUnique()
  690. .HasFilter("[UserId] IS NOT NULL");
  691. b.ToTable("Preferences");
  692. });
  693. modelBuilder.Entity("Jellyfin.Data.Entities.Security.ApiKey", b =>
  694. {
  695. b.Property<int>("Id")
  696. .ValueGeneratedOnAdd()
  697. .HasColumnType("INTEGER");
  698. b.Property<string>("AccessToken")
  699. .IsRequired()
  700. .HasColumnType("TEXT");
  701. b.Property<DateTime>("DateCreated")
  702. .HasColumnType("TEXT");
  703. b.Property<DateTime>("DateLastActivity")
  704. .HasColumnType("TEXT");
  705. b.Property<string>("Name")
  706. .IsRequired()
  707. .HasMaxLength(64)
  708. .HasColumnType("TEXT");
  709. b.HasKey("Id");
  710. b.HasIndex("AccessToken")
  711. .IsUnique();
  712. b.ToTable("ApiKeys");
  713. });
  714. modelBuilder.Entity("Jellyfin.Data.Entities.Security.Device", b =>
  715. {
  716. b.Property<int>("Id")
  717. .ValueGeneratedOnAdd()
  718. .HasColumnType("INTEGER");
  719. b.Property<string>("AccessToken")
  720. .IsRequired()
  721. .HasColumnType("TEXT");
  722. b.Property<string>("AppName")
  723. .IsRequired()
  724. .HasMaxLength(64)
  725. .HasColumnType("TEXT");
  726. b.Property<string>("AppVersion")
  727. .IsRequired()
  728. .HasMaxLength(32)
  729. .HasColumnType("TEXT");
  730. b.Property<DateTime>("DateCreated")
  731. .HasColumnType("TEXT");
  732. b.Property<DateTime>("DateLastActivity")
  733. .HasColumnType("TEXT");
  734. b.Property<DateTime>("DateModified")
  735. .HasColumnType("TEXT");
  736. b.Property<string>("DeviceId")
  737. .IsRequired()
  738. .HasMaxLength(256)
  739. .HasColumnType("TEXT");
  740. b.Property<string>("DeviceName")
  741. .IsRequired()
  742. .HasMaxLength(64)
  743. .HasColumnType("TEXT");
  744. b.Property<bool>("IsActive")
  745. .HasColumnType("INTEGER");
  746. b.Property<Guid>("UserId")
  747. .HasColumnType("TEXT");
  748. b.HasKey("Id");
  749. b.HasIndex("DeviceId");
  750. b.HasIndex("AccessToken", "DateLastActivity");
  751. b.HasIndex("DeviceId", "DateLastActivity");
  752. b.HasIndex("UserId", "DeviceId");
  753. b.ToTable("Devices");
  754. });
  755. modelBuilder.Entity("Jellyfin.Data.Entities.Security.DeviceOptions", b =>
  756. {
  757. b.Property<int>("Id")
  758. .ValueGeneratedOnAdd()
  759. .HasColumnType("INTEGER");
  760. b.Property<string>("CustomName")
  761. .HasColumnType("TEXT");
  762. b.Property<string>("DeviceId")
  763. .IsRequired()
  764. .HasColumnType("TEXT");
  765. b.HasKey("Id");
  766. b.HasIndex("DeviceId")
  767. .IsUnique();
  768. b.ToTable("DeviceOptions");
  769. });
  770. modelBuilder.Entity("Jellyfin.Data.Entities.TrickplayInfo", b =>
  771. {
  772. b.Property<Guid>("ItemId")
  773. .HasColumnType("TEXT");
  774. b.Property<int>("Width")
  775. .HasColumnType("INTEGER");
  776. b.Property<int>("Bandwidth")
  777. .HasColumnType("INTEGER");
  778. b.Property<int>("Height")
  779. .HasColumnType("INTEGER");
  780. b.Property<int>("Interval")
  781. .HasColumnType("INTEGER");
  782. b.Property<int>("ThumbnailCount")
  783. .HasColumnType("INTEGER");
  784. b.Property<int>("TileHeight")
  785. .HasColumnType("INTEGER");
  786. b.Property<int>("TileWidth")
  787. .HasColumnType("INTEGER");
  788. b.HasKey("ItemId", "Width");
  789. b.ToTable("TrickplayInfos");
  790. });
  791. modelBuilder.Entity("Jellyfin.Data.Entities.User", b =>
  792. {
  793. b.Property<Guid>("Id")
  794. .ValueGeneratedOnAdd()
  795. .HasColumnType("TEXT");
  796. b.Property<string>("AudioLanguagePreference")
  797. .HasMaxLength(255)
  798. .HasColumnType("TEXT");
  799. b.Property<string>("AuthenticationProviderId")
  800. .IsRequired()
  801. .HasMaxLength(255)
  802. .HasColumnType("TEXT");
  803. b.Property<string>("CastReceiverId")
  804. .HasMaxLength(32)
  805. .HasColumnType("TEXT");
  806. b.Property<bool>("DisplayCollectionsView")
  807. .HasColumnType("INTEGER");
  808. b.Property<bool>("DisplayMissingEpisodes")
  809. .HasColumnType("INTEGER");
  810. b.Property<bool>("EnableAutoLogin")
  811. .HasColumnType("INTEGER");
  812. b.Property<bool>("EnableLocalPassword")
  813. .HasColumnType("INTEGER");
  814. b.Property<bool>("EnableNextEpisodeAutoPlay")
  815. .HasColumnType("INTEGER");
  816. b.Property<bool>("EnableUserPreferenceAccess")
  817. .HasColumnType("INTEGER");
  818. b.Property<bool>("HidePlayedInLatest")
  819. .HasColumnType("INTEGER");
  820. b.Property<long>("InternalId")
  821. .HasColumnType("INTEGER");
  822. b.Property<int>("InvalidLoginAttemptCount")
  823. .HasColumnType("INTEGER");
  824. b.Property<DateTime?>("LastActivityDate")
  825. .HasColumnType("TEXT");
  826. b.Property<DateTime?>("LastLoginDate")
  827. .HasColumnType("TEXT");
  828. b.Property<int?>("LoginAttemptsBeforeLockout")
  829. .HasColumnType("INTEGER");
  830. b.Property<int>("MaxActiveSessions")
  831. .HasColumnType("INTEGER");
  832. b.Property<int?>("MaxParentalAgeRating")
  833. .HasColumnType("INTEGER");
  834. b.Property<bool>("MustUpdatePassword")
  835. .HasColumnType("INTEGER");
  836. b.Property<string>("Password")
  837. .HasMaxLength(65535)
  838. .HasColumnType("TEXT");
  839. b.Property<string>("PasswordResetProviderId")
  840. .IsRequired()
  841. .HasMaxLength(255)
  842. .HasColumnType("TEXT");
  843. b.Property<bool>("PlayDefaultAudioTrack")
  844. .HasColumnType("INTEGER");
  845. b.Property<bool>("RememberAudioSelections")
  846. .HasColumnType("INTEGER");
  847. b.Property<bool>("RememberSubtitleSelections")
  848. .HasColumnType("INTEGER");
  849. b.Property<int?>("RemoteClientBitrateLimit")
  850. .HasColumnType("INTEGER");
  851. b.Property<uint>("RowVersion")
  852. .IsConcurrencyToken()
  853. .HasColumnType("INTEGER");
  854. b.Property<string>("SubtitleLanguagePreference")
  855. .HasMaxLength(255)
  856. .HasColumnType("TEXT");
  857. b.Property<int>("SubtitleMode")
  858. .HasColumnType("INTEGER");
  859. b.Property<int>("SyncPlayAccess")
  860. .HasColumnType("INTEGER");
  861. b.Property<string>("Username")
  862. .IsRequired()
  863. .HasMaxLength(255)
  864. .HasColumnType("TEXT")
  865. .UseCollation("NOCASE");
  866. b.HasKey("Id");
  867. b.HasIndex("Username")
  868. .IsUnique();
  869. b.ToTable("Users");
  870. });
  871. modelBuilder.Entity("Jellyfin.Data.Entities.UserData", b =>
  872. {
  873. b.Property<string>("Key")
  874. .HasColumnType("TEXT");
  875. b.Property<Guid>("UserId")
  876. .HasColumnType("TEXT");
  877. b.Property<int?>("AudioStreamIndex")
  878. .HasColumnType("INTEGER");
  879. b.Property<Guid?>("BaseItemEntityId")
  880. .HasColumnType("TEXT");
  881. b.Property<bool>("IsFavorite")
  882. .HasColumnType("INTEGER");
  883. b.Property<DateTime?>("LastPlayedDate")
  884. .HasColumnType("TEXT");
  885. b.Property<bool?>("Likes")
  886. .HasColumnType("INTEGER");
  887. b.Property<int>("PlayCount")
  888. .HasColumnType("INTEGER");
  889. b.Property<long>("PlaybackPositionTicks")
  890. .HasColumnType("INTEGER");
  891. b.Property<bool>("Played")
  892. .HasColumnType("INTEGER");
  893. b.Property<double?>("Rating")
  894. .HasColumnType("REAL");
  895. b.Property<int?>("SubtitleStreamIndex")
  896. .HasColumnType("INTEGER");
  897. b.HasKey("Key", "UserId");
  898. b.HasIndex("BaseItemEntityId");
  899. b.HasIndex("UserId");
  900. b.HasIndex("Key", "UserId", "IsFavorite");
  901. b.HasIndex("Key", "UserId", "LastPlayedDate");
  902. b.HasIndex("Key", "UserId", "PlaybackPositionTicks");
  903. b.HasIndex("Key", "UserId", "Played");
  904. b.ToTable("UserData");
  905. });
  906. modelBuilder.Entity("Jellyfin.Data.Entities.AccessSchedule", b =>
  907. {
  908. b.HasOne("Jellyfin.Data.Entities.User", null)
  909. .WithMany("AccessSchedules")
  910. .HasForeignKey("UserId")
  911. .OnDelete(DeleteBehavior.Cascade)
  912. .IsRequired();
  913. });
  914. modelBuilder.Entity("Jellyfin.Data.Entities.AncestorId", b =>
  915. {
  916. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", null)
  917. .WithMany("AncestorIds")
  918. .HasForeignKey("BaseItemEntityId");
  919. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  920. .WithMany()
  921. .HasForeignKey("ItemId")
  922. .OnDelete(DeleteBehavior.Cascade)
  923. .IsRequired();
  924. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "ParentItem")
  925. .WithMany()
  926. .HasForeignKey("ParentItemId")
  927. .OnDelete(DeleteBehavior.Cascade)
  928. .IsRequired();
  929. b.Navigation("Item");
  930. b.Navigation("ParentItem");
  931. });
  932. modelBuilder.Entity("Jellyfin.Data.Entities.AttachmentStreamInfo", b =>
  933. {
  934. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  935. .WithMany()
  936. .HasForeignKey("ItemId")
  937. .OnDelete(DeleteBehavior.Cascade)
  938. .IsRequired();
  939. b.Navigation("Item");
  940. });
  941. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemImageInfo", b =>
  942. {
  943. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  944. .WithMany("Images")
  945. .HasForeignKey("ItemId")
  946. .OnDelete(DeleteBehavior.Cascade)
  947. .IsRequired();
  948. b.Navigation("Item");
  949. });
  950. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemMetadataField", b =>
  951. {
  952. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  953. .WithMany("LockedFields")
  954. .HasForeignKey("ItemId")
  955. .OnDelete(DeleteBehavior.Cascade)
  956. .IsRequired();
  957. b.Navigation("Item");
  958. });
  959. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemProvider", b =>
  960. {
  961. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  962. .WithMany("Provider")
  963. .HasForeignKey("ItemId")
  964. .OnDelete(DeleteBehavior.Cascade)
  965. .IsRequired();
  966. b.Navigation("Item");
  967. });
  968. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemTrailerType", b =>
  969. {
  970. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  971. .WithMany("TrailerTypes")
  972. .HasForeignKey("ItemId")
  973. .OnDelete(DeleteBehavior.Cascade)
  974. .IsRequired();
  975. b.Navigation("Item");
  976. });
  977. modelBuilder.Entity("Jellyfin.Data.Entities.Chapter", b =>
  978. {
  979. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  980. .WithMany("Chapters")
  981. .HasForeignKey("ItemId")
  982. .OnDelete(DeleteBehavior.Cascade)
  983. .IsRequired();
  984. b.Navigation("Item");
  985. });
  986. modelBuilder.Entity("Jellyfin.Data.Entities.DisplayPreferences", b =>
  987. {
  988. b.HasOne("Jellyfin.Data.Entities.User", null)
  989. .WithMany("DisplayPreferences")
  990. .HasForeignKey("UserId")
  991. .OnDelete(DeleteBehavior.Cascade)
  992. .IsRequired();
  993. });
  994. modelBuilder.Entity("Jellyfin.Data.Entities.HomeSection", b =>
  995. {
  996. b.HasOne("Jellyfin.Data.Entities.DisplayPreferences", null)
  997. .WithMany("HomeSections")
  998. .HasForeignKey("DisplayPreferencesId")
  999. .OnDelete(DeleteBehavior.Cascade)
  1000. .IsRequired();
  1001. });
  1002. modelBuilder.Entity("Jellyfin.Data.Entities.ImageInfo", b =>
  1003. {
  1004. b.HasOne("Jellyfin.Data.Entities.User", null)
  1005. .WithOne("ProfileImage")
  1006. .HasForeignKey("Jellyfin.Data.Entities.ImageInfo", "UserId")
  1007. .OnDelete(DeleteBehavior.Cascade);
  1008. });
  1009. modelBuilder.Entity("Jellyfin.Data.Entities.ItemDisplayPreferences", b =>
  1010. {
  1011. b.HasOne("Jellyfin.Data.Entities.User", null)
  1012. .WithMany("ItemDisplayPreferences")
  1013. .HasForeignKey("UserId")
  1014. .OnDelete(DeleteBehavior.Cascade)
  1015. .IsRequired();
  1016. });
  1017. modelBuilder.Entity("Jellyfin.Data.Entities.ItemValueMap", b =>
  1018. {
  1019. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  1020. .WithMany("ItemValues")
  1021. .HasForeignKey("ItemId")
  1022. .OnDelete(DeleteBehavior.Cascade)
  1023. .IsRequired();
  1024. b.HasOne("Jellyfin.Data.Entities.ItemValue", "ItemValue")
  1025. .WithMany("BaseItemsMap")
  1026. .HasForeignKey("ItemValueId")
  1027. .OnDelete(DeleteBehavior.Cascade)
  1028. .IsRequired();
  1029. b.Navigation("Item");
  1030. b.Navigation("ItemValue");
  1031. });
  1032. modelBuilder.Entity("Jellyfin.Data.Entities.MediaStreamInfo", b =>
  1033. {
  1034. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  1035. .WithMany("MediaStreams")
  1036. .HasForeignKey("ItemId")
  1037. .OnDelete(DeleteBehavior.Cascade)
  1038. .IsRequired();
  1039. b.Navigation("Item");
  1040. });
  1041. modelBuilder.Entity("Jellyfin.Data.Entities.People", b =>
  1042. {
  1043. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", "Item")
  1044. .WithMany("Peoples")
  1045. .HasForeignKey("ItemId")
  1046. .OnDelete(DeleteBehavior.Cascade)
  1047. .IsRequired();
  1048. b.Navigation("Item");
  1049. });
  1050. modelBuilder.Entity("Jellyfin.Data.Entities.Permission", b =>
  1051. {
  1052. b.HasOne("Jellyfin.Data.Entities.User", null)
  1053. .WithMany("Permissions")
  1054. .HasForeignKey("UserId")
  1055. .OnDelete(DeleteBehavior.Cascade);
  1056. });
  1057. modelBuilder.Entity("Jellyfin.Data.Entities.Preference", b =>
  1058. {
  1059. b.HasOne("Jellyfin.Data.Entities.User", null)
  1060. .WithMany("Preferences")
  1061. .HasForeignKey("UserId")
  1062. .OnDelete(DeleteBehavior.Cascade);
  1063. });
  1064. modelBuilder.Entity("Jellyfin.Data.Entities.Security.Device", b =>
  1065. {
  1066. b.HasOne("Jellyfin.Data.Entities.User", "User")
  1067. .WithMany()
  1068. .HasForeignKey("UserId")
  1069. .OnDelete(DeleteBehavior.Cascade)
  1070. .IsRequired();
  1071. b.Navigation("User");
  1072. });
  1073. modelBuilder.Entity("Jellyfin.Data.Entities.UserData", b =>
  1074. {
  1075. b.HasOne("Jellyfin.Data.Entities.BaseItemEntity", null)
  1076. .WithMany("UserData")
  1077. .HasForeignKey("BaseItemEntityId");
  1078. b.HasOne("Jellyfin.Data.Entities.User", "User")
  1079. .WithMany()
  1080. .HasForeignKey("UserId")
  1081. .OnDelete(DeleteBehavior.Cascade)
  1082. .IsRequired();
  1083. b.Navigation("User");
  1084. });
  1085. modelBuilder.Entity("Jellyfin.Data.Entities.BaseItemEntity", b =>
  1086. {
  1087. b.Navigation("AncestorIds");
  1088. b.Navigation("Chapters");
  1089. b.Navigation("Images");
  1090. b.Navigation("ItemValues");
  1091. b.Navigation("LockedFields");
  1092. b.Navigation("MediaStreams");
  1093. b.Navigation("Peoples");
  1094. b.Navigation("Provider");
  1095. b.Navigation("TrailerTypes");
  1096. b.Navigation("UserData");
  1097. });
  1098. modelBuilder.Entity("Jellyfin.Data.Entities.DisplayPreferences", b =>
  1099. {
  1100. b.Navigation("HomeSections");
  1101. });
  1102. modelBuilder.Entity("Jellyfin.Data.Entities.ItemValue", b =>
  1103. {
  1104. b.Navigation("BaseItemsMap");
  1105. });
  1106. modelBuilder.Entity("Jellyfin.Data.Entities.User", b =>
  1107. {
  1108. b.Navigation("AccessSchedules");
  1109. b.Navigation("DisplayPreferences");
  1110. b.Navigation("ItemDisplayPreferences");
  1111. b.Navigation("Permissions");
  1112. b.Navigation("Preferences");
  1113. b.Navigation("ProfileImage");
  1114. });
  1115. #pragma warning restore 612, 618
  1116. }
  1117. }
  1118. }