[IMP] document_page_project: black, isort

This commit is contained in:
Joan Sisquella 2020-01-15 12:15:05 +01:00 committed by Bhavesh Heliconia
parent e275593f5c
commit 120ee8a7f5
3 changed files with 15 additions and 29 deletions

View File

@ -3,22 +3,15 @@
# 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',
"name": "Document Page Project",
"summary": "This module links document pages to projects",
"version": "12.0.1.0.0",
"development_status": "Beta",
'category': 'Project',
'author': 'Eficent, '
'Odoo Community Association (OCA)',
'website': 'https://github.com/OCA/knowledge',
'license': 'AGPL-3',
'depends': [
'project',
'document_page',
],
'data': [
'views/document_page_views.xml',
'views/project_project_views.xml',
],
'installable': True,
"category": "Project",
"author": "Eficent, " "Odoo Community Association (OCA)",
"website": "https://github.com/OCA/knowledge",
"license": "AGPL-3",
"depends": ["project", "document_page"],
"data": ["views/document_page_views.xml", "views/project_project_views.xml"],
"installable": True,
}

View File

@ -6,9 +6,6 @@ from odoo import fields, models
class DocumentPage(models.Model):
_inherit = 'document.page'
_inherit = "document.page"
project_id = fields.Many2one(
string='Project',
comodel_name='project.project',
)
project_id = fields.Many2one(string="Project", comodel_name="project.project")

View File

@ -6,16 +6,12 @@ from odoo import api, fields, models
class ProjectProject(models.Model):
_inherit = 'project.project'
_inherit = "project.project"
document_page_ids = fields.One2many(
string='Wiki',
comodel_name='document.page',
inverse_name='project_id',
)
document_page_count = fields.Integer(
compute='_compute_document_page_count',
string="Wiki", comodel_name="document.page", inverse_name="project_id"
)
document_page_count = fields.Integer(compute="_compute_document_page_count")
@api.multi
def _compute_document_page_count(self):