41 lines
1.1 KiB
C#
41 lines
1.1 KiB
C#
using System;
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace SPMS.Infrastructure.Migrations
|
|
{
|
|
/// <inheritdoc />
|
|
public partial class AddFileEntitySoftDelete : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.AddColumn<DateTime>(
|
|
name: "DeletedAt",
|
|
table: "File",
|
|
type: "datetime(6)",
|
|
nullable: true);
|
|
|
|
migrationBuilder.AddColumn<bool>(
|
|
name: "IsDeleted",
|
|
table: "File",
|
|
type: "tinyint(1)",
|
|
nullable: false,
|
|
defaultValue: false);
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropColumn(
|
|
name: "DeletedAt",
|
|
table: "File");
|
|
|
|
migrationBuilder.DropColumn(
|
|
name: "IsDeleted",
|
|
table: "File");
|
|
}
|
|
}
|
|
}
|