Plix/PlixP/Migrations/20201219204740_init.Designe...

245 lines
7.6 KiB
C#

// <auto-generated />
using System;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using PlixP.Models;
namespace PlixP.Migrations
{
[DbContext(typeof(PlixContext))]
[Migration("20201219204740_init")]
partial class init
{
protected override void BuildTargetModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "5.0.1");
modelBuilder.Entity("PlixP.Models.Category", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime>("CreationDate")
.HasColumnType("TEXT");
b.Property<bool>("IsRemoved")
.HasColumnType("INTEGER");
b.Property<string>("Name")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("Categories");
});
modelBuilder.Entity("PlixP.Models.CategoryMovie", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<int>("CategoryId")
.HasColumnType("INTEGER");
b.Property<DateTime>("CreationDate")
.HasColumnType("TEXT");
b.Property<bool>("IsRemoved")
.HasColumnType("INTEGER");
b.Property<int>("MovieId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("CategoryId");
b.HasIndex("MovieId");
b.ToTable("CategoryMovies");
});
modelBuilder.Entity("PlixP.Models.Movie", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<string>("Actors")
.HasColumnType("TEXT");
b.Property<string>("Awards")
.HasColumnType("TEXT");
b.Property<string>("BoxOffice")
.HasColumnType("TEXT");
b.Property<string>("Country")
.HasColumnType("TEXT");
b.Property<DateTime>("CreationDate")
.HasColumnType("TEXT");
b.Property<string>("DVD")
.HasColumnType("TEXT");
b.Property<string>("Director")
.HasColumnType("TEXT");
b.Property<string>("FileName")
.HasColumnType("TEXT");
b.Property<string>("Genre")
.HasColumnType("TEXT");
b.Property<bool>("IsRemoved")
.HasColumnType("INTEGER");
b.Property<bool>("IsSeen")
.HasColumnType("INTEGER");
b.Property<string>("Language")
.HasColumnType("TEXT");
b.Property<string>("Location")
.HasColumnType("TEXT");
b.Property<string>("Metascore")
.HasColumnType("TEXT");
b.Property<string>("Plot")
.HasColumnType("TEXT");
b.Property<string>("Poster")
.HasColumnType("TEXT");
b.Property<string>("Production")
.HasColumnType("TEXT");
b.Property<string>("Quality")
.HasColumnType("TEXT");
b.Property<string>("Rated")
.HasColumnType("TEXT");
b.Property<string>("Released")
.HasColumnType("TEXT");
b.Property<string>("Response")
.HasColumnType("TEXT");
b.Property<string>("Runtime")
.HasColumnType("TEXT");
b.Property<int>("SyncStatus")
.HasColumnType("INTEGER");
b.Property<string>("Title")
.HasColumnType("TEXT");
b.Property<string>("Type")
.HasColumnType("TEXT");
b.Property<string>("Website")
.HasColumnType("TEXT");
b.Property<string>("Writer")
.HasColumnType("TEXT");
b.Property<string>("Year")
.HasColumnType("TEXT");
b.Property<string>("imdbID")
.HasColumnType("TEXT");
b.Property<string>("imdbRating")
.HasColumnType("TEXT");
b.Property<string>("imdbVotes")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("Movies");
});
modelBuilder.Entity("PlixP.Models.Rating", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property<DateTime>("CreationDate")
.HasColumnType("TEXT");
b.Property<bool>("IsRemoved")
.HasColumnType("INTEGER");
b.Property<int>("MovieId")
.HasColumnType("INTEGER");
b.Property<string>("Source")
.HasColumnType("TEXT");
b.Property<string>("Value")
.HasColumnType("TEXT");
b.HasKey("Id");
b.HasIndex("MovieId");
b.ToTable("Ratings");
});
modelBuilder.Entity("PlixP.Models.CategoryMovie", b =>
{
b.HasOne("PlixP.Models.Category", "Category")
.WithMany("Movies")
.HasForeignKey("CategoryId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.HasOne("PlixP.Models.Movie", "Movie")
.WithMany("Category")
.HasForeignKey("MovieId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Category");
b.Navigation("Movie");
});
modelBuilder.Entity("PlixP.Models.Rating", b =>
{
b.HasOne("PlixP.Models.Movie", "Movie")
.WithMany("Ratings")
.HasForeignKey("MovieId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("Movie");
});
modelBuilder.Entity("PlixP.Models.Category", b =>
{
b.Navigation("Movies");
});
modelBuilder.Entity("PlixP.Models.Movie", b =>
{
b.Navigation("Category");
b.Navigation("Ratings");
});
#pragma warning restore 612, 618
}
}
}