Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0028513Openbravo ERP04. Warehouse managementpublic2015-01-02 11:172015-05-07 22:17
ngarcia 
jorge-garcia 
highminoralways
closedfixed 
5
 
pi 
umartirena
Core
No
0028513: Error message wrongly shown when processing an inventory with a product with % in its name and negative stock
Error message wrongly shown when processing an inventory with a product with % in its name and negative stock
As group admin role:
   Check the Client does not allow negative stock
   Create a new product whose name contains a '%'
   Create two Goods Receipts for that product to different storage bins
   Update from the database the qtyonhand value of one of the records in the m_storage_detail table with a negative value
   Create a physical inventory for that product and increase the stock in the storage bin with positive stock
   Try to process it and check you get the following error:
      Conversion = '''
In InventoryCountProcess.checkStock function, an exception is launched when trying to format the error message
No tags attached.
Issue History
2015-01-02 11:17ngarciaNew Issue
2015-01-02 11:17ngarciaAssigned To => AtulOpenbravo
2015-01-02 11:17ngarciaModules => Core
2015-01-02 11:17ngarciaResolution time => 1426633200
2015-01-02 11:17ngarciaTriggers an Emergency Pack => No
2015-01-02 11:18ngarciaIssue Monitored: networkb
2015-01-13 18:55ngarciaTarget Version => 3.0PR15Q2
2015-02-23 13:30jonalegriaesarteTarget Version3.0PR15Q2 => 3.0PR15Q3
2015-02-23 15:38SandrahuguetAssigned ToAtulOpenbravo => jorge-garcia
2015-02-26 18:24jorge-garciaNote Added: 0074990
2015-03-09 17:27jonalegriaesarteResolution time1426633200 =>
2015-03-11 13:26ngarciaTarget Version3.0PR15Q3 =>
2015-03-25 09:38jorge-garciaStatusnew => scheduled
2015-04-29 12:43hgbotCheckin
2015-04-29 12:43hgbotNote Added: 0076872
2015-04-29 12:43hgbotStatusscheduled => resolved
2015-04-29 12:43hgbotResolutionopen => fixed
2015-04-29 12:43hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/7b24a42b4b251f43154dc00a869c86da93606fc5 [^]
2015-04-29 12:43umartirenaReview Assigned To => umartirena
2015-04-29 12:43umartirenaNote Added: 0076873
2015-04-29 12:43umartirenaStatusresolved => closed
2015-04-29 12:44umartirenaFixed in Version => pi
2015-05-07 22:17hudsonbotCheckin
2015-05-07 22:17hudsonbotNote Added: 0077183

Notes
(0074990)
jorge-garcia   
2015-02-26 18:24   
Test Plan

As group admin role:
   Check the Client does not allow negative stock.
   Create a new product whose name contains a '%'.
   Create two Goods Receipts for that product to different storage bins.
   Update from the database the qtyonhand value of one of the records in the m_storage_detail table with a negative value.
   Create a physical inventory for that product and increase the stock in the storage bin with positive stock.
   Process it and check you get correct message of the product, UOM and storage bin from the storage bin with negative stock
(0076872)
hgbot   
2015-04-29 12:43   
Repository: erp/devel/pi
Changeset: 7b24a42b4b251f43154dc00a869c86da93606fc5
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Thu Feb 26 17:46:48 2015 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/7b24a42b4b251f43154dc00a869c86da93606fc5 [^]

Fixed issue 28513: Error message wrongly shown when processing an inventory.

The error message when processing an inventory is wrongly shown with a product
with % in its name and a negative stock.

The issue occurs when we are parsing the error message and detects the % symbol
and try to find the string format in the next character.

The proposal solution is to eliminate the String.format() method from the
code.

Now, the error message is shown properly with the correct name.

---
M src/org/openbravo/materialmgmt/InventoryCountProcess.java
---
(0076873)
umartirena   
2015-04-29 12:43   
Code Review + Testing OK
(0077183)
hudsonbot   
2015-05-07 22:17   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/a1817f84bd8b [^]
Maturity status: Test