diff --git a/ext/custom-addons/dp_custom/models/res_company.py b/ext/custom-addons/dp_custom/models/res_company.py index d99355e1..af3bca40 100644 --- a/ext/custom-addons/dp_custom/models/res_company.py +++ b/ext/custom-addons/dp_custom/models/res_company.py @@ -30,6 +30,8 @@ class Company(models.Model): eori_nr = fields.Char(string='EORI-Nr') fax = fields.Char(related='partner_id.fax') portal_prefix = fields.Char(string='Portal-Prefix') + partner_description = fields.Char(string='Partner-Beschreibung') + partner_email = fields.Char(string='E-Mail (Partner)') @api.model def set_company_logo(self, company, logo): diff --git a/ext/custom-addons/dp_custom/models/sale.py b/ext/custom-addons/dp_custom/models/sale.py index 913f3040..2811dd09 100644 --- a/ext/custom-addons/dp_custom/models/sale.py +++ b/ext/custom-addons/dp_custom/models/sale.py @@ -260,6 +260,7 @@ class SaleOrder(models.Model): record.weight_total = _sum @api.multi +# @api.depends('assembly_state') def _compute_positions(self): for record in self: pg_complete = True diff --git a/ext/custom-addons/dp_custom/views/res_company_views.xml b/ext/custom-addons/dp_custom/views/res_company_views.xml index ba666ce5..8c5712c1 100644 --- a/ext/custom-addons/dp_custom/views/res_company_views.xml +++ b/ext/custom-addons/dp_custom/views/res_company_views.xml @@ -9,10 +9,14 @@ + + + + diff --git a/ext/custom-addons/dp_custom/views/sale_views.xml b/ext/custom-addons/dp_custom/views/sale_views.xml index ed53a575..5d0871d7 100644 --- a/ext/custom-addons/dp_custom/views/sale_views.xml +++ b/ext/custom-addons/dp_custom/views/sale_views.xml @@ -287,6 +287,11 @@ + + + + + diff --git a/ext/custom-addons/dp_show_company/static/src/js/web_client.js b/ext/custom-addons/dp_show_company/static/src/js/web_client.js index 57f030b8..5e1e5b19 100644 --- a/ext/custom-addons/dp_show_company/static/src/js/web_client.js +++ b/ext/custom-addons/dp_show_company/static/src/js/web_client.js @@ -30,9 +30,9 @@ odoo.define('dp_show_company.ShowCompanyMenu', function (require) { var records = rpc.query({ model: 'res.company', method: 'search_read', - args: [[['id', '=', session.company_id]], ['name']], + args: [[['id', '=', session.company_id]], ['partner_description']], }).then(function (companies){ - self.$('.oe_topbar_name').text(companies[0].name); + self.$('.oe_topbar_name').text(companies[0].partner_description); }); });