I have tested all the scenarios in v6.1, there are 3 possibility for payment voucher,
1. automatic voucher creation via import invoice
2. manually voucher creation while creating statement line manually
3. First create voucher manually outside the bank statement and then assign it to
statement line(only possible with 6.0 and 6.1, not possible with 7.0)
point 1,
I checked your fix, that will solve statement line date problem while we import any invoice and also
create voucher with statement's date. In 6.1, it voucher date is taken from line's and line from statement
date so ultimately it's same. Your fix looks fine.
Note that statement line's date is always taken from bank statement. By import invoice, line date is taken from
statement date and while manual line creation, date is taken from context into _defaults.
point 2,
When create voucher manually, it's date is fetch from context 'default_date' passed on voucher_id. so as soon as
we fix line date in point 1, this will solve problem for voucher date.
point 3,
When creating voucher outside of statement and the date is different than the statement's, in this case shouldn't
the date of voucher be updated with statement/line's date? or it should keep that voucher's date and generate
accounting entries as per voucher date?
What happens currently in 6.1, when creating voucher from outside with date different than statement's, it writes
statement's date on the voucher as soon as you confirm the statement, and creates payment entries as per statement's
date, in this case voucher date will be lost. Can payment voucher date and statement date be different?
>We should perhaps replace this with :
>"date": context.get('default_date', statement.date)
I don't think we need this, because both will always be same. 'default_date' takes line date and that also comes from
the statement itself.
Hello Niels,
I have tested all the scenarios in v6.1, there are 3 possibility for payment voucher,
1. automatic voucher creation via import invoice
2. manually voucher creation while creating statement line manually
3. First create voucher manually outside the bank statement and then assign it to
statement line(only possible with 6.0 and 6.1, not possible with 7.0)
point 1,
I checked your fix, that will solve statement line date problem while we import any invoice and also
create voucher with statement's date. In 6.1, it voucher date is taken from line's and line from statement
date so ultimately it's same. Your fix looks fine.
Note that statement line's date is always taken from bank statement. By import invoice, line date is taken from
statement date and while manual line creation, date is taken from context into _defaults.
point 2,
When create voucher manually, it's date is fetch from context 'default_date' passed on voucher_id. so as soon as
we fix line date in point 1, this will solve problem for voucher date.
point 3,
When creating voucher outside of statement and the date is different than the statement's, in this case shouldn't
the date of voucher be updated with statement/line's date? or it should keep that voucher's date and generate
accounting entries as per voucher date?
What happens currently in 6.1, when creating voucher from outside with date different than statement's, it writes
statement's date on the voucher as soon as you confirm the statement, and creates payment entries as per statement's
date, in this case voucher date will be lost. Can payment voucher date and statement date be different?
>We should perhaps replace this with : get('default_ date', statement.date)
>"date": context.
I don't think we need this, because both will always be same. 'default_date' takes line date and that also comes from
the statement itself.
Awaiting your response.