torrent-man/Migrations/20250312203308_AddUIFeatures.cs
Claude 9e544456db Initial commit with UI fixes for dark mode
This repository contains Transmission RSS Manager with the following changes:
- Fixed dark mode navigation tab visibility issue
- Improved text contrast in dark mode throughout the app
- Created dedicated dark-mode.css for better organization
- Enhanced JavaScript for dynamic styling in dark mode
- Added complete installation scripts

🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
2025-03-13 17:16:41 +00:00

180 lines
5.7 KiB
C#

using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
#nullable disable
namespace TransmissionRssManager.Migrations
{
/// <inheritdoc />
public partial class AddUIFeatures : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<string>(
name: "Category",
table: "Torrents",
type: "text",
nullable: true);
migrationBuilder.AddColumn<double>(
name: "DownloadSpeed",
table: "Torrents",
type: "double precision",
nullable: false,
defaultValue: 0.0);
migrationBuilder.AddColumn<long>(
name: "DownloadedEver",
table: "Torrents",
type: "bigint",
nullable: false,
defaultValue: 0L);
migrationBuilder.AddColumn<bool>(
name: "HasMetadata",
table: "Torrents",
type: "boolean",
nullable: false,
defaultValue: false);
migrationBuilder.AddColumn<int>(
name: "PeersConnected",
table: "Torrents",
type: "integer",
nullable: false,
defaultValue: 0);
migrationBuilder.AddColumn<string>(
name: "TransmissionInstance",
table: "Torrents",
type: "text",
nullable: true);
migrationBuilder.AddColumn<double>(
name: "UploadSpeed",
table: "Torrents",
type: "double precision",
nullable: false,
defaultValue: 0.0);
migrationBuilder.AddColumn<long>(
name: "UploadedEver",
table: "Torrents",
type: "bigint",
nullable: false,
defaultValue: 0L);
migrationBuilder.AddColumn<string>(
name: "DefaultCategory",
table: "RssFeeds",
type: "text",
nullable: true);
migrationBuilder.AddColumn<int>(
name: "ErrorCount",
table: "RssFeeds",
type: "integer",
nullable: false,
defaultValue: 0);
migrationBuilder.AddColumn<int>(
name: "MaxHistoryItems",
table: "RssFeeds",
type: "integer",
nullable: false,
defaultValue: 0);
migrationBuilder.AddColumn<string>(
name: "Schedule",
table: "RssFeeds",
type: "text",
nullable: false,
defaultValue: "");
migrationBuilder.AddColumn<string>(
name: "TransmissionInstanceId",
table: "RssFeeds",
type: "text",
nullable: true);
migrationBuilder.CreateTable(
name: "SystemLogs",
columns: table => new
{
Id = table.Column<int>(type: "integer", nullable: false)
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
Timestamp = table.Column<DateTime>(type: "timestamp with time zone", nullable: false),
Level = table.Column<string>(type: "text", nullable: false),
Message = table.Column<string>(type: "text", nullable: false),
Context = table.Column<string>(type: "text", nullable: true),
Properties = table.Column<string>(type: "text", nullable: true)
},
constraints: table =>
{
table.PrimaryKey("PK_SystemLogs", x => x.Id);
});
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "SystemLogs");
migrationBuilder.DropColumn(
name: "Category",
table: "Torrents");
migrationBuilder.DropColumn(
name: "DownloadSpeed",
table: "Torrents");
migrationBuilder.DropColumn(
name: "DownloadedEver",
table: "Torrents");
migrationBuilder.DropColumn(
name: "HasMetadata",
table: "Torrents");
migrationBuilder.DropColumn(
name: "PeersConnected",
table: "Torrents");
migrationBuilder.DropColumn(
name: "TransmissionInstance",
table: "Torrents");
migrationBuilder.DropColumn(
name: "UploadSpeed",
table: "Torrents");
migrationBuilder.DropColumn(
name: "UploadedEver",
table: "Torrents");
migrationBuilder.DropColumn(
name: "DefaultCategory",
table: "RssFeeds");
migrationBuilder.DropColumn(
name: "ErrorCount",
table: "RssFeeds");
migrationBuilder.DropColumn(
name: "MaxHistoryItems",
table: "RssFeeds");
migrationBuilder.DropColumn(
name: "Schedule",
table: "RssFeeds");
migrationBuilder.DropColumn(
name: "TransmissionInstanceId",
table: "RssFeeds");
}
}
}