24 lines
561 B
C#
24 lines
561 B
C#
using System.ComponentModel.DataAnnotations;
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
|
|
|
namespace SushiBarDatabaseImplement.Models
|
|
{
|
|
public class Promotion
|
|
{
|
|
[Key]
|
|
public int Id { get; set; }
|
|
|
|
[Required]
|
|
public string PromotionName { get; set; } = string.Empty;
|
|
|
|
[Required]
|
|
public float Discount { get; set; }
|
|
|
|
[Required]
|
|
public double TriggeringSum { get; set; }
|
|
|
|
[ForeignKey("PromotionId")]
|
|
public virtual List<Cheque> Cheques { get; set; } = new();
|
|
}
|
|
}
|