mirror of
https://github.com/OCA/pms.git
synced 2025-01-29 00:17:45 +02:00
[IMP]pms: overwrites reservation pricelist saved, company price forced context
This commit is contained in:
@@ -424,13 +424,14 @@ class AvailabilityWizard(models.TransientModel):
|
||||
):
|
||||
room_type_total_price_per_room = 0
|
||||
room_type = self.env["pms.room.type"].browse(room_type_id)
|
||||
pms_property = self.env["pms.property"].browse(pms_property_id)
|
||||
for date_iterator in [
|
||||
checkin + datetime.timedelta(days=x)
|
||||
for x in range(0, (checkout - checkin).days)
|
||||
]:
|
||||
|
||||
product = room_type.product_id
|
||||
product = product.with_context(
|
||||
product = product.with_company(pms_property.company_id).with_context(
|
||||
quantity=1,
|
||||
date=fields.Date.today(),
|
||||
consumption_date=date_iterator,
|
||||
|
||||
Reference in New Issue
Block a user