diff --git a/project_sale_usability/models/project_project.py b/project_sale_usability/models/project_project.py index 74baa16a..00e8f933 100644 --- a/project_sale_usability/models/project_project.py +++ b/project_sale_usability/models/project_project.py @@ -28,7 +28,7 @@ def _domain_sale_invoice_line(self): # check if analytic_distribution contains id of analytic account query.add_where( "account_move_line.analytic_distribution ?| array[%s]", - [str(project.account_id.id) for project in self if project.account_id], + [str(project.account_id.id) for project in self], ) query.order = None query_string, query_param = query.select( @@ -128,7 +128,7 @@ def button_open_out_invoice_line(self): "name": _("Out Invoice Lines"), "domain": domain, "type": "ir.actions.act_window", - "view_mode": "tree", + "view_mode": "list", "res_model": "account.move.line", } @@ -139,6 +139,6 @@ def button_open_out_refund_line(self): "name": _("Out Refund Lines"), "domain": domain, "type": "ir.actions.act_window", - "view_mode": "tree", + "view_mode": "list", "res_model": "account.move.line", }