Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0042725Openbravo ERPA. Platformpublic2020-01-08 10:302020-03-20 17:54
inigo_lerga 
inigo_lerga 
normalminoralways
closedfixed 
5
 
3.0PR20Q2 
dmiguelez
Core
No
0042725: Apply new HQL Style in AddPaymentActionHandler.java
AddPaymentActionHandler.java has one HQL query 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 
Issue History
2020-01-08 10:30inigo_lergaNew Issue
2020-01-08 10:30inigo_lergaAssigned To => inigo_lerga
2020-01-08 10:30inigo_lergaModules => Core
2020-01-08 10:30inigo_lergaTriggers an Emergency Pack => No
2020-01-08 10:30inigo_lergaStatusnew => scheduled
2020-01-08 10:31inigo_lergaRelationship addedrelated to 0041287
2020-01-08 13:19inigo_lergaNote Added: 0116691
2020-01-08 13:25inigo_lergaSummaryApply new HQL Style => Apply new HQL Style in AddPaymentActionHandler.java
2020-01-08 13:25inigo_lergaDescription Updatedbug_revision_view_page.php?rev_id=20040#r20040
2020-01-08 14:02inigo_lergaDescription Updatedbug_revision_view_page.php?rev_id=20048#r20048
2020-01-09 16:18dmiguelezNote Added: 0116734
2020-01-10 08:08hgbotCheckin
2020-01-10 08:08hgbotNote Added: 0116747
2020-01-10 08:08hgbotCheckin
2020-01-10 08:08hgbotNote Added: 0116748
2020-01-10 08:09dmiguelezStatusscheduled => resolved
2020-01-10 08:09dmiguelezFixed in Version => 3.0PR20Q2
2020-01-10 08:09dmiguelezFixed in SCM revision => https://code.openbravo.com/erp/devel/pi/rev/7a262a5840ecb229574906e57dafc36176968fe0 [^]
2020-01-10 08:09dmiguelezResolutionopen => fixed
2020-01-10 08:09dmiguelezReview Assigned To => dmiguelez
2020-01-10 08:09dmiguelezNote Added: 0116749
2020-01-10 08:09dmiguelezStatusresolved => closed
2020-03-20 17:54hudsonbotCheckin
2020-03-20 17:54hudsonbotNote Added: 0118725
2020-03-20 17:54hudsonbotCheckin
2020-03-20 17:54hudsonbotNote Added: 0118726

Notes
(0116691)
inigo_lerga   
2020-01-08 13:19   
Test Plan Mantis:
As the F&B International Group Admin role:
    - Go to Sales Order Window and create a
      new record. Select any Business Partner.
    - Go to Lines Tab and create a new line
      with any product and quantity.
    - Save and press the Book button of
      the Sales Order.
    - Press the Add Payment button.
    - Inside the popup window named Add Payment
      press the Done button.
    #In this moment the modified hql query is executed#
(0116734)
dmiguelez   
2020-01-09 16:18   
Test Plan II

Go to Payment In Window and create a new record with:
  * Organization: F&B España - Región Norte
  * Received From: Alimentos y Supermercados
  * Amount: 100
Click on Add Details Button.
In the Totals section, select 'Leave the credit to be used later' as the Overpayment Action and click on Done.

Create another record with:
  * Organization: F&B España - Región Norte
  * Received From: Alimentos y Supermercados
  * Amount: 0
Click on Add Details Button.
In the GL Items section click on Add New to create a new record with:
  * G/L Item: Capital Social
  * Business Partner: Alimentos y Supermercados
  * Received In: 100
In the Credit to Use section select the record related to the previous payment
Click on Done.
In the Lines, check in the Dimensions section that the Business Partner dimension has the value 'Alimentos y Supermercados'
(0116747)
hgbot   
2020-01-10 08:08   
Repository: erp/devel/pi
Changeset: 7a262a5840ecb229574906e57dafc36176968fe0
Author: Iñigo Lerga <inigo.lerga <at> openbravo.com>
Date: Wed Jan 08 11:23:28 2020 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/7a262a5840ecb229574906e57dafc36176968fe0 [^]

Related to Issue 42725: Applied new HQL Style and SonarLint suggestions

---
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/actionHandler/AddPaymentActionHandler.java
---
(0116748)
hgbot   
2020-01-10 08:08   
Repository: erp/devel/pi
Changeset: 774394e7fee9d65251ccc0f12205309ad121e23f
Author: David Miguelez <david.miguelez <at> openbravo.com>
Date: Thu Jan 09 15:57:31 2020 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/774394e7fee9d65251ccc0f12205309ad121e23f [^]

Related to Issue 42725: Code Review changes
  * Reorder modifiers of class variable
  * Split fullPaydAndHasNegativeLines into two independant methods
    to make code more redable
  * Rename method accountDimension to getAccountDimension and send the class
    as a parameter to properly retrieve the desired BaseOBObject
  * Add final modifiers to variables and parameters

---
M modules/org.openbravo.advpaymentmngt/src/org/openbravo/advpaymentmngt/actionHandler/AddPaymentActionHandler.java
---
(0116749)
dmiguelez   
2020-01-10 08:09   
Code Review + Testing Ok
(0118725)
hudsonbot   
2020-03-20 17:54   
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/b31620115262 [^]
Maturity status: Test
(0118726)
hudsonbot   
2020-03-20 17:54   
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/b31620115262 [^]
Maturity status: Test