2024-03-13 10:24:19 +04:00
|
|
|
|
using System.ComponentModel.DataAnnotations;
|
2024-06-18 21:09:07 +04:00
|
|
|
|
using System.Runtime.Serialization;
|
2024-03-13 10:24:19 +04:00
|
|
|
|
|
|
|
|
|
namespace SushiBarDatabaseImplement.Models
|
|
|
|
|
{
|
2024-06-18 21:09:07 +04:00
|
|
|
|
[DataContract]
|
|
|
|
|
public class SushiComponent
|
2024-03-13 10:24:19 +04:00
|
|
|
|
{
|
2024-06-18 21:09:07 +04:00
|
|
|
|
[DataMember]
|
|
|
|
|
public int Id { get; set; }
|
|
|
|
|
[DataMember]
|
|
|
|
|
[Required]
|
2024-03-13 10:24:19 +04:00
|
|
|
|
public int SushiId { get; set; }
|
2024-06-18 21:09:07 +04:00
|
|
|
|
[DataMember]
|
|
|
|
|
[Required]
|
2024-03-13 10:24:19 +04:00
|
|
|
|
public int ComponentId { get; set; }
|
2024-06-18 21:09:07 +04:00
|
|
|
|
[DataMember]
|
|
|
|
|
[Required]
|
2024-03-13 10:24:19 +04:00
|
|
|
|
public int Count { get; set; }
|
2024-06-18 21:09:07 +04:00
|
|
|
|
public virtual Component Component { get; set; } = new();
|
2024-03-13 10:24:19 +04:00
|
|
|
|
public virtual Sushi Sushi { get; set; } = new();
|
|
|
|
|
}
|
|
|
|
|
}
|