Add Feedback Functions

This commit is contained in:
Andre Beging
2025-04-01 11:34:11 +02:00
parent bf64239625
commit 6d6d79f55a
9 changed files with 435 additions and 42 deletions

View File

@@ -1,78 +1,86 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Data;
using System.Data.Common;
using System.Linq;
using System.Linq.Expressions;
using FoodsharingSiegen.Contracts.Enums;
namespace FoodsharingSiegen.Contracts.Entity
{
/// <summary>
/// The interaction class (a. beging, 21.05.2022)
/// The interaction class (a. beging, 21.05.2022)
/// </summary>
public class Interaction
{
#region Public Properties
/// <summary>
/// Gets or sets the value of the alert (ab)
/// Gets or sets the value of the alert (ab)
/// </summary>
public bool Alert { get; set; }
/// <summary>
/// Gets or sets the value of the created (ab)
/// Gets or sets the value of the created (ab)
/// </summary>
public DateTime Created { get; set; }
/// <summary>
/// Gets or sets the value of the date (ab)
/// Gets or sets the value of the date (ab)
/// </summary>
public DateTime Date { get; set; }
/// <summary>
/// Gets or sets the value of the id (ab)
/// Gets or sets the feedback associated with the interaction.
/// </summary>
[Key] public Guid Id { get; set; }
public InteractionFeedback Feedback { get; set; } = InteractionFeedback.Neutral;
/// <summary>
/// Gets or sets the value of the info (ab)
/// Gets or sets additional information related to feedback for the interaction.
/// </summary>
public string? FeedbackInfo { get; set; }
/// <summary>
/// Gets or sets the value of the id (ab)
/// </summary>
[Key]
public Guid Id { get; set; }
/// <summary>
/// Gets or sets additional information associated with the interaction.
/// </summary>
public string? Info1 { get; set; }
/// <summary>
/// Gets or sets the value of the not needed (ab)
/// Gets or sets the additional information (Info2) associated with the interaction.
/// </summary>
public string? Info2 { get; set; }
/// <summary>
/// Gets or sets the value of the not needed (ab)
/// </summary>
public bool NotNeeded { get; set; }
/// <summary>
/// Gets or sets the value of the prospect (ab)
/// Gets or sets the value of the prospect (ab)
/// </summary>
public Prospect Prospect { get; set; }
/// <summary>
/// Gets or sets the value of the prospect id (ab)
/// Gets or sets the value of the prospect id (ab)
/// </summary>
public Guid ProspectID { get; set; }
/// <summary>
/// Gets or sets the value of the type (ab)
/// Gets or sets the value of the type (ab)
/// </summary>
public InteractionType Type { get; set; }
/// <summary>
/// Gets or sets the value of the user (ab)
/// Gets or sets the value of the user (ab)
/// </summary>
public User User { get; set; }
/// <summary>
/// Gets or sets the value of the user id (ab)
/// Gets or sets the value of the user id (ab)
/// </summary>
public Guid UserID { get; set; }
#endregion
}
}
}

View File

@@ -0,0 +1,12 @@
namespace FoodsharingSiegen.Contracts.Enums
{
/// <summary>
/// Represents the types of feedback that can be associated with an interaction.
/// </summary>
public enum InteractionFeedback
{
Neutral = 10,
Positive = 20,
Negative = 30
}
}