diff --git a/addons/base_import/models/base_import.py b/addons/base_import/models/base_import.py index e970d1ca3ad..6a2f6b729bc 100644 --- a/addons/base_import/models/base_import.py +++ b/addons/base_import/models/base_import.py @@ -453,7 +453,7 @@ class Import(models.TransientModel): :rtype: (None, None) | (list(str), dict(int: list(str))) """ if not options.get('headers'): - return None, None + return [], {} headers = next(rows) return headers, { diff --git a/addons/base_import/tests/test_base_import.py b/addons/base_import/tests/test_base_import.py index 0502af6d0ab..a0031c192e9 100644 --- a/addons/base_import/tests/test_base_import.py +++ b/addons/base_import/tests/test_base_import.py @@ -152,7 +152,7 @@ class TestMatchHeadersMultiple(TransactionCase): def test_noheaders(self): self.assertEqual( - self.env['base_import.import']._match_headers([], [], {}), (None, None) + self.env['base_import.import']._match_headers([], [], {}), ([], {}) ) def test_nomatch(self): diff --git a/addons/point_of_sale/static/src/js/db.js b/addons/point_of_sale/static/src/js/db.js index c2b3fad52f0..ccdd0fb6616 100644 --- a/addons/point_of_sale/static/src/js/db.js +++ b/addons/point_of_sale/static/src/js/db.js @@ -477,6 +477,13 @@ var PosDB = core.Class.extend({ } return orders; }, + set_cashier: function(cashier) { + // Always update if the user is the same as before + this.save('cashier', cashier); + }, + get_cashier: function() { + return this.load('cashier'); + } }); return PosDB; diff --git a/addons/point_of_sale/static/src/js/models.js b/addons/point_of_sale/static/src/js/models.js index 9b222f12922..4edff2ce8ea 100644 --- a/addons/point_of_sale/static/src/js/models.js +++ b/addons/point_of_sale/static/src/js/models.js @@ -240,6 +240,7 @@ exports.PosModel = Backbone.Model.extend({ } self.db.set_uuid(self.config.uuid); + self.cashier = self.get_cashier(); var orders = self.db.get_orders(); for (var i = 0; i < orders.length; i++) { @@ -572,11 +573,12 @@ exports.PosModel = Backbone.Model.extend({ // returns the user who is currently the cashier for this point of sale get_cashier: function(){ - return this.cashier || this.user; + return this.db.get_cashier() || this.cashier || this.user; }, // changes the current cashier set_cashier: function(user){ this.cashier = user; + this.db.set_cashier(this.cashier); }, //creates a new empty order and sets it as the current order add_new_order: function(){ diff --git a/doc/setup/deploy.rst b/doc/setup/deploy.rst index ec1a31e0a3c..eb5d4cec144 100644 --- a/doc/setup/deploy.rst +++ b/doc/setup/deploy.rst @@ -213,6 +213,10 @@ Instead you must have a proxy redirecting requests whose URL starts with ``/longpolling/`` to the longpolling port. Other request should be proxied to the :option:`normal HTTP port ` +.. warning:: The livechat worker requires the ``psycogreen`` Python module, + which is not always included with all installation packages. + It can be manually installed with ``pip install psycogreen``. + Configuration sample -------------------- diff --git a/odoo/addons/base/base.sql b/odoo/addons/base/base.sql index 3e3a765a280..56934e13032 100644 --- a/odoo/addons/base/base.sql +++ b/odoo/addons/base/base.sql @@ -94,7 +94,7 @@ CREATE TABLE ir_module_module ( website character varying(256), summary character varying(256), name character varying(128) NOT NULL, - author character varying(128), + author character varying, icon varchar, state character varying(16), latest_version character varying(64),