-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDesignVersion.cs
More file actions
58 lines (41 loc) · 1.37 KB
/
DesignVersion.cs
File metadata and controls
58 lines (41 loc) · 1.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace ShedBuilder.Api.Models;
[Table("design_versions")]
public class DesignVersion
{
[Key]
[Column("id")]
public Guid Id { get; set; }
[Column("design_id")]
public Guid DesignId { get; set; }
[ForeignKey(nameof(DesignId))]
public Design Design { get; set; } = null!;
[Column("version_number")]
public int VersionNumber { get; set; }
[MaxLength(200)]
[Column("label")]
public string Label { get; set; } = string.Empty;
[Column("width_feet")]
public int WidthFeet { get; set; }
[Column("width_inches")]
public int WidthInches { get; set; }
[Column("depth_feet")]
public int DepthFeet { get; set; }
[Column("depth_inches")]
public int DepthInches { get; set; }
[Column("height_feet")]
public int HeightFeet { get; set; }
[Column("height_inches")]
public int HeightInches { get; set; }
[Column("roof_pitch")]
public decimal RoofPitch { get; set; }
[Column("roof_type")]
public RoofType RoofType { get; set; }
[Column("roof_overhang_inches")]
public int RoofOverhangInches { get; set; } = 12;
[Column("openings", TypeName = "jsonb")]
public List<Opening> Openings { get; set; } = new();
[Column("created_at")]
public DateTime CreatedAt { get; set; }
}