diff options
| author | stephanchrst <stephanchrst@gmail.com> | 2025-12-18 10:33:07 +0700 |
|---|---|---|
| committer | stephanchrst <stephanchrst@gmail.com> | 2025-12-18 10:33:07 +0700 |
| commit | cd78a30609e0fa956458dabc02c4f199459cee9a (patch) | |
| tree | 3a41edb14d420453fd5d4e93d40bfdd3fd9c6eee | |
| parent | 48e81bf679958286b15812ed5c8982b25e4e3843 (diff) | |
add error if click result more than once
| -rw-r--r-- | indoteknik_custom/models/commission_internal.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/indoteknik_custom/models/commission_internal.py b/indoteknik_custom/models/commission_internal.py index 4de5c723..efe0f4fb 100644 --- a/indoteknik_custom/models/commission_internal.py +++ b/indoteknik_custom/models/commission_internal.py @@ -178,6 +178,9 @@ class CommissionInternal(models.Model): # fill later TODO @stephan def calculate_commission_internal_result(self): + if self.commission_internal_result: + raise UserError('Hapus semua isi table result jika ingin di create result ulang') + exception = ['ONGKOS KIRIM SO/20'] query = [ ('commission_internal_id.id', '=', self.id), |
