diff options
| author | it-fixcomart <it@fixcomart.co.id> | 2025-04-30 08:24:04 +0700 |
|---|---|---|
| committer | it-fixcomart <it@fixcomart.co.id> | 2025-04-30 08:24:04 +0700 |
| commit | 53d840b330769988ac9efd4c4c6fe4f21969d850 (patch) | |
| tree | 193f49b55b708d75951ab80706362b1cb112d0ae | |
| parent | f3854677b0f74db2fbb54ad012b3a6a6fc9e11df (diff) | |
(andri) Penyesuaian Margin Approval (Live 1 Mei)
| -rwxr-xr-x | indoteknik_custom/models/sale_order.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/indoteknik_custom/models/sale_order.py b/indoteknik_custom/models/sale_order.py index 37f767ec..78f2fa38 100755 --- a/indoteknik_custom/models/sale_order.py +++ b/indoteknik_custom/models/sale_order.py @@ -1431,10 +1431,11 @@ class SaleOrder(models.Model): return False def _requires_approval_margin_leader(self): - return self.total_percent_margin < 15 and not self.env.user.is_leader + return self.total_percent_margin <= 15 and not self.env.user.is_leader def _requires_approval_margin_manager(self): - return self.total_percent_margin >= 15 and not self.env.user.is_leader and not self.env.user.is_sales_manager + return 15 < self.total_percent_margin <= 24 and not self.env.user.is_sales_manager and not self.env.user.is_leader + # return self.total_percent_margin >= 15 and not self.env.user.is_leader and not self.env.user.is_sales_manager def _create_approval_notification(self, approval_role): title = 'Warning' |
