Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0020166Openbravo ERP09. Financial managementpublic2012-03-30 00:032012-07-11 12:11
gregor1com 
naiaramartinez 
normalmajoralways
closedfixed 
5
 
3.0MP14 
Core
No
0020166: GFR: Alert message gives inadequate instructions to user to resolve issue
SI 105618 was reported as an alert with the following message:

"this invoice belongs to an order that has its payment plan wrong distributed through its invoices"

the wording of this message should change. However -

"please reactivate all the invoices related to the order and complete them again"

this part of the message is not correct in this case because the re-activate button does not appear and the user cannot reactivate the document.
I believe that the issue here is that the document was voided, yet is still being taken into account by the alert.

Note that the related order has a payment in plan that was fully paid. This voided SI does not have a payment in plan associated with it.
1) that the voided document not generate this alert.
2) that the message be reviewed. Need to know all the conditions in the code that could give rise to the alerted message, and I will propose a new message.
No tags attached.
Issue History
2012-03-30 00:03gregor1comNew Issue
2012-03-30 00:03gregor1comAssigned To => vmromanos
2012-03-30 00:03gregor1comModules => Core
2012-05-10 12:12gorka_gilAssigned Tovmromanos => mirurita
2012-05-25 08:02naiaramartinezNote Added: 0048925
2012-06-11 11:07naiaramartinezAssigned Tomirurita => naiaramartinez
2012-06-11 11:08naiaramartinezStatusnew => scheduled
2012-06-11 11:08naiaramartinezfix_in_branch => pi
2012-07-11 12:05hgbotCheckin
2012-07-11 12:05hgbotNote Added: 0050479
2012-07-11 12:05hgbotStatusscheduled => resolved
2012-07-11 12:05hgbotResolutionopen => fixed
2012-07-11 12:05hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/a8b18247dfc503b7380b21413b66798f5e54f8c1 [^]
2012-07-11 12:11miruritaNote Added: 0050480
2012-07-11 12:11miruritaStatusresolved => closed
2012-07-11 12:11miruritaFixed in Version => 3.0MP14

Notes
(0048925)
naiaramartinez   
2012-05-25 08:02   
Hi Greg,

The invoice number described in the issue (105618) does not exist in the Openbravo demo data, so we cannot research this particular invoice.
Based on the information provided, we have tried to reproduce the situation but the following scenarios are working fine, they are not creating any alert:
a) Invoice one order in a single invoice. Void the invoice.
b) Invoice one order in a single invoice. Add a partial payment against the invoice. Void the invoice.
c) Invoice one order in a two different invoices. Void one invoice.
d) Invoice one order in a two different invoices. Add a partial payment against one invoice. Void the invoice previously paid.

This alert was created to detect invoices affected by the issue 0017760 (one year old).
Probably the invoices caught by the alert in your instance are quite old invoices.

If you want to analyze deeper the problem with the invoice 105618 you should contact with Openbravo support team and they will kindly find out what is wrong with this particular invoice.

From our side, we will improve the message displayed in the alert and voided invoices will be discarded.
(0050479)
hgbot   
2012-07-11 12:05   
Repository: erp/devel/pi
Changeset: a8b18247dfc503b7380b21413b66798f5e54f8c1
Author: Naiara Martinez <naiara.martinez <at> openbravo.com>
Date: Thu May 24 16:44:45 2012 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/a8b18247dfc503b7380b21413b66798f5e54f8c1 [^]

Fixed bug 20166: do not take into account voided invoices in insertAlertRule

---
M modules/org.openbravo.advpaymentmngt/build/classes/org/openbravo/advpaymentmngt/buildvalidation/WrongPaymentScheduleDetailsCheckData.class
M modules/org.openbravo.advpaymentmngt/src-util/buildvalidation/src/org/openbravo/advpaymentmngt/buildvalidation/WrongPaymentScheduleDetailsCheck_data.xsql
M modules/org.openbravo.advpaymentmngt/src-util/buildvalidation/src/src/org/openbravo/advpaymentmngt/buildvalidation/WrongPaymentScheduleDetailsCheckData.java
---
(0050480)
mirurita   
2012-07-11 12:11   
code review + testing OK

Testing Plan
1) Create a sales order (SO1)
2) Create a sales invoice (SI1) for previous order
3) Create inconsistent data through sql updates:
-- the parameter is the psd of the order and invoice
update fin_payment_scheduledetail set fin_payment_schedule_order = null where fin_payment_scheduledetail_id = ?;
-- first parameter is the SO1 payment schedule id
-- second parameter is any psd of the system
update fin_payment_scheduledetail set fin_payment_schedule_order = ? where fin_payment_scheduledetail_id = ?;
4) void the invoice
5) run update.database
6) the alert is not created