Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0031854 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
backport | [Retail Modules] Web POS | critical | always | 2016-01-08 09:49 | 2016-01-19 17:18 | |||
Reporter | gorkaion | View Status | public | |||||
Assigned To | mtaal | |||||||
Priority | immediate | Resolution | fixed | Fixed in Version | ||||
Status | closed | Fix in branch | Fixed in SCM revision | 724d274aa078 | ||||
Projection | none | ETA | none | Target Version | RR16Q1 | |||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | main | SCM revision | ||||||
Merge Request Status | ||||||||
Review Assigned To | migueldejuana | |||||||
OBNetwork customer | OBPS | |||||||
Support ticket | ||||||||
Regression level | QA functional test | |||||||
Regression date | 2015-11-27 | |||||||
Regression introduced in release | pi | |||||||
Regression introduced by commit | https://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/bc165573bb04 [^] | |||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0031854: Null Pointer Exception on Save again button of Errors While Importing POS Data | |||||||
Description | If an Order fails to integrate and appear in the Errors While Importing POS Data. When clicking on the Save again button a Null Pointer Exception message appears. | |||||||
Steps To Reproduce | 1. ensure that the current period is closed (in Open/Close Period Control) 2. create a new receipt in the POS 3. check that the receipt appear in the Errors While Importing POS Data with period closed error. 4. Open the period again 5. Click on Save Again button of "Errors While Importing POS Data" window. 6. See that a Null Pointer Exception message popup appears and the order is not processed. | |||||||
Proposed Solution | The real exception is thrown in the SaveDataActionHandler class of org.openbravo.retail.posterminal. Based in the Data Type of the error record it has to search the java class that manages the json that has to be imported. Since the ExternalOrderLoaded was added there are 2 different classes implementing the "Order" entity. So the following line of code throws a WELD exception as it does not know which class to inject syncProcess = syncProcesses.select(new DataSynchronizationProcess.Selector(type)).get(); This exception is catched in the last catch Exception block. After this catch the SaveDataActionHandler is returning a null that it is the reason of the NPE message. 2 fixes must be done: * The execute method should never return null. It should return an empty JSON or preferably a JSON with the error message. * When the java class that manages the json is loaded it should consider the case when more than one is present and should pick up one. Based on the json or setting up some priorities on the classes. | |||||||
Tags | No tags attached. | |||||||
Attached Files | ||||||||
![]() |
||||||||
|
![]() |
|
(0083299) hgbot (developer) 2016-01-14 13:10 |
Repository: retail/backports/3.0RR16Q1/org.openbravo.retail.posterminal Changeset: 724d274aa078b095d19d22a03e5431494a1fd041 Author: Martin Taal <martin.taal <at> openbravo.com> Date: Thu Jan 14 13:09:35 2016 +0100 URL: http://code.openbravo.com/retail/backports/3.0RR16Q1/org.openbravo.retail.posterminal/rev/724d274aa078b095d19d22a03e5431494a1fd041 [^] Fixes issue 31854: Null Pointer Exception on Save again button of Errors While Importing POS Data Let external order loader determine entity differently, return correct error message on exception --- M src/org/openbravo/retail/posterminal/ExternalOrderLoader.java M src/org/openbravo/retail/posterminal/SaveDataActionHandler.java --- |
(0083411) migueldejuana (viewer) 2016-01-19 17:18 |
Tested and reviewed in RR16Q1 |
![]() |
|||
Date Modified | Username | Field | Change |
2016-01-11 11:30 | Orekaria | Type | defect => backport |
2016-01-14 13:09 | mtaal | Review Assigned To | => marvintm |
2016-01-14 13:10 | hgbot | Checkin | |
2016-01-14 13:10 | hgbot | Note Added: 0083299 | |
2016-01-14 13:10 | hgbot | Status | scheduled => resolved |
2016-01-14 13:10 | hgbot | Resolution | open => fixed |
2016-01-14 13:10 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/retail/backports/3.0RR16Q1/org.openbravo.retail.posterminal/rev/724d274aa078b095d19d22a03e5431494a1fd041 [^] |
2016-01-18 16:49 | mtaal | Review Assigned To | marvintm => migueldejuana |
2016-01-19 17:18 | migueldejuana | Note Added: 0083411 | |
2016-01-19 17:18 | migueldejuana | Status | resolved => closed |
Copyright © 2000 - 2009 MantisBT Group |