Classes expanded
This commit is contained in:
16
DaSaSo.Domain/Model/Buildingsite.cs
Normal file
16
DaSaSo.Domain/Model/Buildingsite.cs
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace DaSaSo.Domain.Model
|
||||||
|
{
|
||||||
|
public class Buildingsite : DomainObject
|
||||||
|
{
|
||||||
|
public string BuildingSiteNumber { get; set; }
|
||||||
|
public string Country { get; set; }
|
||||||
|
public string ContactPerson { get; set; }
|
||||||
|
public IEnumerable<SewerObjects> SewerObjects { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -10,5 +10,9 @@ namespace DaSaSo.Domain.Model
|
|||||||
{
|
{
|
||||||
public string Firstname { get; set; }
|
public string Firstname { get; set; }
|
||||||
public string LastName { get; set; }
|
public string LastName { get; set; }
|
||||||
|
public string Country { get; set; }
|
||||||
|
public string Postcode { get; set; }
|
||||||
|
public IEnumerable<Project> Projects { get; set; }
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,5 +10,6 @@ namespace DaSaSo.Domain.Model
|
|||||||
{
|
{
|
||||||
public string Name { get; set; }
|
public string Name { get; set; }
|
||||||
public Client Client { get; set; }
|
public Client Client { get; set; }
|
||||||
|
public IEnumerable<Buildingsite> BuildingSites { get; set; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
6
DaSaSo.Domain/Model/SewerObjects.cs
Normal file
6
DaSaSo.Domain/Model/SewerObjects.cs
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
namespace DaSaSo.Domain.Model
|
||||||
|
{
|
||||||
|
public class SewerObjects
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -5,4 +5,17 @@
|
|||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="6.0.0-preview.7.21378.4" />
|
||||||
|
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="6.0.0-preview.7.21378.4">
|
||||||
|
<PrivateAssets>all</PrivateAssets>
|
||||||
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||||
|
</PackageReference>
|
||||||
|
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="6.0.0-preview7" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\DaSaSo.Domain\DaSaSo.Domain.csproj" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
|||||||
@@ -15,5 +15,8 @@ namespace DaSaSo.EntityFramework
|
|||||||
}
|
}
|
||||||
|
|
||||||
public DbSet<Client> Clients { get; set; }
|
public DbSet<Client> Clients { get; set; }
|
||||||
|
public DbSet<Project> Projects { get; set; }
|
||||||
|
public DbSet<Buildingsite> Buildingsites { get; set; }
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ namespace DaSaSo.EntityFramework
|
|||||||
{
|
{
|
||||||
public class DaSaSoDbContextFactory : IDesignTimeDbContextFactory<DaSaSoDbContext>
|
public class DaSaSoDbContextFactory : IDesignTimeDbContextFactory<DaSaSoDbContext>
|
||||||
{
|
{
|
||||||
public DaSaSoDbContext CreateDbContext(string[] args)
|
public DaSaSoDbContext CreateDbContext(string[] args = null)
|
||||||
{
|
{
|
||||||
var options = new DbContextOptionsBuilder<DaSaSoDbContext>();
|
var options = new DbContextOptionsBuilder<DaSaSoDbContext>();
|
||||||
options.UseNpgsql("server = localhost");
|
options.UseNpgsql("server = localhost");
|
||||||
|
|||||||
Reference in New Issue
Block a user