From a6a1a08439147ae269c39254396f397bba3c28bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=CD=8B=CC=B5=CD=89=CC=94=CD=9Ea=CC=A4=CD=98=CC=84=CD=83?= =?UTF-8?q?=CC=8Dl=CC=99=CC=91=CC=BE=CD=96=CD=A3l=CC=99=CC=91=CC=BE=CD=96?= =?UTF-8?q?=CD=A3u=CD=95=CC=87=CC=A1=CC=AD=CC=9Bm=CD=85=CD=81=CC=AC=CC=8F?= =?UTF-8?q?=CD=A4=20M=CC=85=CD=AE=CD=92=CD=89=CD=A4a=CC=A4=CD=98=CC=84?= =?UTF-8?q?=CD=83=CC=8Dc=CC=95=CD=95=CD=97=CD=A4=CC=95p=CC=9A=CC=88=CC=9E?= =?UTF-8?q?=CD=91=CD=9Eh=CC=96=CC=87=CD=9B=CC=93=CC=BBe=CC=95=CC=A3=CC=BF?= =?UTF-8?q?=CD=8B=CC=92r=CC=A6=CD=95=CC=9D=CC=B4=CC=A8s=CC=A0=D2=89=CD=85?= =?UTF-8?q?=CD=8A=CD=8Do=CC=8A=CD=A2=CC=AF=CC=B1=CD=8An=CC=A3=CD=9B=CC=92?= =?UTF-8?q?=CC=8D=CC=A4?= <88662046+LBHCallumM@users.noreply.github.com> Date: Mon, 16 Feb 2026 11:41:58 +0000 Subject: [PATCH] Merge pull request #1272 from LBHackney-IT/callum/show-appointments-for-planned-gas-jobs Allow planned gas jobs to be scheduled --- src/models/workOrder.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/models/workOrder.ts b/src/models/workOrder.ts index 5ea58bba8..7106f48b1 100644 --- a/src/models/workOrder.ts +++ b/src/models/workOrder.ts @@ -1,5 +1,6 @@ import { HIGH_PRIORITY_CODES, + PLANNED_PRIORITY_CODE, PRIORITY_CODES_REQUIRING_APPOINTMENTS, } from '@/utils/helpers/priorities' @@ -57,10 +58,17 @@ export class WorkOrder { return PRIORITY_CODES_REQUIRING_APPOINTMENTS.includes(this.priorityCode) } + isPlannedGasBreakdownJob = () => { + return ( + this.priorityCode === PLANNED_PRIORITY_CODE && + this.contractorReference === 'H04' + ) + } + canBeScheduled = () => { return ( this.statusAllowsScheduling() && - this.isAppointmentRequired() && + (this.isAppointmentRequired() || this.isPlannedGasBreakdownJob()) && !this.isOutOfHoursGas() ) }