diff options
| author | Rafi Zadanly <zadanlyr@gmail.com> | 2024-04-26 11:12:56 +0700 |
|---|---|---|
| committer | Rafi Zadanly <zadanlyr@gmail.com> | 2024-04-26 11:12:56 +0700 |
| commit | d026ce987698790c8424a1b88d7bfacf1508dad6 (patch) | |
| tree | b8eaa53d5bd2b4edf9ac2f27968bc41c33cdcc7b /indoteknik_custom/models | |
| parent | 175ee679cbd2af2245bc9468312a6ad28419e110 (diff) | |
Update approval by procurement
Diffstat (limited to 'indoteknik_custom/models')
| -rwxr-xr-x | indoteknik_custom/models/sale_order.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/indoteknik_custom/models/sale_order.py b/indoteknik_custom/models/sale_order.py index 3b6879cd..88d9aec7 100755 --- a/indoteknik_custom/models/sale_order.py +++ b/indoteknik_custom/models/sale_order.py @@ -469,8 +469,8 @@ class SaleOrder(models.Model): SYSTEM_UID = 25 FROM_WEBSITE = order.create_uid.id == SYSTEM_UID - if FROM_WEBSITE and main_parent.use_so_approval and order.web_approval != 'cust_procurement': - raise UserError("This order not yet approved by customer procurement") + if FROM_WEBSITE and main_parent.use_so_approval and order.web_approval not in ['cust_procurement', 'cust_director']: + raise UserError("This order not yet approved by customer procurement or director") if order.validate_partner_invoice_due(): return self._create_notification_action('Notification', 'Terdapat invoice yang telah melewati batas waktu, mohon perbarui pada dokumen Due Extension') |
