Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0047610 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Retail Modules] Web POS | trivial | have not tried | 2021-08-31 14:54 | 2021-09-01 11:14 | |||
Reporter | alostale | View Status | public | |||||
Assigned To | alostale | |||||||
Priority | normal | Resolution | fixed | Fixed in Version | RR21Q4 | |||
Status | closed | Fix in branch | Fixed in SCM revision | |||||
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 | approved | |||||||
Review Assigned To | ||||||||
OBNetwork customer | No | |||||||
Support ticket | ||||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0047610: Simplify HQLProperty API adding convenient factory methods | |||||||
Description | The Java API to extend masterdata models [1] is quite verbose:return Arrays.asList( new HQLProperty("product.weight", "weight"), new HQLProperty("product.taxCategory.name", "taxcategoryname")); It could be simplified using static factory methods similar to JDK's Map.ofEntries [2] and Map.entry [3]. To something like: import static org.openbravo.mobile.core.model.HQLProperty.property; ... return HQLProperty.listOfProperties( property("product.weight", "weight"), property("product.taxCategory.name", "taxcategoryname")); [1] http://wiki.openbravo.com/wiki/How_to_Extend_Models [^] [2] https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Map.html#ofEntries(java.util.Map.Entry...) [^] [3] https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Map.html#entry(K,V) [^] | |||||||
Steps To Reproduce | - | |||||||
Tags | No tags attached. | |||||||
Attached Files | ||||||||
![]() |
|
![]() |
|
(0131469) hgbot (developer) 2021-09-01 08:03 |
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core/-/merge_requests/280 [^] |
(0131470) hgbot (developer) 2021-09-01 11:14 |
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core/-/merge_requests/280 [^] |
(0131471) hgbot (developer) 2021-09-01 11:14 |
Directly closing issue as related merge request is already approved. Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core [^] Changeset: d66fff024b592ab6a4442ea216f5f05e1cd85251 Author: Asier Lostalé <asier.lostale@openbravo.com> Date: 2021-09-01T08:02:17+02:00 URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.mobile.core/-/commit/d66fff024b592ab6a4442ea216f5f05e1cd85251 [^] fixed FR-47610: simplify HQLProperty API adding convenient factory methods Adds property(String hqlProperty, String jsonName) for the most common constructor and listOfProperties(HQLProperty... properties) to be used from ModelExtension.getHQLProperties. --- M src/org/openbravo/mobile/core/model/HQLProperty.java --- |
![]() |
|||
Date Modified | Username | Field | Change |
2021-08-31 14:54 | alostale | New Issue | |
2021-08-31 14:54 | alostale | Assigned To | => Retail |
2021-08-31 14:54 | alostale | OBNetwork customer | => No |
2021-08-31 14:54 | alostale | Triggers an Emergency Pack | => No |
2021-09-01 08:03 | hgbot | Merge Request Status | => open |
2021-09-01 08:03 | hgbot | Note Added: 0131469 | |
2021-09-01 11:11 | hgbot | Merge Request Status | open => approved |
2021-09-01 11:14 | hgbot | Resolution | open => fixed |
2021-09-01 11:14 | hgbot | Status | new => closed |
2021-09-01 11:14 | hgbot | Note Added: 0131470 | |
2021-09-01 11:14 | hgbot | Fixed in Version | => RR21Q4 |
2021-09-01 11:14 | hgbot | Note Added: 0131471 | |
2021-09-01 11:14 | alostale | Assigned To | Retail => alostale |
Copyright © 2000 - 2009 MantisBT Group |