using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; using Newtonsoft.Json; using OnecMonitor.Server.Converters.Json; using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using System.Linq; using System.Linq.Expressions; using System.Text; using System.Threading.Tasks; namespace OnecMonitor.Server.Models { public class LogTemplate { public Guid Id { get; init; } public string Name { get; set; } = string.Empty; public string Content { get; set; } = string.Empty; public List Seances { get; set; } = new(); public override bool Equals(object? obj) { return obj is LogTemplate log && Id.Equals(log.Id); } public override int GetHashCode() { return HashCode.Combine(Id); } public static Guid ServerMonitoringId => new("dc610b92-6851-4f13-8cb4-78d457cb74c1"); public static string ServerMonitoringTemplate => """ """; public static Guid WaitingsOnManagedLocksId => new("35eb7ecf-1280-4c82-9513-2c5bfd2a7dda"); public static string WaitingsOnManagedLocksTemplate => """ """; public static Guid TimeoutsOnManagedLocksId => new("f869c902-37a2-414c-8002-c46e18362948"); public static string TimeoutsOnManagedLocksTemplate => """ """; public static Guid DeadlocksOnManagedLocksId => new("d4f5551a-995a-480c-8487-e30d96605c1a"); public static string CallsScallTemplate => """ """; public static Guid CallScallsId => new("f20908d6-2c2c-4a7b-82e4-4c62b6a8f99a"); public static string DeadlocksOnManagedLocksTemplate => """ """; public static Guid FullId => new("54695318-0ca1-4c95-896f-731872fb1c0e"); public static string FullTemplate => """ """; public static Guid[] BuiltInTemplatesIds => new[] { ServerMonitoringId, WaitingsOnManagedLocksId, TimeoutsOnManagedLocksId, DeadlocksOnManagedLocksId, CallScallsId, FullId }; } }