mirror of
https://github.com/OCA/pms.git
synced 2025-01-29 00:17:45 +02:00
[ADD] Button service on day
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
'wizard/massive_changes.xml',
|
||||
'wizard/split_reservation.xml',
|
||||
'wizard/duplicate_reservation.xml',
|
||||
'wizard/service_on_day.xml',
|
||||
'views/res_config.xml',
|
||||
'data/menus.xml',
|
||||
'views/inherited_account_payment_views.xml',
|
||||
|
||||
@@ -34,6 +34,9 @@ class HotelServiceLine(models.Model):
|
||||
|
||||
@api.depends('day_qty', 'service_id.price_total')
|
||||
def _compute_price_total(self):
|
||||
"""
|
||||
Used to reports
|
||||
"""
|
||||
for record in self:
|
||||
record.price_total = (record.service_id.price_total * record.day_qty) / record.service_id.product_qty
|
||||
|
||||
|
||||
@@ -244,6 +244,8 @@
|
||||
<page name="services" string="Services"
|
||||
attrs="{'invisible': ['|',('reservation_type','in',('out')),
|
||||
('parent_reservation','!=',False)]}">
|
||||
<button name="%(action_service_on_day)d" string="Service on Day"
|
||||
type="action" icon="fa-coffee"/>
|
||||
<group string="Reservation Services" name="reservation_services">
|
||||
<field name="service_ids"
|
||||
context="{'default_ser_room_line': active_id, 'default_folio_id': folio_id, 'form_view_ref':'hotel.hotel_service_view_form'}"
|
||||
|
||||
Reference in New Issue
Block a user