shoc-backend/SeaHaven.DataServices/Interfaces/WorkOrderAdvancedSearchModels.cs
Alexandre Brandizzi 3019e71093 feat(workorders): filter board search to an exact work-order id set
GET /board/search accepts ids=1,2,3 (positive ints, deduplicated, at most
200). When present the result is exactly those work orders inside the
caller's tenant and base scope; date, status, dispatcher, facet and text
filters are ignored so none of them can hide a listed work order.
Malformed or oversized lists are a 400.
2026-09-25 10:56:47 -03:00

42 lines
1.3 KiB
C#

using Data.SeaHavenIndustries.Enums;
using SeaHaven.DataServices.Interfaces;
namespace SeaHaven.DataServices.Interfaces
{
public record WorkOrderAdvancedSearchQuery(
string? Search,
DateOnly DateFrom,
DateOnly DateTo,
bool UnscheduledOnly,
IReadOnlyList<string>? Sites,
IReadOnlyList<string>? Regions,
IReadOnlyList<WorkOrderType>? Types,
bool Overdue,
IReadOnlyList<string>? Dispatchers,
IReadOnlyList<LifecycleStatus>? Statuses,
IReadOnlyList<string>? PmTypes,
IReadOnlyList<int>? VendorIds,
IReadOnlyList<DocStatus>? DocStatuses,
IReadOnlyList<int>? Severities,
bool Rescheduled,
bool CarriedOver,
bool AddOn,
bool AvetaOnly,
IReadOnlyList<string>? FlagColors,
bool InternalOnly,
bool HasUplift,
IReadOnlyList<string>? UpliftStatuses,
bool MyWorkOrders,
string? CurrentUserId,
int Page,
int PageSize,
string SortBy,
string SortDir,
int? AccountId = null,
bool IncludeDateless = false,
IReadOnlyList<int>? Ids = null);
public record WorkOrderAdvancedSearchResult(
IReadOnlyList<WorkOrderBoardRawRow> Rows,
int TotalCount);
}