2026-09-10 15:46:25 -03:00
|
|
|
using Data.SeaHavenIndustries;
|
2026-06-30 10:09:48 -03:00
|
|
|
using Data.SeaHavenIndustries.Enums;
|
|
|
|
|
|
|
|
|
|
namespace SeaHaven.DataServices.Interfaces
|
|
|
|
|
{
|
|
|
|
|
public record WorkOrderBoardQuery(
|
|
|
|
|
DateOnly WeekStart,
|
|
|
|
|
DateOnly WeekEnd,
|
|
|
|
|
IReadOnlyList<string>? Dispatchers,
|
|
|
|
|
bool MyWorkOrders,
|
|
|
|
|
IReadOnlyList<WorkOrderType>? Types,
|
2026-07-24 18:12:03 -03:00
|
|
|
bool Overdue,
|
2026-06-30 10:09:48 -03:00
|
|
|
string? Search,
|
2026-08-11 10:45:37 -03:00
|
|
|
string? CurrentUserId,
|
|
|
|
|
int? AccountId = null);
|
2026-06-30 10:09:48 -03:00
|
|
|
|
|
|
|
|
public record WorkOrderBoardRawRow(
|
|
|
|
|
int Id,
|
|
|
|
|
string? InternalWONumber,
|
|
|
|
|
int RescheduleCount,
|
|
|
|
|
int CarriedOver,
|
2026-07-30 12:20:07 -03:00
|
|
|
bool IsAddOn,
|
2026-06-30 10:09:48 -03:00
|
|
|
WorkOrderType? WorkOrderType,
|
2026-09-16 18:02:57 -03:00
|
|
|
int? ServiceId,
|
|
|
|
|
string? ServiceNameSnapshot,
|
2026-06-30 10:09:48 -03:00
|
|
|
string? SiteCode,
|
|
|
|
|
string? LocationName,
|
|
|
|
|
string? PocName,
|
|
|
|
|
string? PocPhone,
|
|
|
|
|
string? PocNotes,
|
|
|
|
|
LifecycleStatus? LifecycleStatus,
|
|
|
|
|
string? LegacyStatus,
|
|
|
|
|
string? AssignTo,
|
|
|
|
|
string? DispatcherFirstName,
|
|
|
|
|
string? DispatcherLastName,
|
|
|
|
|
string? Initials,
|
|
|
|
|
string? Color,
|
|
|
|
|
DateTime? DueDate,
|
|
|
|
|
DateTime? ScheduledDate,
|
|
|
|
|
DateTime? ScheduledStart,
|
|
|
|
|
DateTime? ScheduledEnd,
|
|
|
|
|
DateOnly? TargetWeek,
|
|
|
|
|
bool? ScheduleWeekOnly,
|
|
|
|
|
int? VendorId,
|
|
|
|
|
string? VendorName,
|
|
|
|
|
string? TechName,
|
|
|
|
|
string? TechPhone,
|
|
|
|
|
DateTime? DispatchApptDate,
|
|
|
|
|
string? Trade,
|
|
|
|
|
string? Problem,
|
2026-07-17 10:37:23 -03:00
|
|
|
string? ServiceNotes,
|
|
|
|
|
string? ExtraServices,
|
2026-08-13 16:11:36 -03:00
|
|
|
string? AdditionalContacts,
|
2026-06-30 10:09:48 -03:00
|
|
|
DocStatus? DocStatus,
|
2026-07-31 11:58:22 -03:00
|
|
|
DateTime? CompletedDate,
|
2026-07-21 09:42:10 -03:00
|
|
|
string? FlagColor,
|
2026-07-07 11:26:13 -03:00
|
|
|
int? PrimaryDispatchId,
|
2026-06-30 10:09:48 -03:00
|
|
|
byte[]? RowVersion,
|
2026-07-07 11:26:13 -03:00
|
|
|
byte[]? DispatchRowVersion,
|
2026-08-12 09:43:10 -03:00
|
|
|
int PendingUpliftCount,
|
2026-08-13 14:49:56 -03:00
|
|
|
bool HasUplift,
|
|
|
|
|
string? PrimaryUpliftStatus,
|
|
|
|
|
decimal? PrimaryUpliftAmount,
|
2026-08-20 13:22:12 -03:00
|
|
|
string? PrimaryDispatchStatus,
|
2026-08-24 15:14:31 -03:00
|
|
|
bool AvetaRequired,
|
2026-08-25 15:10:45 -03:00
|
|
|
bool HasAvetaDocument,
|
2026-08-24 15:14:31 -03:00
|
|
|
DateOnly? OriginalDate,
|
|
|
|
|
DateOnly? OriginalWeek,
|
2026-09-07 11:46:13 -03:00
|
|
|
bool IsUnscheduled,
|
2026-09-08 21:10:52 -03:00
|
|
|
string? Severity = null,
|
2026-09-10 15:46:25 -03:00
|
|
|
int MediaCount = 0,
|
|
|
|
|
WorkOrderFrozenSite? FrozenSite = null,
|
|
|
|
|
WorkOrderFrozenCompany? FrozenCompany = null,
|
|
|
|
|
WorkOrderFrozenPoc? FrozenPoc = null);
|
2026-06-30 10:09:48 -03:00
|
|
|
|
|
|
|
|
public record WorkOrderBoardQueryResult(
|
|
|
|
|
IReadOnlyList<WorkOrderBoardRawRow> ScheduledRows,
|
|
|
|
|
IReadOnlyList<WorkOrderBoardRawRow> UnscheduledRows,
|
|
|
|
|
int ScheduledTotalBeforeSearch);
|
|
|
|
|
|
|
|
|
|
public record DispatcherLookupRow(
|
|
|
|
|
string Id,
|
|
|
|
|
string FirstName,
|
|
|
|
|
string? LastName,
|
|
|
|
|
string? Initials,
|
|
|
|
|
string? Color);
|
|
|
|
|
}
|