[FIX] point_of_sale: the product name field changed to display_name to include varian...
authorFrederic van der Essen <fva@openerp.com / fvdessen+o@gmail.com>
Mon, 18 Aug 2014 09:35:24 +0000 (11:35 +0200)
committerFrederic van der Essen <fva@openerp.com / fvdessen+o@gmail.com>
Mon, 18 Aug 2014 09:35:24 +0000 (11:35 +0200)
addons/point_of_sale/static/src/js/db.js
addons/point_of_sale/static/src/js/screens.js

index 06a6a6b..ef6a29f 100644 (file)
@@ -128,7 +128,7 @@ function openerp_pos_db(instance, module){
             this.cache[store] = data;
         },
         _product_search_string: function(product){
-            var str = '' + product.id + ':' + product.name;
+            var str = '' + product.id + ':' + product.display_name;
             if(product.ean13){
                 str += '|' + product.ean13;
             }
index d0d91a2..8610460 100644 (file)
@@ -492,7 +492,7 @@ function openerp_pos_screens(instance, module){ //module is instance.point_of_sa
         },
         get_product_name: function(){
             var product = this.get_product();
-            return (product ? product.name : undefined) || 'Unnamed Product';
+            return (product ? product.display_name : undefined) || 'Unnamed Product';
         },
         get_product_price: function(){
             var product = this.get_product();