using System; using Microsoft.EntityFrameworkCore.Migrations; #nullable disable namespace DataModel.Migrations { public partial class _202206AddSettings : Migration { protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.CreateTable( name: "Settings", columns: table => new { Id = table.Column(type: "INTEGER", nullable: false) .Annotation("Sqlite:Autoincrement", true), Name = table.Column(type: "TEXT", nullable: false), TextValue = table.Column(type: "TEXT", nullable: false), BoolValue = table.Column(type: "INTEGER", nullable: false), IntegerValue = table.Column(type: "INTEGER", nullable: false), GuidValue = table.Column(type: "TEXT", nullable: false) }, constraints: table => { table.PrimaryKey("PK_Settings", x => x.Id); }); migrationBuilder.CreateIndex( name: "IX_Settings_BoolValue", table: "Settings", column: "BoolValue"); migrationBuilder.CreateIndex( name: "IX_Settings_GuidValue", table: "Settings", column: "GuidValue"); migrationBuilder.CreateIndex( name: "IX_Settings_Id", table: "Settings", column: "Id"); migrationBuilder.CreateIndex( name: "IX_Settings_IntegerValue", table: "Settings", column: "IntegerValue"); migrationBuilder.CreateIndex( name: "IX_Settings_Name", table: "Settings", column: "Name", unique: true); migrationBuilder.CreateIndex( name: "IX_Settings_TextValue", table: "Settings", column: "TextValue"); } protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "Settings"); } } }