details: https://code.openbravo.com/erp/devel/pi/rev/e47262bb76d3
changeset: 32712:e47262bb76d3
user: Armaignac <collazoandy4 <at> gmail.com>
date: Tue Jul 25 17:45:37 2017 -0400
summary: Fixes issue 32861: Product search key should be included in the
error message
shown in the Costing Background Process log
The Product search key was included in the exception message to properly
identified
the product causing the error.
diffstat:
src/org/openbravo/costing/CostingAlgorithm.java | 4 ++--
src/org/openbravo/costing/CostingUtils.java | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diffs (26 lines):
diff -r 95e47d6f312c -r e47262bb76d3
src/org/openbravo/costing/CostingAlgorithm.java
--- a/src/org/openbravo/costing/CostingAlgorithm.java Fri Jul 21 13:17:58
2017 -0400
+++ b/src/org/openbravo/costing/CostingAlgorithm.java Tue Jul 25 17:45:37
2017 -0400
@@ -284,8 +284,8 @@
if (stdCost == null && pp == null && orderLine == null) {
throw new OBException("@NoPriceListOrStandardCostForProduct@
@Organization@: "
- + costOrg.getName() + ", @Product@: " +
transaction.getProduct().getName() + ", @Date@: "
- + OBDateUtils.formatDate(transaction.getTransactionProcessDate()));
+ + costOrg.getName() + ", @Product@: " +
transaction.getProduct().getSearchKey()
+ + ", @Date@: " +
OBDateUtils.formatDate(transaction.getTransactionProcessDate()));
}
Date stdCostDate = new Date(0L);
if (stdCost != null) {
diff -r 95e47d6f312c -r e47262bb76d3 src/org/openbravo/costing/CostingUtils.java
--- a/src/org/openbravo/costing/CostingUtils.java Fri Jul 21 13:17:58
2017 -0400
+++ b/src/org/openbravo/costing/CostingUtils.java Tue Jul 25 17:45:37
2017 -0400
@@ -160,7 +160,7 @@
false, false);
if (stdCost == null && pp == null) {
throw new OBException("@NoPriceListOrStandardCostForProduct@
@Organization@: "
- + org.getName() + ", @Product@: " + product.getName() + ", @Date@: "
+ + org.getName() + ", @Product@: " + product.getSearchKey() + ",
@Date@: "
+ OBDateUtils.formatDate(costDate));
} else if (stdCost != null && pp == null) {
BigDecimal standardCost = getStandardCost(product, org, costDate,
costDimensions, currency);
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits