shoc-backend/Data.SeaHavenIndustries/Models/Locations.cs

41 lines
1.5 KiB
C#
Raw Normal View History

using System.ComponentModel.DataAnnotations.Schema;
2024-09-28 14:58:36 -04:00
namespace Data.SeaHavenIndustries
{
public class Locations : FullAuditEntity
{
2026-04-28 18:55:14 -05:00
public int Id { get; set; }
public int? AccountId { get; set; }
[ForeignKey(nameof(AccountId))]
public Accounts? Account { get; set; }
2024-09-28 14:58:36 -04:00
public string? Title { get; set; }
public string? Name { get; set; }
2026-04-28 18:55:14 -05:00
public string? Latitude { get; set; }
public string? Longitude { get; set; }
// Address fields - match actual database columns
public string? Address1 { get; set; }
public string? Address2 { get; set; }
public string? City { get; set; }
public string? State { get; set; }
2026-04-28 18:55:14 -05:00
public string? Zip { get; set; }
// Contact fields - match actual database columns
public string? PhoneNumber { get; set; }
public string? Email { get; set; }
public string? Status { get; set; }
public string? ExternalSource { get; set; }
public string? ExternalLocationId { get; set; }
2026-04-28 18:55:14 -05:00
/// <summary>Free-text site notes, edited from the work-order Site dialog.</summary>
public string? Notes { get; set; }
2026-04-28 18:55:14 -05:00
// Navigation Properties
2024-09-28 14:58:36 -04:00
public ICollection<Template>? Templates { get; set; }
public ICollection<WorkOrder>? workOrders { get; set; }
// SH-138: site contacts (soft-deleted rows stay for historical WorkOrderContacts)
public ICollection<Contacts>? Contacts { get; set; }
2024-09-28 14:58:36 -04:00
}
}