From 7e1a523fbff1df45e41fb24b71ea6d0bbb86d0e9 Mon Sep 17 00:00:00 2001 From: Alexis de Lattre Date: Tue, 25 Apr 2017 17:57:07 +0200 Subject: [PATCH] [FIX] product: missing string on field Closes #16640 --- addons/product/i18n/product.pot | 12 ++++-------- addons/product/models/product.py | 3 ++- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/addons/product/i18n/product.pot b/addons/product/i18n/product.pot index 842fd0356db..5669c10274f 100644 --- a/addons/product/i18n/product.pot +++ b/addons/product/i18n/product.pot @@ -4,10 +4,10 @@ # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 10.0c\n" +"Project-Id-Version: Odoo Server 10.0\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2016-09-29 14:00+0000\n" -"PO-Revision-Date: 2016-09-29 14:00+0000\n" +"POT-Creation-Date: 2017-04-26 13:35+0000\n" +"PO-Revision-Date: 2017-04-26 13:35+0000\n" "Last-Translator: <>\n" "Language-Team: \n" "MIME-Version: 1.0\n" @@ -602,6 +602,7 @@ msgid "Companies" msgstr "" #. module: product +#: model:ir.model.fields,field_description:product.field_product_price_history_company_id #: model:ir.model.fields,field_description:product.field_product_pricelist_company_id #: model:ir.model.fields,field_description:product.field_product_pricelist_item_company_id #: model:ir.model.fields,field_description:product.field_product_product_company_id @@ -610,11 +611,6 @@ msgstr "" msgid "Company" msgstr "" -#. module: product -#: model:ir.model.fields,field_description:product.field_product_price_history_company_id -msgid "Company id" -msgstr "" - #. module: product #: model:ir.ui.view,arch_db:product.product_pricelist_item_form_view msgid "Compute Price" diff --git a/addons/product/models/product.py b/addons/product/models/product.py index 39505563ba9..ca31a71f90b 100644 --- a/addons/product/models/product.py +++ b/addons/product/models/product.py @@ -94,7 +94,8 @@ class ProductPriceHistory(models.Model): def _get_default_company_id(self): return self._context.get('force_company', self.env.user.company_id.id) - company_id = fields.Many2one('res.company', default=_get_default_company_id, required=True) + company_id = fields.Many2one('res.company', string='Company', + default=_get_default_company_id, required=True) product_id = fields.Many2one('product.product', 'Product', ondelete='cascade', required=True) datetime = fields.Datetime('Date', default=fields.Datetime.now) cost = fields.Float('Cost', digits=dp.get_precision('Product Price'))