mirror of
https://github.com/Sea-Haven-Industries/shoc-backend.git
synced 2026-09-30 09:33:13 +00:00
#144 branched from the SH-210 decision-actions commit before the SH-207/SH-208 read-contract corrections landed, so it re-implemented workOrderClosed, attachmentCount, decidedByName, and pendingExposureTotal with stale semantics: it projected WorkerOrderNumber (the CRM external id) instead of InternalWONumber (what the board renders) and summed raw RequestedNTE, which double-counts the new NTE total on vendor-portal rows across sequential approvals. Merge origin/feat/ab/sh-210-uplift-decisions (#141, what lands) in and resolve every conflict in #141's favour, so those fields and their granted-amount exposure math now come from #141 rather than being duplicated here. Keep only the two deltas #144 actually adds on top of #141: - attachmentCount counts non-deleted UpliftEvidence documents on the dispatch, not every completion document, so completion photos no longer inflate the chip; - the queue read resolves the effective work order via the primary-plus-linked (DispatchWorkOrders) convention the sibling reads use, so a dispatch linked only through that table surfaces its WO context, closed flag, and exposure. Covered by an in-memory test and a SQLite relational test that proves the fallback translates to SQL. Drop the superseded attachment-count test that asserted completion documents count, and align the relational test to seed InternalWONumber. |
||
|---|---|---|
| .. | ||
| Accounts.cs | ||
| Addresses.cs | ||
| Area.cs | ||
| Assets.cs | ||
| Category.cs | ||
| Comments.cs | ||
| CompletionDocTemplate.cs | ||
| ContactDetails.cs | ||
| Contacts.cs | ||
| Dispatch.cs | ||
| DispatchChecklistItem.cs | ||
| DispatchSignoff.cs | ||
| DispatchUpliftRequest.cs | ||
| DispatchWorkOrder.cs | ||
| DropdownOption.cs | ||
| Employee.cs | ||
| Events.cs | ||
| FollowUps.cs | ||
| ForgetPasswordCode.cs | ||
| LinkedWorkOrderInfo.cs | ||
| Locations.cs | ||
| PMSchedules.cs | ||
| Quotes.cs | ||
| Service.cs | ||
| SitePreferredVendor.cs | ||
| TaskListTemplate.cs | ||
| TaskListTemplateItem.cs | ||
| Template.cs | ||
| Trade.cs | ||
| TradeCatalog.cs | ||
| Vendor.cs | ||
| VendorAccessToken.cs | ||
| VendorAuditLog.cs | ||
| VendorCompany.cs | ||
| VendorCompletionDocument.cs | ||
| VendorPortalReadModels.cs | ||
| WorkerOrder.cs | ||
| WorkOrderAttachments.cs | ||
| WorkOrderAuditLog.cs | ||
| WorkOrderCategories.cs | ||
| WorkOrderCompletionSnapshot.cs | ||
| WorkOrderContacts.cs | ||
| WorkOrderExternalReceipt.cs | ||
| WorkOrderFieldLock.cs | ||
| WorkOrderReconciliationJob.cs | ||
| WorkOrderWebhookDelivery.cs | ||
| WorkOrderWeekRolledLedger.cs | ||