Merge branch 'master-sale-account-discount' into 'master'
[IMP] Remove unnecessary code See merge request flectra-hq/flectra!23
This commit is contained in:
commit
5d8eb4fb9f
@ -117,8 +117,6 @@ class AccountInvoice(models.Model):
|
|||||||
|
|
||||||
@api.onchange('discount_amount')
|
@api.onchange('discount_amount')
|
||||||
def onchange_discount_amount(self):
|
def onchange_discount_amount(self):
|
||||||
if self.discount_method == 'per':
|
|
||||||
return True
|
|
||||||
values = self.get_maximum_per_amount()
|
values = self.get_maximum_per_amount()
|
||||||
if self.discount < 0:
|
if self.discount < 0:
|
||||||
raise Warning(_("Discount should be less than Gross Amount"))
|
raise Warning(_("Discount should be less than Gross Amount"))
|
||||||
|
Loading…
Reference in New Issue
Block a user