mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-07-27 23:35:01 +00:00
tweaks
This commit is contained in:
parent
f32628b293
commit
18dfda038d
3 changed files with 3 additions and 16 deletions
|
|
@ -42,10 +42,8 @@ class AbriTriggerRequest(BaseModel):
|
|||
confirmed_survey_time: Optional[str] = None
|
||||
last_submission_date: Optional[date] = None
|
||||
outcome: Optional[str] = None
|
||||
# OpenHousing's bookable resource for the survey; required by the log
|
||||
# and amend flows. A blank resource does not error at the relay —
|
||||
# OpenHousing silently drops the appointment — so blank is treated as
|
||||
# missing and fails the per-flow validation instead.
|
||||
# OpenHousing's bookable resource for the survey; required by the log and
|
||||
# amend flows. Empty string is also rejected by Abri, so not allowed here
|
||||
third_party_surveyor_identifier: Optional[str] = None
|
||||
|
||||
@field_validator("third_party_surveyor_identifier")
|
||||
|
|
|
|||
|
|
@ -44,9 +44,6 @@ class LogJobRequest:
|
|||
appointment_time: SlotCode
|
||||
short_description: str
|
||||
long_description: str
|
||||
# The bookable OpenHousing resource. Mandatory: a missing or blank
|
||||
# resource does not error at the relay — OpenHousing logs the job but
|
||||
# silently drops the appointment.
|
||||
resource: str
|
||||
|
||||
|
||||
|
|
@ -71,9 +68,6 @@ class AmendJobRequest:
|
|||
job_no: str
|
||||
appointment_date: date
|
||||
appointment_time: SlotCode
|
||||
# The bookable OpenHousing resource. Mandatory: a missing or blank
|
||||
# resource does not error at the relay — OpenHousing silently drops
|
||||
# the appointment.
|
||||
resource: str
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -244,9 +244,7 @@ class HubspotDealDiffer:
|
|||
flows.append("abandon_job")
|
||||
|
||||
if not flows:
|
||||
logger.info(
|
||||
"No Abri flows triggered for HubSpot deal %s", hubspot_deal_id
|
||||
)
|
||||
logger.info("No Abri flows triggered for HubSpot deal %s", hubspot_deal_id)
|
||||
return None
|
||||
|
||||
logger.info(
|
||||
|
|
@ -267,9 +265,6 @@ class HubspotDealDiffer:
|
|||
else None
|
||||
),
|
||||
"confirmed_survey_time": new_deal.get("confirmed_survey_time"),
|
||||
# Carried for the log/amend flows: sent to OpenHousing as the
|
||||
# bookable resource. Mandatory for those flows — a deal without
|
||||
# it fails the message contract's validation and dead-letters.
|
||||
"third_party_surveyor_identifier": new_deal.get(
|
||||
"third_party_surveyor_identifier"
|
||||
),
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue