← Back to team overview

openerp-expert-accounting team mailing list archive

[Bug 560459] Re: Payment term Date computation needs attention!

 

Jay, instead of a "day of the month" I would use a "days of the month"
letting the user select more than one payment day.

On Spain is pretty usual for companies to have 2 pay days, for example
the 10th and 25th of each month.

For Spain this is what would be needed:

1. Date criteria: From invoice date | From end of the month | From the start of the current month
2. Number of days: Number of days to add to the date in the date criteria before searching for a "pay day" (if there are no "pay days" defined, then we would use this day). If the day is in the past, then 'jump' to the next month.
3. Pay days: A list of days valid for payments (split by comas). The first payment day from the day calculated will be used.


Some examples:

    * Date criteria: From end of the month
    * Number of days: -5
    * Pay days: (empty)

Invoice dated 2010-04-08 ==> payment on 2010-04-26;
Invoice dated 2010-04-17 ==> payment on 2010-04-26;
Invoice dated 2010-04-27 ==> payment on 2010-05-27.


    * Date criteria: From invoice date
    * Number of days: 30
    * Pay days: 10, 25

Invoice dated 2010-04-08 ==> payment on 2010-05-10;
Invoice dated 2010-04-17 ==> payment on 2010-05-25;
Invoice dated 2010-04-27 ==> payment on 2010-06-10.


    * Date criteria: From the start of the current month
    * Number of days: 10
    * Pay days: (empty)

Invoice dated 2010-04-08 ==> payment on 2010-04-10;
Invoice dated 2010-04-17 ==> payment on 2010-05-10;
Invoice dated 2010-04-27 ==> payment on 2010-05-10.


I think that with those three options you cover pretty much all the use cases.

-- 
Payment term Date computation needs attention!
https://bugs.launchpad.net/bugs/560459
You received this bug notification because you are a member of OpenERP
Accounting Experts, which is a direct subscriber.

Status in OpenObject Addons Modules: Confirmed
Status in OpenObject Addons 5.0 series: Won't Fix
Status in OpenObject Addons trunk series: Confirmed

Bug description:
In computing next_date, add 1 month from source code, but you should be configurable, and it is not always well.

These can be configurable since the model: account.payment.term.line
adding a field: months