22668e8a8f
- migration x nuovo campo da gestire - inizio divisione controllo TaskList x avere gestione gruppi
43 lines
1.3 KiB
C#
43 lines
1.3 KiB
C#
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace MP.TaskMan.Migrations
|
|
{
|
|
public partial class AddTaskGroup : Migration
|
|
{
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.AddColumn<int>(
|
|
name: "Group",
|
|
table: "TaskList",
|
|
type: "int",
|
|
nullable: false,
|
|
defaultValue: 1);
|
|
|
|
migrationBuilder.CreateTable(
|
|
name: "DbSetTaskResult",
|
|
columns: table => new
|
|
{
|
|
Task = table.Column<string>(type: "nvarchar(450)", nullable: false),
|
|
ExecResult = table.Column<int>(type: "int", nullable: false),
|
|
TextResult = table.Column<string>(type: "nvarchar(max)", nullable: true)
|
|
},
|
|
constraints: table =>
|
|
{
|
|
table.PrimaryKey("PK_DbSetTaskResult", x => x.Task);
|
|
});
|
|
}
|
|
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropTable(
|
|
name: "DbSetTaskResult");
|
|
|
|
migrationBuilder.DropColumn(
|
|
name: "Group",
|
|
table: "TaskList");
|
|
}
|
|
}
|
|
}
|