Skip to content

Commit

Permalink
#21 - updated space model. added properties
Browse files Browse the repository at this point in the history
  • Loading branch information
sipakov committed May 23, 2023
1 parent 8b35d5e commit 280dc87
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 71 deletions.
26 changes: 0 additions & 26 deletions AlgoTecture.Domain/Models/SpaceDetails.cs

This file was deleted.

2 changes: 1 addition & 1 deletion AlgoTecture.Domain/Models/SpaceProperty.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ public class SpaceProperty

public string Description { get; set; }

public SpaceDetails SpaceDetails { get; set; }
public Dictionary<string, string> Properties { get; set; }

public long OwnerId { get; set; }

Expand Down
2 changes: 1 addition & 1 deletion AlgoTecture.Domain/Models/SubSpace.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public SubSpace()

private List<SubSpace> _subSpaces;

public SubSpaceDetails SubSpaceDetails { get; set; }
public List<Dictionary<string, string>> Properties { get; set; }

public double Area { get; set; }

Expand Down
12 changes: 0 additions & 12 deletions AlgoTecture.Domain/Models/SubSpaceDetails.cs

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -20,45 +20,21 @@ public void ConversationClassToJsonSimpleTest()
{
Name = string.Empty,
Description = string.Empty,
SpaceDetails = new SpaceDetails
{
BuildingYear = "2023",
BuildingName = string.Empty,
Levels = "3",
Area = "456.4",
Flats = "1",
FloorArea = "674",
BuildingClass = "Gebäude mit 1 Wohnung",
BuildingCategory = "Andere Wohngebäude",
PlaceName = "Werthenstein",
MunicipalityId = "1009",
MunicipalityName = "Werthenstein"
},
Properties = new Dictionary<string, string>(){{"BuildingName", "Name"}, {"Area", "100"}},

SubSpaces = new List<AddSubSpaceModel>()
{
new AddSubSpaceModel
{
UtilizationTypeId = 1,
Description = string.Empty,
SubSpaceDetails = new SubSpaceDetails
{
Levels = "1",
Area = "300",
Flats = "1",
FloorArea = "477",
}
Properties = new Dictionary<string, string>(){{"Levels", "2"}, {"Area", "45"}}
},
new AddSubSpaceModel
{
UtilizationTypeId = 1,
Description = string.Empty,
SubSpaceDetails = new SubSpaceDetails
{
Levels = "2",
Area = "200",
Flats = "1",
FloorArea = "287",
}
Properties = new Dictionary<string, string>(){{"Levels", "2"}, {"Area", "44"}}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ public class AddSpacePropertyModel
public string Name { get; set; }

public string Description { get; set; }

public SpaceDetails SpaceDetails { get; set; }
public Dictionary<string, string> Properties { get; set; }

public List<AddSubSpaceModel> SubSpaces { get; set; }
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public AddSubSpaceModel()

private List<AddSubSpaceModel> _subSpaces;

public SubSpaceDetails SubSpaceDetails { get; set; }
public Dictionary<string, string> Properties { get; set; }

public int UtilizationTypeId { get; set; }

Expand Down

0 comments on commit 280dc87

Please sign in to comment.