Openbravo Issue Tracking System - Retail Modules
View Issue Details
0026217Retail ModulesWeb POSpublic2014-04-08 18:302014-06-27 16:50
jecharri 
malsasua 
urgentminoralways
closedfixed 
5
RMP31.2 
RR14Q3RR14Q3 
marvintm
No
0026217: When the order goes to Errors while importing POS Data due to a wrong configuration in the BP
When the order goes to Errors while importing POS Data due to a wrong configuration in the BP
-Configure a business partner without payment method
-Go to Web POS and create and order
-Pay it
-The order will go to "errors while importing pos data"

At this point, you need to edit JSON object and isert a valid payment method id. It will be easier if the user has to change only the BP configuration using UI, so when the java OrderLoader try to create the order, can get the BusinessPartner object using DAL and not from the JSON object.
Instead of taking the BP values from json object, use DAL to get last BP object:
order.setPartnerAddress(OBDal.getInstance().get(Location.class,
        jsonorder.getJSONObject("bp").getString("locId")));
    order.setInvoiceAddress(order.getPartnerAddress());
    order.setPaymentMethod((FIN_PaymentMethod) OBDal.getInstance().getProxy("FIN_PaymentMethod",
        jsonorder.getJSONObject("bp").getString("paymentMethod")));
    order.setPaymentTerms((PaymentTerm) OBDal.getInstance().getProxy("FinancialMgmtPaymentTerm",
        jsonorder.getJSONObject("bp").getString("paymentTerms")));
    order.setInvoiceTerms(jsonorder.getJSONObject("bp").getString("invoiceTerms"));
No tags attached.
related to defect 0032777 closed ranjith_qualiantech_com [SER QA 974] Ticket not synchronized to the backoffice because the Invoice Term is not defined  
Issue History
2014-04-08 18:30jecharriNew Issue
2014-04-08 18:30jecharriAssigned To => malsasua
2014-04-08 18:30jecharriResolution time => 1399932000
2014-04-08 18:30jecharriTriggers an Emergency Pack => No
2014-06-26 00:06hgbotCheckin
2014-06-26 00:06hgbotNote Added: 0068324
2014-06-26 00:06hgbotStatusnew => resolved
2014-06-26 00:06hgbotResolutionopen => fixed
2014-06-26 00:06hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/7b35aae163e6ef90996a7d80b6f64a226e5958ae [^]
2014-06-27 16:50hgbotCheckin
2014-06-27 16:50hgbotNote Added: 0068422
2014-06-27 16:50marvintmReview Assigned To => marvintm
2014-06-27 16:50marvintmStatusresolved => closed
2014-06-27 16:50marvintmFixed in Version => RR14Q3
2016-04-28 17:09VictorVillarRelationship addedrelated to 0032777

Notes
(0068324)
hgbot   
2014-06-26 00:06   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 7b35aae163e6ef90996a7d80b6f64a226e5958ae
Author: Salvador Zapata <salvador.zapata <at> gmail.com>
Date: Wed Jun 25 18:47:04 2014 -0300
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/7b35aae163e6ef90996a7d80b6f64a226e5958ae [^]

fixed issue 26217: customer data came from bp now except address

---
M src/org/openbravo/retail/posterminal/OrderLoader.java
---
(0068422)
hgbot   
2014-06-27 16:50   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 409cef1f6b5c8e9d47aaef5bb0316395b6807ecf
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Fri Jun 27 16:50:17 2014 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/409cef1f6b5c8e9d47aaef5bb0316395b6807ecf [^]

Related to issue 26217. Improved efficiency a bit by avoiding additional OBDal.get

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