Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0043044Openbravo ERPA. Platformpublic2020-01-29 10:212020-02-07 10:48
inigo_lerga 
inigo_lerga 
normalminorhave not tried
closedfixed 
5
 
3.0PR20Q2 
dmiguelez
Core
No
0043044: Apply new HQL Style in CostingAlgorithmAdjustmentImp.java
CostingAlgorithmAdjustmentImp.java has two HQL queries with:
- the HQL is hard to read because of formatting
- and it is mixing txt and i.e PROPERTY_ID constant which is not recommended by default
-
Follow new format as in http://wiki.openbravo.com/wiki/HQL_Coding_Conventions [^]
No tags attached.
related to design defect 0041287 acknowledged Triage Platform Base Tracking issue: Convert HQL to apply new style 
related to defect 0043061 closed inigo_lerga Private functions not locally used in CostingAlgorithmAdjustmentImp.java 
Issue History
2020-01-29 10:21inigo_lergaNew Issue
2020-01-29 10:21inigo_lergaAssigned To => inigo_lerga
2020-01-29 10:21inigo_lergaModules => Core
2020-01-29 10:21inigo_lergaTriggers an Emergency Pack => No
2020-01-29 10:21inigo_lergaRelationship addedrelated to 0041287
2020-01-29 11:03inigo_lergaStatusnew => acknowledged
2020-01-29 11:03inigo_lergaStatusacknowledged => scheduled
2020-01-29 15:18inigo_lergaNote Added: 0117324
2020-01-30 09:49inigo_lergaRelationship addedrelated to 0043061
2020-02-07 10:46hgbotCheckin
2020-02-07 10:46hgbotNote Added: 0117548
2020-02-07 10:46hgbotStatusscheduled => resolved
2020-02-07 10:46hgbotResolutionopen => fixed
2020-02-07 10:46hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/93e16fd2b91833d4868763128b4297a4dbc4d853 [^]
2020-02-07 10:46hgbotCheckin
2020-02-07 10:46hgbotNote Added: 0117549
2020-02-07 10:48dmiguelezReview Assigned To => dmiguelez
2020-02-07 10:48dmiguelezNote Added: 0117550
2020-02-07 10:48dmiguelezStatusresolved => closed
2020-02-07 10:48dmiguelezFixed in Version => 3.0PR20Q2

Notes
(0117324)
inigo_lerga   
2020-01-29 15:18   
Test Plan Mantis HQL queries:
Execute the TestCosting.java JUnit tests.
#In this moment all the modified HQLs are executed#
(0117548)
hgbot   
2020-02-07 10:46   
Repository: erp/devel/pi
Changeset: 93e16fd2b91833d4868763128b4297a4dbc4d853
Author: IƱigo Lerga <inigo.lerga <at> openbravo.com>
Date: Wed Jan 29 15:55:25 2020 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/93e16fd2b91833d4868763128b4297a4dbc4d853 [^]

fixes BUG-43044:New HQL Style + minor Sonarlint suggestions

---
M src/org/openbravo/costing/CostingAlgorithmAdjustmentImp.java
---
(0117549)
hgbot   
2020-02-07 10:46   
Repository: erp/devel/pi
Changeset: 130c190966f38597a1773763e3470aa7f549f3a7
Author: David Miguelez <david.miguelez <at> openbravo.com>
Date: Fri Feb 07 10:46:06 2020 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/130c190966f38597a1773763e3470aa7f549f3a7 [^]

Related to ISSUE-43044. Code Review Changes:
  * Changed variable names to better reflect that they are referring to
    id's and not to the objects
  * Use id in hql query instead of object
  * In swithc-case statement, remove added breaks, as they were altering
    the originally intended logic

---
M src/org/openbravo/costing/CostingAlgorithmAdjustmentImp.java
---
(0117550)
dmiguelez   
2020-02-07 10:48   
Code Review + Testing ok