ключи для исполнителя
This commit is contained in:
parent
dda1172394
commit
06c1f429eb
@ -11,8 +11,8 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\LawCompanyDataModels\LawCompanyDataModels.csproj" />
|
|
||||||
<ProjectReference Include="..\LawCompanyContracts\LawCompanyContracts.csproj" />
|
<ProjectReference Include="..\LawCompanyContracts\LawCompanyContracts.csproj" />
|
||||||
|
<ProjectReference Include="..\LawCompany\LawCompanyDataModels.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
using LawCompanyContracts.BindingModels;
|
using LawCompanyContracts.BindingModels;
|
||||||
using LawCompanyContracts.ViewModels;
|
using LawCompanyContracts.ViewModels;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
|
|
||||||
namespace LawCompanyDatabaseImplement.Models
|
namespace LawCompanyDatabaseImplement.Models
|
||||||
{
|
{
|
||||||
@ -15,6 +16,13 @@ namespace LawCompanyDatabaseImplement.Models
|
|||||||
[Required]
|
[Required]
|
||||||
public string Password { get; private set; } = string.Empty;
|
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)
|
public static Executor? Create(ExecutorBindingModel? model)
|
||||||
{
|
{
|
||||||
if (model == null)
|
if (model == null)
|
||||||
|
Loading…
Reference in New Issue
Block a user