diff options
| author | stephanchrst <stephanchrst@gmail.com> | 2023-12-18 09:31:54 +0700 |
|---|---|---|
| committer | stephanchrst <stephanchrst@gmail.com> | 2023-12-18 09:31:54 +0700 |
| commit | 7099c4615aa3435273839c49ceee121306fec84d (patch) | |
| tree | 81d305474cb66747955aaf0c571a3ef81b8baad3 /indoteknik_custom/models/account_move.py | |
| parent | 07e8a51fc023025d2cbde83ab0333e5e53e2ad12 (diff) | |
| parent | 8fc9eddc57f76f62c3efaa70c9a3aee8be1911fa (diff) | |
Merge branch 'production' into purchasing-job
# Conflicts:
# indoteknik_custom/models/__init__.py
# indoteknik_custom/security/ir.model.access.csv
Diffstat (limited to 'indoteknik_custom/models/account_move.py')
| -rw-r--r-- | indoteknik_custom/models/account_move.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/indoteknik_custom/models/account_move.py b/indoteknik_custom/models/account_move.py index 699191d6..82a86a39 100644 --- a/indoteknik_custom/models/account_move.py +++ b/indoteknik_custom/models/account_move.py @@ -31,6 +31,17 @@ class AccountMove(models.Model): due_line = fields.One2many('due.extension.line', 'invoice_id', compute='_compute_due_line', string='Due Extension Lines') no_faktur_pajak = fields.Char(string='No Faktur Pajak') date_completed = fields.Datetime(string='Date Completed') + mark_upload_efaktur = fields.Selection([ + ('belum_upload', 'Belum Upload FP'), + ('sudah_upload', 'Sudah Upload FP'), + ], 'Mark Upload Faktur', compute='_compute_mark_upload_efaktur', default='belum_upload') + + def _compute_mark_upload_efaktur(self): + for move in self: + if move.date_efaktur_exported or move.is_efaktur_exported or move.efaktur_document: + move.mark_upload_efaktur = 'sudah_upload' + else: + move.mark_upload_efaktur = 'belum_upload' def _compute_due_line(self): for invoice in self: |
