-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathProject.cs
46 lines (41 loc) · 1.05 KB
/
Project.cs
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
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Text;
namespace DataModel
{
public class Project : DocumentBase
{
private string _CompanyGlobalId;
/// <summary>
/// The <see cref="Company.GlobalId"/> of the company that the project refers to.
/// </summary>
public string CompanyGlobalId
{
get => _CompanyGlobalId;
set
{
_CompanyGlobalId = value;
this.Partition = $"company:{value}";
}
}
private Company _Company;
/// <summary>
/// The company associated with the project.
/// </summary>
[JsonIgnore]
public Company Company
{
get => _Company;
set
{
_Company = value;
this.CompanyGlobalId = value?.GlobalId;
}
}
/// <summary>
/// The name of the project.
/// </summary>
public string Name { get; set; }
}
}