details:   https://code.openbravo.com/erp/devel/pi/rev/2e2ef063c7dd
changeset: 26383:2e2ef063c7dd
user:      Jorge Garcia <jorge.garcia <at> openbravo.com>
date:      Mon Mar 02 11:02:02 2015 +0100
summary:   Fixed issue 29091: Fully depreciated field is not updated

The process didn't update the Fully Depreciated field when one or more
asset amortization lines were unprocessed.

The problem was in the amortization process.

Now the process changes the isFullyDepreciated field if the Depreciated
Value and the Depreciated Plan fields are differents.

details:   https://code.openbravo.com/erp/devel/pi/rev/4d152114fbe9
changeset: 26384:4d152114fbe9
user:      Unai Martirena <unai.martirena <at> openbravo.com>
date:      Wed Apr 29 10:22:24 2015 +0200
summary:   Related to bug 29091: Code Review

[1]: Fix copyright
[2]: Change != for <>

diffstat:

 src-db/database/model/functions/A_AMORTIZATION_PROCESS.xml |  5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diffs (22 lines):

diff -r 1bd95ea2cdb4 -r 4d152114fbe9 
src-db/database/model/functions/A_AMORTIZATION_PROCESS.xml
--- a/src-db/database/model/functions/A_AMORTIZATION_PROCESS.xml        Wed Apr 
29 08:55:42 2015 +0200
+++ b/src-db/database/model/functions/A_AMORTIZATION_PROCESS.xml        Wed Apr 
29 10:22:24 2015 +0200
@@ -16,7 +16,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-2013 Openbravo SLU
+* All portions are Copyright (C) 2001-2015 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -150,6 +150,9 @@
       UPDATE a_asset
         SET IsFullyDepreciated='Y',Updated=now(),UpdatedBy=v_AD_User_ID
       WHERE COALESCE(DepreciatedPlan, -1)=COALESCE(DepreciatedValue, -2) ;
+      UPDATE a_asset
+        SET IsFullyDepreciated='N',Updated=now(),UpdatedBy=v_AD_User_ID
+      WHERE DepreciatedPlan<>DepreciatedValue;
     END IF;
     --<<FINISH_PROCESS>>
     IF(p_PInstance_ID IS NOT NULL) THEN

------------------------------------------------------------------------------
One dashboard for servers and applications across Physical-Virtual-Cloud 
Widest out-of-the-box monitoring support with 50+ applications
Performance metrics, stats and reports that give you Actionable Insights
Deep dive visibility with transaction tracing using APM Insight.
http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to