Issue 9643

Title
Use more apropiate date for commissions
Priority
feature
Status
resolved
Nosy list
pokoli, reviewbot, roundup-bot
Assigned to
pokoli
Keywords
review

Created on 2020-09-28.14:51:13 by pokoli, last changed 2 months ago by roundup-bot.

Messages

New changeset faa0bacd350a by Sergi Almacellas Abellana in branch 'default':
Use the invoice date or payment date for commission date
https://hg.tryton.org/tryton-env/rev/faa0bacd350a
New changeset 780efc2639b4 by Sergi Almacellas Abellana in branch 'default':
Use the invoice date or payment date for commission date
https://hg.tryton.org/modules/commission/rev/780efc2639b4
Author: [hidden] (pokoli) Tryton committer Tryton translator
Date: 2020-09-28.14:51:12
Currently the invoice module sets the commission date based on the method:

* On posting: The date is set to today when the invoice is posted.
* On payment: The date is set to today when the invoice is paid.

This works well when the system is receiving the data in real time but it may be some delay (specially when paying an invoice) which may cause inconsistence. 

So I think it will be better to use:

* On posting: Set the commission date to invoice date (fallback to today if empty)
* On payment: Set the commission date to the reconcile date of the invoice (max date of payments). 


This way, the commission date always reflects the date when the commission its due and not when the due condition was encoded on the system.
History
Date User Action Args
2020-11-13 14:03:41roundup-botsetmessages: + msg61901
2020-11-13 14:03:37roundup-botsetmessages: + msg61900
nosy: + roundup-bot
status: testing -> resolved
2020-11-07 20:08:49reviewbotsetmessages: + msg61747
2020-10-12 18:11:19reviewbotsetmessages: + msg60867
2020-10-11 23:37:52reviewbotsetmessages: + msg60805
2020-09-28 14:55:12reviewbotsetnosy: + reviewbot
messages: + msg60446
2020-09-28 14:52:17pokolisetstatus: in-progress -> testing
reviews: 294601002
keyword: + review
2020-09-28 14:51:13pokolicreate

Showing 10 items. Show all history (warning: this could be VERY long)