From cc9da35526ea2a470d15d3dabc07313c9664dae7 Mon Sep 17 00:00:00 2001 From: Joan Sisquella Date: Wed, 15 Jan 2020 12:40:00 +0100 Subject: [PATCH] [MIG] document_page_project: Migration to 13.0 --- document_page_project/__manifest__.py | 9 +++-- document_page_project/models/document_page.py | 3 +- .../models/project_project.py | 6 ++-- document_page_project/readme/CONTRIBUTORS.rst | 4 +-- .../views/document_page_views.xml | 23 ++++++------ .../views/project_project_views.xml | 35 +++++++++++++------ .../odoo/addons/document_page_project | 1 + setup/document_page_project/setup.py | 6 ++++ 8 files changed, 52 insertions(+), 35 deletions(-) create mode 120000 setup/document_page_project/odoo/addons/document_page_project create mode 100644 setup/document_page_project/setup.py diff --git a/document_page_project/__manifest__.py b/document_page_project/__manifest__.py index a98ea9a9..a42a8418 100644 --- a/document_page_project/__manifest__.py +++ b/document_page_project/__manifest__.py @@ -1,14 +1,13 @@ -# Copyright 2019 Eficent Business and IT Consulting Services S.L. -# (http://www.eficent.com) - Lois Rilo +# Copyright 2019 ForgeFlow S.L. (https://www.forgeflow.com) - Lois Rilo # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). { "name": "Document Page Project", "summary": "This module links document pages to projects", - "version": "12.0.1.0.0", - "development_status": "Beta", + "version": "13.0.1.0.0", + "development_status": "Production/Stable", "category": "Project", - "author": "Eficent, " "Odoo Community Association (OCA)", + "author": "ForgeFlow, Odoo Community Association (OCA)", "website": "https://github.com/OCA/knowledge", "license": "AGPL-3", "depends": ["project", "document_page"], diff --git a/document_page_project/models/document_page.py b/document_page_project/models/document_page.py index 0509b1a7..f819bb75 100644 --- a/document_page_project/models/document_page.py +++ b/document_page_project/models/document_page.py @@ -1,5 +1,4 @@ -# Copyright 2019 Eficent Business and IT Consulting Services S.L. -# (http://www.eficent.com) +# Copyright 2019 ForgeFlow S.L. (https://www.forgeflow.com) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). from odoo import fields, models diff --git a/document_page_project/models/project_project.py b/document_page_project/models/project_project.py index a5d3a53b..259fdf5d 100644 --- a/document_page_project/models/project_project.py +++ b/document_page_project/models/project_project.py @@ -1,8 +1,7 @@ -# Copyright 2019 Eficent Business and IT Consulting Services S.L. -# (http://www.eficent.com) +# Copyright 2019 ForgeFlow S.L. (https://www.forgeflow.com) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). -from odoo import api, fields, models +from odoo import fields, models class ProjectProject(models.Model): @@ -13,7 +12,6 @@ class ProjectProject(models.Model): ) document_page_count = fields.Integer(compute="_compute_document_page_count") - @api.multi def _compute_document_page_count(self): for rec in self: rec.document_page_count = len(rec.document_page_ids) diff --git a/document_page_project/readme/CONTRIBUTORS.rst b/document_page_project/readme/CONTRIBUTORS.rst index edfe8468..a17f4de9 100644 --- a/document_page_project/readme/CONTRIBUTORS.rst +++ b/document_page_project/readme/CONTRIBUTORS.rst @@ -1,3 +1,3 @@ -* `Eficent `_: +* `Forgeflow `_: - * Lois Rilo + * Lois Rilo diff --git a/document_page_project/views/document_page_views.xml b/document_page_project/views/document_page_views.xml index 19d0d23f..ad1be2d2 100644 --- a/document_page_project/views/document_page_views.xml +++ b/document_page_project/views/document_page_views.xml @@ -1,35 +1,36 @@ - + - document.page.form - document_page_project document.page - + - + - Project Wiki document.page - [('type','=','content'), ('project_id', '=', active_id)] + [('type','=','content'), ('project_id', '=', active_id)] { 'default_type': 'content', 'default_project_id': active_id} - form tree,form - - + (0,0,{'view_mode':'form', 'view_id': ref('document_page.view_wiki_form')})]" + /> +

Click to create a new web page.

-
diff --git a/document_page_project/views/project_project_views.xml b/document_page_project/views/project_project_views.xml index 9bbb9337..7b68782f 100644 --- a/document_page_project/views/project_project_views.xml +++ b/document_page_project/views/project_project_views.xml @@ -1,15 +1,22 @@ - + - project.project - + - +
- + Wiki Pages
@@ -17,19 +24,25 @@
- project.project.form - document_page_project project.project - +
-
-
diff --git a/setup/document_page_project/odoo/addons/document_page_project b/setup/document_page_project/odoo/addons/document_page_project new file mode 120000 index 00000000..4a05cc1b --- /dev/null +++ b/setup/document_page_project/odoo/addons/document_page_project @@ -0,0 +1 @@ +../../../../document_page_project \ No newline at end of file diff --git a/setup/document_page_project/setup.py b/setup/document_page_project/setup.py new file mode 100644 index 00000000..28c57bb6 --- /dev/null +++ b/setup/document_page_project/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +)