From e23b09c3022d5e302ce3264d5bd6293d3470251f Mon Sep 17 00:00:00 2001 From: braisab Date: Thu, 25 Aug 2022 22:20:15 +0200 Subject: [PATCH] [REF]pms_api_rest: added max availability in avail plan rule post service --- pms_api_rest/services/pms_availability_plan_service.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pms_api_rest/services/pms_availability_plan_service.py b/pms_api_rest/services/pms_availability_plan_service.py index 8b0a4e2ce7..425363f265 100644 --- a/pms_api_rest/services/pms_availability_plan_service.py +++ b/pms_api_rest/services/pms_availability_plan_service.py @@ -175,6 +175,8 @@ def create_availability_plan_rule( vals.update({"closed_arrival": avail_plan_rule.closedArrival}) if avail_plan_rule.quota is not None: vals.update({"quota": avail_plan_rule.quota}) + if avail_plan_rule.maxAvailability is not None: + vals.update({"max_avail": avail_plan_rule.maxAvailability}) avail_rule = self.env["pms.availability.plan.rule"].search( [ ("availability_plan_id", "=", avail_plan_rule.availabilityPlanId),