//
using System;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using PlixP.Models;
namespace PlixP.Migrations
{
[DbContext(typeof(PlixContext))]
partial class PlixContextModelSnapshot : ModelSnapshot
{
protected override void BuildModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "5.0.1");
modelBuilder.Entity("PlixP.Models.Category", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property("CreationDate")
.HasColumnType("TEXT");
b.Property("IsRemoved")
.HasColumnType("INTEGER");
b.Property("Name")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("Categories");
});
modelBuilder.Entity("PlixP.Models.CategoryMovie", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property("CategoryId")
.HasColumnType("INTEGER");
b.Property("CreationDate")
.HasColumnType("TEXT");
b.Property("IsRemoved")
.HasColumnType("INTEGER");
b.Property("MovieId")
.HasColumnType("INTEGER");
b.HasKey("Id");
b.HasIndex("CategoryId");
b.HasIndex("MovieId");
b.ToTable("CategoryMovies");
});
modelBuilder.Entity("PlixP.Models.Movie", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property("Actors")
.HasColumnType("TEXT");
b.Property("Awards")
.HasColumnType("TEXT");
b.Property("BoxOffice")
.HasColumnType("TEXT");
b.Property("Country")
.HasColumnType("TEXT");
b.Property("CreationDate")
.HasColumnType("TEXT");
b.Property("DVD")
.HasColumnType("TEXT");
b.Property("Director")
.HasColumnType("TEXT");
b.Property("FileName")
.HasColumnType("TEXT");
b.Property("Genre")
.HasColumnType("TEXT");
b.Property("IsRemoved")
.HasColumnType("INTEGER");
b.Property("IsSeen")
.HasColumnType("INTEGER");
b.Property("Language")
.HasColumnType("TEXT");
b.Property("Location")
.HasColumnType("TEXT");
b.Property("Metascore")
.HasColumnType("TEXT");
b.Property("Plot")
.HasColumnType("TEXT");
b.Property("Poster")
.HasColumnType("TEXT");
b.Property("Production")
.HasColumnType("TEXT");
b.Property("Quality")
.HasColumnType("TEXT");
b.Property("Rated")
.HasColumnType("TEXT");
b.Property("Released")
.HasColumnType("TEXT");
b.Property("Response")
.HasColumnType("TEXT");
b.Property("Runtime")
.HasColumnType("TEXT");
b.Property("SyncStatus")
.HasColumnType("INTEGER");
b.Property("Title")
.HasColumnType("TEXT");
b.Property("Type")
.HasColumnType("TEXT");
b.Property("Website")
.HasColumnType("TEXT");
b.Property("Writer")
.HasColumnType("TEXT");
b.Property("Year")
.HasColumnType("TEXT");
b.Property("imdbID")
.HasColumnType("TEXT");
b.Property("imdbRating")
.HasColumnType("TEXT");
b.Property("imdbVotes")
.HasColumnType("TEXT");
b.HasKey("Id");
b.ToTable("Movies");
});
modelBuilder.Entity("PlixP.Models.Rating", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("INTEGER");
b.Property("CreationDate")
.HasColumnType("TEXT");
b.Property("IsRemoved")
.HasColumnType("INTEGER");
b.Property("MovieId")
.HasColumnType("INTEGER");
b.Property("Source")
.HasColumnType("TEXT");
b.Property("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
}
}
}