[IMP] point_of_sale: order selector now scrolls in case of overflow.
authorFrederic van der Essen <fva@openerp.com / fvdessen+o@gmail.com>
Fri, 19 Sep 2014 13:51:48 +0000 (15:51 +0200)
committerFrédéric van der Essen <fvdessen@gmail.com>
Tue, 25 Nov 2014 16:10:11 +0000 (17:10 +0100)
addons/point_of_sale/static/src/css/pos.css
addons/point_of_sale/static/src/js/widgets.js
addons/point_of_sale/static/src/xml/pos.xml

index 4e63048..26c2bfb 100644 (file)
@@ -54,6 +54,9 @@ td {
 .oe_hidden{
     display: none !important;
 }
+.oe_invisible{
+    visibility: hidden !important;
+}
 .clearfix:after {
     content:" ";
     display: block;
@@ -317,6 +320,11 @@ td {
     right:0;
     top:0;
     height:100%;
+    display: -webkit-flex;
+    display: flex;
+}
+.pos .pos-rightheader > * {
+    border-right: 1px solid #292929;
 }
 
 .pos .order-button{
@@ -347,6 +355,8 @@ td {
     height: 45px;
     border-bottom: solid 1px rgb(196, 196, 196);
     box-shadow: none;
+    -webkit-flex-shrink: 0;
+    flex-shrink: 0;
 }
 
 .pos .order-button .order-sequence{
@@ -383,12 +393,19 @@ td {
 }
 
 .pos .order-selector {
-    display: inline-block;
+    display: -webkit-flex;
+    display: flex;
+    -webkit-flex: 1;
+    flex: 1;
 }
 .pos .orders {
-    display: inline-block;
+    display: -webkit-flex;
+    display: flex;
     vertical-align: top;
     margin-left: 8px;
+    overflow: hidden;
+    overflow-x: auto;
+    -webkit-overflow-scrolling: touch;
 }
 
 /*  c) The session buttons */
index ff3b179..5496034 100644 (file)
@@ -1015,6 +1015,9 @@ function openerp_pos_widgets(instance, module){ //module is instance.point_of_sa
 
             // --------  Misc ---------
 
+            this.notification = new module.SynchNotificationWidget(this,{});
+            this.notification.appendTo(this.$('.pos-rightheader'));
+
             this.close_button = new module.HeaderButtonWidget(this,{
                 label: _t('Close'),
                 action: function(){ 
@@ -1035,8 +1038,6 @@ function openerp_pos_widgets(instance, module){ //module is instance.point_of_sa
             });
             this.close_button.appendTo(this.$('.pos-rightheader'));
 
-            this.notification = new module.SynchNotificationWidget(this,{});
-            this.notification.appendTo(this.$('.pos-rightheader'));
 
             if(this.pos.config.use_proxy){
                 this.proxy_status = new module.ProxyStatusWidget(this,{});
index 362f1a2..21d3fcb 100644 (file)
@@ -12,7 +12,7 @@
                 </div>
                 <div class="pos-rightheader">
                     <div class="order-selector">
-                        <span class="orders"></span>
+                        <span class="orders touch-scrollable"></span>
                         <span class="order-button square neworder-button"><i class='fa fa-plus' /></span>
                         <span class="order-button square deleteorder-button"><i class='fa fa-minus' /></span>
                     </div>