реализованы классы-представления в контрактах

This commit is contained in:
Елена Бакальская 2024-04-24 18:34:15 +04:00
parent 88df65662c
commit 8763406288
5 changed files with 94 additions and 6 deletions

View File

@ -6,12 +6,6 @@
<Nullable>enable</Nullable> <Nullable>enable</Nullable>
</PropertyGroup> </PropertyGroup>
<ItemGroup>
<Folder Include="StoragesContracts\" />
<Folder Include="ViewModels\" />
<Folder Include="BusinessLogicsContracts\" />
</ItemGroup>
<ItemGroup> <ItemGroup>
<ProjectReference Include="..\PolyclinicDataModels\PolyclinicDataModels.csproj" /> <ProjectReference Include="..\PolyclinicDataModels\PolyclinicDataModels.csproj" />
</ItemGroup> </ItemGroup>

View File

@ -0,0 +1,23 @@
using PolyclinicDataModels.Models;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PolyclinicContracts.ViewModels
{
public class MedicamentView : IMedicamentModel
{
public int Id { get; set; }
[DisplayName("Название медикамента")]
public string Name { get; set; } = string.Empty;
[DisplayName("Комментарий")]
public string Comment { get; set; } = string.Empty;
public Dictionary<int, ISymptomModel> MedicamentSymptom { get; set; } = new();
public Dictionary<int, IProcedureModel> MedicamentProcedure { get; set; } = new();
}
}

View File

@ -0,0 +1,24 @@
using PolyclinicDataModels.Models;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PolyclinicContracts.ViewModels
{
public class ProcedureView : IProcedureModel
{
public int Id { get; set; }
[DisplayName("Название процедуры")]
public string Name { get; set; }
[DisplayName("Комментарий")]
public string Comment { get; set; }
public Dictionary<int, ICourseModel> ProcedureCourse { get; set; } = new();
}
}

View File

@ -0,0 +1,23 @@
using PolyclinicDataModels.Models;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PolyclinicContracts.ViewModels
{
public class RecipeView : IRecipeModel
{
public int Id { get; set; }
[DisplayName("Количество процедур")]
public int CountProcedures { get; set; }
[DisplayName("Комментарий")]
public string Comment { get; set; } = string.Empty;
public Dictionary<int, IRecipeModel> ProcedureRecipe { get; set; } = new();
}
}

View File

@ -0,0 +1,24 @@
using PolyclinicDataModels.Models;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace PolyclinicContracts.ViewModels
{
public class SuretorView : ISuretorModel
{
public int Id { get; set; }
[DisplayName("ФИО поручителя")]
public string FIO { get; set; } = string.Empty;
public string Password { get; set; } = "123";
[DisplayName("Почта")]
public string Email { get; set; } = string.Empty;
}
}