details:   https://code.openbravo.com/erp/devel/pi/rev/1de5f88e8ae4
changeset: 34475:1de5f88e8ae4
user:      Atul Gaware <atul.gaware <at> openbravo.com>
date:      Tue Jul 31 00:08:23 2018 +0530
summary:   Fixes Issue 38932:Wrong date in Costing tab when manually
adjusting a stock decrease: ending date is prior to
starting date

** Use transaction process date instead of current date
to create costing register

diffstat:

 src/org/openbravo/costing/AverageCostAdjustment.java |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 85528f7d08b4 -r 1de5f88e8ae4 
src/org/openbravo/costing/AverageCostAdjustment.java
--- a/src/org/openbravo/costing/AverageCostAdjustment.java      Tue Jul 31 
19:09:32 2018 +0200
+++ b/src/org/openbravo/costing/AverageCostAdjustment.java      Tue Jul 31 
00:08:23 2018 +0530
@@ -178,7 +178,7 @@
             cost.toPlainString());
       }
       if (basetrx.getMaterialMgmtCostingList().isEmpty()) {
-        Date newDate = new Date();
+        Date newDate = basetrx.getTransactionProcessDate();
         Date dateTo = costing.getEndingDate();
         costing.setEndingDate(newDate);
         Costing newCosting = OBProvider.getInstance().get(Costing.class);

------------------------------------------------------------------------------
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
Openbravo-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to