21 lines
448 B
C#
21 lines
448 B
C#
using System.ComponentModel.DataAnnotations;
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
|
|
|
namespace CandyHouseDataBase.Models;
|
|
|
|
public class Ingredient
|
|
{
|
|
[Key]
|
|
public string Id { get; set; } = Guid.NewGuid().ToString();
|
|
|
|
[Required]
|
|
public string Name { get; set; }
|
|
|
|
[Required]
|
|
public string Unit { get; set; }
|
|
|
|
[Required]
|
|
public decimal Cost { get; set; }
|
|
|
|
public List<Recipe> Recipes { get; set; }
|
|
} |