change snapshot
This commit is contained in:
11806
CompanyManagment.EFCore/Migrations/20260101102440_RecreateSnapshot.Designer.cs
generated
Normal file
11806
CompanyManagment.EFCore/Migrations/20260101102440_RecreateSnapshot.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,204 @@
|
||||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace CompanyManagment.EFCore.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RecreateSnapshot : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ClassificationSchemes",
|
||||
columns: table => new
|
||||
{
|
||||
id = table.Column<long>(type: "bigint", nullable: false)
|
||||
.Annotation("SqlServer:Identity", "1, 1"),
|
||||
IncludingDateGr = table.Column<DateTime>(type: "datetime2", nullable: false),
|
||||
ExecutionDateGr = table.Column<DateTime>(type: "datetime2", nullable: false),
|
||||
EndSchemeDateGr = table.Column<DateTime>(type: "datetime2", nullable: true),
|
||||
DesignerFullName = table.Column<string>(type: "nvarchar(50)", maxLength: 50, nullable: true),
|
||||
DesignerPhone = table.Column<string>(type: "nvarchar(20)", maxLength: 20, nullable: true),
|
||||
WorkshopId = table.Column<long>(type: "bigint", nullable: false),
|
||||
TypeOfCoefficient = table.Column<string>(type: "nvarchar(30)", maxLength: 30, nullable: false),
|
||||
CreationDate = table.Column<DateTime>(type: "datetime2", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ClassificationSchemes", x => x.id);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ClassificationGroups",
|
||||
columns: table => new
|
||||
{
|
||||
id = table.Column<long>(type: "bigint", nullable: false)
|
||||
.Annotation("SqlServer:Identity", "1, 1"),
|
||||
GroupNo = table.Column<string>(type: "nvarchar(2)", maxLength: 2, nullable: true),
|
||||
WorkshopId = table.Column<long>(type: "bigint", nullable: false),
|
||||
ClassificationSchemeId = table.Column<long>(type: "bigint", nullable: false),
|
||||
CreationDate = table.Column<DateTime>(type: "datetime2", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ClassificationGroups", x => x.id);
|
||||
table.ForeignKey(
|
||||
name: "FK_ClassificationGroups_ClassificationSchemes_ClassificationSchemeId",
|
||||
column: x => x.ClassificationSchemeId,
|
||||
principalTable: "ClassificationSchemes",
|
||||
principalColumn: "id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ClassificationRialCoefficients",
|
||||
columns: table => new
|
||||
{
|
||||
id = table.Column<long>(type: "bigint", nullable: false)
|
||||
.Annotation("SqlServer:Identity", "1, 1"),
|
||||
ClassificationSchemeId = table.Column<long>(type: "bigint", nullable: false),
|
||||
RialCoefficient = table.Column<double>(type: "float", nullable: false),
|
||||
StartDate = table.Column<DateTime>(type: "datetime2", nullable: false),
|
||||
EndDate = table.Column<DateTime>(type: "datetime2", nullable: false),
|
||||
Year = table.Column<int>(type: "int", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ClassificationRialCoefficients", x => x.id);
|
||||
table.ForeignKey(
|
||||
name: "FK_ClassificationRialCoefficients_ClassificationSchemes_ClassificationSchemeId",
|
||||
column: x => x.ClassificationSchemeId,
|
||||
principalTable: "ClassificationSchemes",
|
||||
principalColumn: "id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ClassificationEmployee",
|
||||
columns: table => new
|
||||
{
|
||||
id = table.Column<long>(type: "bigint", nullable: false)
|
||||
.Annotation("SqlServer:Identity", "1, 1"),
|
||||
WorkshopId = table.Column<long>(type: "bigint", nullable: false),
|
||||
EmployeeId = table.Column<long>(type: "bigint", nullable: false),
|
||||
ClassificationSchemeId = table.Column<long>(type: "bigint", nullable: false),
|
||||
ClassificationGroupId = table.Column<long>(type: "bigint", nullable: false),
|
||||
ClassificationGroupJobId = table.Column<long>(type: "bigint", nullable: false),
|
||||
StartGroupDate = table.Column<DateTime>(type: "datetime2", nullable: true),
|
||||
EndGroupDate = table.Column<DateTime>(type: "datetime2", nullable: true),
|
||||
CreationDate = table.Column<DateTime>(type: "datetime2", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ClassificationEmployee", x => x.id);
|
||||
table.ForeignKey(
|
||||
name: "FK_ClassificationEmployee_ClassificationGroups_ClassificationGroupId",
|
||||
column: x => x.ClassificationGroupId,
|
||||
principalTable: "ClassificationGroups",
|
||||
principalColumn: "id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ClassificationGroupJobs",
|
||||
columns: table => new
|
||||
{
|
||||
id = table.Column<long>(type: "bigint", nullable: false)
|
||||
.Annotation("SqlServer:Identity", "1, 1"),
|
||||
JobId = table.Column<long>(type: "bigint", nullable: false),
|
||||
JobName = table.Column<string>(type: "nvarchar(255)", maxLength: 255, nullable: true),
|
||||
JobCode = table.Column<string>(type: "nvarchar(100)", maxLength: 100, nullable: true),
|
||||
ClassificationGroupId = table.Column<long>(type: "bigint", nullable: false),
|
||||
GroupNo = table.Column<string>(type: "nvarchar(2)", maxLength: 2, nullable: true)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ClassificationGroupJobs", x => x.id);
|
||||
table.ForeignKey(
|
||||
name: "FK_ClassificationGroupJobs_ClassificationGroups_ClassificationGroupId",
|
||||
column: x => x.ClassificationGroupId,
|
||||
principalTable: "ClassificationGroups",
|
||||
principalColumn: "id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ClassificationGroupSalaries",
|
||||
columns: table => new
|
||||
{
|
||||
id = table.Column<long>(type: "bigint", nullable: false)
|
||||
.Annotation("SqlServer:Identity", "1, 1"),
|
||||
ClassificationGroupId = table.Column<long>(type: "bigint", nullable: false),
|
||||
GroupNo = table.Column<string>(type: "nvarchar(2)", maxLength: 2, nullable: true),
|
||||
GroupSalary = table.Column<double>(type: "float", nullable: false),
|
||||
StartDate = table.Column<DateTime>(type: "datetime2", nullable: false),
|
||||
EndDate = table.Column<DateTime>(type: "datetime2", nullable: false),
|
||||
Year = table.Column<int>(type: "int", nullable: false),
|
||||
SchemeId = table.Column<long>(type: "bigint", nullable: false),
|
||||
CreationDate = table.Column<DateTime>(type: "datetime2", nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ClassificationGroupSalaries", x => x.id);
|
||||
table.ForeignKey(
|
||||
name: "FK_ClassificationGroupSalaries_ClassificationGroups_ClassificationGroupId",
|
||||
column: x => x.ClassificationGroupId,
|
||||
principalTable: "ClassificationGroups",
|
||||
principalColumn: "id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
});
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ClassificationEmployee_ClassificationGroupId",
|
||||
table: "ClassificationEmployee",
|
||||
column: "ClassificationGroupId");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ClassificationGroupJobs_ClassificationGroupId",
|
||||
table: "ClassificationGroupJobs",
|
||||
column: "ClassificationGroupId");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ClassificationGroups_ClassificationSchemeId",
|
||||
table: "ClassificationGroups",
|
||||
column: "ClassificationSchemeId");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ClassificationGroupSalaries_ClassificationGroupId",
|
||||
table: "ClassificationGroupSalaries",
|
||||
column: "ClassificationGroupId");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_ClassificationRialCoefficients_ClassificationSchemeId",
|
||||
table: "ClassificationRialCoefficients",
|
||||
column: "ClassificationSchemeId");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropTable(
|
||||
name: "ClassificationEmployee");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ClassificationGroupJobs");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ClassificationGroupSalaries");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ClassificationRialCoefficients");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ClassificationGroups");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "ClassificationSchemes");
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -706,6 +706,33 @@ namespace CompanyManagment.EFCore.Migrations
|
||||
b.ToTable("Checkouts", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Company.Domain.CheckoutAgg.CheckoutWarningMessage", b =>
|
||||
{
|
||||
b.Property<long>("id")
|
||||
.ValueGeneratedOnAdd()
|
||||
.HasColumnType("bigint");
|
||||
|
||||
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("id"));
|
||||
|
||||
b.Property<long>("CheckoutId")
|
||||
.HasColumnType("bigint");
|
||||
|
||||
b.Property<string>("TypeOfCheckoutWarning")
|
||||
.IsRequired()
|
||||
.HasMaxLength(30)
|
||||
.HasColumnType("nvarchar(30)");
|
||||
|
||||
b.Property<string>("WarningMessage")
|
||||
.HasMaxLength(150)
|
||||
.HasColumnType("nvarchar(150)");
|
||||
|
||||
b.HasKey("id");
|
||||
|
||||
b.HasIndex("CheckoutId");
|
||||
|
||||
b.ToTable("CheckoutWarningMessage", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Company.Domain.ClassificationSchemeAgg.ClassificationEmployee", b =>
|
||||
{
|
||||
b.Property<long>("id")
|
||||
@@ -7737,6 +7764,17 @@ namespace CompanyManagment.EFCore.Migrations
|
||||
b.Navigation("Workshop");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Company.Domain.CheckoutAgg.CheckoutWarningMessage", b =>
|
||||
{
|
||||
b.HasOne("Company.Domain.CheckoutAgg.Checkout", "Checkout")
|
||||
.WithMany("CheckoutWarningMessageList")
|
||||
.HasForeignKey("CheckoutId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.Navigation("Checkout");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Company.Domain.ClassificationSchemeAgg.ClassificationEmployee", b =>
|
||||
{
|
||||
b.HasOne("Company.Domain.ClassificationSchemeAgg.ClassificationGroup", "ClassificationGroup")
|
||||
|
||||
Reference in New Issue
Block a user