From a02f3bc08567feaf70a316c172dfee4b4f8b0327 Mon Sep 17 00:00:00 2001 From: Vicente Date: Thu, 23 Feb 2023 14:04:49 +0100 Subject: [PATCH] [IMP] pos_pms_link: README && model domain --- pos_pms_link/README.rst | 32 ++++++++++++++++++++++++++++ pos_pms_link/static/src/js/models.js | 3 +-- 2 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 pos_pms_link/README.rst diff --git a/pos_pms_link/README.rst b/pos_pms_link/README.rst new file mode 100644 index 000000000..9deb09675 --- /dev/null +++ b/pos_pms_link/README.rst @@ -0,0 +1,32 @@ +POS PMS LINK +======================= + +**Table of contents** + +.. contents:: + :local: + +POS PMS LINK +----------------------- + +Settings +-------- + +- PMS Service product needs to be avaible in pos (available_in_pos = True) to add it from pms.service.line. +- On pos.config you can mark pay_on_reservation = True to be able to pay with reservations. After that select a pos.payment.method that will be used after selecting the reservation. + + +Add reservation services to pos.order +------------------------------------- + +- While on a pos.order click on the 'Reservation' button. A modal will open, select the desired reservation and the lines will be added as pos.order.lines. + - Only the lines of the service with the current date will be added. + - This will only add the quantity of the lines that is not already linked to another pos.order.line. + +Pay pos.order on pms.reservation +-------------------------------- + +- if pay_on_reservation is active on pos.config, the payment screen will show the payment method: 'Reservation'. +- Click on it and the reservation modal will open, select the resired reservation, the pos.order will be validated and you will be shown the bill printing screen. + - This will add the payment method selected in the pos.config. + - pos.order.lines will be added as pms.service.lines in the reservation. diff --git a/pos_pms_link/static/src/js/models.js b/pos_pms_link/static/src/js/models.js index 0a65b2076..34ee73cc2 100644 --- a/pos_pms_link/static/src/js/models.js +++ b/pos_pms_link/static/src/js/models.js @@ -277,8 +277,7 @@ odoo.define('pos_pms_link.models', function (require) { model: 'pms.reservation', fields: ['name', 'id', 'state', 'service_ids', 'partner_name', 'adults', 'children'], domain: function(self){ - /* return [['state', '=', 'onboard']]; */ - return []; + return [['state', '=', 'onboard']]; }, loaded: function(self, reservations) { self.reservations = reservations;