41 lines
1.2 KiB
C#
41 lines
1.2 KiB
C#
using Microsoft.EntityFrameworkCore.Migrations;
|
|
using NpgsqlTypes;
|
|
|
|
#nullable disable
|
|
|
|
namespace OpenArchival.DataAccess.Migrations
|
|
{
|
|
/// <inheritdoc />
|
|
public partial class AddedFileTextContentsSearchVector : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.AddColumn<string>(
|
|
name: "FileContentSearchString",
|
|
table: "ArtifactGroupings",
|
|
type: "text",
|
|
nullable: false,
|
|
defaultValue: "");
|
|
|
|
migrationBuilder.AddColumn<NpgsqlTsVector>(
|
|
name: "FileContentSearchVector",
|
|
table: "ArtifactGroupings",
|
|
type: "tsvector",
|
|
nullable: false);
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropColumn(
|
|
name: "FileContentSearchString",
|
|
table: "ArtifactGroupings");
|
|
|
|
migrationBuilder.DropColumn(
|
|
name: "FileContentSearchVector",
|
|
table: "ArtifactGroupings");
|
|
}
|
|
}
|
|
}
|