ae746d65ba
build-and-deploy / deploy (push) Failing after 15m11s
Remove in-cluster Postgres; serve WASM via nginx; add audio import job for Gooya archives.
398 lines
13 KiB
C#
398 lines
13 KiB
C#
// <auto-generated />
|
|
using System;
|
|
using Microsoft.EntityFrameworkCore;
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
using Microsoft.EntityFrameworkCore.Metadata;
|
|
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
using TafsirQuran.Infrastructure.Persistence;
|
|
|
|
#nullable disable
|
|
|
|
namespace TafsirQuran.Infrastructure.Persistence.Migrations
|
|
{
|
|
[DbContext(typeof(AppDbContext))]
|
|
partial class AppDbContextModelSnapshot : ModelSnapshot
|
|
{
|
|
protected override void BuildModel(ModelBuilder modelBuilder)
|
|
{
|
|
#pragma warning disable 612, 618
|
|
modelBuilder
|
|
.HasAnnotation("ProductVersion", "9.0.10")
|
|
.HasAnnotation("Relational:MaxIdentifierLength", 128);
|
|
|
|
SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.AppUser", b =>
|
|
{
|
|
b.Property<Guid>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<DateTimeOffset>("CreatedAt")
|
|
.HasColumnType("datetimeoffset");
|
|
|
|
b.Property<string>("DisplayName")
|
|
.IsRequired()
|
|
.HasMaxLength(128)
|
|
.HasColumnType("nvarchar(128)");
|
|
|
|
b.Property<string>("Email")
|
|
.IsRequired()
|
|
.HasMaxLength(256)
|
|
.HasColumnType("nvarchar(256)");
|
|
|
|
b.Property<string>("PasswordHash")
|
|
.IsRequired()
|
|
.HasColumnType("nvarchar(max)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("Email")
|
|
.IsUnique();
|
|
|
|
b.ToTable("Users");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Ayah", b =>
|
|
{
|
|
b.Property<Guid>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<int>("Number")
|
|
.HasColumnType("int");
|
|
|
|
b.Property<int>("SurahId")
|
|
.HasColumnType("int");
|
|
|
|
b.Property<string>("TextAr")
|
|
.IsRequired()
|
|
.HasColumnType("nvarchar(max)");
|
|
|
|
b.Property<string>("TextFa")
|
|
.HasColumnType("nvarchar(max)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("SurahId", "Number")
|
|
.IsUnique();
|
|
|
|
b.ToTable("Ayahs");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Bookmark", b =>
|
|
{
|
|
b.Property<Guid>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<DateTimeOffset>("CreatedAt")
|
|
.HasColumnType("datetimeoffset");
|
|
|
|
b.Property<string>("DeviceId")
|
|
.IsRequired()
|
|
.HasMaxLength(64)
|
|
.HasColumnType("nvarchar(64)");
|
|
|
|
b.Property<Guid>("EpisodeId")
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<string>("Note")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("nvarchar(500)");
|
|
|
|
b.Property<Guid?>("UserId")
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("EpisodeId");
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
b.HasIndex("DeviceId", "UserId", "EpisodeId")
|
|
.IsUnique()
|
|
.HasFilter("[UserId] IS NOT NULL");
|
|
|
|
b.ToTable("Bookmarks");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Favorite", b =>
|
|
{
|
|
b.Property<Guid>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<DateTimeOffset>("CreatedAt")
|
|
.HasColumnType("datetimeoffset");
|
|
|
|
b.Property<string>("DeviceId")
|
|
.IsRequired()
|
|
.HasMaxLength(64)
|
|
.HasColumnType("nvarchar(64)");
|
|
|
|
b.Property<Guid>("EpisodeId")
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<Guid?>("UserId")
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("EpisodeId");
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
b.HasIndex("DeviceId", "UserId", "EpisodeId")
|
|
.IsUnique()
|
|
.HasFilter("[UserId] IS NOT NULL");
|
|
|
|
b.ToTable("Favorites");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.ListeningProgress", b =>
|
|
{
|
|
b.Property<Guid>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<string>("DeviceId")
|
|
.IsRequired()
|
|
.HasMaxLength(64)
|
|
.HasColumnType("nvarchar(64)");
|
|
|
|
b.Property<Guid>("EpisodeId")
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<double>("PositionSeconds")
|
|
.HasColumnType("float");
|
|
|
|
b.Property<DateTimeOffset>("UpdatedAt")
|
|
.HasColumnType("datetimeoffset");
|
|
|
|
b.Property<Guid?>("UserId")
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("EpisodeId");
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
b.HasIndex("DeviceId", "UserId");
|
|
|
|
b.ToTable("ListeningProgresses");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Surah", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("int");
|
|
|
|
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("NameAr")
|
|
.IsRequired()
|
|
.HasMaxLength(80)
|
|
.HasColumnType("nvarchar(80)");
|
|
|
|
b.Property<string>("NameFa")
|
|
.IsRequired()
|
|
.HasMaxLength(80)
|
|
.HasColumnType("nvarchar(80)");
|
|
|
|
b.Property<int>("Number")
|
|
.HasColumnType("int");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("Number")
|
|
.IsUnique();
|
|
|
|
b.ToTable("Surahs");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Tafsir", b =>
|
|
{
|
|
b.Property<Guid>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<string>("Author")
|
|
.IsRequired()
|
|
.HasMaxLength(120)
|
|
.HasColumnType("nvarchar(120)");
|
|
|
|
b.Property<string>("CoverUrl")
|
|
.HasColumnType("nvarchar(max)");
|
|
|
|
b.Property<bool>("IsPublished")
|
|
.HasColumnType("bit");
|
|
|
|
b.Property<string>("Slug")
|
|
.IsRequired()
|
|
.HasMaxLength(120)
|
|
.HasColumnType("nvarchar(120)");
|
|
|
|
b.Property<string>("Title")
|
|
.IsRequired()
|
|
.HasMaxLength(200)
|
|
.HasColumnType("nvarchar(200)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("Slug")
|
|
.IsUnique();
|
|
|
|
b.ToTable("Tafsirs");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.TafsirEpisode", b =>
|
|
{
|
|
b.Property<Guid>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<string>("AudioUrl")
|
|
.IsRequired()
|
|
.HasColumnType("nvarchar(max)");
|
|
|
|
b.Property<int>("AyahNumber")
|
|
.HasColumnType("int");
|
|
|
|
b.Property<int>("DurationSeconds")
|
|
.HasColumnType("int");
|
|
|
|
b.Property<int>("SortOrder")
|
|
.HasColumnType("int");
|
|
|
|
b.Property<string>("Summary")
|
|
.HasColumnType("nvarchar(max)");
|
|
|
|
b.Property<int>("SurahId")
|
|
.HasColumnType("int");
|
|
|
|
b.Property<Guid>("TafsirId")
|
|
.HasColumnType("uniqueidentifier");
|
|
|
|
b.Property<string>("Title")
|
|
.IsRequired()
|
|
.HasMaxLength(300)
|
|
.HasColumnType("nvarchar(300)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("SurahId");
|
|
|
|
b.HasIndex("TafsirId", "SortOrder");
|
|
|
|
b.ToTable("Episodes");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Ayah", b =>
|
|
{
|
|
b.HasOne("TafsirQuran.Domain.Entities.Surah", "Surah")
|
|
.WithMany("Ayahs")
|
|
.HasForeignKey("SurahId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("Surah");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Bookmark", b =>
|
|
{
|
|
b.HasOne("TafsirQuran.Domain.Entities.TafsirEpisode", "Episode")
|
|
.WithMany()
|
|
.HasForeignKey("EpisodeId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("TafsirQuran.Domain.Entities.AppUser", "User")
|
|
.WithMany("Bookmarks")
|
|
.HasForeignKey("UserId");
|
|
|
|
b.Navigation("Episode");
|
|
|
|
b.Navigation("User");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Favorite", b =>
|
|
{
|
|
b.HasOne("TafsirQuran.Domain.Entities.TafsirEpisode", "Episode")
|
|
.WithMany()
|
|
.HasForeignKey("EpisodeId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("TafsirQuran.Domain.Entities.AppUser", "User")
|
|
.WithMany("Favorites")
|
|
.HasForeignKey("UserId");
|
|
|
|
b.Navigation("Episode");
|
|
|
|
b.Navigation("User");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.ListeningProgress", b =>
|
|
{
|
|
b.HasOne("TafsirQuran.Domain.Entities.TafsirEpisode", "Episode")
|
|
.WithMany()
|
|
.HasForeignKey("EpisodeId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("TafsirQuran.Domain.Entities.AppUser", "User")
|
|
.WithMany("ListeningProgresses")
|
|
.HasForeignKey("UserId");
|
|
|
|
b.Navigation("Episode");
|
|
|
|
b.Navigation("User");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.TafsirEpisode", b =>
|
|
{
|
|
b.HasOne("TafsirQuran.Domain.Entities.Surah", "Surah")
|
|
.WithMany("Episodes")
|
|
.HasForeignKey("SurahId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("TafsirQuran.Domain.Entities.Tafsir", "Tafsir")
|
|
.WithMany("Episodes")
|
|
.HasForeignKey("TafsirId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("Surah");
|
|
|
|
b.Navigation("Tafsir");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.AppUser", b =>
|
|
{
|
|
b.Navigation("Bookmarks");
|
|
|
|
b.Navigation("Favorites");
|
|
|
|
b.Navigation("ListeningProgresses");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Surah", b =>
|
|
{
|
|
b.Navigation("Ayahs");
|
|
|
|
b.Navigation("Episodes");
|
|
});
|
|
|
|
modelBuilder.Entity("TafsirQuran.Domain.Entities.Tafsir", b =>
|
|
{
|
|
b.Navigation("Episodes");
|
|
});
|
|
#pragma warning restore 612, 618
|
|
}
|
|
}
|
|
}
|