using System; using Microsoft.EntityFrameworkCore.Migrations; #nullable disable #pragma warning disable CA1814 // Prefer jagged arrays over multidimensional namespace Shared.Infrastructure.Migrations { /// public partial class SeedInitialData : Migration { /// protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.AlterDatabase() .Annotation("MySql:CharSet", "utf8mb4"); migrationBuilder.CreateTable( name: "__MODULE__", columns: table => new { Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), Status = table.Column(type: "int", nullable: false), Date = table.Column(type: "datetime(6)", nullable: false), Modified = table.Column(type: "datetime(6)", nullable: false) }, constraints: table => { table.PrimaryKey("PK___MODULE__", x => x.Id); }) .Annotation("MySql:CharSet", "utf8mb4"); migrationBuilder.CreateTable( name: "User", columns: table => new { Id = table.Column(type: "char(36)", nullable: false, collation: "ascii_general_ci"), Name = table.Column(type: "longtext", nullable: true) .Annotation("MySql:CharSet", "utf8mb4"), Email = table.Column(type: "longtext", nullable: true) .Annotation("MySql:CharSet", "utf8mb4"), Picture = table.Column(type: "longtext", nullable: true) .Annotation("MySql:CharSet", "utf8mb4"), Role = table.Column(type: "int", nullable: false), Status = table.Column(type: "int", nullable: false), Date = table.Column(type: "datetime(6)", nullable: false), Modified = table.Column(type: "datetime(6)", nullable: false) }, constraints: table => { table.PrimaryKey("PK_User", x => x.Id); }) .Annotation("MySql:CharSet", "utf8mb4"); migrationBuilder.InsertData( table: "User", columns: new[] { "Id", "Date", "Email", "Modified", "Name", "Picture", "Role", "Status" }, values: new object[,] { { new Guid("11111111-1111-1111-1111-111111111111"), new DateTime(2026, 2, 10, 21, 56, 10, 153, DateTimeKind.Local).AddTicks(5286), "", new DateTime(2026, 2, 10, 21, 56, 10, 153, DateTimeKind.Local).AddTicks(5300), "Test", null, 1, 1 }, { new Guid("22222222-2222-2222-2222-222222222222"), new DateTime(2026, 2, 10, 21, 56, 10, 153, DateTimeKind.Local).AddTicks(6780), "truongdxfx08031@funix.edu.vn", new DateTime(2026, 2, 10, 21, 56, 10, 153, DateTimeKind.Local).AddTicks(6782), "Truong Dang", null, 0, 1 }, { new Guid("33333333-3333-3333-3333-333333333333"), new DateTime(2026, 2, 10, 21, 56, 10, 153, DateTimeKind.Local).AddTicks(6788), "truonghusk17aws1@gmail.com", new DateTime(2026, 2, 10, 21, 56, 10, 153, DateTimeKind.Local).AddTicks(6789), "Thai Son", null, 0, 1 } }); migrationBuilder.InsertData( table: "__MODULE__", columns: new[] { "Id", "Date", "Modified", "Status" }, values: new object[] { new Guid("11111111-1111-1111-1111-111111111111"), new DateTime(2026, 2, 10, 21, 56, 10, 155, DateTimeKind.Local).AddTicks(6644), new DateTime(2026, 2, 10, 21, 56, 10, 155, DateTimeKind.Local).AddTicks(6652), 1 }); } /// protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "__MODULE__"); migrationBuilder.DropTable( name: "User"); } } }