mirror of
https://github.com/pretix/pretix.git
synced 2026-05-03 14:54:04 +00:00
Ensure the number of decimal places of payment fees
This commit is contained in:
@@ -47,7 +47,7 @@ class BasePaymentProvider:
|
||||
"""
|
||||
fee_abs = self.settings.get('_fee_abs', as_type=Decimal, default=0)
|
||||
fee_percent = self.settings.get('_fee_percent', as_type=Decimal, default=0)
|
||||
return Decimal(price * fee_percent / 100 + fee_abs)
|
||||
return (price * fee_percent / 100).quantize('.01') + fee_abs
|
||||
|
||||
@property
|
||||
def verbose_name(self) -> str:
|
||||
|
||||
Reference in New Issue
Block a user