wrong behaviour in cancel/redo payment voucher

Bug #781850 reported by filsys
22
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Invalid
Low
OpenERP R&D Addons Team 3

Bug Description

Step to reproduce:
OpenERP 6.0.2:
Make 3 vouchers (v1, v2, v3) for 3 partial payments for on customer invoice f1.
Cancel v2 voucer. You will see that all reconcile records for f1 is deleted.
Reopen (set to draft) and validate v2.
Check account move line coresponding to v2.
I think that reconcile model is inconsistent for cancel/reopen multiple partial reconcile.
Thanks

Related branches

Revision history for this message
Frederic Clementi - Camptocamp (frederic-clementi) wrote :

+1

Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
importance: Undecided → Low
status: New → Confirmed
Revision history for this message
filsys (office-filsystem) wrote : Re: [Bug 781850] Re: wrong behaviour in cancel/redo payment voucher

Hi Frederic,
Our customer has a trade bussiness. He sell products and collect
payments in cash, from bank and other forms (cards, vouchers etc.)
Imagine that he encode hundreds of invoices (tens for each customer) in
a month and collect money in partial payments every day from many customers.
If I use payment vouchers for collect partial payments, imagine that
user responsible make an error for one payment from tens. If I cancel
wrong voucher then ALL reconciled move is unreconciled. Means that ALL
payments for invoice is unreconciled. That means to deep dig in account
move line to reconcile.
CamptoCamp is a best partner involved in OpenERP. You have a workarround
for this issue?

Dumitru Gilcescu

Thanks

On 13.05.2011 09:56, Frederic Clementi - Camptocamp.com wrote:
> +1
>

Revision history for this message
Frederic Clementi - Camptocamp (frederic-clementi) wrote :

Hi Dimitru, thanks for the "best partner" :) but I have no workaround when
using voucher.

it is purely a bug and it has to be fixed.

sorry

Frédéric CLEMENTI
Business Solutions
Camptocamp SA
Tel : + 41 (0)21 619 1041
http://www.camptocamp.com

 <email address hidden>

2011/5/13 filsys <email address hidden>

> Hi Frederic,
> Our customer has a trade bussiness. He sell products and collect
> payments in cash, from bank and other forms (cards, vouchers etc.)
> Imagine that he encode hundreds of invoices (tens for each customer) in
> a month and collect money in partial payments every day from many
> customers.
> If I use payment vouchers for collect partial payments, imagine that
> user responsible make an error for one payment from tens. If I cancel
> wrong voucher then ALL reconciled move is unreconciled. Means that ALL
> payments for invoice is unreconciled. That means to deep dig in account
> move line to reconcile.
> CamptoCamp is a best partner involved in OpenERP. You have a workarround
> for this issue?
>
> Dumitru Gilcescu
>
> Thanks
>
>
> On 13.05.2011 09:56, Frederic Clementi - Camptocamp.com wrote:
> > +1
> >
>
> --
> You received this bug notification because you are a direct subscriber
> of the bug.
> https://bugs.launchpad.net/bugs/781850
>
> Title:
> wrong behaviour in cancel/redo payment voucher
>
> Status in OpenERP Modules (addons):
> Confirmed
>
> Bug description:
> Step to reproduce:
> OpenERP 6.0.2:
> Make 3 vouchers (v1, v2, v3) for 3 partial payments for on customer
> invoice f1.
> Cancel v2 voucer. You will see that all reconcile records for f1 is
> deleted.
> Reopen (set to draft) and validate v2.
> Check account move line coresponding to v2.
> I think that reconcile model is inconsistent for cancel/reopen multiple
> partial reconcile.
> Thanks
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/openobject-addons/+bug/781850/+subscribe
>

Revision history for this message
filsys (office-filsystem) wrote :

sad...
...and OpenERP (Vinay Rana) has set low importance for this bug.:-(

On 13.05.2011 15:12, Frederic Clementi - Camptocamp.com wrote:
> Hi Dimitru, thanks for the "best partner" :) but I have no workaround when
> using voucher.
>
> it is purely a bug and it has to be fixed.
>
> sorry
>
> Frédéric CLEMENTI
> Business Solutions
> Camptocamp SA
> Tel : + 41 (0)21 619 1041
> http://www.camptocamp.com
>
> <email address hidden>
>
>
>
> 2011/5/13 filsys<email address hidden>
>
>> Hi Frederic,
>> Our customer has a trade bussiness. He sell products and collect
>> payments in cash, from bank and other forms (cards, vouchers etc.)
>> Imagine that he encode hundreds of invoices (tens for each customer) in
>> a month and collect money in partial payments every day from many
>> customers.
>> If I use payment vouchers for collect partial payments, imagine that
>> user responsible make an error for one payment from tens. If I cancel
>> wrong voucher then ALL reconciled move is unreconciled. Means that ALL
>> payments for invoice is unreconciled. That means to deep dig in account
>> move line to reconcile.
>> CamptoCamp is a best partner involved in OpenERP. You have a workarround
>> for this issue?
>>
>> Dumitru Gilcescu
>>
>> Thanks
>>
>>
>> On 13.05.2011 09:56, Frederic Clementi - Camptocamp.com wrote:
>>> +1
>>>
>> --
>> You received this bug notification because you are a direct subscriber
>> of the bug.
>> https://bugs.launchpad.net/bugs/781850
>>
>> Title:
>> wrong behaviour in cancel/redo payment voucher
>>
>> Status in OpenERP Modules (addons):
>> Confirmed
>>
>> Bug description:
>> Step to reproduce:
>> OpenERP 6.0.2:
>> Make 3 vouchers (v1, v2, v3) for 3 partial payments for on customer
>> invoice f1.
>> Cancel v2 voucer. You will see that all reconcile records for f1 is
>> deleted.
>> Reopen (set to draft) and validate v2.
>> Check account move line coresponding to v2.
>> I think that reconcile model is inconsistent for cancel/reopen multiple
>> partial reconcile.
>> Thanks
>>
>> To unsubscribe from this bug, go to:
>> https://bugs.launchpad.net/openobject-addons/+bug/781850/+subscribe
>>

