2025-08-01 11:59:14 +03:00
|
|
|
using Microsoft.EntityFrameworkCore;
|
|
|
|
|
|
2025-07-09 13:09:56 +03:00
|
|
|
namespace OneSwiss.Server.Models;
|
|
|
|
|
|
|
|
|
|
public class ConfigurationRepository : DatabaseObject
|
|
|
|
|
{
|
2025-07-15 19:37:18 +03:00
|
|
|
public Guid InternalId { get; set; }
|
2025-07-09 13:09:56 +03:00
|
|
|
public string Name { get; set; }
|
2025-07-15 19:37:18 +03:00
|
|
|
public string Host { get; set; }
|
|
|
|
|
public int Port { get; set; }
|
|
|
|
|
public bool Deleted { get; set; }
|
2025-07-09 13:09:56 +03:00
|
|
|
public Guid AgentId { get; set; }
|
|
|
|
|
public Guid? CredentialsId { get; set; }
|
2025-09-15 14:32:38 +03:00
|
|
|
public int LastReadVersion { get; set; }
|
2025-09-08 20:24:15 +03:00
|
|
|
|
2025-07-09 13:09:56 +03:00
|
|
|
public Agent Agent { get; set; }
|
2025-09-08 20:24:15 +03:00
|
|
|
|
2025-08-01 11:59:14 +03:00
|
|
|
[DeleteBehavior(DeleteBehavior.SetNull)]
|
2025-07-09 13:09:56 +03:00
|
|
|
public Credentials? Credentials { get; set; }
|
2025-09-08 20:24:15 +03:00
|
|
|
|
2025-07-09 13:09:56 +03:00
|
|
|
public List<ConfigurationRepositoryUser> Users { get; set; }
|
2025-07-15 19:37:18 +03:00
|
|
|
|
|
|
|
|
public override string ToString()
|
2025-09-08 20:24:15 +03:00
|
|
|
{
|
|
|
|
|
return $"{Host}:{Port}/{Name}";
|
|
|
|
|
}
|
2025-07-09 13:09:56 +03:00
|
|
|
}
|