ключи для исполнителя
This commit is contained in:
parent
dda1172394
commit
06c1f429eb
@ -10,9 +10,9 @@
|
||||
<PackageReference Include="Microsoft.Extensions.Logging" Version="8.0.0" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\LawCompanyDataModels\LawCompanyDataModels.csproj" />
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\LawCompanyContracts\LawCompanyContracts.csproj" />
|
||||
<ProjectReference Include="..\LawCompany\LawCompanyDataModels.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
@ -2,6 +2,7 @@
|
||||
using LawCompanyContracts.BindingModels;
|
||||
using LawCompanyContracts.ViewModels;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace LawCompanyDatabaseImplement.Models
|
||||
{
|
||||
@ -15,6 +16,13 @@ namespace LawCompanyDatabaseImplement.Models
|
||||
[Required]
|
||||
public string Password { get; private set; } = string.Empty;
|
||||
|
||||
[ForeignKey("ExecutorId")]
|
||||
public virtual List<Case> Cases { get; set; } = new();
|
||||
[ForeignKey("ExecutorId")]
|
||||
public virtual List<Client> Clients { get; set; } = new();
|
||||
[ForeignKey("ExecutorId")]
|
||||
public virtual List<Visit> Visits { get; set; } = new();
|
||||
|
||||
public static Executor? Create(ExecutorBindingModel? model)
|
||||
{
|
||||
if (model == null)
|
||||
|
Loading…
Reference in New Issue
Block a user