Revision history for this message
Tech Receptives (techreceptives) wrote :

Hi,

Can you please try the attached patch and let revert.

Regards,
tech receptives

Revision history for this message
filsys (office-filsystem) wrote :

I used another way, but we'll try it on.

Thanks

Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
Mustufa Rangwala (Open ERP) (mra-tinyerp) wrote :

Hello filsys,

Yes we can do like,

If we have 3 partial payments for one invoice and we are unreconciled one of the partial payment that time we need to create "Partial reconciliation" id on move line by calling reconcile_partial(...) method.

So it means when full payment is going to unreconcile we will create partial_recocile_id But we need to consider all the cases for partial and fully payment.

And more we can improve the cancel method on voucher object by calling below method.
self.pool.get('account.move.line')._remove_move_reconcile(cr, uid, move_ids, context)

Thanks,
mra

Revision history for this message
Purnendu Singh (OpenERP) (purnendu-singh) wrote :

Hello,

Thanks for you guidance and contribution Mustufa. It's help me a lot. I fixed this bug in lp:~openerp-dev/openobject-addons/trunk-bug-781850-psi branch. and it will be merge in to main addons very soon.

Revision No: 4773
Revision ID: <email address hidden>

Thanks,
Purnendu Singh

Changed in openobject-addons:
status: In Progress → Fix Committed
Changed in openobject-addons:
milestone: none → 6.1
Revision history for this message
Fabien (Open ERP) (fp-tinyerp) wrote :

This is due to the way reconciliation is managed in OpenERP.
We decided to merge reconciliation if possible to transform partial reconciliations into total ones.
This means that when you validate v3, all small payments are reconcilied into one big reconciliation containing the invoice and the 3 payments. This is good for the traceability.

As a result of this, the 3 payments and 1 invoice are considered as one big reconciliation (total) and not 3 small ones (partials). This means that if you unreconcile, you loose the 3 others.

There are PROs and CONs against this technique. The main CON is the one reported here. But PROs are so much useful that I prefer to keep this situation.

It's not a bug as, legally, everything remains valid.

Changed in openobject-addons:
status: Fix Committed → Invalid
Revision history for this message
Colm (colml) wrote :

Fabian,

This bug isn't exactly related to the scenario you describe. At any time a previous partial reconcile is changed all recorded partial reconciles that were made after the original one (that was changed) are lost. It doesn't matter if the invoice is still partially open or not.

The patch submitted by Purnendu Singh fixes this bug for me.

I can created a video example demonstrating the bug if needed.

I hope you can reconsider rejecting this.

-Colm

Revision history for this message
Sandro Issufo (sandroissufo) wrote :

Hello,

After a apply the the patch submitted by Purnendu Singh, it solve the problem of unreconcile partial payments BUT creates a new problem, when unreconcile a single payment with more than one invoice, the residual amount of the affected invoice become equal to total of the unreconciled voucher.

Ex:
Invoice 001 - 200
Invoice 002 - 100

Both are paid by Voucher 001 (300)

Unreconcile Voucher 001 ----> Residual amount of Invoice001 will be 300 and Residual amount of Invoice002 will be 300

Of course this wrong,

Thanks

Revision history for this message
Roxly Rivero (rcrivero) wrote :

Hello,

Try the new account_voucher from the forum.
It fixes this issue.

Revision history for this message
hbto [Vauxoo] http://www.vauxoo.com (humbertoarocha) wrote :

We are solving this issue to this bug,
which is both affecting v6.0 & v6.1

The solution is almost out there

Regards,

Hbto [Vauxoo]

Revision history for this message
Colm (colml) wrote :

Thank you Vauxoo, glad to hear this bug is finally being fixed.

Revision history for this message
Nhomar - Vauxoo (nhomar) wrote :

@fabien.

You said in comment #9:

>>There are PROs and CONs against this technique. The main CON is the one reported here. But PROs are so much useful that I >>prefer to keep this situation.

>>It's not a bug as, legally, everything remains valid.

We solved already this bug, but im a little worried about your Whys...

When you said "We decided to merge reconciliation if possible"

i need to know the why, not the decisition itself.

I remember this as a real big Bug from OpenERP.

Why.?

In several countries at least in Latin america the withholding process must to be managed as a payment, and have legal meaning as Invoice itself, and Reconciliation is the right concept to Join integrity between Invoice and Withholding [1]

As you see in definition this kind of tax management (what we already manage in an strong way on localization for Venezuela and Colombia).

Even if you have reason that the feature or "decition" it self does't brake the legal stuff, it is not less true that to comply with the constraint between invoice and "payment for withholding" requiere A LOT of technical logic (if we need automate this precess) or "functional work" if we want to mantain this IMPORTANT feature _reconciliation_ as core does by default to mantain the OPW working with less cost for customer.

Can you , please, help me understand your decition, and make possible teke mine (develop and make our own reconciliation way) or propose a new module called _alternative_reconciliation_ for merge.

Please, is important to know that if OpenERP want to comply with more local stuff from country to country and mantain a lot of OPW NEED to be as more generical as it can, or support this kind of automations with a lot of documentation.

[1] http://en.wikipedia.org/wiki/Withholding_tax

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.