mirror of
https://github.com/Kareadita/Kavita.git
synced 2025-06-20 05:54:15 -04:00
* Bump loader-utils from 2.0.2 to 2.0.3 in /UI/Web Bumps [loader-utils](https://github.com/webpack/loader-utils) from 2.0.2 to 2.0.3. - [Release notes](https://github.com/webpack/loader-utils/releases) - [Changelog](https://github.com/webpack/loader-utils/blob/v2.0.3/CHANGELOG.md) - [Commits](https://github.com/webpack/loader-utils/compare/v2.0.2...v2.0.3) --- updated-dependencies: - dependency-name: loader-utils dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> * Fixed is want to read coming back as a string and not working correctly. * Changed from to Continue to be more explicit * Added the first migration which exports data as a csv in temp/. This is the backup in case data is lost in the migration. * Note for later * Fixed the migration for the series relation so when deleting any series on any edge of the relationship, the SeriesRelation row deletes. * Change buttons back to titles on series detail page * Wrote the code to import relations from the backup. * Added an additional version check to avoid file io on migration. * Code cleanup Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
62 lines
2.1 KiB
C#
62 lines
2.1 KiB
C#
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace API.Data.Migrations
|
|
{
|
|
public partial class SeriesRelationChange : Migration
|
|
{
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropForeignKey(
|
|
name: "FK_SeriesRelation_Series_SeriesId",
|
|
table: "SeriesRelation");
|
|
|
|
migrationBuilder.DropForeignKey(
|
|
name: "FK_SeriesRelation_Series_TargetSeriesId",
|
|
table: "SeriesRelation");
|
|
|
|
migrationBuilder.AddForeignKey(
|
|
name: "FK_SeriesRelation_Series_SeriesId",
|
|
table: "SeriesRelation",
|
|
column: "SeriesId",
|
|
principalTable: "Series",
|
|
principalColumn: "Id",
|
|
onDelete: ReferentialAction.Cascade);
|
|
|
|
migrationBuilder.AddForeignKey(
|
|
name: "FK_SeriesRelation_Series_TargetSeriesId",
|
|
table: "SeriesRelation",
|
|
column: "TargetSeriesId",
|
|
principalTable: "Series",
|
|
principalColumn: "Id",
|
|
onDelete: ReferentialAction.Cascade);
|
|
}
|
|
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropForeignKey(
|
|
name: "FK_SeriesRelation_Series_SeriesId",
|
|
table: "SeriesRelation");
|
|
|
|
migrationBuilder.DropForeignKey(
|
|
name: "FK_SeriesRelation_Series_TargetSeriesId",
|
|
table: "SeriesRelation");
|
|
|
|
migrationBuilder.AddForeignKey(
|
|
name: "FK_SeriesRelation_Series_SeriesId",
|
|
table: "SeriesRelation",
|
|
column: "SeriesId",
|
|
principalTable: "Series",
|
|
principalColumn: "Id");
|
|
|
|
migrationBuilder.AddForeignKey(
|
|
name: "FK_SeriesRelation_Series_TargetSeriesId",
|
|
table: "SeriesRelation",
|
|
column: "TargetSeriesId",
|
|
principalTable: "Series",
|
|
principalColumn: "Id");
|
|
}
|
|
}
|
|
}
|