Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.

Module: Expenses

Entity: hr.expense

Compute Method: _compute_can_edit_account

View 20.0
Inputs Method Outputs
  • state
+ if not self.env.user.has_group('account.group_account_invoice'):
+             self.can_edit_account = False
+         else:
+             for expense in self:
+                 expense.can_edit_account = expense.state == 'approved'
  • can_edit_account

Back to entity