//
using System;
using Blueprint.Infra.Database;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
#nullable disable
namespace Blueprint.Infra.Migrations
{
[DbContext(typeof(MyDbContext))]
partial class MyDbContextModelSnapshot : ModelSnapshot
{
protected override void BuildModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "8.0.10")
.HasAnnotation("Relational:MaxIdentifierLength", 64);
MySqlModelBuilderExtensions.AutoIncrementColumns(modelBuilder);
modelBuilder.Entity("Blueprint.Core.Entities.Category", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("int");
MySqlPropertyBuilderExtensions.UseMySqlIdentityColumn(b.Property("Id"));
b.Property("Content")
.HasColumnType("longtext");
b.Property("CoverImage")
.HasColumnType("longtext");
b.Property("Date")
.HasColumnType("datetime(6)");
b.Property("Modified")
.HasColumnType("datetime(6)");
b.Property("Name")
.HasColumnType("longtext");
b.Property("Status")
.HasColumnType("tinyint(1)");
b.Property("Title")
.HasColumnType("longtext");
b.HasKey("Id");
b.ToTable("Category");
b.HasData(
new
{
Id = 1,
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6934),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6935),
Name = "Item 1",
Status = true
},
new
{
Id = 2,
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6937),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6937),
Name = "Item 2",
Status = true
});
});
modelBuilder.Entity("Blueprint.Core.Entities.Product", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("int");
MySqlPropertyBuilderExtensions.UseMySqlIdentityColumn(b.Property("Id"));
b.Property("CategoryId")
.HasColumnType("int");
b.Property("Content")
.HasColumnType("longtext");
b.Property("CoverImage")
.HasColumnType("longtext");
b.Property("Date")
.HasColumnType("datetime(6)");
b.Property("Modified")
.HasColumnType("datetime(6)");
b.Property("Name")
.HasColumnType("longtext");
b.Property("Status")
.HasColumnType("tinyint(1)");
b.Property("Title")
.HasColumnType("longtext");
b.HasKey("Id");
b.HasIndex("CategoryId");
b.ToTable("Product");
b.HasData(
new
{
Id = 1,
CategoryId = 1,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/keo-dan-gach-TOA-Premtilmiue.png",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6954),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6954),
Name = "Item 1",
Status = true
},
new
{
Id = 2,
CategoryId = 2,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/keo-dan-gach-TOA-Protile.png",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6956),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6957),
Name = "Item 2",
Status = true
},
new
{
Id = 3,
CategoryId = 2,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/keo-dan-gach-TOA-Supertile.png",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6959),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6959),
Name = "Item 3",
Status = true
},
new
{
Id = 4,
CategoryId = 1,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/Silicone-Sealant-HP.jpg",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6961),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6962),
Name = "Item 4",
Status = true
},
new
{
Id = 5,
CategoryId = 2,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/Silicone-TOA-.jpg",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6964),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6964),
Name = "Item 5",
Status = true
},
new
{
Id = 6,
CategoryId = 2,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/Silicone-TOA-1.jpg",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6966),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6966),
Name = "Item 6",
Status = true
},
new
{
Id = 7,
CategoryId = 1,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/Silicone-TOA-303.jpg",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6968),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6969),
Name = "Item 7",
Status = true
},
new
{
Id = 8,
CategoryId = 2,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/keo-dan-gach-TOA-Premtilmiue.png",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6971),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6971),
Name = "Item 8",
Status = true
},
new
{
Id = 9,
CategoryId = 2,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/keo-dan-gach-TOA-Protile.png",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6973),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6973),
Name = "Item 9",
Status = true
},
new
{
Id = 10,
CategoryId = 1,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/keo-dan-gach-TOA-Supertile.png",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6975),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6976),
Name = "Item 10",
Status = true
},
new
{
Id = 11,
CategoryId = 2,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/Silicone-Sealant-HP.jpg",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6978),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6978),
Name = "Item 11",
Status = true
},
new
{
Id = 12,
CategoryId = 2,
CoverImage = "https://innocons.s3.ap-southeast-1.amazonaws.com/products/Silicone-TOA-.jpg",
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6980),
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6980),
Name = "Item 12",
Status = true
});
});
modelBuilder.Entity("Blueprint.Core.Entities.User", b =>
{
b.Property("Id")
.ValueGeneratedOnAdd()
.HasColumnType("int");
MySqlPropertyBuilderExtensions.UseMySqlIdentityColumn(b.Property("Id"));
b.Property("Date")
.HasColumnType("datetime(6)");
b.Property("Email")
.HasColumnType("longtext");
b.Property("Modified")
.HasColumnType("datetime(6)");
b.Property("Name")
.HasColumnType("longtext");
b.Property("Picture")
.HasColumnType("longtext");
b.Property("Role")
.HasColumnType("int");
b.Property("Status")
.HasColumnType("tinyint(1)");
b.HasKey("Id");
b.ToTable("User");
b.HasData(
new
{
Id = 1,
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6827),
Email = "",
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6827),
Name = "Test",
Role = 0,
Status = true
},
new
{
Id = 2,
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6830),
Email = "truongdxfx08031@funix.edu.vn",
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6830),
Name = "Truong Dang",
Role = 0,
Status = true
},
new
{
Id = 3,
Date = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6832),
Email = "truonghusk17aws1@gmail.com",
Modified = new DateTime(2025, 4, 6, 6, 56, 0, 937, DateTimeKind.Local).AddTicks(6833),
Name = "Thai Son",
Role = 0,
Status = true
});
});
modelBuilder.Entity("Blueprint.Core.Entities.Product", b =>
{
b.HasOne("Blueprint.Core.Entities.Category", "Category")
.WithMany("Products")
.HasForeignKey("CategoryId")
.OnDelete(DeleteBehavior.Cascade);
b.Navigation("Category");
});
modelBuilder.Entity("Blueprint.Core.Entities.Category", b =>
{
b.Navigation("Products");
});
#pragma warning restore 612, 618
}
}
}