feat(dal): Индексы для RobotHistory
This commit is contained in:
3791
PARR.DAL/Migrations/20260415000357_tblRobotHistoryAddIndex.Designer.cs
generated
Normal file
3791
PARR.DAL/Migrations/20260415000357_tblRobotHistoryAddIndex.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,55 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace PARR.DAL.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class tblRobotHistoryAddIndex : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropIndex(
|
||||
name: "IX_RobotHistories_HistoryLevel",
|
||||
table: "RobotHistories");
|
||||
|
||||
migrationBuilder.DropIndex(
|
||||
name: "IX_RobotHistories_RobotConfigurationId",
|
||||
table: "RobotHistories");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_RobotHistories_HistoryLevel_DateCreated",
|
||||
table: "RobotHistories",
|
||||
columns: new[] { "HistoryLevel", "DateCreated" },
|
||||
descending: new[] { false, true });
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_RobotHistories_RobotConfigurationId_DateCreated",
|
||||
table: "RobotHistories",
|
||||
columns: new[] { "RobotConfigurationId", "DateCreated" });
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropIndex(
|
||||
name: "IX_RobotHistories_HistoryLevel_DateCreated",
|
||||
table: "RobotHistories");
|
||||
|
||||
migrationBuilder.DropIndex(
|
||||
name: "IX_RobotHistories_RobotConfigurationId_DateCreated",
|
||||
table: "RobotHistories");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_RobotHistories_HistoryLevel",
|
||||
table: "RobotHistories",
|
||||
column: "HistoryLevel");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_RobotHistories_RobotConfigurationId",
|
||||
table: "RobotHistories",
|
||||
column: "RobotConfigurationId");
|
||||
}
|
||||
}
|
||||
}
|
||||
3793
PARR.DAL/Migrations/20260415002940_tblRobotHistoryAddIndex2.Designer.cs
generated
Normal file
3793
PARR.DAL/Migrations/20260415002940_tblRobotHistoryAddIndex2.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,27 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace PARR.DAL.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class tblRobotHistoryAddIndex2 : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_RobotHistories_DateCreated",
|
||||
table: "RobotHistories",
|
||||
column: "DateCreated");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropIndex(
|
||||
name: "IX_RobotHistories_DateCreated",
|
||||
table: "RobotHistories");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1900,12 +1900,15 @@ namespace PARR.DAL.Migrations
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("HistoryLevel");
|
||||
|
||||
b.HasIndex("RobotConfigurationId");
|
||||
b.HasIndex("DateCreated");
|
||||
|
||||
b.HasIndex("TaskStatusCode");
|
||||
|
||||
b.HasIndex("HistoryLevel", "DateCreated")
|
||||
.IsDescending(false, true);
|
||||
|
||||
b.HasIndex("RobotConfigurationId", "DateCreated");
|
||||
|
||||
b.ToTable("RobotHistories");
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user