JellyfinDbContextModelSnapshot.cs 56 KB

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