Отчистика кода

This commit is contained in:
2025-04-18 17:32:23 +04:00
parent 9a711c5a9d
commit 02d35d72d2
11 changed files with 1181 additions and 1229 deletions
+2 -2
View File
@@ -1,5 +1,5 @@
using Pf2eModel.Model.Base;
using Pf2eModel.Model;
using Pf2eModel.Model;
using Pf2eModel.Model.Base;
using Pf2eModel.Model.Enum;
using System.Reflection;
+15 -16
View File
@@ -2,15 +2,15 @@
#nullable disable
namespace Pf2eModel.Migrations
namespace Pf2eModel.Migrations;
/// <inheritdoc />
public partial class Function : Migration
{
/// <inheritdoc />
public partial class Function : Migration
protected override void Up(MigrationBuilder migrationBuilder)
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.Sql("""
migrationBuilder.Sql("""
CREATE OR REPLACE FUNCTION f_truncate_tables()
RETURNS void
LANGUAGE plpgsql AS
@@ -27,7 +27,7 @@ BEGIN
END
$func$;
""");
migrationBuilder.Sql("""
migrationBuilder.Sql("""
CREATE OR REPLACE FUNCTION f_drop_tables()
RETURNS void
LANGUAGE plpgsql AS
@@ -43,7 +43,7 @@ BEGIN
END
$func$;
""");
migrationBuilder.Sql("""
migrationBuilder.Sql("""
CREATE OR REPLACE FUNCTION f_permission_tables(_username text)
RETURNS void
LANGUAGE plpgsql AS
@@ -62,14 +62,13 @@ BEGIN
END
$func$;
""");
}
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.Sql("DROP FUNCTION f_truncate_tables;");
migrationBuilder.Sql("DROP FUNCTION f_drop_tables;");
migrationBuilder.Sql("DROP FUNCTION f_permission_tables;");
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.Sql("DROP FUNCTION f_truncate_tables;");
migrationBuilder.Sql("DROP FUNCTION f_drop_tables;");
migrationBuilder.Sql("DROP FUNCTION f_permission_tables;");
}
}
File diff suppressed because it is too large Load Diff
@@ -1,5 +1,4 @@
using Microsoft.EntityFrameworkCore;
using Newtonsoft.Json;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
+2 -2
View File
@@ -18,10 +18,10 @@ public partial class Action : IEntity
[Column(Order = 3)]
public int? Actions { get; set; } = null;
[Column(Order = 4)]
[Column(Order = 4)]
public int? MaxActions { get; set; } = null;
[Column(Order = 5)]
[Column(Order = 5)]
public bool IsReaction { get; set; } = false;
[Column(Order = 6)]
+1 -3
View File
@@ -1,5 +1,4 @@
using LinqToDB.Common;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata.Builders;
using Pf2eModel.Model.Base;
using Pf2eModel.Model.Base.Keywords;
@@ -14,7 +13,6 @@ using Pf2eModel.Model.Structure.ClassRelation;
using Pf2eModel.Model.Structure.DeityRelation;
using Pf2eModel.Model.Structure.FeatRelation;
using Pf2eModel.Model.Structure.SpellRelation;
using System.Reflection;
namespace Pf2eModel.Model;