Backend UX: Hide advanced tax rule settings

This commit is contained in:
Raphael Michel
2018-03-26 10:15:36 +02:00
parent 12b5e21314
commit 28a628ec93
2 changed files with 96 additions and 76 deletions

View File

@@ -125,6 +125,10 @@ class TaxRule(LoggedModel):
s += ' ({})'.format(_('reverse charge enabled'))
return str(s)
@property
def has_custom_rules(self):
return self.custom_rules and self.custom_rules != '[]'
def tax(self, base_price, base_price_is='auto'):
if self.rate == Decimal('0.00'):
return TaxedPrice(