using System;
using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace Infrastructure.Migrations.AppDb
{
    /// <inheritdoc />
    public partial class AddYouTubeFieldsToChannel : Migration
    {
        /// <inheritdoc />
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.AddColumn<string>(
                name: "BannerUrl",
                table: "Channel",
                type: "nvarchar(max)",
                nullable: true);

            migrationBuilder.AddColumn<string>(
                name: "Description",
                table: "Channel",
                type: "nvarchar(max)",
                nullable: true);

            migrationBuilder.AddColumn<string>(
                name: "Email",
                table: "Channel",
                type: "nvarchar(max)",
                nullable: true);

            migrationBuilder.AddColumn<long>(
                name: "SubscriberCount",
                table: "Channel",
                type: "bigint",
                nullable: false,
                defaultValue: 0L);

            migrationBuilder.AddColumn<string>(
                name: "ThumbnailUrl",
                table: "Channel",
                type: "nvarchar(max)",
                nullable: true);

            migrationBuilder.AddColumn<long>(
                name: "VideoCount",
                table: "Channel",
                type: "bigint",
                nullable: false,
                defaultValue: 0L);

            migrationBuilder.AddColumn<long>(
                name: "ViewCount",
                table: "Channel",
                type: "bigint",
                nullable: false,
                defaultValue: 0L);

            migrationBuilder.AddColumn<string>(
                name: "YouTubeChannelID",
                table: "Channel",
                type: "nvarchar(max)",
                nullable: true);

            migrationBuilder.AddColumn<DateTime>(
                name: "YouTubePublishedAt",
                table: "Channel",
                type: "datetime2",
                nullable: true);
        }

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

            migrationBuilder.DropColumn(
                name: "Description",
                table: "Channel");

            migrationBuilder.DropColumn(
                name: "Email",
                table: "Channel");

            migrationBuilder.DropColumn(
                name: "SubscriberCount",
                table: "Channel");

            migrationBuilder.DropColumn(
                name: "ThumbnailUrl",
                table: "Channel");

            migrationBuilder.DropColumn(
                name: "VideoCount",
                table: "Channel");

            migrationBuilder.DropColumn(
                name: "ViewCount",
                table: "Channel");

            migrationBuilder.DropColumn(
                name: "YouTubeChannelID",
                table: "Channel");

            migrationBuilder.DropColumn(
                name: "YouTubePublishedAt",
                table: "Channel");
        }
    }
}
