DamageAssessment_Backend/DamageAssesmentApi/DamageAssesment.Api.Answers/Migrations/20230816214724_InitialCreate.cs
2023-08-18 17:14:41 -04:00

38 lines
1.3 KiB
C#

using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace DamageAssesment.Api.Answers.Migrations
{
/// <inheritdoc />
public partial class InitialCreate : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "Answers",
columns: table => new
{
Id = table.Column<int>(type: "int", nullable: false)
.Annotation("SqlServer:Identity", "1, 1"),
QuestionId = table.Column<int>(type: "int", nullable: false),
AnswerText = table.Column<string>(type: "nvarchar(250)", maxLength: 250, nullable: false),
Comment = table.Column<string>(type: "nvarchar(max)", nullable: false),
SurveyResponseId = table.Column<int>(type: "int", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_Answers", x => x.Id);
});
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "Answers");
}
}
}