diff options
| author | Azka Nathan <darizkyfaz@gmail.com> | 2023-11-08 11:03:23 +0700 |
|---|---|---|
| committer | Azka Nathan <darizkyfaz@gmail.com> | 2023-11-08 11:03:23 +0700 |
| commit | 019493c8e0e6cc5aff4c612eb332f1c882b0519d (patch) | |
| tree | f2c384cb7620c6ef58b29373df74ba84d95e39a2 | |
| parent | f64c15810e963555e88511becee56f4ee8efb21b (diff) | |
button reset to draft entries
| -rw-r--r-- | indoteknik_custom/models/account_move.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/indoteknik_custom/models/account_move.py b/indoteknik_custom/models/account_move.py index 2c9b9816..4e1beb3a 100644 --- a/indoteknik_custom/models/account_move.py +++ b/indoteknik_custom/models/account_move.py @@ -63,7 +63,7 @@ class AccountMove(models.Model): if not self.env.user.is_accounting: raise UserError('Hanya Accounting yang bisa Reset to Draft') - for rec in self: + for rec in self.line_ids: if rec.write_date != rec.create_date: if rec.statement_line_id and not rec.statement_line_id.statement_id.is_edit and rec.statement_line_id.statement_id.state == 'confirm': raise UserError('Bank Statement di Lock, Minta admin reconcile untuk unlock') |
