From e9f09559b80b83e12727fd24e90d8c7f31d64856 Mon Sep 17 00:00:00 2001 From: Jake Mannens Date: Tue, 29 Aug 2023 13:02:41 +1000 Subject: Added width and height properties to media objects --- Migrations/20230829010104_MediaSize.cs | 40 ++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 Migrations/20230829010104_MediaSize.cs (limited to 'Migrations/20230829010104_MediaSize.cs') diff --git a/Migrations/20230829010104_MediaSize.cs b/Migrations/20230829010104_MediaSize.cs new file mode 100644 index 0000000..734064c --- /dev/null +++ b/Migrations/20230829010104_MediaSize.cs @@ -0,0 +1,40 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace HyperBooru.Migrations +{ + /// + public partial class MediaSize : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.AddColumn( + name: "Height", + table: "Media", + type: "integer", + nullable: false, + defaultValue: 0); + + migrationBuilder.AddColumn( + name: "Width", + table: "Media", + type: "integer", + nullable: false, + defaultValue: 0); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropColumn( + name: "Height", + table: "Media"); + + migrationBuilder.DropColumn( + name: "Width", + table: "Media"); + } + } +} -- cgit v1.3