Creating all entities for subject 2

This commit is contained in:
2025-09-26 16:18:22 +01:00
parent cd0e4e6431
commit 1078244eeb
12 changed files with 146 additions and 4 deletions

15
PyroFetes/Models/Price.cs Normal file
View File

@@ -0,0 +1,15 @@
using System.ComponentModel.DataAnnotations;
using Microsoft.EntityFrameworkCore;
namespace PyroFetes.Models;
[PrimaryKey(nameof(ProductId), nameof(SupplierId))]
public class Price
{
[Required] public int ProductId { get; set; }
[Required] public int SupplierId { get; set; }
[Required] public decimal SellingPrice { get; set; }
public Product? Product { get; set; }
public Supplier? Supplier { get; set; }
}