Merge remote-tracking branch 'origin/master'
# Conflicts: # DaSaSo.ViewModel/SewerPipeLinerViewModel.cs
This commit is contained in:
@@ -9,7 +9,7 @@ namespace DaSaSo.Domain.Model
|
|||||||
public abstract class SewerRehabilation : DomainObject
|
public abstract class SewerRehabilation : DomainObject
|
||||||
{
|
{
|
||||||
public string Operator { get; set; }
|
public string Operator { get; set; }
|
||||||
public DateTime Date { get; set; }
|
public DateOnly Date { get; set; }
|
||||||
public decimal TemperatureOutdoors { get; set; }
|
public decimal TemperatureOutdoors { get; set; }
|
||||||
public decimal TemperatureSewer { get; set; }
|
public decimal TemperatureSewer { get; set; }
|
||||||
public string Weather { get; set; }
|
public string Weather { get; set; }
|
||||||
|
|||||||
@@ -19,4 +19,8 @@
|
|||||||
<ProjectReference Include="..\DaSaSo.Domain\DaSaSo.Domain.csproj" />
|
<ProjectReference Include="..\DaSaSo.Domain\DaSaSo.Domain.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<Folder Include="Migrations\" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
@@ -1,187 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210912175956_InitialCommit")]
|
|
||||||
partial class InitialCommit
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-preview.7.21378.4")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("PointFrom")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("PointTo")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", null)
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId")
|
|
||||||
.OnDelete(DeleteBehavior.Cascade)
|
|
||||||
.IsRequired();
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId")
|
|
||||||
.OnDelete(DeleteBehavior.Cascade)
|
|
||||||
.IsRequired();
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,124 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class InitialCommit : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "Clients",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
|
||||||
Firstname = table.Column<string>(type: "text", nullable: false),
|
|
||||||
LastName = table.Column<string>(type: "text", nullable: false),
|
|
||||||
Country = table.Column<string>(type: "text", nullable: false),
|
|
||||||
Postcode = table.Column<string>(type: "text", nullable: false)
|
|
||||||
},
|
|
||||||
constraints: table =>
|
|
||||||
{
|
|
||||||
table.PrimaryKey("PK_Clients", x => x.Id);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "Projects",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
|
||||||
Name = table.Column<string>(type: "text", nullable: false),
|
|
||||||
ClientId = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
},
|
|
||||||
constraints: table =>
|
|
||||||
{
|
|
||||||
table.PrimaryKey("PK_Projects", x => x.Id);
|
|
||||||
table.ForeignKey(
|
|
||||||
name: "FK_Projects_Clients_ClientId",
|
|
||||||
column: x => x.ClientId,
|
|
||||||
principalTable: "Clients",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Cascade);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "Buildingsites",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
|
||||||
BuildingSiteNumber = table.Column<string>(type: "text", nullable: false),
|
|
||||||
Country = table.Column<string>(type: "text", nullable: false),
|
|
||||||
ContactPerson = table.Column<string>(type: "text", nullable: false),
|
|
||||||
ProjectId = table.Column<int>(type: "integer", nullable: true)
|
|
||||||
},
|
|
||||||
constraints: table =>
|
|
||||||
{
|
|
||||||
table.PrimaryKey("PK_Buildingsites", x => x.Id);
|
|
||||||
table.ForeignKey(
|
|
||||||
name: "FK_Buildingsites_Projects_ProjectId",
|
|
||||||
column: x => x.ProjectId,
|
|
||||||
principalTable: "Projects",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Restrict);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "SewerObjects",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
|
||||||
BuildingSiteId = table.Column<int>(type: "integer", nullable: false),
|
|
||||||
StreetName = table.Column<string>(type: "text", nullable: false),
|
|
||||||
ObjektName = table.Column<string>(type: "text", nullable: false),
|
|
||||||
PointFrom = table.Column<string>(type: "text", nullable: false),
|
|
||||||
PointTo = table.Column<string>(type: "text", nullable: false),
|
|
||||||
DN = table.Column<int>(type: "integer", nullable: false),
|
|
||||||
SewerLength = table.Column<decimal>(type: "numeric", nullable: false)
|
|
||||||
},
|
|
||||||
constraints: table =>
|
|
||||||
{
|
|
||||||
table.PrimaryKey("PK_SewerObjects", x => x.Id);
|
|
||||||
table.ForeignKey(
|
|
||||||
name: "FK_SewerObjects_Buildingsites_BuildingSiteId",
|
|
||||||
column: x => x.BuildingSiteId,
|
|
||||||
principalTable: "Buildingsites",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Cascade);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
|
||||||
name: "IX_Buildingsites_ProjectId",
|
|
||||||
table: "Buildingsites",
|
|
||||||
column: "ProjectId");
|
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
|
||||||
name: "IX_Projects_ClientId",
|
|
||||||
table: "Projects",
|
|
||||||
column: "ClientId");
|
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
|
||||||
name: "IX_SewerObjects_BuildingSiteId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "BuildingSiteId");
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropTable(
|
|
||||||
name: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropTable(
|
|
||||||
name: "Buildingsites");
|
|
||||||
|
|
||||||
migrationBuilder.DropTable(
|
|
||||||
name: "Projects");
|
|
||||||
|
|
||||||
migrationBuilder.DropTable(
|
|
||||||
name: "Clients");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,191 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210913113208_StreetAdded")]
|
|
||||||
partial class StreetAdded
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-preview.7.21378.4")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("PointFrom")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("PointTo")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.IsRequired()
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", null)
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId")
|
|
||||||
.OnDelete(DeleteBehavior.Cascade)
|
|
||||||
.IsRequired();
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId")
|
|
||||||
.OnDelete(DeleteBehavior.Cascade)
|
|
||||||
.IsRequired();
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,24 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class StreetAdded : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.AddColumn<string>(
|
|
||||||
name: "Street",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "");
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "Street",
|
|
||||||
table: "Clients");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,176 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210915174236_ProjectReferenzAdded")]
|
|
||||||
partial class ProjectReferenzAdded
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-preview.7.21378.4")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("PointFrom")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("PointTo")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", "Project")
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
|
|
||||||
b.Navigation("Project");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId");
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId");
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,331 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class ProjectReferenzAdded : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_Projects_Clients_ClientId",
|
|
||||||
table: "Projects");
|
|
||||||
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_Buildingsites_BuildingSiteId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "StreetName",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "PointTo",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "PointFrom",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "ObjektName",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<int>(
|
|
||||||
name: "BuildingSiteId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(int),
|
|
||||||
oldType: "integer");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Name",
|
|
||||||
table: "Projects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<int>(
|
|
||||||
name: "ClientId",
|
|
||||||
table: "Projects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(int),
|
|
||||||
oldType: "integer");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Street",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Postcode",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "LastName",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Firstname",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Country",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Country",
|
|
||||||
table: "Buildingsites",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "ContactPerson",
|
|
||||||
table: "Buildingsites",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "BuildingSiteNumber",
|
|
||||||
table: "Buildingsites",
|
|
||||||
type: "text",
|
|
||||||
nullable: true,
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text");
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_Projects_Clients_ClientId",
|
|
||||||
table: "Projects",
|
|
||||||
column: "ClientId",
|
|
||||||
principalTable: "Clients",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Restrict);
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_Buildingsites_BuildingSiteId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "BuildingSiteId",
|
|
||||||
principalTable: "Buildingsites",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Restrict);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_Projects_Clients_ClientId",
|
|
||||||
table: "Projects");
|
|
||||||
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_Buildingsites_BuildingSiteId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "StreetName",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "PointTo",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "PointFrom",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "ObjektName",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<int>(
|
|
||||||
name: "BuildingSiteId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: 0,
|
|
||||||
oldClrType: typeof(int),
|
|
||||||
oldType: "integer",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Name",
|
|
||||||
table: "Projects",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<int>(
|
|
||||||
name: "ClientId",
|
|
||||||
table: "Projects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: 0,
|
|
||||||
oldClrType: typeof(int),
|
|
||||||
oldType: "integer",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Street",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Postcode",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "LastName",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Firstname",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Country",
|
|
||||||
table: "Clients",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "Country",
|
|
||||||
table: "Buildingsites",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "ContactPerson",
|
|
||||||
table: "Buildingsites",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<string>(
|
|
||||||
name: "BuildingSiteNumber",
|
|
||||||
table: "Buildingsites",
|
|
||||||
type: "text",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: "",
|
|
||||||
oldClrType: typeof(string),
|
|
||||||
oldType: "text",
|
|
||||||
oldNullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_Projects_Clients_ClientId",
|
|
||||||
table: "Projects",
|
|
||||||
column: "ClientId",
|
|
||||||
principalTable: "Clients",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Cascade);
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_Buildingsites_BuildingSiteId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "BuildingSiteId",
|
|
||||||
principalTable: "Buildingsites",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Cascade);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,234 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210916075225_SewerDamageAdded")]
|
|
||||||
partial class SewerDamageAdded
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-preview.7.21378.4")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("DamageType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("Distance")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<int>("PreparationType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("SewerObjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("SewerObjectId");
|
|
||||||
|
|
||||||
b.ToTable("SewerDamages");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("BuildingsiteBarier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Material")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("PointFrom")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("PointTo")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerActivated")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerCleaned")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBarrier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", "Project")
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
|
|
||||||
b.Navigation("Project");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId");
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerObjects", "SewerObject")
|
|
||||||
.WithMany("SewerDamages")
|
|
||||||
.HasForeignKey("SewerObjectId");
|
|
||||||
|
|
||||||
b.Navigation("SewerObject");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId");
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObjects", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerDamages");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,109 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class SewerDamageAdded : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "BuildingsiteBarier",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<string>(
|
|
||||||
name: "Material",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "PermitNeeded",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "SewerActivated",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "SewerCleaned",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "WaterBarrier",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "SewerDamages",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
|
||||||
SewerObjectId = table.Column<int>(type: "integer", nullable: true),
|
|
||||||
Distance = table.Column<decimal>(type: "numeric", nullable: false),
|
|
||||||
DamageType = table.Column<int>(type: "integer", nullable: false),
|
|
||||||
PreparationType = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
},
|
|
||||||
constraints: table =>
|
|
||||||
{
|
|
||||||
table.PrimaryKey("PK_SewerDamages", x => x.Id);
|
|
||||||
table.ForeignKey(
|
|
||||||
name: "FK_SewerDamages_SewerObjects_SewerObjectId",
|
|
||||||
column: x => x.SewerObjectId,
|
|
||||||
principalTable: "SewerObjects",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Restrict);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
|
||||||
name: "IX_SewerDamages_SewerObjectId",
|
|
||||||
table: "SewerDamages",
|
|
||||||
column: "SewerObjectId");
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropTable(
|
|
||||||
name: "SewerDamages");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "BuildingsiteBarier",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "Material",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PermitNeeded",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "SewerActivated",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "SewerCleaned",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "WaterBarrier",
|
|
||||||
table: "SewerObjects");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,234 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210916135239_SewerObjectsAdded")]
|
|
||||||
partial class SewerObjectsAdded
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-preview.7.21378.4")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("DamageType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("Distance")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<int>("PreparationType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("SewerObjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("SewerObjectId");
|
|
||||||
|
|
||||||
b.ToTable("SewerDamages");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("BuildingsiteBarier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Material")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("PointFrom")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("PointTo")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerActivated")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerCleaned")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBarrier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", "Project")
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
|
|
||||||
b.Navigation("Project");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId");
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerObject", "SewerObject")
|
|
||||||
.WithMany("SewerDamages")
|
|
||||||
.HasForeignKey("SewerObjectId");
|
|
||||||
|
|
||||||
b.Navigation("SewerObject");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId");
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerDamages");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,17 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class SewerObjectsAdded : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,271 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210920062903_transfertoenum")]
|
|
||||||
partial class transfertoenum
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-preview.7.21378.4")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("DamageType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("Distance")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<int>("PreparationType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("SewerObjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("SewerObjectId");
|
|
||||||
|
|
||||||
b.ToTable("SewerDamages");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("BuildingsiteBarier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Material")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktObenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktObenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktUntenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktUntenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerActivated")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerCleaned")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBarrier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktObenId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktUntenId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerPoint", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Objektnummer")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("SewerPoint");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", "Project")
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
|
|
||||||
b.Navigation("Project");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId");
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerObject", "SewerObject")
|
|
||||||
.WithMany("SewerDamages")
|
|
||||||
.HasForeignKey("SewerObjectId");
|
|
||||||
|
|
||||||
b.Navigation("SewerObject");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktOben")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktObenId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktUnten")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktUntenId");
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
|
|
||||||
b.Navigation("PunktOben");
|
|
||||||
|
|
||||||
b.Navigation("PunktUnten");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerDamages");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,134 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class transfertoenum : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PointFrom",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PointTo",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<int>(
|
|
||||||
name: "PunktObenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<int>(
|
|
||||||
name: "PunktObenType",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: 0);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<int>(
|
|
||||||
name: "PunktUntenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<int>(
|
|
||||||
name: "PunktUntenType",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: 0);
|
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "SewerPoint",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
|
||||||
Objektnummer = table.Column<string>(type: "text", nullable: true)
|
|
||||||
},
|
|
||||||
constraints: table =>
|
|
||||||
{
|
|
||||||
table.PrimaryKey("PK_SewerPoint", x => x.Id);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
|
||||||
name: "IX_SewerObjects_PunktObenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PunktObenId");
|
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
|
||||||
name: "IX_SewerObjects_PunktUntenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PunktUntenId");
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoint_PunktObenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PunktObenId",
|
|
||||||
principalTable: "SewerPoint",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Restrict);
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoint_PunktUntenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PunktUntenId",
|
|
||||||
principalTable: "SewerPoint",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Restrict);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoint_PunktObenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoint_PunktUntenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropTable(
|
|
||||||
name: "SewerPoint");
|
|
||||||
|
|
||||||
migrationBuilder.DropIndex(
|
|
||||||
name: "IX_SewerObjects_PunktObenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropIndex(
|
|
||||||
name: "IX_SewerObjects_PunktUntenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PunktObenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PunktObenType",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PunktUntenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PunktUntenType",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<string>(
|
|
||||||
name: "PointFrom",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<string>(
|
|
||||||
name: "PointTo",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,381 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210921145350_Lineradded")]
|
|
||||||
partial class Lineradded
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-preview.7.21378.4")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Impregnation", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
|
||||||
.HasColumnType("timestamp without time zone");
|
|
||||||
|
|
||||||
b.Property<bool>("IsAvaible")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("LinerNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("Linerlength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("Number")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("WallThickness")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Impregnations");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.PipeLiner", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedHD")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedMechanisch")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedRoborter")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("ClosedEnd")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
|
||||||
.HasColumnType("timestamp without time zone");
|
|
||||||
|
|
||||||
b.Property<int?>("ImpregnationId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("InversionPressure")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("LinerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("Operator")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("Preliner")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("STVO")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturAssembly")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturStorage")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperatureOutdoors")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperatureSewer")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBaried")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("Weather")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ImpregnationId");
|
|
||||||
|
|
||||||
b.ToTable("PipeLiners");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("DamageType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("Distance")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<int>("PreparationType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("SewerObjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("SewerObjectId");
|
|
||||||
|
|
||||||
b.ToTable("SewerDamages");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("BuildingsiteBarier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Material")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktObenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktObenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktUntenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktUntenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerActivated")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerCleaned")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBarrier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktObenId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktUntenId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerPoint", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Objektnummer")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("SewerPoint");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", "Project")
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
|
|
||||||
b.Navigation("Project");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.PipeLiner", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Impregnation", "Impregnation")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("ImpregnationId");
|
|
||||||
|
|
||||||
b.Navigation("Impregnation");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId");
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerObject", "SewerObject")
|
|
||||||
.WithMany("SewerDamages")
|
|
||||||
.HasForeignKey("SewerObjectId");
|
|
||||||
|
|
||||||
b.Navigation("SewerObject");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktOben")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktObenId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktUnten")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktUntenId");
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
|
|
||||||
b.Navigation("PunktOben");
|
|
||||||
|
|
||||||
b.Navigation("PunktUnten");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerDamages");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,81 +0,0 @@
|
|||||||
using System;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class Lineradded : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "Impregnations",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
|
||||||
DN = table.Column<int>(type: "integer", nullable: false),
|
|
||||||
Number = table.Column<string>(type: "text", nullable: true),
|
|
||||||
Linerlength = table.Column<decimal>(type: "numeric", nullable: false),
|
|
||||||
IsAvaible = table.Column<bool>(type: "boolean", nullable: false),
|
|
||||||
Date = table.Column<DateTime>(type: "timestamp without time zone", nullable: false),
|
|
||||||
LinerNumber = table.Column<string>(type: "text", nullable: true),
|
|
||||||
WallThickness = table.Column<decimal>(type: "numeric", nullable: false)
|
|
||||||
},
|
|
||||||
constraints: table =>
|
|
||||||
{
|
|
||||||
table.PrimaryKey("PK_Impregnations", x => x.Id);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateTable(
|
|
||||||
name: "PipeLiners",
|
|
||||||
columns: table => new
|
|
||||||
{
|
|
||||||
Id = table.Column<int>(type: "integer", nullable: false)
|
|
||||||
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
|
||||||
InversionPressure = table.Column<decimal>(type: "numeric", nullable: false),
|
|
||||||
ImpregnationId = table.Column<int>(type: "integer", nullable: true),
|
|
||||||
ClosedEnd = table.Column<bool>(type: "boolean", nullable: false),
|
|
||||||
Preliner = table.Column<bool>(type: "boolean", nullable: false),
|
|
||||||
TemperaturAssembly = table.Column<decimal>(type: "numeric", nullable: false),
|
|
||||||
TemperaturStorage = table.Column<decimal>(type: "numeric", nullable: false),
|
|
||||||
LinerLength = table.Column<decimal>(type: "numeric", nullable: false),
|
|
||||||
Operator = table.Column<string>(type: "text", nullable: true),
|
|
||||||
Date = table.Column<DateTime>(type: "timestamp without time zone", nullable: false),
|
|
||||||
TemperatureOutdoors = table.Column<decimal>(type: "numeric", nullable: false),
|
|
||||||
TemperatureSewer = table.Column<decimal>(type: "numeric", nullable: false),
|
|
||||||
Weather = table.Column<string>(type: "text", nullable: true),
|
|
||||||
CleanedHD = table.Column<bool>(type: "boolean", nullable: false),
|
|
||||||
CleanedMechanisch = table.Column<bool>(type: "boolean", nullable: false),
|
|
||||||
CleanedRoborter = table.Column<bool>(type: "boolean", nullable: false),
|
|
||||||
WaterBaried = table.Column<bool>(type: "boolean", nullable: false),
|
|
||||||
PermitNeeded = table.Column<bool>(type: "boolean", nullable: false),
|
|
||||||
STVO = table.Column<bool>(type: "boolean", nullable: false)
|
|
||||||
},
|
|
||||||
constraints: table =>
|
|
||||||
{
|
|
||||||
table.PrimaryKey("PK_PipeLiners", x => x.Id);
|
|
||||||
table.ForeignKey(
|
|
||||||
name: "FK_PipeLiners_Impregnations_ImpregnationId",
|
|
||||||
column: x => x.ImpregnationId,
|
|
||||||
principalTable: "Impregnations",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Restrict);
|
|
||||||
});
|
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
|
||||||
name: "IX_PipeLiners_ImpregnationId",
|
|
||||||
table: "PipeLiners",
|
|
||||||
column: "ImpregnationId");
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropTable(
|
|
||||||
name: "PipeLiners");
|
|
||||||
|
|
||||||
migrationBuilder.DropTable(
|
|
||||||
name: "Impregnations");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,392 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210921145447_LineraddedToSewer")]
|
|
||||||
partial class LineraddedToSewer
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63)
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-preview.7.21378.4")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Impregnation", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
|
||||||
.HasColumnType("timestamp without time zone");
|
|
||||||
|
|
||||||
b.Property<bool>("IsAvaible")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("LinerNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("Linerlength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("Number")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("WallThickness")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Impregnations");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.PipeLiner", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedHD")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedMechanisch")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedRoborter")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("ClosedEnd")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
|
||||||
.HasColumnType("timestamp without time zone");
|
|
||||||
|
|
||||||
b.Property<int?>("ImpregnationId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("InversionPressure")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("LinerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("Operator")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("Preliner")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("STVO")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturAssembly")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturStorage")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperatureOutdoors")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperatureSewer")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBaried")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("Weather")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ImpregnationId");
|
|
||||||
|
|
||||||
b.ToTable("PipeLiners");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int>("DamageType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("Distance")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<int>("PreparationType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("SewerObjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("SewerObjectId");
|
|
||||||
|
|
||||||
b.ToTable("SewerDamages");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<int?>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("BuildingsiteBarier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Material")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int?>("PipeLinerId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktObenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktObenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktUntenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktUntenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerActivated")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerCleaned")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBarrier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasIndex("PipeLinerId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktObenId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktUntenId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerPoint", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer")
|
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
|
||||||
|
|
||||||
b.Property<string>("Objektnummer")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("SewerPoint");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", "Project")
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
|
|
||||||
b.Navigation("Project");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.PipeLiner", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Impregnation", "Impregnation")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("ImpregnationId");
|
|
||||||
|
|
||||||
b.Navigation("Impregnation");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId");
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerObject", "SewerObject")
|
|
||||||
.WithMany("SewerDamages")
|
|
||||||
.HasForeignKey("SewerObjectId");
|
|
||||||
|
|
||||||
b.Navigation("SewerObject");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.PipeLiner", "PipeLiner")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PipeLinerId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktOben")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktObenId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktUnten")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktUntenId");
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
|
|
||||||
b.Navigation("PipeLiner");
|
|
||||||
|
|
||||||
b.Navigation("PunktOben");
|
|
||||||
|
|
||||||
b.Navigation("PunktUnten");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerDamages");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,44 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class LineraddedToSewer : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.AddColumn<int>(
|
|
||||||
name: "PipeLinerId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "integer",
|
|
||||||
nullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.CreateIndex(
|
|
||||||
name: "IX_SewerObjects_PipeLinerId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PipeLinerId");
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_PipeLiners_PipeLinerId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PipeLinerId",
|
|
||||||
principalTable: "PipeLiners",
|
|
||||||
principalColumn: "Id",
|
|
||||||
onDelete: ReferentialAction.Restrict);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_PipeLiners_PipeLinerId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropIndex(
|
|
||||||
name: "IX_SewerObjects_PipeLinerId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PipeLinerId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,403 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210928140403_SewerPointsAdded")]
|
|
||||||
partial class SewerPointsAdded
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-rc.1.21452.10")
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63);
|
|
||||||
|
|
||||||
NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Impregnation", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
|
||||||
.HasColumnType("timestamp with time zone");
|
|
||||||
|
|
||||||
b.Property<bool>("IsAvaible")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("LinerNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("Linerlength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("Number")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("WallThickness")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Impregnations");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.PipeLiner", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedHD")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedMechanisch")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedRoborter")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("ClosedEnd")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
|
||||||
.HasColumnType("timestamp with time zone");
|
|
||||||
|
|
||||||
b.Property<int?>("ImpregnationId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("InversionPressure")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("LinerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("Operator")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("Preliner")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("STVO")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturAssembly")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturStorage")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperatureOutdoors")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperatureSewer")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBaried")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("Weather")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ImpregnationId");
|
|
||||||
|
|
||||||
b.ToTable("PipeLiners");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<int?>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<int>("DamageType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("Distance")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<int>("PreparationType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("SewerObjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("SewerObjectId");
|
|
||||||
|
|
||||||
b.ToTable("SewerDamages");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<int?>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("BuildingsiteBarier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Material")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int?>("PipeLinerId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktObenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktObenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktUntenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktUntenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerActivated")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerCleaned")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBarrier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasIndex("PipeLinerId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktObenId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktUntenId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerPoint", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<string>("Objektnummer")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("SewerPoints");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", "Project")
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
|
|
||||||
b.Navigation("Project");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.PipeLiner", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Impregnation", "Impregnation")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("ImpregnationId");
|
|
||||||
|
|
||||||
b.Navigation("Impregnation");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId");
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerObject", "SewerObject")
|
|
||||||
.WithMany("SewerDamages")
|
|
||||||
.HasForeignKey("SewerObjectId");
|
|
||||||
|
|
||||||
b.Navigation("SewerObject");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.PipeLiner", "PipeLiner")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PipeLinerId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktOben")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktObenId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktUnten")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktUntenId");
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
|
|
||||||
b.Navigation("PipeLiner");
|
|
||||||
|
|
||||||
b.Navigation("PunktOben");
|
|
||||||
|
|
||||||
b.Navigation("PunktUnten");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerDamages");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,118 +0,0 @@
|
|||||||
using System;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class SewerPointsAdded : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoint_PunktObenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoint_PunktUntenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropPrimaryKey(
|
|
||||||
name: "PK_SewerPoint",
|
|
||||||
table: "SewerPoint");
|
|
||||||
|
|
||||||
migrationBuilder.RenameTable(
|
|
||||||
name: "SewerPoint",
|
|
||||||
newName: "SewerPoints");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<DateTime>(
|
|
||||||
name: "Date",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "timestamp with time zone",
|
|
||||||
nullable: false,
|
|
||||||
oldClrType: typeof(DateTime),
|
|
||||||
oldType: "timestamp without time zone");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<DateTime>(
|
|
||||||
name: "Date",
|
|
||||||
table: "Impregnations",
|
|
||||||
type: "timestamp with time zone",
|
|
||||||
nullable: false,
|
|
||||||
oldClrType: typeof(DateTime),
|
|
||||||
oldType: "timestamp without time zone");
|
|
||||||
|
|
||||||
migrationBuilder.AddPrimaryKey(
|
|
||||||
name: "PK_SewerPoints",
|
|
||||||
table: "SewerPoints",
|
|
||||||
column: "Id");
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoints_PunktObenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PunktObenId",
|
|
||||||
principalTable: "SewerPoints",
|
|
||||||
principalColumn: "Id");
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoints_PunktUntenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PunktUntenId",
|
|
||||||
principalTable: "SewerPoints",
|
|
||||||
principalColumn: "Id");
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoints_PunktObenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoints_PunktUntenId",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropPrimaryKey(
|
|
||||||
name: "PK_SewerPoints",
|
|
||||||
table: "SewerPoints");
|
|
||||||
|
|
||||||
migrationBuilder.RenameTable(
|
|
||||||
name: "SewerPoints",
|
|
||||||
newName: "SewerPoint");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<DateTime>(
|
|
||||||
name: "Date",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "timestamp without time zone",
|
|
||||||
nullable: false,
|
|
||||||
oldClrType: typeof(DateTime),
|
|
||||||
oldType: "timestamp with time zone");
|
|
||||||
|
|
||||||
migrationBuilder.AlterColumn<DateTime>(
|
|
||||||
name: "Date",
|
|
||||||
table: "Impregnations",
|
|
||||||
type: "timestamp without time zone",
|
|
||||||
nullable: false,
|
|
||||||
oldClrType: typeof(DateTime),
|
|
||||||
oldType: "timestamp with time zone");
|
|
||||||
|
|
||||||
migrationBuilder.AddPrimaryKey(
|
|
||||||
name: "PK_SewerPoint",
|
|
||||||
table: "SewerPoint",
|
|
||||||
column: "Id");
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoint_PunktObenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PunktObenId",
|
|
||||||
principalTable: "SewerPoint",
|
|
||||||
principalColumn: "Id");
|
|
||||||
|
|
||||||
migrationBuilder.AddForeignKey(
|
|
||||||
name: "FK_SewerObjects_SewerPoint_PunktUntenId",
|
|
||||||
table: "SewerObjects",
|
|
||||||
column: "PunktUntenId",
|
|
||||||
principalTable: "SewerPoint",
|
|
||||||
principalColumn: "Id");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,406 +0,0 @@
|
|||||||
// <auto-generated />
|
|
||||||
using System;
|
|
||||||
using DaSaSo.EntityFramework;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
|
||||||
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
||||||
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
|
||||||
[Migration("20210928153745_ProjectNumberAdded")]
|
|
||||||
partial class ProjectNumberAdded
|
|
||||||
{
|
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
|
||||||
{
|
|
||||||
#pragma warning disable 612, 618
|
|
||||||
modelBuilder
|
|
||||||
.HasAnnotation("ProductVersion", "6.0.0-rc.1.21452.10")
|
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63);
|
|
||||||
|
|
||||||
NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<string>("BuildingSiteNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ContactPerson")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<int?>("ProjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ProjectId");
|
|
||||||
|
|
||||||
b.ToTable("Buildingsites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<string>("Country")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Firstname")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("LastName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Postcode")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Street")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Clients");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Impregnation", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
|
||||||
.HasColumnType("timestamp with time zone");
|
|
||||||
|
|
||||||
b.Property<bool>("IsAvaible")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("LinerNumber")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("Linerlength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("Number")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<decimal>("WallThickness")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("Impregnations");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.PipeLiner", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedHD")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedMechanisch")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("CleanedRoborter")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("ClosedEnd")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
|
||||||
.HasColumnType("timestamp with time zone");
|
|
||||||
|
|
||||||
b.Property<int?>("ImpregnationId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("InversionPressure")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("LinerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("Operator")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("Preliner")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("STVO")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturAssembly")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturStorage")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperatureOutdoors")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperatureSewer")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBaried")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("Weather")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ImpregnationId");
|
|
||||||
|
|
||||||
b.ToTable("PipeLiners");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<int?>("ClientId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Name")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("Projektnummer")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("ClientId");
|
|
||||||
|
|
||||||
b.ToTable("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<int>("DamageType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<decimal>("Distance")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<int>("PreparationType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("SewerObjectId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("SewerObjectId");
|
|
||||||
|
|
||||||
b.ToTable("SewerDamages");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<int?>("BuildingSiteId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("BuildingsiteBarier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int>("DN")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<string>("Material")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<string>("ObjektName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<int?>("PipeLinerId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktObenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktObenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int?>("PunktUntenId")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<int>("PunktUntenType")
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerActivated")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("SewerCleaned")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("SewerLength")
|
|
||||||
.HasColumnType("numeric");
|
|
||||||
|
|
||||||
b.Property<string>("StreetName")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.Property<bool>("WaterBarrier")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.HasIndex("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasIndex("PipeLinerId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktObenId");
|
|
||||||
|
|
||||||
b.HasIndex("PunktUntenId");
|
|
||||||
|
|
||||||
b.ToTable("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerPoint", b =>
|
|
||||||
{
|
|
||||||
b.Property<int>("Id")
|
|
||||||
.ValueGeneratedOnAdd()
|
|
||||||
.HasColumnType("integer");
|
|
||||||
|
|
||||||
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
||||||
|
|
||||||
b.Property<string>("Objektnummer")
|
|
||||||
.HasColumnType("text");
|
|
||||||
|
|
||||||
b.HasKey("Id");
|
|
||||||
|
|
||||||
b.ToTable("SewerPoints");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Project", "Project")
|
|
||||||
.WithMany("BuildingSites")
|
|
||||||
.HasForeignKey("ProjectId");
|
|
||||||
|
|
||||||
b.Navigation("Project");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.PipeLiner", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Impregnation", "Impregnation")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("ImpregnationId");
|
|
||||||
|
|
||||||
b.Navigation("Impregnation");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Client", "Client")
|
|
||||||
.WithMany("Projects")
|
|
||||||
.HasForeignKey("ClientId");
|
|
||||||
|
|
||||||
b.Navigation("Client");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerDamage", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerObject", "SewerObject")
|
|
||||||
.WithMany("SewerDamages")
|
|
||||||
.HasForeignKey("SewerObjectId");
|
|
||||||
|
|
||||||
b.Navigation("SewerObject");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.Buildingsite", "BuildingSite")
|
|
||||||
.WithMany("SewerObjects")
|
|
||||||
.HasForeignKey("BuildingSiteId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.PipeLiner", "PipeLiner")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PipeLinerId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktOben")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktObenId");
|
|
||||||
|
|
||||||
b.HasOne("DaSaSo.Domain.Model.SewerPoint", "PunktUnten")
|
|
||||||
.WithMany()
|
|
||||||
.HasForeignKey("PunktUntenId");
|
|
||||||
|
|
||||||
b.Navigation("BuildingSite");
|
|
||||||
|
|
||||||
b.Navigation("PipeLiner");
|
|
||||||
|
|
||||||
b.Navigation("PunktOben");
|
|
||||||
|
|
||||||
b.Navigation("PunktUnten");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Buildingsite", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerObjects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Client", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("Projects");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.Project", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("BuildingSites");
|
|
||||||
});
|
|
||||||
|
|
||||||
modelBuilder.Entity("DaSaSo.Domain.Model.SewerObject", b =>
|
|
||||||
{
|
|
||||||
b.Navigation("SewerDamages");
|
|
||||||
});
|
|
||||||
#pragma warning restore 612, 618
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class ProjectNumberAdded : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.AddColumn<string>(
|
|
||||||
name: "Projektnummer",
|
|
||||||
table: "Projects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "Projektnummer",
|
|
||||||
table: "Projects");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,70 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class DeletedPrepartionFromDamage : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PreparationType",
|
|
||||||
table: "SewerDamages");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "CleanedHD",
|
|
||||||
table: "PipeLiners");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "CleanedMechanisch",
|
|
||||||
table: "PipeLiners");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "CleanedRoborter",
|
|
||||||
table: "PipeLiners");
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<int>(
|
|
||||||
name: "PreparationType",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "integer",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PreparationType",
|
|
||||||
table: "PipeLiners");
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<int>(
|
|
||||||
name: "PreparationType",
|
|
||||||
table: "SewerDamages",
|
|
||||||
type: "integer",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: 0);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "CleanedHD",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "CleanedMechanisch",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "CleanedRoborter",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,68 +0,0 @@
|
|||||||
using Microsoft.EntityFrameworkCore.Migrations;
|
|
||||||
|
|
||||||
#nullable disable
|
|
||||||
|
|
||||||
namespace DaSaSo.EntityFramework.Migrations
|
|
||||||
{
|
|
||||||
public partial class AddHousenumbers : Migration
|
|
||||||
{
|
|
||||||
protected override void Up(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "PermitNeeded",
|
|
||||||
table: "PipeLiners");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "STVO",
|
|
||||||
table: "PipeLiners");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "WaterBaried",
|
|
||||||
table: "PipeLiners");
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<string>(
|
|
||||||
name: "Hausnummer",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<string>(
|
|
||||||
name: "SanNummer",
|
|
||||||
table: "SewerObjects",
|
|
||||||
type: "text",
|
|
||||||
nullable: true);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected override void Down(MigrationBuilder migrationBuilder)
|
|
||||||
{
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "Hausnummer",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.DropColumn(
|
|
||||||
name: "SanNummer",
|
|
||||||
table: "SewerObjects");
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "PermitNeeded",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "STVO",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
|
|
||||||
migrationBuilder.AddColumn<bool>(
|
|
||||||
name: "WaterBaried",
|
|
||||||
table: "PipeLiners",
|
|
||||||
type: "boolean",
|
|
||||||
nullable: false,
|
|
||||||
defaultValue: false);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -12,8 +12,8 @@ using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|||||||
namespace DaSaSo.EntityFramework.Migrations
|
namespace DaSaSo.EntityFramework.Migrations
|
||||||
{
|
{
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
[DbContext(typeof(DaSaSoDbContext))]
|
||||||
[Migration("20211005082652_AddHousenumbers")]
|
[Migration("20211009183922_Initial")]
|
||||||
partial class AddHousenumbers
|
partial class Initial
|
||||||
{
|
{
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
||||||
{
|
{
|
||||||
272
DaSaSo.EntityFramework/Migrations/20211009183922_Initial.cs
Normal file
272
DaSaSo.EntityFramework/Migrations/20211009183922_Initial.cs
Normal file
@@ -0,0 +1,272 @@
|
|||||||
|
using System;
|
||||||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
|
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
||||||
|
|
||||||
|
#nullable disable
|
||||||
|
|
||||||
|
namespace DaSaSo.EntityFramework.Migrations
|
||||||
|
{
|
||||||
|
public partial class Initial : Migration
|
||||||
|
{
|
||||||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
migrationBuilder.Sql("SET TimeZone='UTC'");
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "Clients",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
||||||
|
Firstname = table.Column<string>(type: "text", nullable: true),
|
||||||
|
LastName = table.Column<string>(type: "text", nullable: true),
|
||||||
|
Country = table.Column<string>(type: "text", nullable: true),
|
||||||
|
Street = table.Column<string>(type: "text", nullable: true),
|
||||||
|
Postcode = table.Column<string>(type: "text", nullable: true)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_Clients", x => x.Id);
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "Impregnations",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
||||||
|
DN = table.Column<int>(type: "integer", nullable: false),
|
||||||
|
Number = table.Column<string>(type: "text", nullable: true),
|
||||||
|
Linerlength = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
IsAvaible = table.Column<bool>(type: "boolean", nullable: false),
|
||||||
|
Date = table.Column<DateTime>(type: "timestamp with time zone", nullable: false),
|
||||||
|
LinerNumber = table.Column<string>(type: "text", nullable: true),
|
||||||
|
WallThickness = table.Column<decimal>(type: "numeric", nullable: false)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_Impregnations", x => x.Id);
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "SewerPoints",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
||||||
|
Objektnummer = table.Column<string>(type: "text", nullable: true)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_SewerPoints", x => x.Id);
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "Projects",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
||||||
|
Name = table.Column<string>(type: "text", nullable: true),
|
||||||
|
Projektnummer = table.Column<string>(type: "text", nullable: true),
|
||||||
|
ClientId = table.Column<int>(type: "integer", nullable: true)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_Projects", x => x.Id);
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_Projects_Clients_ClientId",
|
||||||
|
column: x => x.ClientId,
|
||||||
|
principalTable: "Clients",
|
||||||
|
principalColumn: "Id");
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "PipeLiners",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
||||||
|
InversionPressure = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
ImpregnationId = table.Column<int>(type: "integer", nullable: true),
|
||||||
|
ClosedEnd = table.Column<bool>(type: "boolean", nullable: false),
|
||||||
|
Preliner = table.Column<bool>(type: "boolean", nullable: false),
|
||||||
|
TemperaturAssembly = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
TemperaturStorage = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
LinerLength = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
Operator = table.Column<string>(type: "text", nullable: true),
|
||||||
|
Date = table.Column<DateTime>(type: "timestamp with time zone", nullable: false),
|
||||||
|
TemperatureOutdoors = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
TemperatureSewer = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
Weather = table.Column<string>(type: "text", nullable: true),
|
||||||
|
PreparationType = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_PipeLiners", x => x.Id);
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_PipeLiners_Impregnations_ImpregnationId",
|
||||||
|
column: x => x.ImpregnationId,
|
||||||
|
principalTable: "Impregnations",
|
||||||
|
principalColumn: "Id");
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "Buildingsites",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
||||||
|
ProjectId = table.Column<int>(type: "integer", nullable: true),
|
||||||
|
BuildingSiteNumber = table.Column<string>(type: "text", nullable: true),
|
||||||
|
Country = table.Column<string>(type: "text", nullable: true),
|
||||||
|
ContactPerson = table.Column<string>(type: "text", nullable: true)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_Buildingsites", x => x.Id);
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_Buildingsites_Projects_ProjectId",
|
||||||
|
column: x => x.ProjectId,
|
||||||
|
principalTable: "Projects",
|
||||||
|
principalColumn: "Id");
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "SewerObjects",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
||||||
|
BuildingSiteId = table.Column<int>(type: "integer", nullable: true),
|
||||||
|
SanNummer = table.Column<string>(type: "text", nullable: true),
|
||||||
|
StreetName = table.Column<string>(type: "text", nullable: true),
|
||||||
|
Hausnummer = table.Column<string>(type: "text", nullable: true),
|
||||||
|
ObjektName = table.Column<string>(type: "text", nullable: true),
|
||||||
|
PunktObenId = table.Column<int>(type: "integer", nullable: true),
|
||||||
|
PunktObenType = table.Column<int>(type: "integer", nullable: false),
|
||||||
|
PunktUntenId = table.Column<int>(type: "integer", nullable: true),
|
||||||
|
PunktUntenType = table.Column<int>(type: "integer", nullable: false),
|
||||||
|
Material = table.Column<string>(type: "text", nullable: true),
|
||||||
|
DN = table.Column<int>(type: "integer", nullable: false),
|
||||||
|
SewerLength = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
SewerActivated = table.Column<bool>(type: "boolean", nullable: false),
|
||||||
|
SewerCleaned = table.Column<bool>(type: "boolean", nullable: false),
|
||||||
|
WaterBarrier = table.Column<bool>(type: "boolean", nullable: false),
|
||||||
|
PermitNeeded = table.Column<bool>(type: "boolean", nullable: false),
|
||||||
|
BuildingsiteBarier = table.Column<bool>(type: "boolean", nullable: false),
|
||||||
|
PipeLinerId = table.Column<int>(type: "integer", nullable: true)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_SewerObjects", x => x.Id);
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_SewerObjects_Buildingsites_BuildingSiteId",
|
||||||
|
column: x => x.BuildingSiteId,
|
||||||
|
principalTable: "Buildingsites",
|
||||||
|
principalColumn: "Id");
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_SewerObjects_PipeLiners_PipeLinerId",
|
||||||
|
column: x => x.PipeLinerId,
|
||||||
|
principalTable: "PipeLiners",
|
||||||
|
principalColumn: "Id");
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_SewerObjects_SewerPoints_PunktObenId",
|
||||||
|
column: x => x.PunktObenId,
|
||||||
|
principalTable: "SewerPoints",
|
||||||
|
principalColumn: "Id");
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_SewerObjects_SewerPoints_PunktUntenId",
|
||||||
|
column: x => x.PunktUntenId,
|
||||||
|
principalTable: "SewerPoints",
|
||||||
|
principalColumn: "Id");
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "SewerDamages",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
Id = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
.Annotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn),
|
||||||
|
SewerObjectId = table.Column<int>(type: "integer", nullable: true),
|
||||||
|
Distance = table.Column<decimal>(type: "numeric", nullable: false),
|
||||||
|
DamageType = table.Column<int>(type: "integer", nullable: false)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_SewerDamages", x => x.Id);
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_SewerDamages_SewerObjects_SewerObjectId",
|
||||||
|
column: x => x.SewerObjectId,
|
||||||
|
principalTable: "SewerObjects",
|
||||||
|
principalColumn: "Id");
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_Buildingsites_ProjectId",
|
||||||
|
table: "Buildingsites",
|
||||||
|
column: "ProjectId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_PipeLiners_ImpregnationId",
|
||||||
|
table: "PipeLiners",
|
||||||
|
column: "ImpregnationId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_Projects_ClientId",
|
||||||
|
table: "Projects",
|
||||||
|
column: "ClientId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_SewerDamages_SewerObjectId",
|
||||||
|
table: "SewerDamages",
|
||||||
|
column: "SewerObjectId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_SewerObjects_BuildingSiteId",
|
||||||
|
table: "SewerObjects",
|
||||||
|
column: "BuildingSiteId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_SewerObjects_PipeLinerId",
|
||||||
|
table: "SewerObjects",
|
||||||
|
column: "PipeLinerId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_SewerObjects_PunktObenId",
|
||||||
|
table: "SewerObjects",
|
||||||
|
column: "PunktObenId");
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_SewerObjects_PunktUntenId",
|
||||||
|
table: "SewerObjects",
|
||||||
|
column: "PunktUntenId");
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "SewerDamages");
|
||||||
|
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "SewerObjects");
|
||||||
|
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "Buildingsites");
|
||||||
|
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "PipeLiners");
|
||||||
|
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "SewerPoints");
|
||||||
|
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "Projects");
|
||||||
|
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "Impregnations");
|
||||||
|
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "Clients");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -12,8 +12,8 @@ using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|||||||
namespace DaSaSo.EntityFramework.Migrations
|
namespace DaSaSo.EntityFramework.Migrations
|
||||||
{
|
{
|
||||||
[DbContext(typeof(DaSaSoDbContext))]
|
[DbContext(typeof(DaSaSoDbContext))]
|
||||||
[Migration("20211005060234_DeletedPrepartionFromDamage")]
|
[Migration("20211009185244_DateOnly")]
|
||||||
partial class DeletedPrepartionFromDamage
|
partial class DateOnly
|
||||||
{
|
{
|
||||||
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
protected override void BuildTargetModel(ModelBuilder modelBuilder)
|
||||||
{
|
{
|
||||||
@@ -124,8 +124,8 @@ namespace DaSaSo.EntityFramework.Migrations
|
|||||||
b.Property<bool>("ClosedEnd")
|
b.Property<bool>("ClosedEnd")
|
||||||
.HasColumnType("boolean");
|
.HasColumnType("boolean");
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
b.Property<DateOnly>("Date")
|
||||||
.HasColumnType("timestamp with time zone");
|
.HasColumnType("date");
|
||||||
|
|
||||||
b.Property<int?>("ImpregnationId")
|
b.Property<int?>("ImpregnationId")
|
||||||
.HasColumnType("integer");
|
.HasColumnType("integer");
|
||||||
@@ -139,18 +139,12 @@ namespace DaSaSo.EntityFramework.Migrations
|
|||||||
b.Property<string>("Operator")
|
b.Property<string>("Operator")
|
||||||
.HasColumnType("text");
|
.HasColumnType("text");
|
||||||
|
|
||||||
b.Property<bool>("PermitNeeded")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<bool>("Preliner")
|
b.Property<bool>("Preliner")
|
||||||
.HasColumnType("boolean");
|
.HasColumnType("boolean");
|
||||||
|
|
||||||
b.Property<int>("PreparationType")
|
b.Property<int>("PreparationType")
|
||||||
.HasColumnType("integer");
|
.HasColumnType("integer");
|
||||||
|
|
||||||
b.Property<bool>("STVO")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<decimal>("TemperaturAssembly")
|
b.Property<decimal>("TemperaturAssembly")
|
||||||
.HasColumnType("numeric");
|
.HasColumnType("numeric");
|
||||||
|
|
||||||
@@ -163,9 +157,6 @@ namespace DaSaSo.EntityFramework.Migrations
|
|||||||
b.Property<decimal>("TemperatureSewer")
|
b.Property<decimal>("TemperatureSewer")
|
||||||
.HasColumnType("numeric");
|
.HasColumnType("numeric");
|
||||||
|
|
||||||
b.Property<bool>("WaterBaried")
|
|
||||||
.HasColumnType("boolean");
|
|
||||||
|
|
||||||
b.Property<string>("Weather")
|
b.Property<string>("Weather")
|
||||||
.HasColumnType("text");
|
.HasColumnType("text");
|
||||||
|
|
||||||
@@ -241,6 +232,9 @@ namespace DaSaSo.EntityFramework.Migrations
|
|||||||
b.Property<int>("DN")
|
b.Property<int>("DN")
|
||||||
.HasColumnType("integer");
|
.HasColumnType("integer");
|
||||||
|
|
||||||
|
b.Property<string>("Hausnummer")
|
||||||
|
.HasColumnType("text");
|
||||||
|
|
||||||
b.Property<string>("Material")
|
b.Property<string>("Material")
|
||||||
.HasColumnType("text");
|
.HasColumnType("text");
|
||||||
|
|
||||||
@@ -265,6 +259,9 @@ namespace DaSaSo.EntityFramework.Migrations
|
|||||||
b.Property<int>("PunktUntenType")
|
b.Property<int>("PunktUntenType")
|
||||||
.HasColumnType("integer");
|
.HasColumnType("integer");
|
||||||
|
|
||||||
|
b.Property<string>("SanNummer")
|
||||||
|
.HasColumnType("text");
|
||||||
|
|
||||||
b.Property<bool>("SewerActivated")
|
b.Property<bool>("SewerActivated")
|
||||||
.HasColumnType("boolean");
|
.HasColumnType("boolean");
|
||||||
|
|
||||||
32
DaSaSo.EntityFramework/Migrations/20211009185244_DateOnly.cs
Normal file
32
DaSaSo.EntityFramework/Migrations/20211009185244_DateOnly.cs
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
using System;
|
||||||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
|
|
||||||
|
#nullable disable
|
||||||
|
|
||||||
|
namespace DaSaSo.EntityFramework.Migrations
|
||||||
|
{
|
||||||
|
public partial class DateOnly : Migration
|
||||||
|
{
|
||||||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
migrationBuilder.AlterColumn<DateOnly>(
|
||||||
|
name: "Date",
|
||||||
|
table: "PipeLiners",
|
||||||
|
type: "date",
|
||||||
|
nullable: false,
|
||||||
|
oldClrType: typeof(DateTime),
|
||||||
|
oldType: "timestamp with time zone");
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
migrationBuilder.AlterColumn<DateTime>(
|
||||||
|
name: "Date",
|
||||||
|
table: "PipeLiners",
|
||||||
|
type: "timestamp with time zone",
|
||||||
|
nullable: false,
|
||||||
|
oldClrType: typeof(DateOnly),
|
||||||
|
oldType: "date");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -122,8 +122,8 @@ namespace DaSaSo.EntityFramework.Migrations
|
|||||||
b.Property<bool>("ClosedEnd")
|
b.Property<bool>("ClosedEnd")
|
||||||
.HasColumnType("boolean");
|
.HasColumnType("boolean");
|
||||||
|
|
||||||
b.Property<DateTime>("Date")
|
b.Property<DateOnly>("Date")
|
||||||
.HasColumnType("timestamp with time zone");
|
.HasColumnType("date");
|
||||||
|
|
||||||
b.Property<int?>("ImpregnationId")
|
b.Property<int?>("ImpregnationId")
|
||||||
.HasColumnType("integer");
|
.HasColumnType("integer");
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ namespace DaSaSo.ViewModel
|
|||||||
private string _clientname = "";
|
private string _clientname = "";
|
||||||
private string _projektname = "";
|
private string _projektname = "";
|
||||||
private string _buildingsitename = "";
|
private string _buildingsitename = "";
|
||||||
private readonly RegistryKey? registry;
|
private RegistryKey? registry;
|
||||||
const string REGISTRYKEY = "HKEY_CURRENT_USER\\Software\\Cosysda\\DaSaSo";
|
const string REGISTRYKEY = "HKEY_CURRENT_USER\\Software\\Cosysda\\DaSaSo";
|
||||||
public bool CanSelectProject { get => _actualProject.AktuellClient != null; }
|
public bool CanSelectProject { get => _actualProject.AktuellClient != null; }
|
||||||
public bool CanSelectBuildingSite { get => _actualProject.AktuellProjekt != null; }
|
public bool CanSelectBuildingSite { get => _actualProject.AktuellProjekt != null; }
|
||||||
@@ -177,7 +177,7 @@ namespace DaSaSo.ViewModel
|
|||||||
|
|
||||||
private void InitRegistry()
|
private void InitRegistry()
|
||||||
{
|
{
|
||||||
Registry.CurrentUser.CreateSubKey("Software\\Cosysda\\DaSaSo");
|
registry = Registry.CurrentUser.CreateSubKey("Software\\Cosysda\\DaSaSo");
|
||||||
LadeRegistry();
|
LadeRegistry();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user