src/Saas.Admin/Saas.Admin.Service/Migrations/20220405012345_InitialCreate.cs (38 lines of code) (raw):

using Microsoft.EntityFrameworkCore.Migrations; #nullable disable namespace Saas.Admin.Service.Migrations { public partial class InitialCreate : Migration { protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.CreateTable( name: "Tenants", columns: table => new { Id = table.Column<Guid>(type: "uniqueidentifier", nullable: false), Name = table.Column<string>(type: "nvarchar(max)", nullable: false), Route = table.Column<string>(type: "nvarchar(450)", nullable: false), ProductTierId = table.Column<int>(type: "int", nullable: false), CategoryId = table.Column<int>(type: "int", nullable: false), CreatorEmail = table.Column<string>(type: "nvarchar(max)", nullable: false), CreatedTime = table.Column<DateTime>(type: "datetime2", nullable: false, defaultValue: new DateTime(2022, 4, 5, 1, 23, 45, 159, DateTimeKind.Utc).AddTicks(9974)), ConcurrencyToken = table.Column<byte[]>(type: "rowversion", rowVersion: true, nullable: true) }, constraints: table => { table.PrimaryKey("PK_Tenants", x => x.Id); }); migrationBuilder.CreateIndex( name: "IX_Tenants_Route", table: "Tenants", column: "Route", unique: true); } protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "Tenants"); } } }