invoice with dynamic discounts
Dear Team, we have a business case as follows:
1. Order is created with 2 lines on 1-Mar-2015
Line 1--qty--1, price per qty-60= Total amount per line 60
Line 2-qty--1, price per qty-40=Total amount per line 40
Now, if invoice is paid within 30 days of invoice creation date, 20% discount is to be applied on invoice.
In such case, invoice will be created on 01-Mar-2015 with assumption that customer will pay in 30 days.
Invoice amount will be =20% discount on 100= 80
Line 1 amount- =20% discount on 60= 48
Line 2 amount- =20% discount on 40= 32
Now for example, if customer does not pay by 30-Mar then, additional invoice with 20 shall be generated in AR with 2 lines of Line 1 with 12 and Line 2 with 8.