Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Panel

The algorithm to calculate the new dates for the invoice credit terms consist of 2 simple functions:
a) setDate(YY1,MM1,DD1)
b) addDate(YY2,MM2,DD2)

Scenario 1:
The credit terms date is next month 7th day.
Assuming today 
d0 = 2013 Feb 8
d1 = setDate(d0, 0,0,1); this will return the results as 2013 Feb 1 (0 means don't modify the value)
d2 = addDate(0,1,7); this will return the results as 2013 March 7

Scenario 2:
The credit terms date is 15 days from the current invoice date:
d0 = 2013 Feb 8
d1 = setDate(d0,0,0,0), as we don't need to modify the day value, it will return 2013 Feb 8 (same as d0)
d2 = addDate(d1,0,0,15), we just add 15 days from the current date, results will be 2013 Feb 23

Scenario 3:
The credit date is last day of the same month
d0 = 2013 Feb 8
d1 = setDate(d0, 0,0,1); this will return the results as 2013 Feb 1 (0 means don't modify the value)
d2 = addDate(0,1,-1); this will return the results as 2013 Feb 28 or 29 (depends on which year, basically, adding one month to 1st of March, and minus one day to get the day before)

So, basically, the settings for this column would be :
YY1, MM1,DD1,YY2,MM2,DD2


Related Wiki Pages:

Panel

Search Results
spacekeyWMS
maxLimit5
querycustomer maintenance
typepage