summaryrefslogtreecommitdiff
path: root/addons/point_of_sale/tests
diff options
context:
space:
mode:
authorGert Pellin <gpe@odoo.com>2019-06-26 06:11:18 +0000
committerPierre Masereel <pim@odoo.com>2019-08-19 14:15:25 +0000
commit118190f3b3ecde11d7bcb46301af0e016d6ea19f (patch)
tree6f6d8c14afae6358c53ae38b8cbdf34b5a9058cf /addons/point_of_sale/tests
parent761f695e0da7f2b3bfb817f9d1f810d44e7b4dbd (diff)
[IMP] point_of_sale, pos_restaurant: multi-user sessions
PURPOSE ========= When working in restaurants, there are often more than one waiter working on the same floor. But Odoo doesn't support that. There can only be one person working on one session for the same tables. The purpose of this task to allow several people to work on the same session (while synchronizing sessions). SPECIFICATIONS =============== - MultiUser is active by default. - Allow multiple waiters to login on one PoS Config. - All waiters login to the same session, the waiter that does the paiment is the responsible for the order (same as now). - Synchonize the information across the multiple instances running on same floors. Syncronisation will take place at switch of table. (close tables automaticly if no activity, to force sync) - Syncro cannot be done if no internet : how do we manage it ? We should inform the user the internet connection has been lost and that synchro cannot be done. What impacts? To check Useful links https://github.com/it-projects-llc/pos-addons https://apps.odoo.com/apps/modules/11.0/pos_bus_restaurant/ Related PR: odoo#32789 TASK-ID: 1891130 closes odoo/odoo#33973 Signed-off-by: pimodoo <pimodoo@users.noreply.github.com>
Diffstat (limited to 'addons/point_of_sale/tests')
-rw-r--r--addons/point_of_sale/tests/test_frontend.py4
-rw-r--r--addons/point_of_sale/tests/test_point_of_sale_flow.py4
2 files changed, 2 insertions, 6 deletions
diff --git a/addons/point_of_sale/tests/test_frontend.py b/addons/point_of_sale/tests/test_frontend.py
index 593c88876dc..772741a188d 100644
--- a/addons/point_of_sale/tests/test_frontend.py
+++ b/addons/point_of_sale/tests/test_frontend.py
@@ -323,9 +323,9 @@ class TestUi(odoo.tests.HttpCase):
# this you end up with js, css but no qweb.
env['ir.module.module'].search([('name', '=', 'point_of_sale')], limit=1).state = 'installed'
- self.start_tour("/pos/web", 'pos_pricelist', login="admin")
+ self.start_tour("/pos/web?config_id=%d" % main_pos_config.id, 'pos_pricelist', login="admin")
- self.start_tour("/pos/web", 'pos_basic_order', login="admin")
+ self.start_tour("/pos/web?config_id=%d" % main_pos_config.id, 'pos_basic_order', login="admin")
for order in env['pos.order'].search([]):
self.assertEqual(order.state, 'paid', "Validated order has payment of " + str(order.amount_paid) + " and total of " + str(order.amount_total))
diff --git a/addons/point_of_sale/tests/test_point_of_sale_flow.py b/addons/point_of_sale/tests/test_point_of_sale_flow.py
index 3466b4ca112..b42b8129cfe 100644
--- a/addons/point_of_sale/tests/test_point_of_sale_flow.py
+++ b/addons/point_of_sale/tests/test_point_of_sale_flow.py
@@ -540,10 +540,6 @@ class TestPointOfSaleFlow(TestPointOfSaleCommon):
self.PosOrder.create_from_ui([carrot_order])
self.assertEqual(num_starting_orders + 1, len(current_session.order_ids), "Submitted order not encoded")
- # I resubmit the same order
- self.PosOrder.create_from_ui([carrot_order])
- self.assertEqual(num_starting_orders + 1, len(current_session.order_ids), "Resubmitted order was not skipped")
-
# I close the session
current_session.action_pos_session_closing_control()
self.assertEqual(current_session.state, 'closed', "Session was not properly closed")