using System; using Microsoft.EntityFrameworkCore.Migrations; using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata; namespace UnivateProperties_API.Migrations { public partial class GeorgeNew : Migration { protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.DropColumn( name: "CreatedBy", table: "Properties"); migrationBuilder.AddColumn( name: "GCRecord", table: "Properties", nullable: true); migrationBuilder.CreateTable( name: "SearchLogs", columns: table => new { Id = table.Column(nullable: false) .Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.SerialColumn), Created = table.Column(nullable: false), Modified = table.Column(nullable: false), ModifiedBy = table.Column(nullable: true), UserID = table.Column(nullable: true), Search = table.Column(nullable: true) }, constraints: table => { table.PrimaryKey("PK_SearchLogs", x => x.Id); }); } protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "SearchLogs"); migrationBuilder.DropColumn( name: "GCRecord", table: "Properties"); migrationBuilder.AddColumn( name: "CreatedBy", table: "Properties", nullable: true); } } }