From 117ed7ca252e956d5c6ce0192711096a054d2f1a Mon Sep 17 00:00:00 2001 From: Paul Catinean Date: Mon, 27 Feb 2017 16:28:09 +0200 Subject: [PATCH 1/4] [MGR] Migrated product_customer_code to version 10 --- product_customer_code/__init__.py | 5 +- product_customer_code/__manifest__.py | 39 ++++------ product_customer_code/models/__init__.py | 5 ++ product_customer_code/models/product.py | 39 ++++++++++ .../models/product_customer_code.py | 58 +++++++++++++++ product_customer_code/models/res_partner.py | 13 ++++ product_customer_code/product.py | 73 ------------------- .../product_customer_code.py | 67 ----------------- .../product_customer_code_view.xml | 61 ---------------- .../product_product_view.xml | 31 -------- .../product_customer_code_security.xml | 16 ++-- .../views/product_customer_code_view.xml | 59 +++++++++++++++ .../views/product_product_view.xml | 28 +++++++ .../views/res_partner_view.xml | 29 ++++++++ 14 files changed, 255 insertions(+), 268 deletions(-) create mode 100644 product_customer_code/models/__init__.py create mode 100644 product_customer_code/models/product.py create mode 100644 product_customer_code/models/product_customer_code.py create mode 100644 product_customer_code/models/res_partner.py delete mode 100644 product_customer_code/product.py delete mode 100644 product_customer_code/product_customer_code.py delete mode 100644 product_customer_code/product_customer_code_view.xml delete mode 100644 product_customer_code/product_product_view.xml create mode 100644 product_customer_code/views/product_customer_code_view.xml create mode 100644 product_customer_code/views/product_product_view.xml create mode 100644 product_customer_code/views/res_partner_view.xml diff --git a/product_customer_code/__init__.py b/product_customer_code/__init__.py index df5910868b4..21ff7c22f3c 100644 --- a/product_customer_code/__init__.py +++ b/product_customer_code/__init__.py @@ -1,2 +1,3 @@ -import product_customer_code -import product +# -*- encoding: utf-8 -*- + +from . import models diff --git a/product_customer_code/__manifest__.py b/product_customer_code/__manifest__.py index af8cd13e819..9f7c8678673 100644 --- a/product_customer_code/__manifest__.py +++ b/product_customer_code/__manifest__.py @@ -8,53 +8,40 @@ ############################################################################ # Coded by: el_rodo_1 (rodo@vauxoo.com) ############################################################################ -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## + { "name": "Products Customer Code", - "version": "1.0", + 'version': '10.0.1.0.0', "author": "Vauxoo,Odoo Community Association (OCA)", "website": "http://www.vauxoo.com/", "license": "AGPL-3", "category": "Generic Modules/Product", "summary": "Add many Customers' Codes in product", "depends": [ - "base", - "product", + "base", + "product", ], "description": """ Customer' codes in product ========================== -This module does just like the product.supplierinfo but for customers instead. For instance it -allows to have different references for the same product according to the customer. +This module does just like the product.supplierinfo but for customers instead. +For instance it allows to have different references for the same product +according to the customer. .. image:: product_customer_code/static/src/img/screenshot1.png .. tip:: - You will need install some of the Apps which enable the product menu to see this module in - action, like Sales, Purchase or Warehouse Management + You will need install some of the Apps which enable the product menu to + see this module in action, like Sales, Purchase or Warehouse Management """, "data": [ "security/product_customer_code_security.xml", "security/ir.model.access.csv", - "product_customer_code_view.xml", - "product_product_view.xml", + "views/product_customer_code_view.xml", + "views/product_product_view.xml", + "views/res_partner_view.xml", ], - "active": False, - 'installable': False, + 'installable': True, } diff --git a/product_customer_code/models/__init__.py b/product_customer_code/models/__init__.py new file mode 100644 index 00000000000..67911682a2b --- /dev/null +++ b/product_customer_code/models/__init__.py @@ -0,0 +1,5 @@ +# -*- encoding: utf-8 -*- + +from . import product_customer_code +from . import product +from . import res_partner diff --git a/product_customer_code/models/product.py b/product_customer_code/models/product.py new file mode 100644 index 00000000000..bb9c9d4e444 --- /dev/null +++ b/product_customer_code/models/product.py @@ -0,0 +1,39 @@ +# -*- coding: utf-8 -*- + +########################################################################### +# Module Writen to OpenERP, Open Source Management Solution +# +# Copyright (c) 2012 Vauxoo - http://www.vauxoo.com +# All Rights Reserved. +# info@vauxoo.com +############################################################################ +# Coded by: Rodo (rodo@vauxoo.com),Moy (moylop260@vauxoo.com) +############################################################################ + +from odoo import models, fields, api + + +class ProductProduct(models.Model): + _inherit = "product.product" + + product_customer_code_ids = fields.One2many( + comodel_name='product.customer.code', + inverse_name='product_id', + string='Customer Codes', + copy=False + ) + + @api.model + def name_search(self, name='', args=None, operator='ilike', limit=100): + res = super(ProductProduct, self).name_search( + name=name, args=args, operator=operator, limit=limit) + if not res: + partner_id = self._context.get('partner_id') + if partner_id: + product_customer_code_obj = self.env['product.customer.code'] + product_codes = product_customer_code_obj.search([ + ('product_code', '=', name), + ('partner_id', '=', partner_id) + ], limit=limit) + return product_codes.name_get() + return res diff --git a/product_customer_code/models/product_customer_code.py b/product_customer_code/models/product_customer_code.py new file mode 100644 index 00000000000..24cde6ddac1 --- /dev/null +++ b/product_customer_code/models/product_customer_code.py @@ -0,0 +1,58 @@ +# -*- coding: utf-8 -*- +########################################################################### +# Module Writen to OpenERP, Open Source Management Solution +# +# Copyright (c) 2012 Vauxoo - http://www.vauxoo.com +# All Rights Reserved. +# info@vauxoo.com +############################################################################ +# Coded by: Rodo (rodo@vauxoo.com),Moy (moylop260@vauxoo.com) +############################################################################ + +from odoo import models, fields + + +class ProductCustomerCode(models.Model): + _name = "product.customer.code" + _description = "Add multiple product customer codes" + + _rec_name = 'product_code' + + product_code = fields.Char( + string='Customer Product Code', + required=True, + help="""This customer's product code will be used when searching into + a request for quotation.""", + ) + + product_name = fields.Char( + string='Customer Product Name', + help="""This customer's product name will be used when searching into + a request for quotation.""", + ) + + product_id = fields.Many2one( + comodel_name='product.product', + string='Product', + required=True, + ) + + partner_id = fields.Many2one( + comodel_name='res.partner', + string='Customer', + required=True + ) + + company_id = fields.Many2one( + comodel_name='res.company', + string='Company', + required=False, + default=lambda self: self.env['res.company']._company_default_get(), + ) + + _sql_constraints = [ + ('unique_code', 'unique(product_code,company_id,partner_id)', + 'Product customer code must be unique'), + ] + + # TODO: Add index to product_code, partner diff --git a/product_customer_code/models/res_partner.py b/product_customer_code/models/res_partner.py new file mode 100644 index 00000000000..98ef4ebe95f --- /dev/null +++ b/product_customer_code/models/res_partner.py @@ -0,0 +1,13 @@ +# -*- coding: utf-8 -*- + +from odoo import models, fields + + +class ResPartner(models.Model): + _inherit = 'res.partner' + + product_code_ids = fields.One2many( + comodel_name='product.customer.code', + inverse_name='partner_id', + string='Products' + ) diff --git a/product_customer_code/product.py b/product_customer_code/product.py deleted file mode 100644 index 350a66f23db..00000000000 --- a/product_customer_code/product.py +++ /dev/null @@ -1,73 +0,0 @@ -# -*- coding: utf-8 -*- -########################################################################### -# Module Writen to OpenERP, Open Source Management Solution -# -# Copyright (c) 2012 Vauxoo - http://www.vauxoo.com -# All Rights Reserved. -# info@vauxoo.com -############################################################################ -# Coded by: Rodo (rodo@vauxoo.com),Moy (moylop260@vauxoo.com) -############################################################################ -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## -from openerp.osv import orm, fields -from openerp.tools.translate import _ - - -class product_product(orm.Model): - _inherit = "product.product" - - _columns = { - 'product_customer_code_ids': fields.one2many('product.customer.code', - 'product_id', - 'Customer Codes'), - } - - def copy(self, cr, uid, id, default=None, context=None): - if not default: - default = {} - default['product_customer_code_ids'] = False - res = super(product_product, self).copy( - cr, uid, id, default=default, context=context) - return res - - def name_search(self, cr, user, name='', args=None, operator='ilike', - context=None, limit=80): - res = super(product_product, self).name_search( - cr, user, name, args, operator, context, limit) - if not context: - context = {} - product_customer_code_obj = self.pool.get('product.customer.code') - if not res: - ids = [] - partner_id = context.get('partner_id', False) - if partner_id: - id_prod_code = \ - product_customer_code_obj.search(cr, user, - [('product_code', - '=', name), - ('partner_id', '=', - partner_id)], - limit=limit, - context=context) - # TODO: Search for product customer name - id_prod = id_prod_code and product_customer_code_obj.browse( - cr, user, id_prod_code, context=context) or [] - for ppu in id_prod: - ids.append(ppu.product_id.id) - if ids: - res = self.name_get(cr, user, ids, context) - return res diff --git a/product_customer_code/product_customer_code.py b/product_customer_code/product_customer_code.py deleted file mode 100644 index d3593891a20..00000000000 --- a/product_customer_code/product_customer_code.py +++ /dev/null @@ -1,67 +0,0 @@ -# -*- coding: utf-8 -*- -########################################################################### -# Module Writen to OpenERP, Open Source Management Solution -# -# Copyright (c) 2012 Vauxoo - http://www.vauxoo.com -# All Rights Reserved. -# info@vauxoo.com -############################################################################ -# Coded by: Rodo (rodo@vauxoo.com),Moy (moylop260@vauxoo.com) -############################################################################ -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## -from openerp.osv import orm, fields -from openerp.tools.translate import _ - - -class product_customer_code(orm.Model): - _name = "product.customer.code" - _description = "Add manies Code of Customer's" - - _rec_name = 'product_code' - - _columns = { - 'product_code': fields.char('Customer Product Code', size=64, - required=True, - help="""This customer's product code - will be used when searching into - a request for quotation."""), - 'product_name': fields.char('Customer Product Name', size=128, - help="""This customer's product name will - be used when searching into a - request for quotation."""), - 'product_id': fields.many2one('product.product', 'Product', - required=True), - 'partner_id': fields.many2one('res.partner', 'Customer', - required=True), - 'company_id': fields.many2one('res.company', 'Company', - required=False), - } - - _defaults = { - 'company_id': lambda s, cr, - uid, c: s.pool.get('res.company'). - _company_default_get(cr, uid, - 'product.customer.code', - context=c), - } - - _sql_constraints = [ - ('unique_code', 'unique(product_code,company_id,partner_id)', - 'Product Code of customer must be unique'), - ] - - # TODO: Add index to product_code, partner_id diff --git a/product_customer_code/product_customer_code_view.xml b/product_customer_code/product_customer_code_view.xml deleted file mode 100644 index 0fddfd30f01..00000000000 --- a/product_customer_code/product_customer_code_view.xml +++ /dev/null @@ -1,61 +0,0 @@ - - - - - - view.product.customer.code.form - product.customer.code - -
- - - - - - -
- - - view.product.customer.code.tree - product.customer.code - - - - - - - - - - - - Product Customer Code - product.customer.code - form - - - - - view.product.customer.code.certificate.search - product.customer.code - - - - - - - - - - - - - - - - - - - -
-
diff --git a/product_customer_code/product_product_view.xml b/product_customer_code/product_product_view.xml deleted file mode 100644 index 3aec998b591..00000000000 --- a/product_customer_code/product_product_view.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - product.normal.form.inh.product.customer.code.01 - product.product - - - - - - - - - - -
- - - - -
-
-
-
- -
-
\ No newline at end of file diff --git a/product_customer_code/security/product_customer_code_security.xml b/product_customer_code/security/product_customer_code_security.xml index ebc3b409efc..48e4989c475 100644 --- a/product_customer_code/security/product_customer_code_security.xml +++ b/product_customer_code/security/product_customer_code_security.xml @@ -1,14 +1,14 @@ - + - - Product_Customer / Manager - + + Product_Customer / Manager + - - Product_Customer / User - + + Product_Customer / User + - + diff --git a/product_customer_code/views/product_customer_code_view.xml b/product_customer_code/views/product_customer_code_view.xml new file mode 100644 index 00000000000..1aac35dd425 --- /dev/null +++ b/product_customer_code/views/product_customer_code_view.xml @@ -0,0 +1,59 @@ + + + + + view.product.customer.code.form + product.customer.code + +
+ + + + + + +
+ + + view.product.customer.code.tree + product.customer.code + + + + + + + + + + + + Product Customer Code + product.customer.code + form + + + + + view.product.customer.code.certificate.search + product.customer.code + + + + + + + + + + + + + + + + + + + +
diff --git a/product_customer_code/views/product_product_view.xml b/product_customer_code/views/product_product_view.xml new file mode 100644 index 00000000000..1b948412f1c --- /dev/null +++ b/product_customer_code/views/product_product_view.xml @@ -0,0 +1,28 @@ + + + + + product.normal.form.inh.product.customer.code.01 + product.product + + + + + + + + + +
+ + + + +
+
+
+
+
+
+ +
diff --git a/product_customer_code/views/res_partner_view.xml b/product_customer_code/views/res_partner_view.xml new file mode 100644 index 00000000000..19bc184e45c --- /dev/null +++ b/product_customer_code/views/res_partner_view.xml @@ -0,0 +1,29 @@ + + + + + product.customer.code.partner.form.view.inherit + res.partner + + + + + + + + + +
+ + + + +
+
+
+
+ +
+
+ +
From 176193b56ed4d13fe5b5bcc7c81d4cf5adee30d2 Mon Sep 17 00:00:00 2001 From: Paul Catinean Date: Fri, 19 May 2017 17:35:54 +0200 Subject: [PATCH 2/4] Review fixes --- product_customer_code/README.rst | 64 +++++++++++++++++++ product_customer_code/__manifest__.py | 30 +-------- product_customer_code/models/product.py | 14 +--- .../models/product_customer_code.py | 26 +++----- product_customer_code/models/res_partner.py | 4 +- .../product_customer_code_security.xml | 16 ++--- .../views/res_partner_view.xml | 1 - 7 files changed, 88 insertions(+), 67 deletions(-) create mode 100644 product_customer_code/README.rst diff --git a/product_customer_code/README.rst b/product_customer_code/README.rst new file mode 100644 index 00000000000..91da1edbb05 --- /dev/null +++ b/product_customer_code/README.rst @@ -0,0 +1,64 @@ +.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 + +========================== +Customer codes in product +========================== + +This module does just like the product.supplierinfo but for customers instead. +For instance it allows to have different references for the same product +according to the customer. + +.. image:: product_customer_code/static/src/img/screenshot1.png + +Installation +============ + +To install this module, you need to: + +Install some of the Apps which enable the product menu to +see this module in action, like Sales, Purchase or Warehouse Management + +Known issues / Roadmap +====================== + +None + +Bug Tracker +=========== + +Bugs are tracked on `GitHub Issues +`_. In case of trouble, please +check there if your issue has already been reported. If you spotted it first, +help us smash it by providing detailed and welcomed feedback. + +Credits +======= + +Images +------ + +* Odoo Community Association: `Icon `_. + +Contributors +------------ + +* Vauxoo - http://www.vauxoo.com +* el_rodo_1 +* Paul Catinean + +Maintainer +---------- + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +This module is maintained by the OCA. + +OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use. + +To contribute to this module, please visit https://odoo-community.org. diff --git a/product_customer_code/__manifest__.py b/product_customer_code/__manifest__.py index 9f7c8678673..cc51f1e39d7 100644 --- a/product_customer_code/__manifest__.py +++ b/product_customer_code/__manifest__.py @@ -1,14 +1,6 @@ -# -*- encoding: utf-8 -*- -########################################################################### -# Module Writen to OpenERP, Open Source Management Solution -# -# Copyright (c) 2012 Vauxoo - http://www.vauxoo.com/ -# All Rights Reserved. -# info Vauxoo (info@vauxoo.com) -############################################################################ -# Coded by: el_rodo_1 (rodo@vauxoo.com) -############################################################################ - +# -*- coding: utf-8 -*- +# Copyright 2012 Vauxoo - http://www.vauxoo.com +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). { "name": "Products Customer Code", 'version': '10.0.1.0.0', @@ -18,24 +10,8 @@ "category": "Generic Modules/Product", "summary": "Add many Customers' Codes in product", "depends": [ - "base", "product", ], - "description": """ -Customer' codes in product -========================== - -This module does just like the product.supplierinfo but for customers instead. -For instance it allows to have different references for the same product -according to the customer. - -.. image:: product_customer_code/static/src/img/screenshot1.png - -.. tip:: - - You will need install some of the Apps which enable the product menu to - see this module in action, like Sales, Purchase or Warehouse Management - """, "data": [ "security/product_customer_code_security.xml", "security/ir.model.access.csv", diff --git a/product_customer_code/models/product.py b/product_customer_code/models/product.py index bb9c9d4e444..ea51e76458c 100644 --- a/product_customer_code/models/product.py +++ b/product_customer_code/models/product.py @@ -1,16 +1,8 @@ # -*- coding: utf-8 -*- +# Copyright 2012 Vauxoo - http://www.vauxoo.com +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -########################################################################### -# Module Writen to OpenERP, Open Source Management Solution -# -# Copyright (c) 2012 Vauxoo - http://www.vauxoo.com -# All Rights Reserved. -# info@vauxoo.com -############################################################################ -# Coded by: Rodo (rodo@vauxoo.com),Moy (moylop260@vauxoo.com) -############################################################################ - -from odoo import models, fields, api +from odoo import api, fields, models class ProductProduct(models.Model): diff --git a/product_customer_code/models/product_customer_code.py b/product_customer_code/models/product_customer_code.py index 24cde6ddac1..c6637ab0208 100644 --- a/product_customer_code/models/product_customer_code.py +++ b/product_customer_code/models/product_customer_code.py @@ -1,15 +1,8 @@ # -*- coding: utf-8 -*- -########################################################################### -# Module Writen to OpenERP, Open Source Management Solution -# -# Copyright (c) 2012 Vauxoo - http://www.vauxoo.com -# All Rights Reserved. -# info@vauxoo.com -############################################################################ -# Coded by: Rodo (rodo@vauxoo.com),Moy (moylop260@vauxoo.com) -############################################################################ +# Copyright 2012 Vauxoo - http://www.vauxoo.com +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -from odoo import models, fields +from odoo import fields, models class ProductCustomerCode(models.Model): @@ -21,14 +14,14 @@ class ProductCustomerCode(models.Model): product_code = fields.Char( string='Customer Product Code', required=True, - help="""This customer's product code will be used when searching into - a request for quotation.""", + help="This customer's product code will be used when searching into" + "a request for quotation.", ) product_name = fields.Char( string='Customer Product Name', - help="""This customer's product name will be used when searching into - a request for quotation.""", + help="This customer's product name will be used when searching into" + "a request for quotation.", ) product_id = fields.Many2one( @@ -40,7 +33,8 @@ class ProductCustomerCode(models.Model): partner_id = fields.Many2one( comodel_name='res.partner', string='Customer', - required=True + required=True, + index=True, ) company_id = fields.Many2one( @@ -54,5 +48,3 @@ class ProductCustomerCode(models.Model): ('unique_code', 'unique(product_code,company_id,partner_id)', 'Product customer code must be unique'), ] - - # TODO: Add index to product_code, partner diff --git a/product_customer_code/models/res_partner.py b/product_customer_code/models/res_partner.py index 98ef4ebe95f..a55c95c4220 100644 --- a/product_customer_code/models/res_partner.py +++ b/product_customer_code/models/res_partner.py @@ -1,6 +1,6 @@ # -*- coding: utf-8 -*- -from odoo import models, fields +from odoo import fields, models class ResPartner(models.Model): @@ -9,5 +9,5 @@ class ResPartner(models.Model): product_code_ids = fields.One2many( comodel_name='product.customer.code', inverse_name='partner_id', - string='Products' + string='Products', ) diff --git a/product_customer_code/security/product_customer_code_security.xml b/product_customer_code/security/product_customer_code_security.xml index 48e4989c475..089bfebc95f 100644 --- a/product_customer_code/security/product_customer_code_security.xml +++ b/product_customer_code/security/product_customer_code_security.xml @@ -1,14 +1,12 @@ - - + - - Product_Customer / Manager - + + Product_Customer / Manager + - - Product_Customer / User - + + Product_Customer / User + - diff --git a/product_customer_code/views/res_partner_view.xml b/product_customer_code/views/res_partner_view.xml index 19bc184e45c..79fb17924c3 100644 --- a/product_customer_code/views/res_partner_view.xml +++ b/product_customer_code/views/res_partner_view.xml @@ -22,7 +22,6 @@ - From a2e6ccd2e4416334cca47fd660d21ad0fac54b47 Mon Sep 17 00:00:00 2001 From: Nicola Malcontenti Date: Wed, 24 May 2017 11:06:29 +0200 Subject: [PATCH 3/4] [FIX] fixed name search error in return and logic about operator --- product_customer_code/models/product.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/product_customer_code/models/product.py b/product_customer_code/models/product.py index ea51e76458c..10fe948f974 100644 --- a/product_customer_code/models/product.py +++ b/product_customer_code/models/product.py @@ -19,13 +19,13 @@ class ProductProduct(models.Model): def name_search(self, name='', args=None, operator='ilike', limit=100): res = super(ProductProduct, self).name_search( name=name, args=args, operator=operator, limit=limit) - if not res: + if (len(res) < limit): partner_id = self._context.get('partner_id') if partner_id: product_customer_code_obj = self.env['product.customer.code'] product_codes = product_customer_code_obj.search([ - ('product_code', '=', name), + ('product_code', operator, name), ('partner_id', '=', partner_id) ], limit=limit) - return product_codes.name_get() + res.extend(product_codes.mapped('product_id').name_get()) return res From 4575ac73cb252395a6d6fdf1098f1fef1246c48b Mon Sep 17 00:00:00 2001 From: Nicola Malcontenti Date: Wed, 24 May 2017 12:20:57 +0200 Subject: [PATCH 4/4] [FIX] Readme image fix --- product_customer_code/README.rst | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/product_customer_code/README.rst b/product_customer_code/README.rst index 91da1edbb05..128eca89ed9 100644 --- a/product_customer_code/README.rst +++ b/product_customer_code/README.rst @@ -10,7 +10,9 @@ This module does just like the product.supplierinfo but for customers instead. For instance it allows to have different references for the same product according to the customer. -.. image:: product_customer_code/static/src/img/screenshot1.png +.. figure:: product_customer_code/static/src/img/screenshot1.png + :alt: alternative description + :width: 600 px Installation ============