From 1e30883fbf53678a6d36cd56b3a82aa7e802a559 Mon Sep 17 00:00:00 2001 From: David Vidal Date: Thu, 14 Jun 2018 02:45:32 +0200 Subject: [PATCH] [CI] Fix .rst lint errors (#276) * [CI] Fix .rst lint errors * [FIX] licence Key --- pos_customer_display/README.rst | 4 ++-- pos_customer_display/models/pos_customer_display.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pos_customer_display/README.rst b/pos_customer_display/README.rst index c7e07d2a..958b0ffb 100644 --- a/pos_customer_display/README.rst +++ b/pos_customer_display/README.rst @@ -9,7 +9,7 @@ POS Customer Display This module adds support for Customer Display in the Point of Sale. As incredible as it may seem, the Odoo POS doesn't have native support for a customer display, even on Odoo 10. So, if the customer cannot see the screen of the cashier, he will not be able to check the price of each product scanned by the cashier, he won't be able to see the total amount, etc. This module provides a solution to this problem by adding support for good old POS LCDs, which are often made of 2 lines of 20 caracters. This module is designed to be installed on the *main Odoo server*. On the -*POSbox*, you should install the module *hw_customer_display*. But you will certainly prefer to use `pywebdriver `_ instead of the POSbox. Compared to the POSbox, Pywebdriver has several advantages: +*POSbox*, you should install the module *hw_customer_display*. But you will certainly prefer to use `pywebdriver `__ instead of the POSbox. Compared to the POSbox, Pywebdriver has several advantages: * smaller footprint: no need to have a full-blown Odoo with PostgreSQL on the computer of the cashier (or his small Linux-based PC connected to the hardware, like the RaspberryPi for the POSbox), * availability of an Ubuntu package, for easier deployment, @@ -22,7 +22,7 @@ but should support most serial and USB-serial LCD displays out-of-the-box or with minor adaptations in the source code: * of the module *hw_customer_display* if you use the POSbox, -* or of the Python lib `pyposdisplay `_ if you use `pywebdriver `_. +* or of the Python lib `pyposdisplay `__ if you use `pywebdriver `__. This module has been developped during a POS code sprint at `Akretion France `_ from July 7th to July 10th 2014. diff --git a/pos_customer_display/models/pos_customer_display.py b/pos_customer_display/models/pos_customer_display.py index 03d77fb8..18ae820a 100644 --- a/pos_customer_display/models/pos_customer_display.py +++ b/pos_customer_display/models/pos_customer_display.py @@ -32,12 +32,12 @@ class PosConfig(models.Model): help="Bottom line of the message on the customer display which " "is displayed when POS is closed") - @api.one @api.constrains( 'customer_display_line_length', 'customer_display_msg_next_l1', 'customer_display_msg_next_l2', 'customer_display_msg_closed_l1', 'customer_display_msg_closed_l2') def _check_customer_display_length(self): + self.ensure_one() if self.customer_display_line_length: maxsize = self.customer_display_line_length to_check = {