Openbravo Issue Tracking System - Retail Modules
View Issue Details
0041204Retail ModulesWeb POSpublic2019-06-28 14:002019-07-12 15:01
xabiermerino 
ranjith_qualiantech_com 
urgentmajoralways
closedfixed 
5
 
RR19Q2.1RR19Q2.1 
guilleaer
No
0041204: Errors while importing when synchronize a ticket with a discount of 100% and Generate Invoices active
When you have the check 'Generate Invoice' activate and try to synchronize a ticket with a discount of the 100% an error while importing happens:

java.lang.IndexOutOfBoundsException: Index 0 out-of-bounds for length 0
    at java.base/jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:64)
    at java.base/jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Preconditions.java:70)
    at java.base/jdk.internal.util.Preconditions.checkIndex(Preconditions.java:248)
    at java.base/java.util.Objects.checkIndex(Objects.java:372)
    at java.base/java.util.ArrayList.get(ArrayList.java:440)
    at org.hibernate.collection.internal.PersistentBag.get(PersistentBag.java:452)
    at org.openbravo.retail.posterminal.utility.InvoiceUtils.createPaymentTerms(InvoiceUtils.java:751)
- Configure a Price adjustment of 100% por avalanche
- Configure a POS Terminal type for generate invoices
- Create a ticket of avalanche and pay it
- realize that there is a new the errors while importing
No tags attached.
blocks defect 0041203 closed ranjith_qualiantech_com Errors while importing when synchronize a ticket with a discount of 100% and Generate Invoices active 
Issue History
2019-06-28 14:21marvintmTypedefect => backport
2019-06-28 14:21marvintmTarget Version => RR19Q2.1
2019-07-08 12:56ranjith_qualiantech_comAssigned ToRetail => ranjith_qualiantech_com
2019-07-11 18:56hgbotCheckin
2019-07-11 18:56hgbotNote Added: 0113302
2019-07-11 18:56hgbotStatusscheduled => resolved
2019-07-11 18:56hgbotResolutionopen => fixed
2019-07-11 18:56hgbotFixed in SCM revision => http://code.openbravo.com/retail/backports/3.0RR19Q2.1/org.openbravo.retail.posterminal/rev/6b146064a7193f9f6bc09547be4ae6714f7753fa [^]
2019-07-11 18:56hgbotCheckin
2019-07-11 18:56hgbotNote Added: 0113303
2019-07-11 18:56hgbotFixed in SCM revisionhttp://code.openbravo.com/retail/backports/3.0RR19Q2.1/org.openbravo.retail.posterminal/rev/6b146064a7193f9f6bc09547be4ae6714f7753fa [^] => http://code.openbravo.com/retail/backports/3.0RR19Q2.1/org.openbravo.retail.posterminal/rev/ccc3efbb85ba8d0a206a96c39e8ed3b7f1180469 [^]
2019-07-12 15:01guilleaerReview Assigned To => guilleaer
2019-07-12 15:01guilleaerStatusresolved => closed
2019-07-12 15:01guilleaerFixed in Version => RR19Q2.1

Notes
(0113302)
hgbot   
2019-07-11 18:56   
Repository: retail/backports/3.0RR19Q2.1/org.openbravo.retail.posterminal
Changeset: 6b146064a7193f9f6bc09547be4ae6714f7753fa
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Wed Jul 03 19:08:33 2019 +0530
URL: http://code.openbravo.com/retail/backports/3.0RR19Q2.1/org.openbravo.retail.posterminal/rev/6b146064a7193f9f6bc09547be4ae6714f7753fa [^]

Fixed issue 41204 : Invoice Payment schedule should be validated before creating payment terms

* If invoice amount is zero, then invoice payment schedule will not be created.
  When creating invoice payment terms, Invoice Payment schedule should be validated

---
M src/org/openbravo/retail/posterminal/utility/InvoiceUtils.java
---
(0113303)
hgbot   
2019-07-11 18:56   
Repository: retail/backports/3.0RR19Q2.1/org.openbravo.retail.posterminal
Changeset: ccc3efbb85ba8d0a206a96c39e8ed3b7f1180469
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Thu Jul 11 14:32:47 2019 +0530
URL: http://code.openbravo.com/retail/backports/3.0RR19Q2.1/org.openbravo.retail.posterminal/rev/ccc3efbb85ba8d0a206a96c39e8ed3b7f1180469 [^]

Fixed issue 41204 : Payments should not be processed if payment origAmount is zero

---
M src/org/openbravo/retail/posterminal/OrderLoader.java
---