Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0032280 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] 09. Financial management | major | always | 2016-02-18 17:34 | 2016-03-17 10:56 | |||
Reporter | ngarcia | View Status | public | |||||
Assigned To | AtulOpenbravo | |||||||
Priority | urgent | Resolution | fixed | Fixed in Version | ||||
Status | closed | Fix in branch | Fixed in SCM revision | 216fb4e6048c | ||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | SCM revision | |||||||
Merge Request Status | ||||||||
Review Assigned To | vmromanos | |||||||
OBNetwork customer | OBPS | |||||||
Web browser | ||||||||
Modules | Core | |||||||
Support ticket | 40729 | |||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0032280: Amortization Process / Unprocess should only update Fully Depreciated field of the assets included on it and need the update | |||||||
Description | Amortization Process / Unprocess should only update Fully Depreciated field of the assets included on it and need the update. Currently it is updating all of them | |||||||
Steps To Reproduce | As group admin role: Create three assets: Depreciated, NotDepreciated and Amortized Configure the depreciation of Depreciated and Amortized and create its amortization Update through database the IsFullyDepreciated to 'N' to the NotDepreciated asset (in order to see the update done by the process) Update through database the IsFullyDepreciated to 'Y' to the Depreciated asset (in order to see the update done by the process) Navigate to the amortization of one of the lines of the Amortized asset Process it and check the IsFullyDepreciated field has changed for the other two assets: Depreciated ('N') and Not Depreciated ('Y') | |||||||
Proposed Solution | Add a filter to the following two updates to update only the assets included in the amortization being processed and also to update the ones that have different value in the isfullydepreciated field than the one set: UPDATE a_asset SET IsFullyDepreciated='Y',Updated=TO_DATE(NOW()),UpdatedBy='100' WHERE COALESCE(DepreciatedPlan, -1)=COALESCE(DepreciatedValue, -2) ; UPDATE a_asset SET IsFullyDepreciated='N',Updated=TO_DATE(NOW()),UpdatedBy='100' WHERE DepreciatedPlan<>DepreciatedValue; | |||||||
Tags | No tags attached. | |||||||
Attached Files | ||||||||
![]() |
||||||||
|
![]() |
|
(0084419) AtulOpenbravo (viewer) 2016-02-23 11:38 edited on: 2016-02-23 11:38 |
Test Plan - Login as F&B International Group admin role. - Create three assets: Depreciated, NotDepreciated and Amortized - Configure the depreciation of Depreciated and Amortized and create its amortization. - Update through database the IsFullyDepreciated to 'N' to the NotDepreciated asset (in order to see the update done by the process). - Update through database the IsFullyDepreciated to 'Y' to the Depreciated asset (in order to see the update done by the process). - Navigate to the amortization of one of the lines of the Amortized asset. - Process it. - Check the IsFullyDepreciated field for "Not Depreciated" asset is not updated and it is same as ('N') previous value. |
(0084453) psanjuan (viewer) 2016-02-24 09:55 |
Issue Verified. |
(0084454) psanjuan (viewer) 2016-02-24 10:21 edited on: 2016-02-24 10:22 |
Test Plan above verified Values does not change now in the database, after running amortization for other assets than 2 ones below. select value, isfullydepreciated, depreciatedplan, depreciatedvalue, updated from a_asset where a_asset_id in ('EE21580379FB4D5889059A46A6DE59FF', '221DB1350A974132930164537D8B81D2') update a_asset set isfullydepreciated = 'N' where a_asset_id = 'EE21580379FB4D5889059A46A6DE59FF' update a_asset set isfullydepreciated = 'Y' where a_asset_id = '221DB1350A974132930164537D8B81D2' Records keep as: "NotDepreciated";"N";0;0 "Depreciated";"Y";10000;0 Issue can be code reviewed and closed. |
(0084466) hgbot (developer) 2016-02-24 15:33 |
Repository: erp/devel/pi Changeset: 216fb4e6048c4546b3ade9e36c58dc27f810d900 Author: Atul Gaware <atul.gaware <at> openbravo.com> Date: Tue Feb 23 16:05:13 2016 +0530 URL: http://code.openbravo.com/erp/devel/pi/rev/216fb4e6048c4546b3ade9e36c58dc27f810d900 [^] Fixes Issue 32280:Amortization Process / Unprocess should only update Fully Depreciated field of the assets included on it and need the update Condition added in update query to only update those assets record on which amortization process is being called --- M src-db/database/model/functions/A_AMORTIZATION_PROCESS.xml --- |
(0084467) vmromanos (viewer) 2016-02-24 15:33 |
Code review + testing OK |
(0085166) hudsonbot (viewer) 2016-03-17 10:56 |
A changeset related to this issue has been promoted main and to the Central Repository, after passing a series of tests. Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/b22fb0500156 [^] Maturity status: Test |
![]() |
|||
Date Modified | Username | Field | Change |
2016-02-18 17:34 | ngarcia | New Issue | |
2016-02-18 17:34 | ngarcia | Assigned To | => Triage Finance |
2016-02-18 17:34 | ngarcia | OBNetwork customer | => Yes |
2016-02-18 17:34 | ngarcia | Modules | => Core |
2016-02-18 17:34 | ngarcia | Triggers an Emergency Pack | => No |
2016-02-18 17:34 | ngarcia | Issue Monitored: networkb | |
2016-02-18 17:35 | ngarcia | Support ticket | => 40729 |
2016-02-18 17:35 | ngarcia | Resolution time | => 1458774000 |
2016-02-18 17:44 | ngarcia | Relationship added | related to 0029091 |
2016-02-23 11:38 | AtulOpenbravo | Note Added: 0084419 | |
2016-02-23 11:38 | AtulOpenbravo | Note Edited: 0084419 | View Revisions |
2016-02-23 11:43 | AtulOpenbravo | Assigned To | Triage Finance => AtulOpenbravo |
2016-02-23 11:43 | AtulOpenbravo | Status | new => scheduled |
2016-02-24 09:55 | psanjuan | Note Added: 0084453 | |
2016-02-24 10:21 | psanjuan | Note Added: 0084454 | |
2016-02-24 10:22 | psanjuan | Note Edited: 0084454 | View Revisions |
2016-02-24 15:33 | hgbot | Checkin | |
2016-02-24 15:33 | hgbot | Note Added: 0084466 | |
2016-02-24 15:33 | hgbot | Status | scheduled => resolved |
2016-02-24 15:33 | hgbot | Resolution | open => fixed |
2016-02-24 15:33 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/216fb4e6048c4546b3ade9e36c58dc27f810d900 [^] |
2016-02-24 15:33 | vmromanos | Review Assigned To | => vmromanos |
2016-02-24 15:33 | vmromanos | Note Added: 0084467 | |
2016-02-24 15:33 | vmromanos | Status | resolved => closed |
2016-03-17 10:56 | hudsonbot | Checkin | |
2016-03-17 10:56 | hudsonbot | Note Added: 0085166 |
Copyright © 2000 - 2009 MantisBT Group |