details:   /erp/devel/pi/rev/5707d6344e5f
changeset: 6712:5707d6344e5f
user:      Víctor Martínez Romanos <victor.martinez <at> openbravo.com>
date:      Mon Mar 15 13:32:53 2010 +0100
summary:   Fixed bug 12637: Major issue in Recalculate amortization

diffstat:

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

diffs (21 lines):

diff -r c6bbb3003e1d -r 5707d6344e5f 
src-db/database/model/functions/A_ASSET_POST.xml
--- a/src-db/database/model/functions/A_ASSET_POST.xml  Mon Mar 15 13:08:19 
2010 +0100
+++ b/src-db/database/model/functions/A_ASSET_POST.xml  Mon Mar 15 13:32:53 
2010 +0100
@@ -19,7 +19,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-2009 Openbravo SLU
+* All portions are Copyright (C) 2001-2010 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -181,7 +181,7 @@
           IF(NOT FINISH_PROCESS) THEN
             if v_AMORTIZATIONCALCTYPE='PE' then
               v_PercentageGeneral:=v_AMORTIZATIONPERCENTAGE;
-              v_UseLifeYears:=trunc(100/v_PercentageGeneral) ;
+              v_UseLifeYears:=ceil(100/v_PercentageGeneral) ;
             else
               --  v_PercentageGeneral := 100 / v_USELIFEYEARS;
               
v_PercentageGeneral:=((v_AMORTIZATIONVALUEAMT-v_DEPRECIATEDPREVIOUSAMT-v_depreciatedPlan)
 *100/v_AMORTIZATIONVALUEAMT) /(v_USELIFEYEARS-v_DepreciatedLines) ;

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to