This commit is contained in:
2026-02-06 09:17:51 +01:00
parent 3f474c4d39
commit 2e40d48a9a
17 changed files with 1659 additions and 329 deletions

View File

@ -0,0 +1,79 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace StandManager.Infrastructure.Migrations
{
/// <inheritdoc />
public partial class CapoareaSuProvIstat : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropForeignKey(
name: "FK_Utente_Province_ProvinciaIstatId",
table: "Utente");
migrationBuilder.DropIndex(
name: "IX_Utente_ProvinciaIstatId",
table: "Utente");
migrationBuilder.DropColumn(
name: "ProvinciaIstatId",
table: "Utente");
migrationBuilder.AddColumn<Guid>(
name: "CapoareaId",
table: "Province",
type: "uniqueidentifier",
nullable: true);
migrationBuilder.CreateIndex(
name: "IX_Province_CapoareaId",
table: "Province",
column: "CapoareaId");
migrationBuilder.AddForeignKey(
name: "FK_Province_Utente_CapoareaId",
table: "Province",
column: "CapoareaId",
principalTable: "Utente",
principalColumn: "Id");
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropForeignKey(
name: "FK_Province_Utente_CapoareaId",
table: "Province");
migrationBuilder.DropIndex(
name: "IX_Province_CapoareaId",
table: "Province");
migrationBuilder.DropColumn(
name: "CapoareaId",
table: "Province");
migrationBuilder.AddColumn<Guid>(
name: "ProvinciaIstatId",
table: "Utente",
type: "uniqueidentifier",
nullable: true);
migrationBuilder.CreateIndex(
name: "IX_Utente_ProvinciaIstatId",
table: "Utente",
column: "ProvinciaIstatId");
migrationBuilder.AddForeignKey(
name: "FK_Utente_Province_ProvinciaIstatId",
table: "Utente",
column: "ProvinciaIstatId",
principalTable: "Province",
principalColumn: "Id");
}
}
}