using System;
using System.Collections.Generic;
namespace Disco.Plugins.ServiceTracker.Models
{
///
/// Extended ticket metadata stored alongside Disco Job records.
/// Links to a Disco Job by JobId.
///
public class ServiceTicket
{
public int JobId { get; set; }
public string PriorityId { get; set; }
public string LocationId { get; set; }
public string AssignedTechId { get; set; }
public DateTime? EstimatedCompletion { get; set; }
public DateTime? SlaDeadline { get; set; }
public string StatusOverride { get; set; }
public string Summary { get; set; }
public List Notes { get; set; }
public DateTime CreatedDate { get; set; }
public DateTime LastModifiedDate { get; set; }
public string LastModifiedBy { get; set; }
public ServiceTicket()
{
Notes = new List();
CreatedDate = DateTime.Now;
LastModifiedDate = DateTime.Now;
}
}
public class TicketNote
{
public string Id { get; set; }
public string AuthorId { get; set; }
public string AuthorName { get; set; }
public DateTime Timestamp { get; set; }
public string Content { get; set; }
public string NoteType { get; set; } // "update", "escalation", "resolution", "general"
public TicketNote()
{
Id = Guid.NewGuid().ToString("N").Substring(0, 8);
Timestamp = DateTime.Now;
NoteType = "general";
}
}
}