diff --git a/partner_company_type/README.rst b/partner_company_type/README.rst
index 2f7f1caa9..ac06c22ec 100644
--- a/partner_company_type/README.rst
+++ b/partner_company_type/README.rst
@@ -10,7 +10,7 @@ Adds a title to partner that are companies.
(Before: Partner Title in Odoo - limited to contacts now)
See :
- :target: https://en.wikipedia.org/wiki/Types_of_business_entity
+ :target: https://en.wikipedia.org/wiki/Types_of_business_entity
Usage
=====
@@ -20,9 +20,6 @@ Usage
:alt: Try me on Runbot
:target: https://runbot.odoo-community.org/runbot/134/10.0
-.. repo_id is available in https://github.com/OCA/maintainer-tools/blob/master/tools/repos_with_ids.txt
-.. branch is "8.0" for example
-
Bug Tracker
===========
diff --git a/partner_company_type/__manifest__.py b/partner_company_type/__manifest__.py
index cd8b9237e..25c496eda 100644
--- a/partner_company_type/__manifest__.py
+++ b/partner_company_type/__manifest__.py
@@ -4,15 +4,15 @@
{
'name': 'Partner Company Type',
- 'summary': """
- Adds a company type to partner that are companies""",
- 'version': '10.0.1.0.0',
+ 'summary': 'Adds a company type to partner that are companies',
+ 'version': '10.0.1.0.1',
'license': 'AGPL-3',
'author': 'ACSONE SA/NV,Odoo Community Association (OCA)',
'website': 'https://acsone.eu',
- 'depends': ['base',
- 'sales_team'
- ],
+ 'depends': [
+ 'base',
+ 'sales_team',
+ ],
'data': [
'security/res_partner_company_type.xml',
'views/res_partner_company_type.xml',
diff --git a/partner_company_type/migrations/10.0.1.0.1/post-migration.py b/partner_company_type/migrations/10.0.1.0.1/post-migration.py
new file mode 100644
index 000000000..e0ae776d4
--- /dev/null
+++ b/partner_company_type/migrations/10.0.1.0.1/post-migration.py
@@ -0,0 +1,10 @@
+# -*- coding: utf-8 -*-
+# Copyright 2017 ACSONE SA/NV
+# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
+
+
+def migrate(cr, version):
+
+ cr.execute(
+ 'UPDATE res_partner SET partner_company_type_id = company_type_id'
+ )
diff --git a/partner_company_type/models/res_partner.py b/partner_company_type/models/res_partner.py
index fcc6569e1..21d936b2c 100644
--- a/partner_company_type/models/res_partner.py
+++ b/partner_company_type/models/res_partner.py
@@ -8,5 +8,7 @@ from odoo import fields, models
class ResPartner(models.Model):
_inherit = "res.partner"
- company_type_id = fields.Many2one('res.partner.company.type',
- string='Company Type')
+ partner_company_type_id = fields.Many2one(
+ 'res.partner.company.type',
+ string='Company Type'
+ )
diff --git a/partner_company_type/models/res_partner_company_type.py b/partner_company_type/models/res_partner_company_type.py
index 06990e08a..c93089777 100644
--- a/partner_company_type/models/res_partner_company_type.py
+++ b/partner_company_type/models/res_partner_company_type.py
@@ -14,4 +14,4 @@ class ResPartnerCompanyType(models.Model):
shortcut = fields.Char(string='Abbreviation', translate=True)
_sql_constraints = [('name_uniq', 'unique (name)',
- "Partner Company Type already exists !")]
+ "Partner Company Type already exists!")]
diff --git a/partner_company_type/views/res_partner.xml b/partner_company_type/views/res_partner.xml
index 2f2a84aaa..129e4d6c7 100644
--- a/partner_company_type/views/res_partner.xml
+++ b/partner_company_type/views/res_partner.xml
@@ -3,16 +3,15 @@
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->
-
-
- res.partner.form
- res.partner
-
-
-
-
-
-
-
-
\ No newline at end of file
+
+ res.partner.form
+ res.partner
+
+
+
+
+
+
+
+