details: https://code.openbravo.com/erp/devel/pi/rev/ca3b550183cb changeset: 20149:ca3b550183cb user: David Miguelez <david.miguelez <at> openbravo.com> date: Fri Apr 19 14:10:40 2013 +0200 summary: Fixes Issue 23583. When the C_Invoice_Post Process fails, it returns an error message without doing more actions.
details: https://code.openbravo.com/erp/devel/pi/rev/3f93afd1a9f2 changeset: 20150:3f93afd1a9f2 user: David Miguelez <david.miguelez <at> openbravo.com> date: Fri Apr 19 14:11:18 2013 +0200 summary: Fixes Issue 23591: It prevents from querying a large list without any filters. diffstat: modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/ProcessInvoice.java | 1 + modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/dao/AdvPaymentMngtDao.java | 17 +++++---- 2 files changed, 10 insertions(+), 8 deletions(-) diffs (40 lines): diff -r 9534810b6032 -r 3f93afd1a9f2 modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/ProcessInvoice.java --- a/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/ProcessInvoice.java Tue Apr 16 10:32:29 2013 +0200 +++ b/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/ad_actionbutton/ProcessInvoice.java Fri Apr 19 14:11:18 2013 +0200 @@ -200,6 +200,7 @@ if (strWindowPath.equals("")) strWindowPath = strDefaultServlet; printPageClosePopUp(response, vars, strWindowPath); + return; } } finally { OBContext.restorePreviousMode(); diff -r 9534810b6032 -r 3f93afd1a9f2 modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/dao/AdvPaymentMngtDao.java --- a/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/dao/AdvPaymentMngtDao.java Tue Apr 16 10:32:29 2013 +0200 +++ b/modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/dao/AdvPaymentMngtDao.java Fri Apr 19 14:11:18 2013 +0200 @@ -1813,16 +1813,17 @@ strInvoiceId).getFINPaymentScheduleList(); OBCriteria<FIN_PaymentScheduleDetail> psdCriteria = OBDal.getInstance().createCriteria( FIN_PaymentScheduleDetail.class); - if (!paySchedList.isEmpty()) + if (!paySchedList.isEmpty()) { psdCriteria.add(Restrictions.in(FIN_PaymentScheduleDetail.PROPERTY_INVOICEPAYMENTSCHEDULE, paySchedList)); - for (FIN_PaymentScheduleDetail psd : psdCriteria.list()) { - if (psd.getPaymentDetails() != null) { - FIN_Payment payment = psd.getPaymentDetails().getFinPayment(); - if ("RPAE".equals(payment.getStatus()) - && hasNotDeferredExecutionProcess(payment.getAccount(), payment.getPaymentMethod(), - payment.isReceipt())) - payments.add(payment); + for (FIN_PaymentScheduleDetail psd : psdCriteria.list()) { + if (psd.getPaymentDetails() != null) { + FIN_Payment payment = psd.getPaymentDetails().getFinPayment(); + if ("RPAE".equals(payment.getStatus()) + && hasNotDeferredExecutionProcess(payment.getAccount(), payment.getPaymentMethod(), + payment.isReceipt())) + payments.add(payment); + } } } ------------------------------------------------------------------------------ Precog is a next-generation analytics platform capable of advanced analytics on semi-structured data. The platform includes APIs for building apps and a phenomenal toolset for data science. Developers can use our toolset for easy data analysis & visualization. Get a free account! http://www2.precog.com/precogplatform/slashdotnewsletter _______________________________________________ Openbravo-commits mailing list Openbravo-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbravo-commits