From 6f5dbdd01a3cf3dc9b8c7ef96edaca16749e13f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20van=20der=20Essen?= Date: Sun, 1 Feb 2015 21:51:15 +0100 Subject: [PATCH] [IMP] point_of_sale: redesign of the empty order. --- addons/point_of_sale/static/src/css/pos.css | 16 +++++++---- addons/point_of_sale/static/src/js/screens.js | 4 +++ addons/point_of_sale/static/src/xml/pos.xml | 28 ++++++++++--------- 3 files changed, 29 insertions(+), 19 deletions(-) diff --git a/addons/point_of_sale/static/src/css/pos.css b/addons/point_of_sale/static/src/css/pos.css index 15407182ffc..b1dcec00c12 100644 --- a/addons/point_of_sale/static/src/css/pos.css +++ b/addons/point_of_sale/static/src/css/pos.css @@ -1683,12 +1683,16 @@ td { -webkit-transform: translate3d(0,0,0); } -.pos .order .empty{ - text-align:center; - margin-top: 15px; - margin-bottom: 5px; - color:#999; - font-weight: normal; +.pos .order .order-empty { + text-align: center; + margin: 48px; + color: #DDD; +} +.pos .order .order-empty .fa { + font-size: 64px; +} +.pos .order .order-empty h1 { + font-size: 20px; } .pos .order .summary{ diff --git a/addons/point_of_sale/static/src/js/screens.js b/addons/point_of_sale/static/src/js/screens.js index 06eb6280542..9fc2fd53d52 100644 --- a/addons/point_of_sale/static/src/js/screens.js +++ b/addons/point_of_sale/static/src/js/screens.js @@ -522,6 +522,10 @@ openerp.point_of_sale.load_screens = function load_screens(instance, module){ // }, update_summary: function(){ var order = this.pos.get_order(); + if (!order.get_orderlines().length) { + return; + } + var total = order ? order.get_total_with_tax() : 0; var taxes = order ? total - order.get_total_without_tax() : 0; diff --git a/addons/point_of_sale/static/src/xml/pos.xml b/addons/point_of_sale/static/src/xml/pos.xml index 63585d3c125..4878801d94e 100644 --- a/addons/point_of_sale/static/src/xml/pos.xml +++ b/addons/point_of_sale/static/src/xml/pos.xml @@ -1097,21 +1097,23 @@
-
    - -
  • - Your shopping cart is empty -
  • -
    -
-
-
-
- Total: 0.00 € -
Taxes: 0.00€
+ +
+ +

Your shopping cart is empty

+
+
+ +
    +
    +
    +
    + Total: 0.00 € +
    Taxes: 0.00€
    +
    -
    +