New: Report-System using globally available Interfaces.

This commit is contained in:
2026-02-12 19:01:30 +01:00
parent a94527f294
commit 28925a3cfa
21 changed files with 847 additions and 8 deletions

View File

@@ -0,0 +1,51 @@
using System.Collections.Generic;
using System.Threading.Tasks;
using Interfaces;
using SZUAbsolventenverein.Module.ReportSystem.Models;
namespace SZUAbsolventenverein.Module.ReportSystem.Services
{
public interface IReportSystemReportingService
{
Task<Reporting> CreateReportAsync(Reporting reporting);
Task<List<Reporting>> GetReportsAsync(int ModuleId);
Task<Reporting> GetReportAsync(int ReportableId, int ModuleId);
Task<Reporting> UpdateReport(Reporting reporting);
Task DeleteReportingAsync(int ReportingId, int ModuleId);
}
public class ReportSystemReportingService : IReportSystemReportingService, IReportingHandler
{
public void Report(IReportable reportable, string note)
{
CreateReportAsync(new Reporting
{ ModuleId = reportable.ModuleID, EntityId = reportable.EntityID, Note = note, Reason = "Default Reason" });
}
public Task<Reporting> CreateReportAsync(Reporting reporting)
{
throw new System.NotImplementedException();
}
public Task<List<Reporting>> GetReportsAsync(int ModuleId)
{
throw new System.NotImplementedException();
}
public Task<Reporting> GetReportAsync(int ReportableId, int ModuleId)
{
throw new System.NotImplementedException();
}
public Task<Reporting> UpdateReport(Reporting Reporting)
{
throw new System.NotImplementedException();
}
public Task DeleteReportingAsync(int ReportingId, int ModuleId)
{
throw new System.NotImplementedException();
}
}
}