Projektdateien hinzufügen.

This commit is contained in:
Webtree-design
2025-07-21 20:17:52 +02:00
parent b5367c704f
commit 16d38a8f39
44 changed files with 4613 additions and 0 deletions

View File

@@ -0,0 +1,41 @@
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Webshop.Domain.Entities;
/// <summary>
/// Kundenbewertungen für Produkte.
/// </summary>
public class Review
{
[Key]
public Guid Id { get; set; }
[Required]
[ForeignKey(nameof(Product))]
public Guid ProductId { get; set; }
[ForeignKey(nameof(Customer))]
public Guid? CustomerId { get; set; }
[Required]
[Range(1, 5)]
public int Rating { get; set; }
[MaxLength(100)]
public string? Title { get; set; }
[MaxLength(2000)]
public string? Comment { get; set; }
[Required]
public DateTimeOffset ReviewDate { get; set; }
[Required]
public bool IsApproved { get; set; }
// Navigation Properties
public virtual Product Product { get; set; }
public virtual Customer? Customer { get; set; }
}