using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace NexusReader.Data.Migrations
{
    /// <inheritdoc />
    public partial class AddEbookProgressAndChapter : Migration
    {
        /// <inheritdoc />
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.AddColumn<string>(
                name: "LastChapter",
                table: "Ebooks",
                type: "character varying(255)",
                maxLength: 255,
                nullable: true);

            migrationBuilder.AddColumn<double>(
                name: "Progress",
                table: "Ebooks",
                type: "double precision",
                nullable: false,
                defaultValue: 0.0);
        }

        /// <inheritdoc />
        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropColumn(
                name: "LastChapter",
                table: "Ebooks");

            migrationBuilder.DropColumn(
                name: "Progress",
                table: "Ebooks");
        }
    }
}
