[OpenbravoERP-commits] devel/pi: Fixed issue 40370: Problem saving record in grid mode ...
details: https://code.openbravo.com/erp/devel/pi/rev/a0588dfa7203 changeset: 35558:a0588dfa7203 user: Javier Armendáriz openbravo.com> date: Mon Mar 25 16:38:38 2019 +0100 summary: Fixed issue 40370: Problem saving record in grid mode with summary function. This patch prevents the update of editor value while fetching the summary row and the entry is still in edit mode, even though the entry is already saved. diffstat: modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-view-grid.js | 5 + 1 files changed, 5 insertions(+), 0 deletions(-) diffs (23 lines): diff -r b76c05056de5 -r a0588dfa7203 modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-view-grid.js --- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-view-grid.js Tue Mar 26 08:54:44 2019 +0100 +++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-view-grid.js Mon Mar 25 16:38:38 2019 +0100 @@ -1295,7 +1295,9 @@ if (summary) { config.params = config.params || {}; config.params._summary = summary; + this.fetchingSummaryRow = true; config.params = this.getFetchRequestParams(config.params); + delete this.fetchingSummaryRow; } return config; }, @@ -3869,6 +3871,9 @@ // requests // https://issues.openbravo.com/view.php?id=16611 storeUpdatedEditorValue: function (suppressChange, editCol) { +if (this.fetchingSummaryRow) { + return; +} this._storingUpdatedEditorValue = true; this._preventDateParsing = true; this.Super('storeUpdatedEditorValue', arguments); ___ Openbravo-commits mailing list Openbravo-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbravo-commits
[OpenbravoERP-commits] devel/pi: related to bug 40303: improved DataEntityQueryService ...
details: https://code.openbravo.com/erp/devel/pi/rev/b76c05056de5 changeset: 35557:b76c05056de5 user: Asier Lostalé openbravo.com> date: Tue Mar 26 08:54:44 2019 +0100 summary: related to bug 40303: improved DataEntityQueryService log for array params diffstat: modules/org.openbravo.service.json/src/org/openbravo/service/json/DataEntityQueryService.java | 13 ++--- 1 files changed, 8 insertions(+), 5 deletions(-) diffs (30 lines): diff -r 934b1ac98038 -r b76c05056de5 modules/org.openbravo.service.json/src/org/openbravo/service/json/DataEntityQueryService.java --- a/modules/org.openbravo.service.json/src/org/openbravo/service/json/DataEntityQueryService.java Fri Mar 22 00:44:46 2019 +0530 +++ b/modules/org.openbravo.service.json/src/org/openbravo/service/json/DataEntityQueryService.java Tue Mar 26 08:54:44 2019 +0100 @@ -19,6 +19,7 @@ package org.openbravo.service.json; import java.util.ArrayList; +import java.util.Arrays; import java.util.Iterator; import java.util.List; import java.util.stream.Collectors; @@ -153,11 +154,13 @@ obq.setFilterOnActive(isFilterOnActive()); log.debug("Setting params:\n{}", -() -> queryBuilder.getNamedParameters() -.entrySet() -.stream() -.map(e -> " -" + e.getKey() + ": " + e.getValue()) -.collect(Collectors.joining("\n"))); +() -> queryBuilder.getNamedParameters().entrySet().stream().map(e -> { + Object v = e.getValue(); + if (v instanceof Object[]) { +v = Arrays.asList((Object[]) v); + } + return " -" + e.getKey() + ": " + v; +}).collect(Collectors.joining("\n"))); obq.setNamedParameters(queryBuilder.getNamedParameters()); ___ Openbravo-commits mailing list Openbravo-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbravo-commits
[OpenbravoERP-commits] devel/pi: Fixes issue 40392: Can't modify an invoice payment pla...
details: https://code.openbravo.com/erp/devel/pi/rev/a121302dfba6 changeset: 35559:a121302dfba6 user: Mark Molina doceleguas.com> date: Mon Mar 18 18:27:33 2019 -0300 summary: Fixes issue 40392: Can't modify an invoice payment plan if it's already modified This solution takes into account all the Payment Plan lines when calculating that modified outstanding amounts are modified. Also, all the payment plan expected amounts are updated if the sum of the updated outstandings amounts are equals than original outstanding amount of the invoice instead of just update the last record. Also when a new record is added are taken into account all the lines and the new outstanding amount is calculated by subtract to the total expected the total already paid and the total outstanding in the existing lines. diffstat: modules/org.openbravo.advpaymentmngt/web/org.openbravo.advpaymentmngt/js/ob-aprm-utilities.js | 21 ++--- 1 files changed, 14 insertions(+), 7 deletions(-) diffs (51 lines): diff -r a0588dfa7203 -r a121302dfba6 modules/org.openbravo.advpaymentmngt/web/org.openbravo.advpaymentmngt/js/ob-aprm-utilities.js --- a/modules/org.openbravo.advpaymentmngt/web/org.openbravo.advpaymentmngt/js/ob-aprm-utilities.js Mon Mar 25 16:38:38 2019 +0100 +++ b/modules/org.openbravo.advpaymentmngt/web/org.openbravo.advpaymentmngt/js/ob-aprm-utilities.js Mon Mar 18 18:27:33 2019 -0300 @@ -11,7 +11,7 @@ * under the License. * The Original Code is Openbravo ERP. * The Initial Developer of the Original Code is Openbravo SLU - * All portions are Copyright (C) 2011-2015 Openbravo SLU + * All portions are Copyright (C) 2011-2019 Openbravo SLU * All Rights Reserved. * Contributor(s): __. @@ -73,10 +73,13 @@ totalOutstanding = totalOutstanding.add(new BigDecimal(String(row.outstanding))); totalReceived = totalReceived.add(new BigDecimal(String(row.received))); } - row.expected = Number(new BigDecimal(String(row.outstanding)).add(new BigDecimal(String(row.received; - if (totalOutstanding.abs().compareTo(invoiceOutstanding.abs()) !== 0) { + if (totalOutstanding.abs().compareTo(totalExpected.subtract(totalReceived).abs()) !== 0) { return false; } + for (indRow = 0; indRow < allRows.length; indRow++) { +row = allRows[indRow]; +row.expected = Number(new BigDecimal(String(row.outstanding)).add(new BigDecimal(String(row.received; + } if (new BigDecimal(String(record.awaitingExecutionAmount)).abs().compareTo(new BigDecimal(String(record.outstanding)).abs()) > 0) { if (!OB.APRM.validateMPPUserWarnedAwaiting) { OB.APRM.validateMPPUserWarnedAwaiting = true; @@ -153,14 +156,18 @@ OB.APRM.addNew = function (grid) { var selectedRecord = grid.view.parentWindow.views[0].getParentRecord(), - allRows = grid.data.allRows || grid.data.localData; + allRows = grid.data.allRows || grid.data.localData, + totalExpected = new BigDecimal("0"), + totalReceived = new BigDecimal("0"); var returnObject = isc.addProperties({}, allRows[0]); - var indRow, row, totalOutstanding = new BigDecimal("0"); + var indRow, row, totalOutstandingInOthers = new BigDecimal("0"); for (indRow = 0; indRow < allRows.length; indRow++) { row = allRows[indRow]; -totalOutstanding = totalOutstanding.add(new BigDecimal(String(row.outstanding))); +totalOutstandingInOthers = totalOutstandingInOthers.add(new BigDecimal(String(row.outstanding))); +totalExpected = totalExpected.add(new BigDecimal(String(row.expected))); +totalReceived = totalReceived.add(new BigDecimal(String(row.received))); } - returnObject.outstanding = Number(new BigDecimal(String(grid.view.parentWindow.activeView.getContextInfo(false, true, true, false).inpoutstandingamt)).subtract(totalOutstanding)); + returnObject.outstanding = Number(totalExpected.subtract(totalReceived).subtract(totalOutstandingInOthers)); returnObject.received = 0; returnObject.expected = 0; returnObject.awaitingExecutionAmount = 0; ___ Openbravo-commits mailing list Openbravo-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbravo-commits
[OpenbravoERP-commits] devel/pi: Fixes issue 40333: Advance Filters in Trial Balance is...
details: https://code.openbravo.com/erp/devel/pi/rev/8fef3f886c45 changeset: 35560:8fef3f886c45 user: Mark Molina doceleguas.com> date: Mon Mar 25 22:17:37 2019 -0300 summary: Fixes issue 40333: Advance Filters in Trial Balance is not working The account from/to filters should be shown just if the Account Level filter is "Subaccount" in any other case it should be hidden as they are used in the report just for this particular case. The display logic of this section/fields was incorrect defined because after a previous search it was setting as TRUE to display the fields if the Advanced Filters section is expanded, but it might take into account also the display logic explained before asking if the selected account level is "Subaccount". When the Advanced filters section is expanded then these fields will be hidden if the selected Account level is different than "Subaccount" diffstat: src/org/openbravo/erpCommon/ad_reports/ReportTrialBalance.html | 5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diffs (27 lines): diff -r a121302dfba6 -r 8fef3f886c45 src/org/openbravo/erpCommon/ad_reports/ReportTrialBalance.html --- a/src/org/openbravo/erpCommon/ad_reports/ReportTrialBalance.htmlMon Mar 18 18:27:33 2019 -0300 +++ b/src/org/openbravo/erpCommon/ad_reports/ReportTrialBalance.htmlMon Mar 25 22:17:37 2019 -0300 @@ -13,7 +13,7 @@ * under the License. * The Original Code is Openbravo ERP. * The Initial Developer of the Original Code is Openbravo SLU - * All portions are Copyright (C) 2001-2016 Openbravo SLU + * All portions are Copyright (C) 2001-2019 Openbravo SLU * All Rights Reserved. * Contributor(s): __. @@ -77,13 +77,12 @@ if (advancedFiltersrow1.style.display == 'none') { displayLogicElement('advancedFiltersrow1', true); displayLogicElement('advancedFiltersrow2', true); -displayLogicElement('AcctFromTo', true); +displayLogicElement('AcctFromTo', (inputValue(document.frmMain.inpLevel) == 'S')); } else{ displayLogicElement('advancedFiltersrow1', false); displayLogicElement('advancedFiltersrow2', false); displayLogicElement('AcctFromTo', false); - } } ___ Openbravo-commits mailing list Openbravo-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbravo-commits
[OpenbravoERP-commits] devel/pi: Fixes Issue 0039304: [SERQA 4539]: It would be nice ha...
details: https://code.openbravo.com/erp/devel/pi/rev/e7e49fefcf93 changeset: 35561:e7e49fefcf93 user: Atul Gaware openbravo.com> date: Thu Mar 07 19:03:09 2019 +0530 summary: Fixes Issue 0039304: [SERQA 4539]: It would be nice have partial indexes for REPLACEDORDER_ID and REPLACEMENTORDER_ID columns in c_order table ** Added partial indexes for columns REPLACEDORDER_ID and REPLACEMENTORDER_ID in C_Order table. diffstat: src-db/database/model/tables/C_ORDER.xml | 8 1 files changed, 8 insertions(+), 0 deletions(-) diffs (18 lines): diff -r 8fef3f886c45 -r e7e49fefcf93 src-db/database/model/tables/C_ORDER.xml --- a/src-db/database/model/tables/C_ORDER.xml Mon Mar 25 22:17:37 2019 -0300 +++ b/src-db/database/model/tables/C_ORDER.xml Thu Mar 07 19:03:09 2019 +0530 @@ -507,6 +507,14 @@ + + + + + + + + ___ Openbravo-commits mailing list Openbravo-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbravo-commits