[IMP] agreement_project: black, isort, prettier

This commit is contained in:
hkapatel
2021-06-17 11:21:42 +05:30
parent df30ae78f7
commit 6ed6b01422
7 changed files with 51 additions and 45 deletions

View File

@@ -7,12 +7,12 @@ from odoo import api, fields, models
class Agreement(models.Model):
_inherit = "agreement"
task_count = fields.Integer('# Tasks',
compute='_compute_task_count')
task_count = fields.Integer("# Tasks", compute="_compute_task_count")
@api.multi
def _compute_task_count(self):
for ag in self:
count = self.env['project.task'].search_count(
[('agreement_id', '=', ag.id)])
count = self.env["project.task"].search_count(
[("agreement_id", "=", ag.id)]
)
ag.task_count = count