Реализовал все модели смежных таблиц многие ко многим
This commit is contained in:
parent
5805b378b4
commit
7bb90df611
@ -5,13 +5,11 @@ namespace PolyclinicDatabaseImplement.Models
|
|||||||
public class ProcedureRecipe
|
public class ProcedureRecipe
|
||||||
{
|
{
|
||||||
public int Id { get; set; }
|
public int Id { get; set; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
public int ProcedureId { get; set; }
|
public int ProcedureId { get; set; }
|
||||||
|
|
||||||
[Required]
|
[Required]
|
||||||
public int RecipeId { get; set; }
|
public int RecipeId { get; set; }
|
||||||
public virtual Procedure Procedure { get; set; }
|
public virtual Procedure Procedure { get; set; } = new();
|
||||||
public virtual Recipe Recipe { get; set; }
|
public virtual Recipe Recipe { get; set; } = new();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,15 @@
|
|||||||
namespace PolyclinicDatabaseImplement.Models
|
using System.ComponentModel.DataAnnotations;
|
||||||
|
|
||||||
|
namespace PolyclinicDatabaseImplement.Models
|
||||||
{
|
{
|
||||||
public class SymptomRecipe
|
public class SymptomRecipe
|
||||||
{
|
{
|
||||||
|
public int Id { get; set; }
|
||||||
|
[Required]
|
||||||
|
public int SymptomId { get; set; }
|
||||||
|
[Required]
|
||||||
|
public int RecipeId { get; set; }
|
||||||
|
public virtual Symptom Symptom { get; set; } = new();
|
||||||
|
public virtual Recipe Recipe { get; set; } = new();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user