[IMP]pms_api_rest: added internal_commit in folio GET and POST services

This commit is contained in:
braisab
2022-11-08 14:12:44 +01:00
committed by Darío Lodeiros
parent 77c08b0473
commit 1f808d6a43
2 changed files with 5 additions and 0 deletions

View File

@@ -35,6 +35,7 @@ class PmsFolioInfo(Datamodel):
externalReference = fields.String(required=False, allow_none=True)
closureReasonId = fields.Integer(required=False, allow_none=True)
preconfirm = fields.Boolean(required=False, allow_none=True)
internalComment = fields.String(required=False, allow_none=True)
class PmsFolioShortInfo(Datamodel):

View File

@@ -48,6 +48,9 @@ class PmsFolioService(Component):
reservationType=folio.reservation_type,
pendingAmount=folio.pending_amount,
lastCheckout=str(folio.last_checkout),
internalComment=folio.internal_comment
if folio.internal_comment
else None,
)
else:
raise MissingError(_("Folio not found"))
@@ -360,6 +363,7 @@ class PmsFolioService(Component):
if pms_folio_info.agencyId
else False,
"reservation_type": pms_folio_info.reservationType,
"internal_comment": pms_folio_info.internalComment,
}
if pms_folio_info.partnerId:
vals.update(